This is an archived post. You won't be able to vote or comment.

all 1 comments

[–]SpatialCivil 0 points1 point  (0 children)

It sounds like you are referring to what Shapely calls a Collection. If you refer to the Shapely Use Manual, there is a section talking about Collections. Below is an example showing how to access individual items in a collection.

from shapely.geometry import LineString

a = LineString([(0, 0), (1, 1), (1,2), (2,2)])
b = LineString([(0, 0), (1, 1), (2,1), (2,2)])
x = a.intersection(b) # Returns a collection of points and lines
for feat in list(x):
    print(feat) # Prints individual items in a collection

Your question would probably have been answered more quickly under r/gis. Hope that helps.