0

I am trying to plot with geopandas with this [tutorial][1]. However, whenever I run this: I find following errors:

Traceback (most recent call last):
  File "/home/mahin/PycharmProjects/ProfessorEick-20191013T041703Z-001/ProfessorEick/KernelDensity2D/GeoPandasPlot.py", line 2, in <module>
    import geoplot
  File "/home/mahin/miniconda3/lib/python3.7/site-packages/geoplot/__init__.py", line 1, in <module>
    from .geoplot import (
  File "/home/mahin/miniconda3/lib/python3.7/site-packages/geoplot/geoplot.py", line 17, in <module>
    import contextily as ctx
  File "/home/mahin/miniconda3/lib/python3.7/site-packages/contextily/__init__.py", line 7, in <module>
    from .place import Place, plot_map
  File "/home/mahin/miniconda3/lib/python3.7/site-packages/contextily/place.py", line 6, in <module>
    from .tile import howmany, bounds2raster, bounds2img, _sm2ll, _calculate_zoom
  File "/home/mahin/miniconda3/lib/python3.7/site-packages/contextily/tile.py", line 20, in <module>
    from rasterio.io import MemoryFile
ModuleNotFoundError: No module named 'rasterio.io'

I have tried installing rasterio using conda from the following link and also using the following instructions. However, the problem still exists. Anybody knows what could be the reason? My operating system is Ubuntu 18.06, I am running the code using pyccharm and my python version is 3.7.

Mahin
  • 449
  • 2
  • 14
  • 25
  • do you have multiple installations of python on your machine? – DBA108642 Nov 19 '19 at 17:26
  • Yes, but I am choosing different interpreter for everyproject using pycharm. – Mahin Nov 19 '19 at 17:28
  • your problem could be that the package is installed to one of your other installations. You're using 3.7 here but it could be installed under the directory for 2.7, for example – DBA108642 Nov 19 '19 at 17:30
  • I am not seeing any rasterio in my python 3.6 using pycharm. Is there any way to check it using commandline? – Mahin Nov 19 '19 at 17:49

0 Answers0