earthkit.data.utils.bbox¶
Classes¶
Represent a geographic bounding box. |
Functions¶
|
Module Contents¶
- class earthkit.data.utils.bbox.BoundingBox(*, north, west, south, east, check=True)¶
Represent a geographic bounding box.
- Parameters:
north (
number) – Northern latitude (degrees)west (
number) – Western longitude (degrees)south (
number) – Southern latitude (degrees)east (
number) – Eastern longitude (degrees)
- add_margins(margins)¶
Generates a new
BoundingBoxobject with adjustedmargins.- Parameters:
margins (
strornumber) – The margin to be added to each side. When it is astrmust specify a percentage in terms of the current size like “50%”, while anumbermust specify degrees.- Returns:
New object with adjusted
margins.- Return type:
- as_dict()¶
- as_list()¶
- as_tuple()¶
- classmethod from_geopandas(gdf)¶
- property height¶
Returns the North-South size (degrees).
- Type:
number
- is_periodic_west_east¶
- classmethod make_invalid()¶
- north¶
- south¶
- classmethod union(bboxes)¶
Generates the union of a list of
BoundingBoxobjects.- Parameters:
bboxes (
list) – InputBoundingBoxobjects.- Returns:
Union of input objects.
- Return type:
See also
- union_with(other)¶
Generates the union of the current object and
other.- Parameters:
other (
BoundingBox) – The object to make the union with.- Returns:
New object containing the union.
- Return type:
See also
- west¶
- property width¶
Returns the East-West size (degrees).
- Type:
number
- earthkit.data.utils.bbox.bounding_box(obj, check=True)¶