odc.geo.geom.Geometry
- class odc.geo.geom.Geometry(geom, crs=None)[source]
2D Geometry with CRS.
This is a wrapper around
shapely.geometry.BaseGeometry
that adds projection information.Instantiate with a GeoJSON structure. If 3D coordinates are supplied, they are converted to 2D by dropping the Z points.
Methods
__init__
(geom[, crs])buffer
(distance[, resolution])- rtype
clone
()- rtype
contains
(other)- rtype
crosses
(other)- rtype
difference
(other)- rtype
disjoint
(other)- rtype
geojson
([properties, simplify, resolution, ...])Render geometry to GeoJSON.
interpolate
(distance)Returns a point
distance
units along the line.intersection
(other)- rtype
intersects
(other)- rtype
overlaps
(other)- rtype
segmented
(resolution)Increase resolution of the geometry.
simplify
(tolerance[, preserve_topology])- rtype
split
(splitter)svg
(*args, **kw)- rtype
svg_path
([ndecimal])Produce SVG path text.
symmetric_difference
(other)- rtype
to_crs
(crs[, resolution, wrapdateline])Convert geometry to a different Coordinate Reference System.
touches
(other)- rtype
transform
(func)Map through arbitrary transform.
union
(other)- rtype
within
(other)- rtype
Attributes
area
- rtype
boundary
- rtype
boundingbox
- rtype
centroid
- rtype
convex_hull
- rtype
coords
envelope
- rtype
exterior
- rtype
interiors
is_empty
- rtype
is_multi
True for multi-geometry types.
is_ring
- rtype
is_valid
- rtype
json
length
- rtype
points
type
- rtype
wkt
- rtype
xy