question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

ImportError: cannot import name 'griddata'

See original GitHub issue

I get the following error when importing this module.

  File "e:\software\anaconda3\envs\wmlpython3\lib\site-packages\osrm\extra.py", line 14, in <module>
    from matplotlib.mlab import griddata

ImportError: cannot import name 'griddata'

It seems that griddata from matplotlib.mlab is removed from the latest matplotlib versions.

See also link:

https://matplotlib.org/3.1.0/api/api_changes.html

matplotlib.mlab removals Lots of code inside the matplotlib.mlab module which was deprecated in Matplotlib 2.2 has been removed.

See below for a list: mlab.griddata (use scipy.interpolate.griddata)

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:6

github_iconTop GitHub Comments

3reactions
zifeocommented, Jul 15, 2020

Thanks for reporting this issue. It was fix by #33 but not published yet, you can install directly:

pip3 install --upgrade git+https://github.com/ustroetz/python-osrm.git 
1reaction
Abhi8162commented, Dec 27, 2021

im getting this error whil trying to import osrm. Any fix? ImportError: cannot import name ‘griddata’ from ‘matplotlib.mlab’

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to install and use pandastable ? 'griddata' missing
how do i use 'from utils import sentence'? 1 · ImportError: cannot import name 'PCA' from 'matplotlib.mlab' · Hot Network Questions.
Read more >
#978264 - python-escript: FTBFS: ImportError: cannot import ...
Debian Bug report logs - #978264 python-escript: FTBFS: ImportError: cannot import name 'griddata' from 'matplotlib.mlab' (/usr/lib/python3/dist ...
Read more >
[SciPy-User] importing griddata - Python mailing list
When i give 'import scipy' or 'import scipy.interpolate' i dnt get any ... in <module> ImportError: cannot import name griddata >>> *import ...
Read more >
matplotlib报错ImportError: cannot import name 'griddata'
matplotlib报错ImportError: cannot import name 'griddata'. from matplotlib.mlab import griddata. ImportError: cannot import name 'griddata'.
Read more >
Issue with 'matplotlib.mlab' in QGIS - GIS Stack Exchange
Couldn't load plugin 'rastertool' due to an error when calling its classFactory() method ImportError: cannot import name 'griddata' from ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found