# Latest

**URL:** https://discourse.itk.org/latest.md?page=47

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

**Page:** 48

---

## [Pixel type error when using MergeLabelMapFilter](https://discourse.itk.org/t/pixel-type-error-when-using-mergelabelmapfilter/4390)

<div class="topic-metadata">

**Author:** [@mattwarkentin](https://discourse.itk.org/u/mattwarkentin)\
**Replies:** 5\
**Last updated:** [August 31, 2021, 7:52pm UTC](https://discourse.itk.org/t/pixel-type-error-when-using-mergelabelmapfilter/4390 "2021-08-31T19:52:39Z")

</div>

Hi, I am running into an error when trying to merge several label maps/masks into one label map. The basics of my code are: import SimpleITK as sitk map\_files = \['label\_map1.nrrd', 'label\_map2.nrrd'\] map\_imgs = \[sitk.…

---

## [Image Spacing and BSpline Registration Variability](https://discourse.itk.org/t/image-spacing-and-bspline-registration-variability/4346)

<div class="topic-metadata">

**Author:** [@cdcooke](https://discourse.itk.org/u/cdcooke)\
**Replies:** 9\
**Last updated:** [August 31, 2021, 7:26pm UTC](https://discourse.itk.org/t/image-spacing-and-bspline-registration-variability/4346 "2021-08-31T19:26:28Z")

</div>

Hello All - I have run across something that I don’t quite understand, but I’m hoping someone here can help. I am trying to register 2 medical images (PET, if that matters) using a BSpline registration. The images are…

---

## [interpolate 3d image where the xy planes have 70nm between each other](https://discourse.itk.org/t/interpolate-3d-image-where-the-xy-planes-have-70nm-between-each-other/4383)

<div class="topic-metadata">

**Author:** [@caniko](https://discourse.itk.org/u/caniko)\
**Replies:** 6\
**Last updated:** [August 31, 2021, 7:08am UTC](https://discourse.itk.org/t/interpolate-3d-image-where-the-xy-planes-have-70nm-between-each-other/4383 "2021-08-31T07:08:16Z")

</div>

I am working with electronmicroscopy where we have brain slices along the z-axis, 70nm. I would like to compute the image data that is missing between each image slice, and need help picking the right algorithm (if there…

---

## [Vector Image To Image of Vectors](https://discourse.itk.org/t/vector-image-to-image-of-vectors/4385)

<div class="topic-metadata">

**Author:** [@Tom\_Birdsong](https://discourse.itk.org/u/Tom_Birdsong)\
**Replies:** 4\
**Last updated:** [August 30, 2021, 9:51pm UTC](https://discourse.itk.org/t/vector-image-to-image-of-vectors/4385 "2021-08-30T21:51:09Z")

</div>

Hi all, In discussion on the ITKStrain remote module we recently encountered a question of handling vector-valued image data in the ITK Python wrapping. I’ve worked with itk.VectorImage and itk.Image\[itk.Vector\[t,d\],d\] …

---

## [How removes holes at the boundaries of the 3d image faster?](https://discourse.itk.org/t/how-removes-holes-at-the-boundaries-of-the-3d-image-faster/4349)

<div class="topic-metadata">

**Author:** [@ainor](https://discourse.itk.org/u/ainor)\
**Replies:** 16\
**Last updated:** [August 30, 2021, 5:14am UTC](https://discourse.itk.org/t/how-removes-holes-at-the-boundaries-of-the-3d-image-faster/4349 "2021-08-30T05:14:13Z")

</div>

I am segmenting an image, but when I apply a threshold filter there are some holes left in the surface that I need to fill. To fill in the holes I am using BinaryMorphologicalClosingImageFilter but it is very slow, even …

---

## [control rigidity in bspline registration](https://discourse.itk.org/t/control-rigidity-in-bspline-registration/4380)

<div class="topic-metadata">

**Author:** [@mary\_na](https://discourse.itk.org/u/mary_na)\
**Replies:** 1\
**Last updated:** [August 29, 2021, 6:47pm UTC](https://discourse.itk.org/t/control-rigidity-in-bspline-registration/4380 "2021-08-29T18:47:21Z")

</div>

Hello! In general the cost function of registration optimization could have two part. One for similarity measurement and the other to control rigidity (registration penalty). In itk I just can change similarity metric. I…

---

## [What attributes to write from CompositeTransform Object to which DICOM tags?](https://discourse.itk.org/t/what-attributes-to-write-from-compositetransform-object-to-which-dicom-tags/4376)

<div class="topic-metadata">

**Author:** [@wafflesaregreat](https://discourse.itk.org/u/wafflesaregreat)\
**Replies:** 1\
**Last updated:** [August 29, 2021, 6:40pm UTC](https://discourse.itk.org/t/what-attributes-to-write-from-compositetransform-object-to-which-dicom-tags/4376 "2021-08-29T18:40:03Z")

</div>

Hi everyone, I’m just wondering what kind of information should be written to DICOM meta tags. Ideally, everything regarding the translation and rotation matrices should be written for Image Fusion/Registration purposes …

---

## [GetGDCMSeriesFileNames: ordering of the returned files](https://discourse.itk.org/t/getgdcmseriesfilenames-ordering-of-the-returned-files/4369)

<div class="topic-metadata">

**Author:** [@KrisHan999](https://discourse.itk.org/u/KrisHan999)\
**Replies:** 3\
**Last updated:** [August 26, 2021, 11:49pm UTC](https://discourse.itk.org/t/getgdcmseriesfilenames-ordering-of-the-returned-files/4369 "2021-08-26T23:49:43Z")

</div>

Same as the title, I had a CT series, after running the ‘GetGDCMSeriesFileNames’, the files were returned according to the file name, instead of the z coordinates. I just wonder, how the files are ordered in function ‘Ge…

---

## [Upgrade from 413 to 512 and vnl](https://discourse.itk.org/t/upgrade-from-413-to-512-and-vnl/4370)

<div class="topic-metadata">

**Author:** [@rfrank](https://discourse.itk.org/u/rfrank)\
**Replies:** 3\
**Last updated:** [August 26, 2021, 8:10pm UTC](https://discourse.itk.org/t/upgrade-from-413-to-512-and-vnl/4370 "2021-08-26T20:10:36Z")

</div>

I’m trying to upgrade an existing project that uses vnl directly for some matrix computations. for instance vnl\_vector\_fixed\<float, 4\> temp; loat ctr4\[4\] = {(float) ctr\[0\],(float)ctr\[1\],(float)ctr\[2\],1.0f }; temp.set(c…

---

## [How to write unit testing in itk?](https://discourse.itk.org/t/how-to-write-unit-testing-in-itk/4371)

<div class="topic-metadata">

**Author:** [@priyanka](https://discourse.itk.org/u/priyanka)\
**Replies:** 1\
**Last updated:** [August 26, 2021, 7:46pm UTC](https://discourse.itk.org/t/how-to-write-unit-testing-in-itk/4371 "2021-08-26T19:46:04Z")

</div>

I found “ITKTestHarness” in itk testing framework but I’m getting errors while building it. I’m getting no idea how unit test for images in itk?

---

## [reading stack of images and writing as single image](https://discourse.itk.org/t/reading-stack-of-images-and-writing-as-single-image/4360)

<div class="topic-metadata">

**Author:** [@Won\_Chul\_Chung](https://discourse.itk.org/u/Won_Chul_Chung)\
**Replies:** 3\
**Last updated:** [August 26, 2021, 12:51pm UTC](https://discourse.itk.org/t/reading-stack-of-images-and-writing-as-single-image/4360 "2021-08-26T12:51:43Z")

</div>

Hello, I am trying to perform a simple task where I read in images with for loop, join them together and write it as a single image. But somehow sitk.JoinSeriesImageFilter does not join the images into a single stack, i…

---

## [Interpolate ITK image data at missing / masked pixels (CUDA / C++)](https://discourse.itk.org/t/interpolate-itk-image-data-at-missing-masked-pixels-cuda-c/4363)

<div class="topic-metadata">

**Author:** [@Thibault\_Pelletier](https://discourse.itk.org/u/Thibault_Pelletier)\
**Replies:** 2\
**Last updated:** [August 26, 2021, 7:47am UTC](https://discourse.itk.org/t/interpolate-itk-image-data-at-missing-masked-pixels-cuda-c/4363 "2021-08-26T07:47:59Z")

</div>

Hi everyone, I would like to know if there are any algorithms in ITK which would allow me to interpolate linearily missing pixels of a 2D image data (preferably with a CUDA implementation)? To detail a little more my q…

---

## [Write German Umlauts into MetaData with SimpleITK](https://discourse.itk.org/t/write-german-umlauts-into-metadata-with-simpleitk/4355)

<div class="topic-metadata">

**Author:** [@Philip](https://discourse.itk.org/u/Philip)\
**Replies:** 5\
**Last updated:** [August 26, 2021, 7:09am UTC](https://discourse.itk.org/t/write-german-umlauts-into-metadata-with-simpleitk/4355 "2021-08-26T07:09:09Z")

</div>

Hello friends, I’ve got a problem I am not able to solve. I have to write a German word containing the letters ‘ö’ and ‘ä’ into the MetaData of our Dicom-File. However SITK’s SetMetaData refuses to write it. It always g…

---

## [Is it possible to use GPU for resample filter in simpleITK and Windows?](https://discourse.itk.org/t/is-it-possible-to-use-gpu-for-resample-filter-in-simpleitk-and-windows/4357)

<div class="topic-metadata">

**Author:** [@TY\_Park](https://discourse.itk.org/u/TY_Park)\
**Replies:** 3\
**Last updated:** [August 25, 2021, 6:26pm UTC](https://discourse.itk.org/t/is-it-possible-to-use-gpu-for-resample-filter-in-simpleitk-and-windows/4357 "2021-08-25T18:26:01Z")

</div>

Is it possible to use GPU for image resample in simpleITK or ITK? I checked the previous post, in that, one of the answers was to use the “itk-elastic-opencl” But it seems like work only on Linux Is there any other wa…

---

## [SimpleElastix build issues](https://discourse.itk.org/t/simpleelastix-build-issues/4364)

<div class="topic-metadata">

**Author:** [@i.v.prgrmmr](https://discourse.itk.org/u/i.v.prgrmmr)\
**Replies:** 4\
**Last updated:** [August 25, 2021, 3:28pm UTC](https://discourse.itk.org/t/simpleelastix-build-issues/4364 "2021-08-25T15:28:29Z")

</div>

Hey @sag, Right now I am running into the same problem. However, I am a bit confused, what paths should I define for PYTHON \_EXECUTABLE PYTHON \_INCLUDE\_DIR PYTHON \_LIBRARY? I still have anaconda3. Thanks in advance!

---

## [super build simpleitk python wrapping link error](https://discourse.itk.org/t/super-build-simpleitk-python-wrapping-link-error/3126)

<div class="topic-metadata">

**Author:** [@sag](https://discourse.itk.org/u/sag)\
**Replies:** 4\
**Last updated:** [June 2, 2020, 1:34pm UTC](https://discourse.itk.org/t/super-build-simpleitk-python-wrapping-link-error/3126 "2020-06-02T13:34:40Z")

</div>

hi all, I have managed to super build simplitk for java, csharp I guess!? but when it gets to swig python wrapping code generation at linking time I get link error because super build has discovered a python37.lib x86 l…

---

## [Extract an oblique 2D slice from a 3D volume](https://discourse.itk.org/t/extract-an-oblique-2d-slice-from-a-3d-volume/4137)

<div class="topic-metadata">

**Author:** [@ainor](https://discourse.itk.org/u/ainor)\
**Replies:** 3\
**Last updated:** [May 20, 2021, 1:00pm UTC](https://discourse.itk.org/t/extract-an-oblique-2d-slice-from-a-3d-volume/4137 "2021-05-20T13:00:02Z")

</div>

Hi, can someone give me an idea on how to extract an oblique 2D slice from a 3D volume with a given thickness?

---

## [How to store the segmented results in a container in itk?](https://discourse.itk.org/t/how-to-store-the-segmented-results-in-a-container-in-itk/4337)

<div class="topic-metadata">

**Author:** [@priyanka](https://discourse.itk.org/u/priyanka)\
**Replies:** 9\
**Last updated:** [August 20, 2021, 5:23pm UTC](https://discourse.itk.org/t/how-to-store-the-segmented-results-in-a-container-in-itk/4337 "2021-08-20T17:23:53Z")

</div>

I’m segmenting the dicom slices, I want to store the results in one container. So that I can use them for 3d reconstruction.

---

## [includes target "gdcmjpeg8" more than once in the export set](https://discourse.itk.org/t/includes-target-gdcmjpeg8-more-than-once-in-the-export-set/4344)

<div class="topic-metadata">

**Author:** [@longjiang321](https://discourse.itk.org/u/longjiang321)\
**Replies:** 4\
**Last updated:** [August 19, 2021, 2:32pm UTC](https://discourse.itk.org/t/includes-target-gdcmjpeg8-more-than-once-in-the-export-set/4344 "2021-08-19T14:32:40Z")

</div>

hi friends: I am trying to compile the ITK source code with cmake, the version of ITK is 5.2.1. if I enable the option BUILD\_SHARED\_LIBS, the configure is successfully but generate failed. the error as below: , if…

---

## [BGFDG\_vtkMRMLModelNodeH.vtp does not contain coordinate system information. Assuming LPS](https://discourse.itk.org/t/bgfdg-vtkmrmlmodelnodeh-vtp-does-not-contain-coordinate-system-information-assuming-lps/4342)

<div class="topic-metadata">

**Author:** [@Mahesh\_Timmanagoudar](https://discourse.itk.org/u/Mahesh_Timmanagoudar)\
**Replies:** 1\
**Last updated:** [August 19, 2021, 2:21pm UTC](https://discourse.itk.org/t/bgfdg-vtkmrmlmodelnodeh-vtp-does-not-contain-coordinate-system-information-assuming-lps/4342 "2021-08-19T14:21:00Z")

</div>

Centerline.tre file created correctly. But there is no points in BranchCenterline\_0.fcsv file. We got message in log that is “BGFDG\_vtkMRMLModelNodeH.vtp does not contain coordinate system information” . I have atta…

---

## [Image with defective pixels while export in different image formats(.png, .tiff)](https://discourse.itk.org/t/image-with-defective-pixels-while-export-in-different-image-formats-png-tiff/4340)

<div class="topic-metadata">

**Author:** [@rubellion](https://discourse.itk.org/u/rubellion)\
**Replies:** 3\
**Last updated:** [August 19, 2021, 4:35am UTC](https://discourse.itk.org/t/image-with-defective-pixels-while-export-in-different-image-formats-png-tiff/4340 "2021-08-19T04:35:32Z")

</div>

Good day, while i try to export single image from .nii file in result i get an image but with defective pixels. I also tried to cast image from sitkUInt8 to sitkUInt16 but it become worse. import sys import SimpleITK as…

---

## [Unable to Reading pixel data from DICOM and store in an array.](https://discourse.itk.org/t/unable-to-reading-pixel-data-from-dicom-and-store-in-an-array/4293)

<div class="topic-metadata">

**Author:** [@priyanka](https://discourse.itk.org/u/priyanka)\
**Replies:** 2\
**Last updated:** [August 18, 2021, 7:49am UTC](https://discourse.itk.org/t/unable-to-reading-pixel-data-from-dicom-and-store-in-an-array/4293 "2021-08-18T07:49:48Z")

</div>

I tried printing with tags but I’m finding difficulty.

---

## [ITK 5.2.1 has been released!](https://discourse.itk.org/t/itk-5-2-1-has-been-released/4336)

<div class="topic-metadata">

**Author:** [@matt.mccormick](https://discourse.itk.org/u/matt.mccormick)\
**Replies:** 0\
**Last updated:** [August 17, 2021, 5:21pm UTC](https://discourse.itk.org/t/itk-5-2-1-has-been-released/4336 "2021-08-17T17:21:54Z")

</div>

ITK 5.2.1 Release Notes We are happy to announce the Insight Toolkit (ITK) 5.2.1! :tada: Python Packages Install ITK Python packages with: pip install --upgrade itk Guide and Textbook InsightSoftwareGuide-Book1-5.2…

---

## [NIfTI-1 or NIfTI-2 Data format](https://discourse.itk.org/t/nifti-1-or-nifti-2-data-format/4330)

<div class="topic-metadata">

**Author:** [@Iryna\_Galytska](https://discourse.itk.org/u/Iryna_Galytska)\
**Replies:** 4\
**Last updated:** [August 16, 2021, 8:08am UTC](https://discourse.itk.org/t/nifti-1-or-nifti-2-data-format/4330 "2021-08-16T08:08:00Z")

</div>

Could you please advise which data format is used when saving image file e.g. with GetImageFromArray(voxel\_buffer) and ImageFileWriter() NIfTI-1 or NIfTI-2 ? is there posibility to specify explicitly data format (NIfTI-1…

---

## [SimpleITK ImageFileWriter give a wrong tag](https://discourse.itk.org/t/simpleitk-imagefilewriter-give-a-wrong-tag/4334)

<div class="topic-metadata">

**Author:** [@zhang-qiang-github](https://discourse.itk.org/u/zhang-qiang-github)\
**Replies:** 2\
**Last updated:** [August 16, 2021, 2:48am UTC](https://discourse.itk.org/t/simpleitk-imagefilewriter-give-a-wrong-tag/4334 "2021-08-16T02:48:37Z")

</div>

I have some process for a image, and I want to save the result. The complete code to save image is: writer = sitk.ImageFileWriter() writer.KeepOriginalImageUIDOn() writer…

---

## [SimpleITK wrong Resampling](https://discourse.itk.org/t/simpleitk-wrong-resampling/4333)

<div class="topic-metadata">

**Author:** [@machadoL](https://discourse.itk.org/u/machadoL)\
**Replies:** 1\
**Last updated:** [August 15, 2021, 5:48pm UTC](https://discourse.itk.org/t/simpleitk-wrong-resampling/4333 "2021-08-15T17:48:47Z")

</div>

Guys, I need help reviewing this code. I am trying to resample a MRI FLAIR image in to a 1mm x 1mm x 1mm space, and then resample that image’s label according to the resampled image. Everything sound ok, BUT the result …

---

## [SimpleITK: demons registration filter requere the size of fixed/moving image to be the same](https://discourse.itk.org/t/simpleitk-demons-registration-filter-requere-the-size-of-fixed-moving-image-to-be-the-same/4335)

<div class="topic-metadata">

**Author:** [@zhang-qiang-github](https://discourse.itk.org/u/zhang-qiang-github)\
**Replies:** 1\
**Last updated:** [August 15, 2021, 3:29pm UTC](https://discourse.itk.org/t/simpleitk-demons-registration-filter-requere-the-size-of-fixed-moving-image-to-be-the-same/4335 "2021-08-15T15:29:31Z")

</div>

I want to use the demons registration method of SimpleITK between two images with different image size. For example, a 64X64X64 (moving image) and 128X128X128 (fixed image). import SimpleITK as sitk import numpy as np f…

---

## [Help getting started with python wrapping](https://discourse.itk.org/t/help-getting-started-with-python-wrapping/3612)

<div class="topic-metadata">

**Author:** [@doconnell](https://discourse.itk.org/u/doconnell)\
**Replies:** 9\
**Last updated:** [August 13, 2021, 8:47am UTC](https://discourse.itk.org/t/help-getting-started-with-python-wrapping/3612 "2021-08-13T08:47:48Z")

</div>

Hello, I’m having some trouble using the ITK python wrapping functionality. I’m trying to work through the basic python examples but I’m unable to import ITK even after copying the WrapITK.pth file to my site-packages d…

---

## [How to delete points in a tube spatial object?](https://discourse.itk.org/t/how-to-delete-points-in-a-tube-spatial-object/4322)

<div class="topic-metadata">

**Author:** [@Mahesh\_Timmanagoudar](https://discourse.itk.org/u/Mahesh_Timmanagoudar)\
**Replies:** 4\
**Last updated:** [August 11, 2021, 8:18pm UTC](https://discourse.itk.org/t/how-to-delete-points-in-a-tube-spatial-object/4322 "2021-08-11T20:18:30Z")

</div>

Graft Plan Log.txt (12.6 KB) I have changed as per the following link. Spatial Objects Refactoring section of the ITK 5 Migration Guide. I got run time error while executing below code. /\*\* Remove duplicate points \*/…

---

## [Patches for ITK 5.2.1](https://discourse.itk.org/t/patches-for-itk-5-2-1/4323)

<div class="topic-metadata">

**Author:** [@matt.mccormick](https://discourse.itk.org/u/matt.mccormick)\
**Replies:** 3\
**Last updated:** [August 11, 2021, 8:06pm UTC](https://discourse.itk.org/t/patches-for-itk-5-2-1/4323 "2021-08-11T20:06:03Z")

</div>

Hi folks, The next patch (bugfix) release, ITK 5.2.1, is coming up. Patches currently staged on the Git release branch are: Bradley Lowekamp (7): BUG: Register ComposeScaleSkewVersor3DTransform transform B…

[Previous page](https://discourse.itk.org/latest.md?page=46)

[Next page](https://discourse.itk.org/latest.md?page=48)
