Installing NETCDF4 in windows using python 3.4

shalu.ashu50 at gmail.com shalu.ashu50 at gmail.com
Fri Apr 13 00:41:58 EDT 2018


Hi All,

I have downloaded NETCDF4 module from https://pypi.python.org/pypi/netCDF4 e.g. netCDF4-1.3.1-cp34-cp34m-win_amd64.whl

I have installed it using pip install netCDF4-1.3.1-cp34-cp34m-win_amd64.whl

through the command prompt in Spyder. It has successfully installed. 

C:\python3>pip install netCDF4-1.3.1-cp34-cp34m-win_amd64.whl
Processing c:\python3\netcdf4-1.3.1-cp34-cp34m-win_amd64.whl
Requirement already satisfied: numpy>=1.7 in c:\python3\winpython-64bit-3.4.4.5qt5\python-3.4.4.amd64\lib\site-packages (from netCDF4==1.3.1)
Installing collected packages: netCDF4
  Found existing installation: netCDF4 1.3.2
    Uninstalling netCDF4-1.3.2:
      Successfully uninstalled netCDF4-1.3.2
Successfully installed netCDF4-1.3.1


But when I am trying to import, it is giving an error:

import netCDF4 as nc4 Traceback (most recent call last):

File "", line 1, in import netCDF4 as nc4

File "C:\python3\WinPython-64bit-3.4.4.5Qt5\python-3.4.4.amd64\lib\site-packages\netCDF4__init__.py", line 3, in from ._netCDF4 import *

File "netCDF4_netCDF4.pyx", line 2988, in init netCDF4._netCDF4

AttributeError: type object 'netCDF4._netCDF4.Dimension' has no attribute 'reduce_cython'

How can I fix it? Suggestions would be appreciated.


More information about the Python-list mailing list