4

I am using PyCharm IDE and am unable to install 'cartopy'.
When I run the command `pip install cartopy' in the PyCharm terminal I receive the following error message:

Collecting cartopy
  Using cached https://files.pythonhosted.org/packages/e5/92/fe8838fa8158931906dfc4f16c5c1436b3dd2daf83592645b179581403ad/Cartopy-0.17.0.tar.gz
  Installing build dependencies ... done
  Getting requirements to build wheel ... error
  Complete output from command f:\python\python.exe f:\python\lib\site-packages\pip\_vendor\pep517\_in_process.py get_requires_for_build_wheel C:\Users\sagar\AppData\Local\Temp\tmpzriwmmff:
  setup.py:171: UserWarning: Unable to determine GEOS version. Ensure you have 3.3.3 or later installed, or installation may fail.
    '.'.join(str(v) for v in GEOS_MIN_VERSION), ))
  Proj 4.9.0 must be installed.

  ----------------------------------------
Command "f:\python\python.exe f:\python\lib\site-packages\pip\_vendor\pep517\_in_process.py get_requires_for_build_wheel C:\Users\AppData\Local\Temp\tmpzriwmmff" failed with error code 1 in C:\Users\AppData\Local\Temp\pip-install-npt9snvs\cartopy
N.Faulc
  • 67
  • 1
Sagar Jogadia
  • 1,330
  • 1
  • 16
  • 25

1 Answers1

0

Cartopy documentation recommends using Conda (link):

conda install -c conda-forge cartopy

Installing it using pip is also possible, but since Cartopy has a bunch of non-Python dependencies (like Proj and GEOS), you'll have to install those separately. That's a hassle and it's easy to end up with errors like the one above. Conda on the other hand can also take care of those non-Python dependencies for you.

Nick
  • 101
  • 4