The Shapely User Manual — Shapely 1.8.0 documentation
Note. Shapely is a planar geometry library and z, the height above or below the plane, is ignored in geometric analysis.There is a potential pitfall for users here: coordinate tuples that differ only in z are not distinguished from each other and their application can result in suprisingly invalid geometry objects. For example, LineString([(0, 0, 0), (0, 0, 1)]) does not return a vertical line ...