morphogen.optimization.filters¶
Regularization of density designs: filter, projection and symmetry.
Density filter (Bruns and Tortorelli 2001, Bourdin 2001): weighted mean of the design over a ball of radius
rwith weightsr - distance(linear hat), periodic. It sets a minimal length scale and removes checkerboards.Heaviside projection (Wang, Lazarov and Sigmund 2011) of the filtered densities:
(tanh(beta eta) + tanh(beta (x - eta))) / (tanh(beta eta) + tanh(beta (1 - eta))), sharper asbetagrows (continuation).Symmetry: projection on the designs invariant by the mirror planes of the cell (orthotropic), and by the permutations of the axes (cubic; square in 2D).
The three operators are linear (filter, symmetry) or diagonal (projection), with their transposes applied to sensitivities.
- class morphogen.optimization.filters.DensityFilter(shape, radius: float)[source]¶
Bases:
objectPeriodic linear-hat filter of radius
radiusvoxels (planar for nz = 1).
- morphogen.optimization.filters.heaviside(x, beta: float, eta: float = 0.5)[source]¶
Smoothed Heaviside projection (identity-like for small beta).
- morphogen.optimization.filters.heaviside_derivative(x, beta: float, eta: float = 0.5)[source]¶
The derivative of the smoothed Heaviside projection (
heaviside()) with respect to the density, of sharpnessbetaand thresholdeta; 1 without projection (beta≤ 0).