darsia.WeightedGeometry#
- class WeightedGeometry(weight, space_dim, num_voxels, dimensions=None, voxel_size=None, **kwargs)[source]#
Bases:
GeometryGeometry with weighted volume.
Constructor for extruded two-dimensional geometry.
- Parameters:
- Raises:
ValueErrorIf weight has wrong dimensions.
Methods
integrate(data)Integrate data over the entire geometry.
make_extensive(data)Convert intensive values to integrated per-cell values on geometry grid.
normalize(img, img_ref[, return_ratio])Normalize image with respect to another one, such that both have the same integral.
subregion(roi)Extract subregion of the geometry.
Attributes
Weight of the geometry, can be a scalar or an array.
Effective voxel volume in 3d.
Internal copy of the voxel volume for efficient integration.
space_dimSpatial dimension of geometry.
num_voxelsNumber of voxels in each spatial direction.
voxel_sizeDimensions of a single voxel.
dimensionsDimensions of geometry.
- subregion(roi)[source]#
Extract subregion of the geometry.
- Parameters:
- roi
darsia.CoordinateArray Region of interest.
- roi
- Returns:
WeightedGeometrySubregion geometry.
- cached_voxel_volume#
Internal copy of the voxel volume for efficient integration.
- voxel_volume#
Effective voxel volume in 3d.
- weight#
Weight of the geometry, can be a scalar or an array.