darsia.ExtrudedGeometry#
- class ExtrudedGeometry(expansion, space_dim, num_voxels, dimensions=None, voxel_size=None, **kwargs)[source]#
Bases:
WeightedGeometryOne or two-dimensional geometry extruded to three dimensions.
Constructor for extruded two-dimensional geometry.
- Parameters:
- Raises:
ValueErrorIf spatial dimension not 2.
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.
voxel_volumes(shape)Voxel volumes with which integrate weights data of the given shape.
Attributes
weightWeight of the geometry, a scalar or an array (NaN replaced by zero).
voxel_volumeEffective voxel volume in 3d.
cached_voxel_volumeVoxel volume for data of the current shape (the voxel volume itself, or a resized one, see _prepare_cached_voxel_volume).
space_dimSpatial dimension of geometry.
num_voxelsNumber of voxels in each spatial direction.
voxel_sizeDimensions of a single voxel.
dimensionsDimensions of geometry.