Required
d| Type: | domain.Domain |
| Description: | The domain to bind to. |
partition to a given domain.def b_partition(d: domain.Domain) -> functools.partial: ...| Type: | domain.Domain |
| Description: | The domain to bind to. |
def da_max(da: xr.DataArray) -> float: ...| Type: | xr.DataArray |
| Description: | The DataArray. |
floatdef da_min(da: xr.DataArray) -> float: ...| Type: | xr.DataArray |
| Description: | The DataArray. |
floatdef delete_duplicate_interfaces(strata: list) -> list: ...| Type: | list |
| Description: | The strata to inspect. |
listLayeredModel into more layers.def partition(
d: domain.Domain,
lm: LayeredModel | Layer,
model_predicate: (
ModelPredicate | tuple[ModelPredicate, interface.Interface]
),
mode: str = "continuous",
interface_modifier: InterfaceFunctor = salvus.utils.utils.identity,
) -> LayeredModel: ...| Type: | domain.Domain |
| Description: | The domain. |
| Type: | LayeredModel | Layer |
| Description: | The layered model to partition. |
| Type: | ModelPredicate | tuple[ModelPredicate, interface.Interface] |
| Description: | Function which transforms a layered model into a set of discrete integers. Each "region" identified by a unique integer will be considered a new layer as long as it is contiguous across the model. Can also be a tuple, with (predicate, interface) as the two tuple entries. In this case, instead of a model-dependent interface being added, the passed interface itself will be used. |
| Type: | str |
| Default value: | 'continuous' |
| Description: | "continuous" for logical partitions (such as those used to find doubling regions) or "discontinuous" for true partitions meant to respect model discontinuities. If the former case, partitions will be located at the input grid point with the largest predicate value, while in the latter partitions will be placed halfway between two grid points. |
| Type: | InterfaceFunctor |
| Default value: | salvus.utils.utils.identity |
| Description: | A function that can re-discretize a derived partition interface. Useful, for instance, to avoid stair-stepping artifacts when partitioning models with nonuniform discontinuities on a regular grid. |