- #1
fog37
- 1,569
- 108
- TL;DR Summary
- 3D numpy array indices and array shape
Hello,
I am clear on 1D and 2D Numpy arrays, how to create them and address them).
I have a question about 3D arrays like the one below:
I would say that it is a 2x4x3 array but that is not correct when I use the command
. The result is (3,2,4). My understanding is that shape should give (row, column, layer). My interpretation is that it is a 3D array composed of 3 identical 2x4 2D arrays
The command shape seem have the first integer in the tuple (, , ) represents the number of layers of the 3D array instead..
Thanks for any advice.
I am clear on 1D and 2D Numpy arrays, how to create them and address them).
- 1D array: single list
- 2D array: list containing multiple lists as elements
- 3D array: list containing lists which contain lists as elements
I have a question about 3D arrays like the one below:
I would say that it is a 2x4x3 array but that is not correct when I use the command
Python:
array_example.shape
The command shape seem have the first integer in the tuple (, , ) represents the number of layers of the 3D array instead..
Thanks for any advice.
Last edited: