error with pyroms.get_nc_Grid_HYCOM.py

Discussion about analysis, visualization, and collaboration tools and techniques

Moderators: arango, robertson

Post Reply
Message
Author
WANGQIAN
Posts: 8
Joined: Tue Aug 22, 2017 5:38 pm
Location: Second Institute of Oceanography

error with pyroms.get_nc_Grid_HYCOM.py

#1 Post by WANGQIAN » Sun Apr 08, 2018 12:34 pm

Hello everyone, when I use pyroms to make clim with the example named Palau_HYCOM,I meet a mistake like this:

File "make_clm.py", line 34, in <module>
src_grd = pyroms_toolbox.Grid_HYCOM.get_nc_Grid_HYCOM('/run/media/root/8E2A6BBD2A6BA0C7/data/HYCOM_SCS_grid.nc')
File "/opt/pyroms/lib/python3.6/site-packages/pyroms_toolbox/Grid_HYCOM/get_nc_Grid_HYCOM.py", line 44, in get_nc_Grid_HYCOM
bottom = int((nlev-1) - bottom)
TypeError: only size-1 arrays can be converted to Python scalars

I search in google, the error may be due to bottom is an array ,not a number.
Could anyone help me with this? Thanks in advance!
My python is Python 3.6.4 |Anaconda custom (64-bit). and my linux is centos7.
Wangqian

User avatar
kate
Posts: 3678
Joined: Wed Jul 02, 2003 5:29 pm
Location: IMS/UAF, USA

Re: error with pyroms.get_nc_Grid_HYCOM.py

#2 Post by kate » Sun Apr 08, 2018 4:01 pm

Sorry about that. I had cleaned up some of those, but not all. Do a "git pull" to get the fix.

WANGQIAN
Posts: 8
Joined: Tue Aug 22, 2017 5:38 pm
Location: Second Institute of Oceanography

Re: error with pyroms.get_nc_Grid_HYCOM.py

#3 Post by WANGQIAN » Mon Apr 09, 2018 1:47 pm

kate wrote:Sorry about that. I had cleaned up some of those, but not all. Do a "git pull" to get the fix.
It worked ! Thank you very much :D
WangQian

Post Reply