Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

basemap ImportError: No module named 'mpl_toolkits.basemap'

from mpl_toolkits.basemap import Basemap  

gives

ImportError: No module named 'mpl_toolkits.basemap'  

I installed basemap with conda

wayne@dors:~$ conda install basemap
Solving environment: done

# All requested packages already installed.  

I am running ubuntu 15.04, Python3.4, matplotlib 2.1.1, numpy 1.8.2
How do I fix?

like image 380
Wayne Angel Avatar asked Jan 22 '18 18:01

Wayne Angel


People also ask

How do I import a basemap into a Jupyter notebook?

Go to "Environments" On the Environments Page, select Not Installed from the drop down menu. Search basemap (or any package you want to install) Select and click Apply.

What is basemap Python?

Basemap allows you to create map plots in python. It extends matplotlib's functionality by adding geographical projections and some datasets for plotting coast lines and political boundaries, among other things.


1 Answers

Try to install it with this command:

conda install -c conda-forge basemap

"Only the 'crude' and 'low', resolution datasets are installed by default" .You may need to install the following for high resolution:

conda install -c conda-forge basemap-data-hires
like image 73
ConfusedMan Avatar answered Sep 20 '22 13:09

ConfusedMan