mia-mesh-d...mable-model(1)
π mia-mesh-deformable-model(1) π β General Commands Manual
Okay so bestie, welcome to mia-mesh-deformable-model(1). Yes, the header is giving βlong name, tiny terminalβ, but weβre folding the manual name right here near the top: this is a General Commands Manual page for mia-mesh-deformable-model. Grab a boba, weβre fitting meshes to images. π«Άβ¨
β¨ NAME β¨
mia-mesh-deformable-model β Fit a mesh by using a deformable model.
π SYNOPSIS π
mia-mesh-deformable-model -i <in-file> -o <out-file> -r <ref-file>
[options]
π¦ DESCRIPTION π¦
mia-mesh-deformable-model This program runs a deformable model to adapt a mesh to an iso-value within a given image. <FIXME: Reference>
Not me leaving the reference as a <FIXME> β literally iconic behavior, but it is what the page says. π
π OPTIONS π
πΎ File I/O πΎ
-i,--in-file=(input, required); ioβ input mesh to be adapted. For supported file types seePLUGINS:mesh/io.-o,--out-file=(output, required); ioβ output mesh that has been deformed. For supported file types seePLUGINS:mesh/io.-r,--ref-file=(input, required); ioβ reference image. For supported file types seePLUGINS:3dimage/io.
π«Ά Help & Info π«Ά
-V,--verbose=warningβ verbosity of output, print messages of given level and higher priorities. Supported priorities starting at lowest level are:traceβ Function call tracedebugβ Debug outputinfoβ Low level messagesmessageβ Normal messageswarningβ Warningsfailβ Report test failureserrorβ Report errorsfatalβ Report only fatal errors
--copyrightβ print copyright information-h,--helpβ print this help-?,--usageβ print a short help--versionβ print the version number and exit
π Model parameters π
--smoothing-weight=0.04; float in [0, inf)β Weight of the inner force used to smooth the mesh--gradient-weight=0.04β Weight of the gradient force drive the mesh deformation. Use a negative value to invert the search direction.--intensity-weight=0.02; float in [0, inf)β Weight of the force resulting from the intensity difference at the vertex position versus the reference intensity'iso'.--intensity-scaling=1; float in (0, inf)β Scaling of the raw intensity difference.-s,--iso=64β Intensity value the mesh verices should adapt to.
π§Ό Preprocessing π§Ό
--image-smoothing=gauss:w=2β Prefilter to smooth the reference image. For supported plugins seePLUGINS:3dimage/filter.
π₯ Processing π₯
--threads=-1β Maxiumum number of threads to use for processing,This number should be lower or equal to the number of logical processor cores in the machine. (-1: automatic estimation).-m,--maxiter=200; uint in (0, inf)β Maximum number of iterations.-e,--epsilon=0.001; float in (0, inf)β Stop iteration when the maximum shift of the vertices falls below this value--reorientβ Reorientate the mesh triangles
π§© PLUGINS: 1d/spacialkernel π§©
cdiffβ Central difference filter kernel, mirror boundary conditions are used.- (no parameters)
gaussβ spacial Gauss filter kernel, supported parameters are:w = 1; uint in [0, inf)β half filter width.
scharrβ This plugin provides the 1D folding kernel for the Scharr gradient filter- (no parameters)
π§© PLUGINS: 1d/splinebc π§©
mirrorβ Spline interpolation boundary conditions that mirror on the boundary- (no parameters)
repeatβ Spline interpolation boundary conditions that repeats the value at the boundary- (no parameters)
zeroβ Spline interpolation boundary conditions that assumes zero for values outside- (no parameters)
π§© PLUGINS: 1d/splinekernel π§©
bsplineβ B-spline kernel creation , supported parameters are:d = 3; int in [0, 5]β Spline degree.
omomsβ OMoms-spline kernel creation, supported parameters are:d = 3; int in [3, 3]β Spline degree.
π§© PLUGINS: 3dimage/combiner π§©
absdiffβ Image combiner 'absdiff'- (no parameters)
addβ Image combiner 'add'- (no parameters)
divβ Image combiner 'div'- (no parameters)
mulβ Image combiner 'mul'- (no parameters)
subβ Image combiner 'sub'- (no parameters)
π§© PLUGINS: 3dimage/filter π§©
bandpassβ intensity bandpass filter, supported parameters are:max = 3.40282e+38; floatβ maximum of the band.min = 0; floatβ minimum of the band.
binarizeβ image binarize filter, supported parameters are:max = 3.40282e+38; floatβ maximum of accepted range.min = 0; floatβ minimum of accepted range.
closeβ morphological close, supported parameters are:hint = black; stringβ a hint at the main image content (black|white).shape = [sphere:r=2]; factoryβ structuring element. For supported plug-ins seePLUGINS:3dimage/shape
combinerβ Combine two images with the given combiner operator. if 'reverse' is set to false, the first operator is the image passed through the filter pipeline, and the second image is loaded from the file given with the 'image' parameter the moment the filter is run., supported parameters are:image =(input, required, io)β second image that is needed in the combiner. For supported file types seePLUGINS:3dimage/ioop =(required, factory)β Image combiner to be applied to the images. For supported plug-ins seePLUGINS:3dimage/combinerreverse = 0; boolβ reverse the order in which the images passed to the combiner.
convertβ image pixel format conversion filter, supported parameters are:a = 1; floatβ linear conversion parameter a.b = 0; floatβ linear conversion parameter b.map = opt; dictβ conversion mapping. Supported values are:copyβ copy data when convertinglinearβ apply linear transformation x -> a*x+brangeβ apply linear transformation that maps the input data type range to the output data type rangeoptβ apply a linear transformation that maps the real input range to the full output rangeoptstatβ apply a linear transform that maps based on input mean and variation to the full output range
repn = ubyte; dictβ output pixel type. Supported values are:bitβ binary datasbyteβ signed 8 bitubyteβ unsigned 8 bitsshortβ signed 16 bitushortβ unsigned 16 bitsintβ signed 32 bituintβ unsigned 32 bitslongβ signed 64 bitulongβ unsigned 64 bitfloatβ floating point 32 bitdoubleβ floating point 64 bitnoneβ no pixel type defined
cropβ Crop a region of an image, the region is always clamped to the original image size in the sense that the given range is kept., supported parameters are:end = [[4294967295,4294967295,4294967295]]; streamableβ end of cropping range, maximum = (-1,-1,-1).start = [[0,0,0]]; streamableβ begin of cropping range.
dilateβ 3d image stack dilate filter, supported parameters are:hint = black; stringβ a hint at the main image content (black|white).shape = [sphere:r=2]; factoryβ structuring element. For supported plug-ins seePLUGINS:3dimage/shape
distanceβ Evaluate the 3D distance transform of an image. If the image is a binary mask, then result of the distance transform in each point corresponds to the Euclidian distance to the mask. If the input image is of a scalar pixel value, then the this scalar is interpreted as heighfield and the per pixel value adds to the distance.- (no parameters)
downscaleβ Downscale the input image by using a given block size to define the downscale factor. Prior to scaling the image is filtered by a smoothing filter to eliminate high frequency data and avoid aliasing artifacts., supported parameters are:b = [[1,1,1]]; 3dboundsβ blocksize.bx = 1; uint in [1, inf)β blocksize in x direction.by = 1; uint in [1, inf)β blocksize in y direction.bz = 1; uint in [1, inf)β blocksize in z direction.kernel = gauss; factoryβ smoothing filter kernel to be applied, the size of the filter is estimated based on the blocksize.. For supported plug-ins seePLUGINS:1d/spacialkernel
erodeβ 3d image stack erode filter, supported parameters are:hint = black; stringβ a hint at the main image content (black|white).shape = [sphere:r=2]; factoryβ structuring element. For supported plug-ins seePLUGINS:3dimage/shape
gaussβ isotropic 3D gauss filter, supported parameters are:w = 1; int in [0, inf)β filter width parameter.
gradnormβ 3D image to gradient norm filter- (no parameters)
growmaskβ Use an input binary mask and a reference gray scale image to do region growing by adding the neighborhood pixels of an already added pixel if the have a lower intensity that is above the given threshold., supported parameters are:min = 1; floatβ lower threshold for mask growing.
invert π
Intensity invert filter. That's it, that's the whole thing.
- no parameters β zero. none. she just flips your intensities and goes.
isovoxel π
This filter scales an image to make the voxel size isometric and its size to correspond to the given value. the params are:
interp = [bspline:d=3]; factory β the interpolation kernel to be used. for which plug-ins are allowed seePLUGINS:1d/splinekernelsize = 1; float in (0, inf) β the isometric target voxel size.
kmeans π§©
3D image k-means filter. bestie listen: in the output image the pixel value represents the class membership, and the class centers get stored as an attribute in the image. params:
c = 3; int in [2, inf) β number of classes.
label π·οΈ
A filter to label the connected components of a binary image. params:
n = 6n; factory β neighborhood mask. supported plug-ins live atPLUGINS:3dimage/shape
labelmap πΊοΈ
Image filter to remap label id's. only applicable to images with integer valued intensities/labels, so don't try it on your floaty bois. params:
map =(input, required, string)β Label mapping file.
labelscale π
A filter that only creates output voxels that are already created in the input image. the scaling is done by a voting algorithm that selects the target pixel value based on the highest pixel count of a certain label in the corresponding source region. and if the region has two labels with the same count, the one with the lower number wins. params:
out-size =(required, 3dbounds)β target size given as two coma separated values.
load π
Load the input image from a file and use it to replace the current image in the pipeline. params:
file =(input, required, io)β name of the input file to load from. for supported file types seePLUGINS:3dimage/io
lvdownscale π½
This is a label voting downscale filter. it downscales a 3D image by blocks. for each block, the (non-zero) label that shows up the most times in the block gets issued as the output pixel in the target image. and if two labels appear the same number of times, the one with the lower absolute value wins. params:
b = [[1,1,1]]; 3dbounds β blocksize for the downscaling. each block will be represented by one pixel in the target image.
mask π
Mask an image β one image comes from the parameters list, the other from the normal filter input. both images must be of the same dimensions and one must be binary. the attributes of the image coming through the filter pipeline are preserved. the output pixel type corresponds to the input image that is not binary. params:
input =(input, required, io)β second input image file name. for supported file types seePLUGINS:3dimage/io
mean π«οΈ
3D image mean filter. params:
w = 1; int in [1, inf) β half filter width.
median π«§
median 3d filter. params:
w = 1; int in [1, inf) β filter width parameter.
mlv π
Mean of Least Variance 3D image filter. params:
w = 1; int in [1, inf) β filter width parameter.
msnormalizer βοΈ
3D image mean-sigma normalizing filter. params:
w = 1; int in [1, inf) β half filter width.
open πΈ
morphological open. params:
hint = black; string β a hint at the main image content (black|white).shape = [sphere:r=2]; factory β structuring element. supported plug-ins atPLUGINS:3dimage/shape
reorient π
3D image reorientation filter. params:
map = xyz; dict β oriantation mapping to be applied. supported values are:xyzβ keep orientationp-yzxβ permutate x->z->y->xp-zxyβ permutate x->y->z->xf-yzβ flip y-zf-xyβ flip x-yf-xzβ flip x-zr-x90β rotate around x-axis clockwise 90 degreer-x180β rotate around x-axis clockwise 180 degreer-x270β rotate around x-axis clockwise 270 degreer-y90β rotate around y-axis clockwise 90 degreer-y180β rotate around y-axis clockwise 180 degreer-y270β rotate around y-axis clockwise 270 degreer-z90β rotate around z-axis clockwise 90 degreer-z180β rotate around z-axis clockwise 180 degreer-z270β rotate around z-axis clockwise 270 degree
resize πΌοΈ
Resize an image. the original data is centered within the new sized image. params:
size = [[0,0,0]]; streamable β new size of the image. a size0indicates to keep the size for the corresponding dimension.
sandp π§
salt and pepper 3d filter. params:
thresh = 100; float in [0, inf) β thresh value.w = 1; int in [1, inf) β filter width parameter.
scale π
3D image filter that scales to a given target size. params:
interp = [bspline:d=3]; factory β interpolation kernel to be used. supported plug-ins atPLUGINS:1d/splinekernels = [[0,0,0]]; 3dbounds β target size to set all components at once (component 0: use input image size).sx = 0; uint in [0, inf) β target size in x direction (0: use input image size).sy = 0; uint in [0, inf) β target size in y direction (0: use input image size).sz = 0; uint in [0, inf) β target size in y direction (0: use input image size).
scharr π
The 3D Scharr filter for gradient evaluation. note that the output pixel type of the filtered image is the same as the input pixel type, so converting the input beforehand to a floating point valued image is recommendable. params:
dir = x; dict β Gradient direction. supported values are:xβ gradient in x-directionyβ gradient in y-directionzβ gradient in z-direction
selectbig π
A filter that creats a binary mask representing the intensity with the highest pixel count. the pixel value 0 will be ignored, and if two intensities have the same pixel count, then the result is undefined π. the input pixel must have an integral pixel type.
- no parameters β she takes no orders, she just finds the biggest one.
sepconv π§΅
3D image intensity separaple convolution filter. params:
kx = [gauss:w=1]; factory β filter kernel in x-direction. supported plug-ins atPLUGINS:1d/spacialkernelky = [gauss:w=1]; factory β filter kernel in y-direction. supported plug-ins atPLUGINS:1d/spacialkernelkz = [gauss:w=1]; factory β filter kernel in z-direction. supported plug-ins atPLUGINS:1d/spacialkernel
sobel β‘
The 2D Sobel filter for gradient evaluation. again bestie, the output pixel type of the filtered image is the same as the input pixel type, so convert the input to a floating point valued image beforehand β it's recommendable. params:
dir = x; dict β Gradient direction. supported values are:xβ gradient in x-directionyβ gradient in y-directionzβ gradient in z-direction
sws π§
seeded watershead. the algorithm extracts exactly as many reagions as initial labels are given in the seed image. params:
grad = 0; bool β Interpret the input image as gradient.mark = 0; bool β Mark the segmented watersheds with a special gray scale value.n = [sphere:r=1]; factory β Neighborhood for watershead region growing. supported plug-ins atPLUGINS:3dimage/shapeseed =(input, required, string)β seed input image containing the lables for the initial regions.
tee π«
Save the input image to a file and also pass it through to the next filter. icon behavior honestly, having it both ways. params:
file =(output, required, io)β name of the output file to save the image too. for supported file types seePLUGINS:3dimage/io
thinning π¦΄
3D morphological thinning, based on: Lee and Kashyap, 'Building Skeleton Models via 3-D Medial Surface/Axis Thinning Algorithms', Graphical Models and Image Processing, 56(6):462-478, 1994. this implementation only supports the 26 neighbourhood.
- no parameters β just vibes and skeletonization.
transform π
Transform the input image with the given transformation. params:
file =(input, required, io)β Name of the file containing the transformation. for supported file types seePLUGINS:3dtransform/ioimgboundary =; factory β override image interpolation boundary conditions. supported plug-ins atPLUGINS:1d/splinebcimgkernel = ; factoryβ override the image interpolator kernel. Wanna know which plug-ins you can throw in here? Go peek atPLUGINS:1d/splinekernelπ«
variance π
3D image variance filter. The parameters it vibes with are:
w = 1; int in [1, inf)β half filter width.
ws π
basic watershed segmentation. Here's what it takes:
evalgrad = 0; boolβ set this to1if your input image is not representing a gradient norm image. (like, flip it on and it'll behave, bestie)mark = 0; boolβ set to1to mark the segmented watersheds with a special gray scale value.n = [sphere:r=1]; factoryβ neighborhood for watershed region growing. Supported plug-ins live over inPLUGINS:3dimage/shape.thresh = 0; float in [0, 1)β relative gradient norm threshold. The actual threshold value isthresh * (max_grad - min_grad) + min_grad. Basins separated by gradients with a lower norm will be joined. periodt.
β¨ PLUGINS: 3dimage/io β¨
analyze πΈ
Analyze 7.5 image.
Recognized file extensions: .HDR, .hdr
Supported element types:
- unsigned 8 bit
- signed 16 bit
- signed 32 bit
- floating point 32 bit
- floating point 64 bit
datapool π«Ά
Virtual IO to and from the internal data pool.
Recognized file extensions: .@
dicom π©Ί
Dicom image series as 3D.
Recognized file extensions: .DCM, .dcm
Supported element types:
- signed 16 bit
- unsigned 16 bit
hdf5 π
HDF5 3D image IO.
Recognized file extensions: .H5, .h5
Supported element types:
- binary data
- signed 8 bit
- unsigned 8 bit
- signed 16 bit
- unsigned 16 bit
- signed 32 bit
- unsigned 32 bit
- signed 64 bit
- unsigned 64 bit
- floating point 32 bit
- floating point 64 bit
inria π
INRIA image.
Recognized file extensions: .INR, .inr
Supported element types:
- signed 8 bit
- unsigned 8 bit
- signed 16 bit
- unsigned 16 bit
- signed 32 bit
- unsigned 32 bit
- floating point 32 bit
- floating point 64 bit
mhd π¬
MetaIO 3D image IO using the VTK implementation (experimental).
Recognized file extensions: .MHA, .MHD, .mha, .mhd
Supported element types:
- signed 8 bit
- unsigned 8 bit
- signed 16 bit
- unsigned 16 bit
- signed 32 bit
- unsigned 32 bit
- floating point 32 bit
- floating point 64 bit
nifti π§
NIFTI-1 3D image IO. The orientation is transformed in the same way like it is done with dicomtonifti --no-reorder from the vtk-dicom package.
Recognized file extensions: .NII, .nii
Supported element types:
- signed 8 bit
- unsigned 8 bit
- signed 16 bit
- unsigned 16 bit
- signed 32 bit
- unsigned 32 bit
- signed 64 bit
- unsigned 64 bit
- floating point 32 bit
- floating point 64 bit
vff β¨
VFF Sun raster format.
Recognized file extensions: .VFF, .vff
Supported element types:
- unsigned 8 bit
- signed 16 bit
vista π¦
Vista 3D.
Recognized file extensions: .-, .V, .VISTA, .v, .vista
Supported element types:
- binary data
- signed 8 bit
- unsigned 8 bit
- signed 16 bit
- unsigned 16 bit
- signed 32 bit
- unsigned 32 bit
- floating point 32 bit
- floating point 64 bit
vti π
3D image VTK-XML in- and output (experimental).
Recognized file extensions: .VTI, .vti
Supported element types:
- signed 8 bit
- unsigned 8 bit
- signed 16 bit
- unsigned 16 bit
- signed 32 bit
- unsigned 32 bit
- floating point 32 bit
- floating point 64 bit
vtk π
3D VTK image legacy in- and output (experimental).
Recognized file extensions: .VTK, .VTKIMAGE, .vtk, .vtkimage
Supported element types:
- signed 8 bit
- unsigned 8 bit
- signed 16 bit
- unsigned 16 bit
- signed 32 bit
- unsigned 32 bit
- floating point 32 bit
- floating point 64 bit
π PLUGINS: 3dimage/shape π
18n
18n neighborhood 3D shape creator.
(no parameters)
26n
26n neighborhood 3D shape creator.
(no parameters)
6n
6n neighborhood 3D shape creator.
(no parameters)
sphere π
Closed spherical shape neighborhood including the pixels within a given radius r. β yes, that's the parameter list:
r = 2; float in (0, inf)β sphere radius.
π PLUGINS: 3dtransform/io π
bbs
Binary (non-portable) serialized IO of 3D transformations.
Recognized file extensions: .bbs
datapool π«Ά
Virtual IO to and from the internal data pool.
Recognized file extensions: .@
vista π¦
Vista storage of 3D transformations.
Recognized file extensions: .v, .v3dt
xml β¨
XML serialized IO of 3D transformations.
Recognized file extensions: .x3dt
π PLUGINS: mesh/io π
datapool π«Ά
Virtual IO to and from the internal data pool.
Recognized file extensions: .@
off π
plugin to load/store some Geomview OFF files. Supported is only the ASCII format 3D meshes with normals and per-vertex RGB colors. Alpha values and texture coordinates, as well as per face properties are ignored. Polygons are read and triangulated.
Recognized file extensions: .OFF, .off
ply π
Ply triangle mesh input/output support.
Recognized file extensions: .PLY, .ply
stl πΊ
STL mesh io plugin.
Recognized file extensions: .STL, .stl
vista π¦
Vista/Simbio triangle mesh input/output support.
Recognized file extensions: .-, .V, .VMESH, .v, .vmesh
vtk π
A subset of VTK mesh in-and output: triangle meshes are written, and triangle meshes and triangle strips are read. Additional per-vertex attributes are supported: normals, colors for three component colors, and scale for a scalar value attached to each vertex. The data is written by the vtkPolyDataWriter in binary format. no cap.
Recognized file extensions: .VTK, .VTKMESH, .vtk, .vtkmesh
πΈ EXAMPLE πΈ
Run the deformable model on input.vmesh with 200 iterations adapting to a value of 128 in the image ref.v and save the result to deformed.vmesh:
mia-mesh-deformable-model -i input.vmesh -o deformed.vmesh --iso 128 --maxiter 200
π AUTHOR(s) π
Gert Wollny
π COPYRIGHT π
This software is Copyright (c) 1999-2015 Leipzig, Germany and Madrid, Spain. It comes with ABSOLUTELY NO WARRANTY and you may redistribute it under the terms of the GNU GENERAL PUBLIC LICENSE Version 3 (or later). For more information run the program with the option --copyright.
okay that's a wrap bestie π«Ά this whole thing lives under USER COMMANDS, version v2.4.7, in the mia-mesh-d...mable-model(1) page. go forth and mesh, you absolute icon π
β¨
π¦ where this page comes from
- debian bookworm: mia-tools 2.4.7-11+b1 Β· GPL-3.0-or-later
- ubuntu jammy: mia-tools 2.4.7-8ubuntu1 Β· GPL-3.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms