# Beginner Questions

**URL:** https://discourse.itk.org/c/beginner-questions/9.md?no_subcategories=false&page=22

[Latest](https://discourse.itk.org/latest.md) · [Categories](https://discourse.itk.org/categories.md) · [Tags](https://discourse.itk.org/tags.md)

**Page:** 23

---

## [Read an fdf file in python](https://discourse.itk.org/t/read-an-fdf-file-in-python/3964)

<div class="topic-metadata">

**Author:** [@jtduda](https://discourse.itk.org/u/jtduda)\
**Replies:** 4\
**Last updated:** [March 23, 2021, 9:54pm UTC](https://discourse.itk.org/t/read-an-fdf-file-in-python/3964 "2021-03-23T21:54:27Z")

</div>

I’m trying to read an .fdf file in python. I installed the relevant package via: pip install itk-iofdf I then tried the following: import itk from itk import IOFDF x = itk.image\_file\_reader(filename="M0slice002.fdf" )…

---

## [How to extract labels of connected components?](https://discourse.itk.org/t/how-to-extract-labels-of-connected-components/3469)

<div class="topic-metadata">

**Author:** [@Enr\_Brunetti](https://discourse.itk.org/u/Enr_Brunetti)\
**Replies:** 3\
**Last updated:** [March 22, 2021, 2:59pm UTC](https://discourse.itk.org/t/how-to-extract-labels-of-connected-components/3469 "2021-03-22T14:59:42Z")

</div>

I have used the itk::ConnectedComponentImageFilter. For each slice I have a certain number of connected component. I want to obtain a label associated to each of these ones, but with the following code I obtain only one …

---

## [How to create an itk.js Image object?](https://discourse.itk.org/t/how-to-create-an-itk-js-image-object/1163)

<div class="topic-metadata">

**Author:** [@Mason](https://discourse.itk.org/u/Mason)\
**Replies:** 14\
**Last updated:** [March 15, 2021, 2:41pm UTC](https://discourse.itk.org/t/how-to-create-an-itk-js-image-object/1163 "2021-03-15T14:41:01Z")

</div>

Hello guys. I am a beginner. I hope to use itk and vtk in backend(C++) and use itk.js and vtk.js in front-end（JavaScript）. I just read the docs of itk.js and want to create an itk.js Image object to show in browser. I wo…

---

## [Limitations of Similarity3DTransform](https://discourse.itk.org/t/limitations-of-similarity3dtransform/3956)

<div class="topic-metadata">

**Author:** [@reox](https://discourse.itk.org/u/reox)\
**Replies:** 2\
**Last updated:** [March 15, 2021, 1:44pm UTC](https://discourse.itk.org/t/limitations-of-similarity3dtransform/3956 "2021-03-15T13:44:22Z")

</div>

I’m using the Similarity3DTransform for quite some time now, but I always find certain configurations where it totally fails to register two images. Usually with some manual pre-alignment it is then no problem. I found …

---

## [3D DICOM Thorax Registration](https://discourse.itk.org/t/3d-dicom-thorax-registration/3953)

<div class="topic-metadata">

**Author:** [@michel.atieh](https://discourse.itk.org/u/michel.atieh)\
**Replies:** 2\
**Last updated:** [March 11, 2021, 9:55pm UTC](https://discourse.itk.org/t/3d-dicom-thorax-registration/3953 "2021-03-11T21:55:13Z")

</div>

Dear all, I am completely new to the world of image registration. Can anyone please help me define the steps that I should take to register 3D CT images of 2 different patient? for instance to what type should I change…

---

## [ITK transform using Dicom header data](https://discourse.itk.org/t/itk-transform-using-dicom-header-data/3858)

<div class="topic-metadata">

**Author:** [@MD2021](https://discourse.itk.org/u/MD2021)\
**Replies:** 6\
**Last updated:** [March 10, 2021, 12:23am UTC](https://discourse.itk.org/t/itk-transform-using-dicom-header-data/3858 "2021-03-10T00:23:50Z")

</div>

I am running a radiomics project that requires segmentation/mask of medical imaging files. The simplest example is that MRI scans are rigidly registered to a CT scan and contours/segments applied. The contours/segments …

---

## [Is there an easy way to determine the boundaries/start of a segmentation?](https://discourse.itk.org/t/is-there-an-easy-way-to-determine-the-boundaries-start-of-a-segmentation/3944)

<div class="topic-metadata">

**Author:** [@MD2021](https://discourse.itk.org/u/MD2021)\
**Replies:** 3\
**Last updated:** [March 10, 2021, 12:22am UTC](https://discourse.itk.org/t/is-there-an-easy-way-to-determine-the-boundaries-start-of-a-segmentation/3944 "2021-03-10T00:22:05Z")

</div>

I have segmentations/contours which correspond to a CT analogous to this example They exist only in approximately 20 slices buried within 200 slices of 3d image set. The remaining slices are completely empty space. F…

---

## [3D DICOM Registration](https://discourse.itk.org/t/3d-dicom-registration/3943)

<div class="topic-metadata">

**Author:** [@michel.atieh](https://discourse.itk.org/u/michel.atieh)\
**Replies:** 1\
**Last updated:** [March 8, 2021, 11:05pm UTC](https://discourse.itk.org/t/3d-dicom-registration/3943 "2021-03-08T23:05:34Z")

</div>

Dear all, I need to register a CT DICOM image sequence onto a 3D numerical phantom(which means onto another DICOM image sequence). the registration should be a non-rigid(free form) registration. how do you advise me to…

---

## [PointSetToPointSetRegistrationMethod in Python](https://discourse.itk.org/t/pointsettopointsetregistrationmethod-in-python/1359)

<div class="topic-metadata">

**Author:** [@Sohail](https://discourse.itk.org/u/Sohail)\
**Replies:** 4\
**Last updated:** [March 8, 2021, 7:09pm UTC](https://discourse.itk.org/t/pointsettopointsetregistrationmethod-in-python/1359 "2021-03-08T19:09:56Z")

</div>

Is PointSetToPointSetRegistrationMethod available in the Python interface for V4? If not, how is one expected to do rigid/non-rigid alignment in Python? Thanks in advance, Sohail

---

## [Point cloud / depth map / mesh registration SimpleITK/ITK Python](https://discourse.itk.org/t/point-cloud-depth-map-mesh-registration-simpleitk-itk-python/3742)

<div class="topic-metadata">

**Author:** [@NPi](https://discourse.itk.org/u/NPi)\
**Replies:** 4\
**Last updated:** [March 8, 2021, 7:06pm UTC](https://discourse.itk.org/t/point-cloud-depth-map-mesh-registration-simpleitk-itk-python/3742 "2021-03-08T19:06:52Z")

</div>

Hello everyone, I am a very very bloody ITK/SimpleITK beginner trying to understand the basic principles of ITK/SimpleITK. My aim is to register to 2 point clouds: the first one is from a stereoscopic imaging modality (…

---

## [std::string to char const \* in python itk for itk.ImageIOBase\`](https://discourse.itk.org/t/std-string-to-char-const-in-python-itk-for-itk-imageiobase/3933)

<div class="topic-metadata">

**Author:** [@donghakang](https://discourse.itk.org/u/donghakang)\
**Replies:** 6\
**Last updated:** [March 8, 2021, 6:36pm UTC](https://discourse.itk.org/t/std-string-to-char-const-in-python-itk-for-itk-imageiobase/3933 "2021-03-08T18:36:18Z")

</div>

Hello! I am quite new to ITK and trying to make a very simple application using ITK / python! I am doing something like this. filename = "./output\_filename.hdr" image\_io = itk.ImageIOBase image\_io.SetFileName(filename…

---

## [Image Registration Method Displacement 1 Example: Composite transform order](https://discourse.itk.org/t/image-registration-method-displacement-1-example-composite-transform-order/3920)

<div class="topic-metadata">

**Author:** [@cpicarr1](https://discourse.itk.org/u/cpicarr1)\
**Replies:** 2\
**Last updated:** [March 8, 2021, 10:32am UTC](https://discourse.itk.org/t/image-registration-method-displacement-1-example-composite-transform-order/3920 "2021-03-08T10:32:10Z")

</div>

Hello, Regarding one of the examples on the SimpleITK documentation website: https://simpleitk.readthedocs.io/en/master/link\_ImageRegistrationMethodDisplacement1\_docs.html In this example, an affine + displacement regi…

---

## [Fatal Error while building ITK-4.8.2](https://discourse.itk.org/t/fatal-error-while-building-itk-4-8-2/3928)

<div class="topic-metadata">

**Author:** [@vtetz](https://discourse.itk.org/u/vtetz)\
**Replies:** 4\
**Last updated:** [March 5, 2021, 9:25pm UTC](https://discourse.itk.org/t/fatal-error-while-building-itk-4-8-2/3928 "2021-03-05T21:25:52Z")

</div>

I’ve been trying to install the ITK-4.8.2, in order to try to build an elder program (constructed in 2018 - a module for 3D Slicer). The ITK-5 wasnt working to build this program, so I started to go back, in order to be…

---

## [Help with curve fitting pls](https://discourse.itk.org/t/help-with-curve-fitting-pls/3918)

<div class="topic-metadata">

**Author:** [@Erol\_Cimen](https://discourse.itk.org/u/Erol_Cimen)\
**Replies:** 2\
**Last updated:** [March 2, 2021, 2:41am UTC](https://discourse.itk.org/t/help-with-curve-fitting-pls/3918 "2021-03-02T02:41:55Z")

</div>

Does anyone know how to fit a curve to a series of points with itk? I currently have a cost function and a Levenberg-Marquad optimizer, but I have no idea how to get the cost function to work - I can’t find documentatio…

---

## [How to perform rigid registration on 3D volumes, but apply transform on single planes?](https://discourse.itk.org/t/how-to-perform-rigid-registration-on-3d-volumes-but-apply-transform-on-single-planes/3912)

<div class="topic-metadata">

**Author:** [@jingxuan](https://discourse.itk.org/u/jingxuan)\
**Replies:** 1\
**Last updated:** [February 26, 2021, 1:33pm UTC](https://discourse.itk.org/t/how-to-perform-rigid-registration-on-3d-volumes-but-apply-transform-on-single-planes/3912 "2021-02-26T13:33:18Z")

</div>

Hello I was able to perform rigid registration on 2 3D volumes and was able to apply those transforms to the 3D moving image. The results look great. I would now however like to apply those transforms to single planes …

---

## [Proper way to flip using AffineTransform with SimpleITK](https://discourse.itk.org/t/proper-way-to-flip-using-affinetransform-with-simpleitk/3898)

<div class="topic-metadata">

**Author:** [@bobdark](https://discourse.itk.org/u/bobdark)\
**Replies:** 2\
**Last updated:** [February 24, 2021, 5:34pm UTC](https://discourse.itk.org/t/proper-way-to-flip-using-affinetransform-with-simpleitk/3898 "2021-02-24T17:34:35Z")

</div>

I’m trying to flip a 3d image using AffineTransform (I have to support multiple possible modifications to a 3d image, like rotation and flipping, so I’m trying to represent them as matrices) and it seems that when I appl…

---

## [Difference between distance measures](https://discourse.itk.org/t/difference-between-distance-measures/3892)

<div class="topic-metadata">

**Author:** [@blizzardboi\_2020](https://discourse.itk.org/u/blizzardboi_2020)\
**Replies:** 3\
**Last updated:** [February 24, 2021, 12:42am UTC](https://discourse.itk.org/t/difference-between-distance-measures/3892 "2021-02-24T00:42:02Z")

</div>

Hello guys. I am trying to measure the similarity measures between a reference binary ground truth and a segmented binary volume. What are signed surface to surface distance, & unsigned surface to surface distance? Are t…

---

## [Segmentation fault error when running Rigid+Affine Registration](https://discourse.itk.org/t/segmentation-fault-error-when-running-rigid-affine-registration/3879)

<div class="topic-metadata">

**Author:** [@cpicarr1](https://discourse.itk.org/u/cpicarr1)\
**Replies:** 7\
**Last updated:** [February 20, 2021, 10:03pm UTC](https://discourse.itk.org/t/segmentation-fault-error-when-running-rigid-affine-registration/3879 "2021-02-20T22:03:28Z")

</div>

Hello, I’m trying to run a rigid + affine registration of around 800 images (CT scans), but I keep getting a Segmentation Fault error, when run using Python3 on Ubuntu. The relevant part of the code is (I think): …

---

## [\[SimpleITK\] Registration of non-medical multi-modal images](https://discourse.itk.org/t/simpleitk-registration-of-non-medical-multi-modal-images/3851)

<div class="topic-metadata">

**Author:** [@PauloFavero](https://discourse.itk.org/u/PauloFavero)\
**Replies:** 10\
**Last updated:** [February 19, 2021, 8:09pm UTC](https://discourse.itk.org/t/simpleitk-registration-of-non-medical-multi-modal-images/3851 "2021-02-19T20:09:38Z")

</div>

Hi everyone, I am starting to learn how to use the toolkit for image registration. I have a pair of thermal-visual images that need to be registered. Each image has a different dimensions and with a 90% of the scene is…

---

## [Resize nii image getting the modified affine information](https://discourse.itk.org/t/resize-nii-image-getting-the-modified-affine-information/3877)

<div class="topic-metadata">

**Author:** [@AmericaBG](https://discourse.itk.org/u/AmericaBG)\
**Replies:** 3\
**Last updated:** [February 18, 2021, 9:25am UTC](https://discourse.itk.org/t/resize-nii-image-getting-the-modified-affine-information/3877 "2021-02-18T09:25:12Z")

</div>

Hello every body! I’m trying to resize nii images but I don’t know how to modify its affine information to have the reference space information. The resize would be from (512,512,n\_slices) to (256,256,n\_slices) What I …

---

## [Subtract two meshes](https://discourse.itk.org/t/subtract-two-meshes/1945)

<div class="topic-metadata">

**Author:** [@zandarina](https://discourse.itk.org/u/zandarina)\
**Replies:** 16\
**Last updated:** [February 17, 2021, 11:59pm UTC](https://discourse.itk.org/t/subtract-two-meshes/1945 "2021-02-17T23:59:26Z")

</div>

Hi everybody, I have a general question. I have an stl image and i read it with vtk and i fill it to be a solid. Now, i would like to make a substraction with another stl also solid. But the function of vtk is not optim…

---

## [Ouput deformation fields in DICOM format](https://discourse.itk.org/t/ouput-deformation-fields-in-dicom-format/2603)

<div class="topic-metadata">

**Author:** [@spencermanwell](https://discourse.itk.org/u/spencermanwell)\
**Replies:** 4\
**Last updated:** [February 16, 2021, 5:12pm UTC](https://discourse.itk.org/t/ouput-deformation-fields-in-dicom-format/2603 "2021-02-16T17:12:10Z")

</div>

Hello, Does anyone have experience writing the deformation vector fields to DICOM, i.e. following the C.20.3 Deformable Spatial Registration Module? Does functionality exist within ITK to do this? Thank you, Spencer

---

## [2D multiplanar (sagittal) from cross sequence](https://discourse.itk.org/t/2d-multiplanar-sagittal-from-cross-sequence/3861)

<div class="topic-metadata">

**Author:** [@AmericaBG](https://discourse.itk.org/u/AmericaBG)\
**Replies:** 12\
**Last updated:** [February 16, 2021, 3:20pm UTC](https://discourse.itk.org/t/2d-multiplanar-sagittal-from-cross-sequence/3861 "2021-02-16T15:20:33Z")

</div>

Hi! There goes my problem: I want to obtain 2D sagittal slices from a 3D volume composed of cross images. So far so good. My problem arrives when I want to resample/reform this sagittal images with a STIR sequence fro…

---

## [Only necessary to compile ITKCommon with KWSys & VXL](https://discourse.itk.org/t/only-necessary-to-compile-itkcommon-with-kwsys-vxl/3863)

<div class="topic-metadata">

**Author:** [@al-sabr](https://discourse.itk.org/u/al-sabr)\
**Replies:** 4\
**Last updated:** [February 15, 2021, 10:14pm UTC](https://discourse.itk.org/t/only-necessary-to-compile-itkcommon-with-kwsys-vxl/3863 "2021-02-15T22:14:38Z")

</div>

Greetings! What are the settings via CMake to generate only the basic compilation for ITK right now there is a compilation error with ITK\_BUILD\_DEFAULT\_MODULES option. See error compilation here : https://github.com/co…

---

## [Watershed Output ...](https://discourse.itk.org/t/watershed-output/3866)

<div class="topic-metadata">

**Author:** [@Niklas](https://discourse.itk.org/u/Niklas)\
**Replies:** 2\
**Last updated:** [February 15, 2021, 6:53pm UTC](https://discourse.itk.org/t/watershed-output/3866 "2021-02-15T18:53:29Z")

</div>

I just started with ITK, sorry if question is silly. I’d like to apply the watershed transformation to a 3D float array (with euclidean distance transform). I do have the EDT and input this into the WatershedImageFilter.…

---

## [Resample to same origin, spacing and size as another image.](https://discourse.itk.org/t/resample-to-same-origin-spacing-and-size-as-another-image/3031)

<div class="topic-metadata">

**Author:** [@acambray](https://discourse.itk.org/u/acambray)\
**Replies:** 5\
**Last updated:** [February 12, 2021, 12:27pm UTC](https://discourse.itk.org/t/resample-to-same-origin-spacing-and-size-as-another-image/3031 "2021-02-12T12:27:06Z")

</div>

Hi, I have two nii images, which I load into SimpleITK on Python: 3D CT scan 3D Segmentation Mask (0s and 1s) The segmentation mask has the size of the minimum bounding box around the segmentation and therefore is mu…

---

## [Building SimpleITK as Shared Libs with System HDF5](https://discourse.itk.org/t/building-simpleitk-as-shared-libs-with-system-hdf5/3847)

<div class="topic-metadata">

**Author:** [@rds](https://discourse.itk.org/u/rds)\
**Replies:** 4\
**Last updated:** [February 11, 2021, 4:19pm UTC](https://discourse.itk.org/t/building-simpleitk-as-shared-libs-with-system-hdf5/3847 "2021-02-11T16:19:24Z")

</div>

Hello, I am trying to build SimpleITK ( branch master ) with a system version of HDF5 ( v1.10.5 ) I cloned ITK ( on branch master ), and successfully built it while linking to the system HDF5. When I try to configure…

---

## [下载问题](https://discourse.itk.org/t/topic/3835)

<div class="topic-metadata">

**Author:** [@123456789](https://discourse.itk.org/u/123456789)\
**Replies:** 1\
**Last updated:** [February 4, 2021, 3:07pm UTC](https://discourse.itk.org/t/topic/3835 "2021-02-04T15:07:41Z")

</div>

请问一下InsightApplications在哪下载，官网页面没有找到呢

---

## [No LineIterator class in itk/Python?](https://discourse.itk.org/t/no-lineiterator-class-in-itk-python/3823)

<div class="topic-metadata">

**Author:** [@Tuelle](https://discourse.itk.org/u/Tuelle)\
**Replies:** 1\
**Last updated:** [February 2, 2021, 4:56pm UTC](https://discourse.itk.org/t/no-lineiterator-class-in-itk-python/3823 "2021-02-02T16:56:48Z")

</div>

I want to use the functionality of the LineIterator class (https://itk.org/Doxygen/html/classitk\_1\_1LineIterator.html) in itk with Python (not simple-itk). However, the class seems to be not available in the itk namespac…

---

## [ITK compilation options for PythonWrapper](https://discourse.itk.org/t/itk-compilation-options-for-pythonwrapper/3798)

<div class="topic-metadata">

**Author:** [@Stephan\_Hahn1](https://discourse.itk.org/u/Stephan_Hahn1)\
**Replies:** 5\
**Last updated:** [February 2, 2021, 10:08am UTC](https://discourse.itk.org/t/itk-compilation-options-for-pythonwrapper/3798 "2021-02-02T10:08:19Z")

</div>

Hi everyone, I am using the hessian\_recursive\_gaussian\_image\_filter method from ITK wrapper in python. But I am facing 2 related problems: My IO pipeline is based on SITK and I am transforming SITK to ITK using this t…

[Previous page](https://discourse.itk.org/c/beginner-questions/9.md?no_subcategories=false&page=21)

[Next page](https://discourse.itk.org/c/beginner-questions/9.md?no_subcategories=false&page=23)
