Thanks for the feedbacks.
I found this error when issuing w=VectorWind(u,v) where u and v are global winds from ERA-I, both being 2D slabs (lat, lon). It seems that when inputs are both 2D, line 93 in cdms.py gives this error because np.prod(u.shape[2:]) gives 1.0, thus making an numpy.float64 in the reshape arg.
My numpy is 1.13.3, windspharm 1.5.1
I guess a possible fix is to use np.prod(u.shape[2:]).astype('int')
Hi Andrew,
Thanks for the feedbacks. I found this error when issuing
w=VectorWind(u,v)
whereu
andv
are global winds from ERA-I, both being 2D slabs (lat, lon). It seems that when inputs are both 2D, line 93 incdms.py
gives this error becausenp.prod(u.shape[2:])
gives1.0
, thus making annumpy.float64
in the reshape arg.My numpy is 1.13.3, windspharm 1.5.1
I guess a possible fix is to use
np.prod(u.shape[2:]).astype('int')
Guangzhi