2019.6.7python the problem

When I appear 'list' object has no attribute 'shape' of the time list with a shape

python in the list, the conversion array of
the above list_temp is a list type, if you want to do some number crunching numpy, we need to convert it to array type.
Converted as follows:
Import numpy AS NP
list_temp = [[l, 2,3], [4,5,6]]
list_temp = np.array (list_temp)
Print list_temp

Guess you like

Origin blog.csdn.net/weixin_43732462/article/details/91125680