Description of problem: When I try to run a number of demos in /usr/share/doc/python-basemap-examples (eg : daynight.py), I get an error message : IOError: proj data directory not found. Expecting it at: /usr/lib/python2.7/site-packages/mpl_toolkits/basemap/data Also, there seems to be 2 copies of "pyproj" : one in the package "python-basemap", and one in "pyproj". Version-Release number of selected component (if applicable): python-basemap-1.0.7-4.fc21.i686 How reproducible: Every time Steps to Reproduce: 1. python /usr/share/doc/python-basemap-examples/daynight.py Actual results: Traceback (most recent call last): File "/usr/share/doc/python-basemap-examples/daynight.py", line 2, in <module> from mpl_toolkits.basemap import Basemap File "/usr/lib/python2.7/site-packages/mpl_toolkits/basemap/__init__.py", line 30, in <module> from mpl_toolkits.basemap import pyproj File "/usr/lib/python2.7/site-packages/mpl_toolkits/basemap/pyproj.py", line 241, in <module> raise IOError(msg) IOError: proj data directory not found. Expecting it at: /usr/lib/python2.7/site-packages/mpl_toolkits/basemap/data Expected results: Pretty pictures Additional info:
I tried changing /usr/lib/python2.7/site-packages/mpl_toolkits/basemap/__init__.py : < from mpl_toolkits.basemap import pyproj --- > import pyproj (and hiding /usr/lib/python2.7/site-packages/mpl_toolkits/basemap/pyproj*), but now I get : Traceback (most recent call last): File "/usr/share/doc/python-basemap-examples/daynight.py", line 2, in <module> from mpl_toolkits.basemap import Basemap File "/usr/lib/python2.7/site-packages/mpl_toolkits/basemap/__init__.py", line 141, in <module> epsgf = open(os.path.join(basemap_datadir,'epsg')) IOError: [Errno 2] No such file or directory: '/usr/lib/python2.7/site-packages/mpl_toolkits/basemap/data/epsg' So, there seems to be 2 copies of the "epsg" data: one in the package python-basemap-data (at /usr/share/basemap/epsg), and one in proj-epsg (at /usr/share/proj/epsg) So fix that in /usr/lib/python2.7/site-packages/mpl_toolkits/basemap/__init__.py < epsgf = open(os.path.join(basemap_datadir,'epsg')) --- > epsgf = open('/usr/share/proj/epsg') ... but then it complains : Traceback (most recent call last): File "/usr/share/doc/python-basemap-examples/daynight.py", line 10, in <module> map = Basemap(projection='mill',lon_0=180) File "/usr/lib/python2.7/site-packages/mpl_toolkits/basemap/__init__.py", line 1080, in __init__ self._readboundarydata('gshhs',as_polygons=True) File "/usr/lib/python2.7/site-packages/mpl_toolkits/basemap/__init__.py", line 1193, in _readboundarydata raise IOError(msg) IOError: Unable to open boundary dataset file. Only the 'crude', 'low', 'intermediate' and 'high' resolution datasets are installed by default. If you are requesting a 'full' resolution dataset, you may need to download and install those files separately (see the basemap README for details). ... dunno what the fix is exactly, but a workaround: export BASEMAPDATA=/usr/share/basemap
Dupe of Bug 1177052.
*** This bug has been marked as a duplicate of bug 1177319 ***