An ITK module to compute 3D thickness
Project description
An ITK module to compute 3D thickness
Overview
This is a module for the Insight Toolkit (ITK) that provides filters that compute the skeleton and thickness transforms of a 3D image.
ITK currently comes without a hands-on solution for 3D thickness evaluation. This contribution implements several filters based on the Euclidean distance transform and binary skeleton to fill this blank.
Binary thinning
Provides a 1 pixel-thin wire skeleton using an efficient curve thinning algorithm.
The thinning algorithm used in this module comes from the Insight Journal article:
Homann H. Implementation of a 3D thinning algorithm The Insight Journal - 2007 July - December. https://hdl.handle.net/1926/1292 https://insight-journal.org/browse/publication/181
Medial thickness
The idea behind the medial thickness as implemented in this module is twice the shortest distance to the outter shell along the medial axis of the object (i.e. diameter of the local maximal fitting sphere).
This definition provides an unbiased method for thickness evaluation compared to the local thickness transform since this last one will result in a higher number of points for thick parts. The skeletonization insure a minimal set of measurements to fully describe the object.
Filters
itk::BinaryThinningImageFilter3D<TInputImage, TOutputImage>: Compute the 3D skeleton of the input image.
itk::MedialThicknessImageFilter3D<TInputImage, TOutputImage>: 2x the distance to the outside along the medial axis.
Installation
Python
Binary Python packages are available for Linux, macOS, and Windows. They can be installed with:
python -m pip install --upgrade pip python -m pip install itk-thickness3d
C++
You need to build ITK from source to use this module.
In the newer versions of ITK, this module is available as a Remote module in the ITK source code. Build it with the CMake option: Module_Thickness3D, this can be switched on with a CMake graphical interface ccmake or directly from the command line with: -DModule_Thickness3D:BOOL=ON
For older ITK versions, add it manually as an External or Remote module to the ITK source code:
External:
cd ${itk_src}/Modules/External git clone https://github.com/InsightSoftwareConsortium/ITKThickness3D
Remote:
Create a file in ${itk_src}/Modules/Remote called Thickness3D.remote.cmake (see this GitHub gist) with the the following contents:
itk_fetch_module(Thickness3D "Tools for 3D thickness measurement" GIT_REPOSITORY ${git_protocol}://github.com/InsightSoftwareConsortium/ITKThickness3D.git GIT_TAG <replace with the latest stable commit tag> )
Usage
Python
Once ITK imported, you can use the itk.MedialThicknessImageFilter3D just as any other ITK methods:
skeleton = itk.BinaryThinningImageFilter3D.New(image)
Here is a simple python script that reads an image, applies the medial thickness filter and writes the resulting image in a file:
import itk input_filename = sys.argv[1] output_filename = sys.argv[2] image = itk.imread(input_filename) thickness_map = itk.MedialThicknessImageFilter3D.New(image) itk.imwrite(thickness_map, output_filename)
License
This software is distributed under the Apache 2.0 license. Please see the LICENSE file for details.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distributions
Hashes for itk_thickness3d-6.0.0-cp311-abi3-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a10decfdb06281ec9c77d1d6e847363c6554b69b838e243bf937cc9d9190cea4 |
|
MD5 | 14c2b44c120794036f619c9b8883e7db |
|
BLAKE2b-256 | a0bdd37949263b385f69648edf7b32994cc5693f3fdd4d43a5c4ecf06d13c66e |
Hashes for itk_thickness3d-6.0.0-cp311-abi3-manylinux_2_28_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e450e9f2abf513861e6eebcd27601aa3aad5f3756dd451eb331916bb03373bed |
|
MD5 | b48ad115276ca5023a341d6d86105dfa |
|
BLAKE2b-256 | 10f5c4b4e6b8f57c808024e7b0206203a4769336aa00d462fbc1bc7fd6b96d17 |
Hashes for itk_thickness3d-6.0.0-cp311-abi3-manylinux_2_28_aarch64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6e7b7c176e76aebe678a482a2febbb46694378b38126089b495e6ce1fcb540eb |
|
MD5 | 27774b32fef159f7110aa9d8089e29b4 |
|
BLAKE2b-256 | 8ee065fbdec7a88c21dc6814c9be2cd15b66b5578f5e58429a803b5832818435 |
Hashes for itk_thickness3d-6.0.0-cp311-abi3-manylinux_2_17_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4cec6aeb37724336e0ea417dedeba5fd70d6ab1c0b8fd5b12a8feb769ec4bf70 |
|
MD5 | 6eb18d0b019745c0e4de28cf5821e10d |
|
BLAKE2b-256 | c2cfb9c29728c769c01396f46cefb2d4b7759d85e692d5f88d6df558cd4dc63c |
Hashes for itk_thickness3d-6.0.0-cp311-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5d026aa36f997c3ef0d823dd7970cd974b89b01a3a56edf03dcfeb75eeb18493 |
|
MD5 | 9be149eb3ad2e96714d31ebdfe4ba533 |
|
BLAKE2b-256 | 1126ed0df3e365a2a290ec054894e9c9f093718a64978aa947c0468bd3b9f4d4 |
Hashes for itk_thickness3d-6.0.0-cp311-abi3-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | d2e632a02eee8bdfe35b05b2c2dee14cc7a81e3cd02ba48bfcc0ceed9c2e9ebc |
|
MD5 | 841bd3e321306a42fecff062e5071330 |
|
BLAKE2b-256 | 9cc50aadd4261f3937c4aebecef3525c52c1b108f92e658345e172a8d5e05c77 |
Hashes for itk_thickness3d-6.0.0-cp311-abi3-macosx_10_9_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a03d85a8a43e0efc7f3e7ca96f828c8b04c950606ba9a833416ace45f524633a |
|
MD5 | 2d9895b450988fe292fd8e40e71efb39 |
|
BLAKE2b-256 | cf017962c45c553d20e15a3be8915e0d8a72defd910a179feb40c9cc22287cef |
Hashes for itk_thickness3d-6.0.0-cp310-cp310-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 872d2abf94812fd41851f1c0e4810193b2ad31bdae7f40a99e3ad53cc0fbf24b |
|
MD5 | f2c80e2adf9a47acc586d6ecdf5dde0d |
|
BLAKE2b-256 | 0474bb40eb8f7f31c7fff208b9c7005b2ae521c0fef4df43e553942d6b2fe8c5 |
Hashes for itk_thickness3d-6.0.0-cp310-cp310-manylinux_2_28_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5f0f6496c44536ae3b9e38068aaff28b502b4da4ccbce46f962d54e487061aa1 |
|
MD5 | de0879c598ec47c31a4f939fa867bfdc |
|
BLAKE2b-256 | e93b817a333d4bf2af95b2edd33d453ebb8df47a57b516715f0d81c37f2ad47b |
Hashes for itk_thickness3d-6.0.0-cp310-cp310-manylinux_2_28_aarch64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 142b00b162d8cc7d0cad897826bdb636d606b7c69df74830d0944e6d4ec2edfc |
|
MD5 | db501e4f5e767634e96a502d455efae8 |
|
BLAKE2b-256 | e72f536b4f7de36bd330c4cba5b330691af4a414ac237e37e64306008d0213a0 |
Hashes for itk_thickness3d-6.0.0-cp310-cp310-manylinux_2_17_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ea3898798c567b7e59fb8112f8e5bfabc750ebb2ca181cc8681ee9708c056d98 |
|
MD5 | 280826e7ad70239724baf1806885e98a |
|
BLAKE2b-256 | aa3a140aed779703ac691676dc55a127206367687973d8592d12bece0cd3b8b9 |
Hashes for itk_thickness3d-6.0.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 537e04d640ced53baf740654a39a3e172c8cf49f018b555f612222de6d1b2722 |
|
MD5 | 9df5914d8595812e7a86f4adcec550f3 |
|
BLAKE2b-256 | 0a8f43692d2a1660847b1e1bf3c55ea5dd2ccbb4073054aaa14b770606b165c9 |
Hashes for itk_thickness3d-6.0.0-cp310-cp310-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6a5114a521faff5fed26225e5ee8ce7b382991f0c2c919c207933c2cc1273cf6 |
|
MD5 | d4984bfad5fd3222449425bc0329c225 |
|
BLAKE2b-256 | dfe8817f2edacb992c112787631303b4db764e62ed59b24be0a0843d73402e81 |
Hashes for itk_thickness3d-6.0.0-cp310-cp310-macosx_10_9_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 89b9c3fcf79ecc3b15702e401a4c9f1c514760c4d99b1dcc14d5966e7fe362ad |
|
MD5 | 63c47e7c86adc44b024c779b142aad8a |
|
BLAKE2b-256 | 6c772be51a70f0079aafcbf83c08cd8d52ea20d309e6aa258588beaea2c57eeb |
Hashes for itk_thickness3d-6.0.0-cp39-cp39-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5f586ee76ecdafe2812db84bddcd1678c8aecc8cca9a93298fc386a6844cd663 |
|
MD5 | 70c80acd4e873aebedc501c04caf9cbe |
|
BLAKE2b-256 | 70f3defacde4a55c70998b47d7883ee0157b49008110f3939f71a72f6e8824a3 |
Hashes for itk_thickness3d-6.0.0-cp39-cp39-manylinux_2_28_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2142f28cdbfa51f68c46cb50b58a8b1f14a16d97ca41a8dbd89acafa373036f9 |
|
MD5 | 78531ba81881685d456d47d14352ea19 |
|
BLAKE2b-256 | 17444e6720c4a7741b04b9ca9534cbf8c0c7e3a1e9f3ec2b3264866212205326 |
Hashes for itk_thickness3d-6.0.0-cp39-cp39-manylinux_2_28_aarch64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c806ec11aa2f87c606599a64de6c46293bea6d5d591bbb7d9baa25eb658518db |
|
MD5 | 7f649266c1135385f8666eafd377e773 |
|
BLAKE2b-256 | 46d92c37be3117f95a535da05847f7fc86ae5a5995716517798b48aede0b193a |
Hashes for itk_thickness3d-6.0.0-cp39-cp39-manylinux_2_17_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9db773b716407a26a97eb1efb45a8f677d59c1e7e0ac88be664059e10145b862 |
|
MD5 | 28d982e425e252049a51345fff98c7af |
|
BLAKE2b-256 | 58f3a55b23ad48db3291440b007b3637f366904c79eb8395789e0b1282d74441 |
Hashes for itk_thickness3d-6.0.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 29e54768f440c21472f198a1c24eed5373ec5583218222c4cad1ce97b33fecfb |
|
MD5 | d50ff8954c2a5418440bb9416fa286d8 |
|
BLAKE2b-256 | bab4c6afc79d276f55ba095973479053346439c59cd473be4231c92f209d1a25 |
Hashes for itk_thickness3d-6.0.0-cp39-cp39-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | eb1db4a0b252dbf17f083dc25d496f323a55554a5241021aa473c73f7f44d645 |
|
MD5 | 86edc09861c6fa40fce0d83d780bc020 |
|
BLAKE2b-256 | 47ae91d4a761f062ba1e78e617a5a1f1b6818067ac43ccc7e6287f73bfa618dd |
Hashes for itk_thickness3d-6.0.0-cp39-cp39-macosx_10_9_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9b05226a7b6577bd919b139a835537da39b610c299ff35e6a35ed865ea7d0d00 |
|
MD5 | 7309bea188f35b660bc0702b3d51e0db |
|
BLAKE2b-256 | 13c3d77c4450f0f0725fbf131a0dc5def5b374e0b9d0f83fb370cb78f086ec30 |
Hashes for itk_thickness3d-6.0.0-cp38-cp38-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 367b5385062ff1952620f2cb397504b735a931ff5e9b3318d0844a886aacb4b1 |
|
MD5 | c4d569ef4fa184351401b66dedbe0bc6 |
|
BLAKE2b-256 | dae459c25a6015c10814062a6982b879da4143f912deab81e187c1606414d27b |
Hashes for itk_thickness3d-6.0.0-cp38-cp38-manylinux_2_28_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3a5f70a44b3ecb6e0010e389057d03fc9b5ad0a71317a20943f04efbae22b949 |
|
MD5 | 1bfec4160cacd85e8c369cff9d84db53 |
|
BLAKE2b-256 | a2cfe78bceb4ed996f9cdfefb2217ce38b30bc7625c10ab5e87fbf503c589ea5 |
Hashes for itk_thickness3d-6.0.0-cp38-cp38-manylinux_2_28_aarch64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | d6cf658a2b1d09e56220a933699e63e08a5548a0bc3e4cc80714ea1f6d8aa803 |
|
MD5 | 83ecc867a94d955dfcd80a4f3ef75cf9 |
|
BLAKE2b-256 | a55d199a4c02bb49b258b3219d81892413869e31e8b0b99be497e3150e2dd601 |
Hashes for itk_thickness3d-6.0.0-cp38-cp38-manylinux_2_17_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8340383c98bee0449c03d42adcad118d3cde9fc9b8618ec8365176d9c5df0a22 |
|
MD5 | 311af077022a9ccf5bbfbf73e6e6798e |
|
BLAKE2b-256 | 79684fc910ca517d483d32dbcc53e5ba0553848150ae02465650bc432a4829a0 |
Hashes for itk_thickness3d-6.0.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | aacd2df8a996a59332c51aa17b7c318edbac14f805a5ab3b116ec6e1d0a05066 |
|
MD5 | b94089dac3dec52f85fa41355d3fe365 |
|
BLAKE2b-256 | 52315e19b429a5e2d2254e373d001b5ac97f21dbfec3224e90e2506f499e17ec |
Hashes for itk_thickness3d-6.0.0-cp38-cp38-macosx_10_9_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a3165eaf636b9ad710855f9ac290fe6b9f47af952b2f11f9401fb81dc8357628 |
|
MD5 | 3ef6099ad48ba1ee622e922c52020d4f |
|
BLAKE2b-256 | 3560b89818ebd93f1af149637d4c965eeec4dd616c75c47a6f27ca82e55889c5 |