【发布时间】:2017-05-06 01:03:01
【问题描述】:
从 conda-forge 成功安装 Geopandas conda 包后如下:
conda install -c conda-forge geopandas
当我尝试在 IPython(Jupyter 笔记本)中导入它时,使用:
import geopandas as gpd
尽管安装了所有依赖项(numpy、pandas、shapely、fiona、6、pyproj)并且是最新的,但我始终收到以下错误:
---------------------------------------------------------------------
------
ImportError Traceback (most recent call
last)
<ipython-input-1-13760ce748ee> in <module>()
4 import matplotlib.mlab as mlab
5
----> 6 import geopandas as gpd
7 import seaborn as sns
8 from sklearn import preprocessing
//anaconda/lib/python2.7/site-packages/geopandas/__init__.py in <module>()
----> 1 from geopandas.geoseries import GeoSeries
2 from geopandas.geodataframe import GeoDataFrame
3
4 from geopandas.io.file import read_file
5 from geopandas.io.sql import read_postgis
//anaconda/lib/python2.7/site-packages/geopandas/geoseries.py in <module>()
6 from pandas import Series, DataFrame
7 from pandas.core.indexing import _NDFrameIndexer
----> 8 from pandas.util.decorators import cache_readonly
9 import pyproj
10 from shapely.geometry import box, shape, Polygon, Point
ImportError: No module named decorators
关于可能导致错误的任何建议?
【问题讨论】:
-
将 pandas 更新到 0.20.1,这将得到修复
-
谢谢,更新到 0.20.1 解决了
-
我在 (0.2.1) 中仍然存在这个问题 - 我不知道编号约定:0.20.1 和 0.2.1 是否相同?
标签: python pandas numpy conda geopandas