mia-3dimag...ics-in-mask(1)
π mia-3dimagestatistics-in-mask β straight from the General Commands Manual π
okay so bestie, this page lives in the General Commands Manual (specifically the USER COMMANDS corner of it, iykyk), and it's about one very specific little icon: mia-3dimagestatistics-in-mask. She does stats. She does histograms. She only does it where you tell her to. Obsessed. Let's get into it π
β¨ NAME β¨
mia-3dimagestatistics-in-mask β Evaluate statistics within a masked region of the input data.
Like, she looks at your image, but only inside the mask. Everywhere else is outside her jurisdiction, no cap. π¦
πΈ SYNOPSIS πΈ
mia-3dimagestatistics-in-mask -i <image> -m <mask> [options]
π DESCRIPTION π
mia-3dimagestatistics-in-mask evaluates the statistics of an image within a masked region of the image. Possible outputs are a summary statistics and a histogram of the values.
That's the whole vibe fr fr: you hand her an image, you hand her a mask, she returns the numbers and/or the histogram for the pixels that made it inside the mask. Main character energy, but only where the mask lets her in. π
π OPTIONS π
π File-IO
-i --image=(input, required); ioβ input image to be analyzed. This one is required, so don't ghost the-iflag, she will simply not run. For supported file types seePLUGINS:3dimage/io.-m --mask=(input, required); ioβ mask image to use to restrict the analysis. Also required, also non-negotiable, also the entire point. For supported file types seePLUGINS:3dimage/io.-s --summary=(output); stringβ File to write the summary statistics to as plain text. Plain. Text. Nothing fancy and honestly? we respect that. β¨-H --histogram=(output); stringβ File to write the histogram to. CapitalHbestie, lowercasehis taken by something else on this very page. π
π 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
like, the lower you go the chattier she gets. trace is her voice-noting the entire runtime. fatal is her barely speaking at all. π«Ά
--copyrightβ print copyright information-h --helpβ print this help-? --usageβ print a short help--versionβ print the version number and exit
ποΈ Parameters
--struct-name=undefinedβ Name of the structure the statistics are evaluated for-l --limit=20; uint in [20, inf)β Number of pixels the mask should at least contain. So if your mask is smol and contains fewer than this, that's a problem. Floor is20, and it's auintthat can go up forever, literally.-b --bins=8; ulong in [4, inf)β number of histogram bins to be used. Default is8, smallest legal value is4, ceiling is the sky (ulong, so a lot of bins if you're feeling chaotic). π--hmin=0β lower bound for the histogram mapping. All values below this value will be mapped into the lowest bin. If this parameter is equal or larger thanhmax, the histogram range is evaluated automatically. So like, if you mess up the order, she just handles it herself. Queen behavior. π--hmax=0β hpper bound for the histogram mapping. All values above this value will be mapped into the highest bin. If this parameter is equal or smaller thanhmin, the histogram range is evaluated automatically. Same deal, other end. (And yes, "hpper" is what the page says, we keep the lore intact π)
βοΈ 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).
so -1 means "girl, you figure it out" and she will. Don't set this higher than your actual logical cores, that's not a flex. π
π§ PLUGINS: 3dimage/io π§
all the formats she can read/write. the full roster, no skips:
- 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
- Recognized file extensions:
- datapool β Virtual IO to and from the internal data pool
- Recognized file extensions:
.@
- Recognized file extensions:
- dicom β Dicom image series as 3D
- Recognized file extensions:
.DCM,.dcm - Supported element types:
- signed 16 bit, unsigned 16 bit
- Recognized file extensions:
- 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
- Recognized file extensions:
- 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
- Recognized file extensions:
- 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
- Recognized file extensions:
- 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
- Recognized file extensions:
- vff β VFF Sun raster format
- Recognized file extensions:
.VFF,.vff - Supported element types:
- unsigned 8 bit, signed 16 bit
- Recognized file extensions:
- 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
- Recognized file extensions:
- 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
- Recognized file extensions:
- 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
- Recognized file extensions:
π« EXAMPLE π«
evaluate the summary statistics on the input and a histogram with 10 bins and automtically evaluated boundaries. Save summary in summary.txt and the histogram in hist.txt
mia-3dimagestatistics-in-mask --image image.v.gz --mask mask.v.gz
--summary summary.txt --histogram hist.txt
see how she didn't even need --hmin or --hmax? that's the "automtically evaluated boundaries" moment, she just knows. β¨
π«Ά AUTHOR(s) π«Ά
Gert Wollny
shoutout to Gert, the architect. π
π 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'.
like, genuinely ABSOLUTELY NO WARRANTY, all caps, she is not kidding, do not come for her if it breaks. π
and that's the whole page bestie!! source/version: USER COMMANDS, v2.4.7 β signed, sealed, delivered. go run her on your masked region, you're gonna eat π πβ¨
π¦ where this page comes from
- ubuntu noble: mia-tools 2.4.7-13build4 Β· GPL-3.0-or-later
- ubuntu resolute: mia-tools 2.4.7-18 Β· GPL-3.0-or-later
- ubuntu stonking: mia-tools 2.4.7-19build1 Β· 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