Код: Выделить всё
IndexError: only integers, slices (`:`), ellipsis (`...`), numpy.newaxis
(`None`) and integer or boolean arrays are valid indices.
Код: Выделить всё
def shuffle_bit_reversed_order(data: np.ndarray) -> np.ndarray:
x = data.size
n = x / 2
y = n * np.mod(x, 2)
data[x], data[y] = data[y], data[x]
return data
Подробнее здесь: https://stackoverflow.com/questions/349 ... and-intege