- classmethod Regions.from_geodataframe(df, *, name=None, source=None, overlap=None)
GeoDataFrame to be transformed to a Regions class.
- namestr, optional
name of the Regions. If None uses
- sourcestr, optional
Source of the shapefile. If None uses
- overlapbool, default: None
Indicates if (some of) the regions overlap. If None uses
df.attrs.get("overlap"). If True
mask_3Dwill ensure overlapping regions are correctly assigned to grid points while
maskwill error (because overlapping regions cannot be represented by a 2D mask).
If False assumes non-overlapping regions. Grid points will silently be assigned to the region with the higher number (this may change in a future version).
There is (currently) no automatic detection of overlapping regions.