我正在尝试了解 Shapely 的工作原理。
我可以用下面的代码画一条简单的线:
import matplotlib.pyplot as plt
A = Point(0,0)
B = Point(1,1)
AB = LineString([A,B])
plt.plot(AB)
Run Code Online (Sandbox Code Playgroud)
但是当我改变坐标时:
A = Point(1,0)
B = Point(3,4)
AB = LineString([A,B])
plt.plot(AB)
Run Code Online (Sandbox Code Playgroud)
Shapely 决定绘制两条线,这是我不理解的行为。
使用Shapely 1.7.0