Python Mapnik行程误差

Python Mapnik行程误差,python,mapnik,Python,Mapnik,运行程序时,我遇到以下错误: AttributeError:“模块”对象没有属性“stroke\u linecap” sym = mapnik.LineSymbolizer() sym.stroke = mapnik.Stroke(mapnik.Color(171,158,137), 0.5) sym.stroke_width = 2 sym.stroke_linecap = mapnik.stroke_linecap.ROUND #Error is here 我发现了一个类似的问题并最终解

运行程序时,我遇到以下错误: AttributeError:“模块”对象没有属性“stroke\u linecap”

sym = mapnik.LineSymbolizer()
sym.stroke = mapnik.Stroke(mapnik.Color(171,158,137), 0.5)
sym.stroke_width = 2
sym.stroke_linecap = mapnik.stroke_linecap.ROUND #Error is here 

我发现了一个类似的问题并最终解决了。笔划线帽使用不当。应该是线头


sym.line\u cap=mapnik.line\u cap.ROUND

看起来那个库有很多bug。只是试图从源代码安装,它会抱怨缺少依赖项。。。