Traceback (most recent call last): File "E:\code-study\coda\test.py", line 3, in <module> a = LineString(345855.517766788951121, 3449487.1722800610587) TypeError: __new__() takes from 1 to 2 positional arguments but 3 were given
时间: 2024-03-01 09:56:16 浏览: 181
tqdm-4.66.0-py3-none-any.whl
这个错误提示表明你在实例化 `LineString` 类时传入了多余的参数。`LineString` 类的实例化需要传入一个坐标列表作为参数,如下所示:
```python
from shapely.geometry import LineString
line = LineString([(345855.517766788951121, 3449487.1722800610587), (x2, y2), ...])
```
请检查你的代码,确保传入的参数格式正确。如果问题仍然存在,请提供更多代码和上下文信息以便我更好地帮助你解决问题。
阅读全文