shapely.get_srid

Contents

shapely.get_srid#

get_srid(geometry, **kwargs)#

Return the SRID of a geometry.

Returns -1 for not-a-geometry values.

Parameters:
geometryGeometry or array_like

Geometry or geometries to get the SRID of.

**kwargs

See NumPy ufunc docs for other keyword arguments.

See also

set_srid

Examples

>>> import shapely
>>> from shapely import Point
>>> point = Point(0, 0)
>>> shapely.get_srid(point)
0
>>> with_srid = shapely.set_srid(point, 4326)
>>> shapely.get_srid(with_srid)
4326