Confused During Reshaping Array Of Image
At the moment I'm trying to run a ConvNet. Each image, which later feeds the neural net, is stored as a list. But the list is at the moment created using three for-loops. Have a lo
Solution 1:
One approach would be to transpose the axes, which is essentially flattening in fortran
mode i.e. reversed manner -
image = np.asarray(im, dtype="uint8")
image_representation = image.ravel('F').tolist()
For a closer look to the function have a look to the numpy.ravel documentation.
Post a Comment for "Confused During Reshaping Array Of Image"