我正在尝试运行一个简单的Cartopy示例:
import cartopy.crs as ccrs
import matplotlib.pyplot as plt
ax = plt.axes(projection=ccrs.PlateCarree())
ax.coastlines()
plt.show()
但我得到了这个错误:
Geometry必须是一个点(Point)或线(LineString)
python:geos_ts_c.cpp:4179: int GEOSCoordSeq_getSize_r(GEOSContextHandle_t,const geos::geom ::CoordinateSequence*,unsigned int*):Assertion`0!= cs' 失败。
我使用miniconda3安装了Cartopy:conda install -c conda-forge cartopy
我也尝试在虚拟环境中使用pip安装Cartopy,但是我遇到了相同的错误。
我的操作系统是Debian Buster。
你有什么想法吗?
!pip uninstall -y shapely
!pip install shapely --no-binary shapely
- Mahmut ARIKAN