assert i[q] != ai and j[q] != aj
for Z in [X, f_X]:
- for k in range(1, nb_rec):
+ for k in range(0, nb_rec):
Z[i[k] : i[k] + delta, j[k] : j[k] + delta] = c[k]
# Z[i[0] + delta // 2 - 1, j[0] + delta // 2 - 1] = c[0]
# Z[i[0] + delta // 2 - 1, j[0] + delta // 2 + 1] = c[0]
# f_X[i[0] : i[0] + delta, j[0] : j[0] + delta] = c[q]
- # f_X[i[0] + delta // 2, j[0] + delta // 2] = c[q]
- f_X[i[0] : i[0] + delta, j[0] : j[0] + delta] = c[q]
+ f_X[i[0] + delta // 2, j[0] + delta // 2] = c[q]
+ # f_X[i[0] : i[0] + delta, j[0] : j[0] + delta] = c[q]
ii, jj = (
i[0] + delta // 2 + (i[q] - ai).sign().long(),