I am using python to read a netcdf dataset. I have installed netcdf and I am trying to read the data by typing, ncdump("sample.nc",header_only=0). And I get the below error: /bin/sh: 1: ncdump.exe: not found.
sample.nc is a netcdf file created using the following code:
from netCDF4 import Dataset
import numpy as np
sfile = Dataset('sample.nc',mode='w', format='NETCDF4')
Can anyone help me understand this error. I am quite new to this concept. Thanks
I had this problem today, and I came across your question during my research to solve my problem. You don't have the ncdump command installed most likely.
Download netCDF4.3.3.1-NC4-64.exe or the 32 bit version from the http://www.unidata.ucar.edu/software/netcdf/docs/winbin.html .
I installed them to my program files. Add the path to the ncdump commands to your system path. I believe they are located in the bin folder once you have run the install. My path was...
C:\\Program Files (x86)\\netCDF 4.3.3.1\\bin
Good Luck.
ncdump -h filename
in command prompt should work
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.