# Uncategorized

**URL:** https://discourse.itk.org/c/uncategorized/1.md?page=3

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

**Page:** 4

---

## [MetaImage: M\_ReadElementsROI: data not read completely](https://discourse.itk.org/t/metaimage-m-readelementsroi-data-not-read-completely/4269)

<div class="topic-metadata">

**Author:** [@JK\_Kim](https://discourse.itk.org/u/JK_Kim)\
**Replies:** 11\
**Last updated:** [July 22, 2023, 1:23pm UTC](https://discourse.itk.org/t/metaimage-m-readelementsroi-data-not-read-completely/4269 "2023-07-22T13:23:01Z")

</div>

Hi I am using SimpleITK 2.0.2 and Python 3.7.9 to read a 3D CT image in the compressed mhd format (ct.mhd, ct.zraw). When I run the code below, I am getting the following message. “data not read completely”. So, I save…

---

## [How to get auto WLWW with SImpleITK in JAVA](https://discourse.itk.org/t/how-to-get-auto-wlww-with-simpleitk-in-java/6085)

<div class="topic-metadata">

**Author:** [@Salu\_Ramos](https://discourse.itk.org/u/Salu_Ramos)\
**Replies:** 1\
**Last updated:** [July 21, 2023, 7:36pm UTC](https://discourse.itk.org/t/how-to-get-auto-wlww-with-simpleitk-in-java/6085 "2023-07-21T19:36:39Z")

</div>

For example, Radiant dicom viewer has “auto window level window width” preset marked as default, that is different for each dicom file. opening dicom file 1: opening dicom file 2: opening dicom file 3: The ques…

---

## [Java SimpleITK Slice extraction and display with JavaFX](https://discourse.itk.org/t/java-simpleitk-slice-extraction-and-display-with-javafx/6055)

<div class="topic-metadata">

**Author:** [@Salu\_Ramos](https://discourse.itk.org/u/Salu_Ramos)\
**Replies:** 18\
**Last updated:** [July 20, 2023, 5:48pm UTC](https://discourse.itk.org/t/java-simpleitk-slice-extraction-and-display-with-javafx/6055 "2023-07-20T17:48:21Z")

</div>

Hi, i am trying to get a slice from any axis like axial, sagital or coronal from dicom volume, i already made it with python, but due to python limitations i migrate to java. this is how i load the volume: public sta…

---

## [How to get Metadata with SimpleITK in Java](https://discourse.itk.org/t/how-to-get-metadata-with-simpleitk-in-java/6066)

<div class="topic-metadata">

**Author:** [@Salu\_Ramos](https://discourse.itk.org/u/Salu_Ramos)\
**Replies:** 2\
**Last updated:** [July 13, 2023, 6:34pm UTC](https://discourse.itk.org/t/how-to-get-metadata-with-simpleitk-in-java/6066 "2023-07-13T18:34:56Z")

</div>

i have a dicom folder that contains many dicom files, i load then using this code: public static org.itk.simple.Image loadLocalFolder (Stage stage) throws Exception { String dicomFolderPath = LocalLoader.selectF…

---

## [slice along a random direction to get 2D slice from 3D volume](https://discourse.itk.org/t/slice-along-a-random-direction-to-get-2d-slice-from-3d-volume/6056)

<div class="topic-metadata">

**Author:** [@swetha.bsharma](https://discourse.itk.org/u/swetha.bsharma)\
**Replies:** 0\
**Last updated:** [July 11, 2023, 3:59pm UTC](https://discourse.itk.org/t/slice-along-a-random-direction-to-get-2d-slice-from-3d-volume/6056 "2023-07-11T15:59:34Z")

</div>

Hi, I want to reslice a volume in a user defined direction. I have used LookatTransform in c++ version long time back ,I am not able to find it in the python version.Is there a similar transform available in python. i…

---

## [Csharp \[c#\] wrappings for ITK (and Plastimatch)](https://discourse.itk.org/t/csharp-c-wrappings-for-itk-and-plastimatch/5472)

<div class="topic-metadata">

**Author:** [@G\_Tom](https://discourse.itk.org/u/G_Tom)\
**Replies:** 5\
**Last updated:** [July 5, 2023, 8:51pm UTC](https://discourse.itk.org/t/csharp-c-wrappings-for-itk-and-plastimatch/5472 "2023-07-05T20:51:08Z")

</div>

Hi , I want to use itk from C# application. So far, I know simple itk works with c# but I am interested in using the plastimatch library which is simply heavily built on ITK. Plastimatch documentation — Plastimatch 1.9.…

---

## [Hurry! Some problems about similarity measurement.](https://discourse.itk.org/t/hurry-some-problems-about-similarity-measurement/6011)

<div class="topic-metadata">

**Author:** [@ljjiayou](https://discourse.itk.org/u/ljjiayou)\
**Replies:** 6\
**Last updated:** [June 25, 2023, 7:12am UTC](https://discourse.itk.org/t/hurry-some-problems-about-similarity-measurement/6011 "2023-06-25T07:12:09Z")

</div>

I am doing a task, which is to rotate the reference image and the registered image to observe the change of the evaluation index. Is there any relevant code? I also need to observe different evaluation indicators. What …

---

## [Transformation matrix](https://discourse.itk.org/t/transformation-matrix/6004)

<div class="topic-metadata">

**Author:** [@feeling](https://discourse.itk.org/u/feeling)\
**Replies:** 3\
**Last updated:** [June 25, 2023, 1:57am UTC](https://discourse.itk.org/t/transformation-matrix/6004 "2023-06-25T01:57:05Z")

</div>

Hello everyone: I am using SimpleITK to align a set of images, let’s say A is a fixed image and B is a moving image, I have done various alignments including Translation, Euler, Affine and got a series of TransformParam…

---

## [itksnap txt file saved after manual registration](https://discourse.itk.org/t/itksnap-txt-file-saved-after-manual-registration/5983)

<div class="topic-metadata">

**Author:** [@ljjiayou](https://discourse.itk.org/u/ljjiayou)\
**Replies:** 3\
**Last updated:** [June 8, 2023, 2:00pm UTC](https://discourse.itk.org/t/itksnap-txt-file-saved-after-manual-registration/5983 "2023-06-08T14:00:37Z")

</div>

This is the txt file that I saved after manually registering itksnap： #Insight Transform File V1.0 #Transform 0 Transform: MatrixOffsetTransformBase\_double\_3\_3 Parameters: 0.9999932831934126 -0.00005697241326605847 -…

---

## [2D affine registration metric/performance](https://discourse.itk.org/t/2d-affine-registration-metric-performance/5967)

<div class="topic-metadata">

**Author:** [@banikr](https://discourse.itk.org/u/banikr)\
**Replies:** 3\
**Last updated:** [May 28, 2023, 6:33pm UTC](https://discourse.itk.org/t/2d-affine-registration-metric-performance/5967 "2023-05-28T18:33:02Z")

</div>

Fixed image: Moving image: the images come from different modalities and do not have labels/annotations. Though visually the center elliptical anatomy overlap, is there a way I can come up with a metric that only c…

---

## [can MultiResolutionPDEDeformableRegistration filter use itk::GPUImage type?](https://discourse.itk.org/t/can-multiresolutionpdedeformableregistration-filter-use-itk-gpuimage-type/5958)

<div class="topic-metadata">

**Author:** [@zx-lhb](https://discourse.itk.org/u/zx-lhb)\
**Replies:** 2\
**Last updated:** [May 22, 2023, 12:53am UTC](https://discourse.itk.org/t/can-multiresolutionpdedeformableregistration-filter-use-itk-gpuimage-type/5958 "2023-05-22T00:53:27Z")

</div>

hi, i used MultiResolutionPDEDeformableRegistration and DemonsRegistrationFilter to do registration, it worked fine. Then I changed DemonsRegistrationFilter to GPUDemonsRegistrationFilter, and let the InternalImageType a…

---

## [Relationship between DICOM coordinate system and IEC 61217 coordinate system](https://discourse.itk.org/t/relationship-between-dicom-coordinate-system-and-iec-61217-coordinate-system/3508)

<div class="topic-metadata">

**Author:** [@zhuangming.shen](https://discourse.itk.org/u/zhuangming.shen)\
**Replies:** 4\
**Last updated:** [May 20, 2023, 4:42am UTC](https://discourse.itk.org/t/relationship-between-dicom-coordinate-system-and-iec-61217-coordinate-system/3508 "2023-05-20T04:42:39Z")

</div>

Do anyone know what’s the relationship between the DICOM coordinate system used by ITK and IEC 61217 coordinate system such as gantry coordinate system, beam limiting device coordinate system, etc? How can I transform be…

---

## [Free form deformation or B-spline](https://discourse.itk.org/t/free-form-deformation-or-b-spline/5895)

<div class="topic-metadata">

**Author:** [@banikr](https://discourse.itk.org/u/banikr)\
**Replies:** 2\
**Last updated:** [May 1, 2023, 4:59pm UTC](https://discourse.itk.org/t/free-form-deformation-or-b-spline/5895 "2023-05-01T16:59:54Z")

</div>

I am trying to perform multi-resolution free form deformation/B-spline between two 2D images by following this: http://insightsoftwareconsortium.github.io/SimpleITK-Notebooks/Python\_html/65\_Registration\_FFD.html I don’t…

---

## [It's been chaotic lately. My purpose is to calculate the normalized mutual information of pre-registration and post-registration images, and make a comparison to observe the registration effect.](https://discourse.itk.org/t/its-been-chaotic-lately-my-purpose-is-to-calculate-the-normalized-mutual-information-of-pre-registration-and-post-registration-images-and-make-a-comparison-to-observe-the-registration-effect/5910)

<div class="topic-metadata">

**Author:** [@ljjiayou](https://discourse.itk.org/u/ljjiayou)\
**Replies:** 1\
**Last updated:** [April 30, 2023, 9:01pm UTC](https://discourse.itk.org/t/its-been-chaotic-lately-my-purpose-is-to-calculate-the-normalized-mutual-information-of-pre-registration-and-post-registration-images-and-make-a-comparison-to-observe-the-registration-effect/5910 "2023-04-30T21:01:19Z")

</div>

It’s been chaotic lately. My purpose is to calculate the normalized mutual information of pre-registration and post-registration images, and make a comparison to observe the registration effect. This is my code for cal…

---

## [ITK/SimpleITK code spell checking](https://discourse.itk.org/t/itk-simpleitk-code-spell-checking/5893)

<div class="topic-metadata">

**Author:** [@dchen](https://discourse.itk.org/u/dchen)\
**Replies:** 4\
**Last updated:** [April 25, 2023, 1:01pm UTC](https://discourse.itk.org/t/itk-simpleitk-code-spell-checking/5893 "2023-04-25T13:01:02Z")

</div>

Recently, I’ve been working on spell checking the headers in ITK’s code base. My goal has been to improve the ITK/SimpleITK documentation which gets pulled from the headers. I’m posting here just to memorialize my work…

---

## [TransformContinuousIndexToPhysicalPoint got a different result](https://discourse.itk.org/t/transformcontinuousindextophysicalpoint-got-a-different-result/5885)

<div class="topic-metadata">

**Author:** [@ljjiayou](https://discourse.itk.org/u/ljjiayou)\
**Replies:** 4\
**Last updated:** [April 21, 2023, 8:08pm UTC](https://discourse.itk.org/t/transformcontinuousindextophysicalpoint-got-a-different-result/5885 "2023-04-21T20:08:40Z")

</div>

I took this line of code directly and got a different result than the world coordinates I saw in ITKsnap. Same image and index. why? this is my code : TransformContinuousIndexToPhysicalPoint

---

## [FFTNormalizedCrossCorrelation: Get location in image](https://discourse.itk.org/t/fftnormalizedcrosscorrelation-get-location-in-image/5789)

<div class="topic-metadata">

**Author:** [@elapins](https://discourse.itk.org/u/elapins)\
**Replies:** 9\
**Last updated:** [April 14, 2023, 1:29pm UTC](https://discourse.itk.org/t/fftnormalizedcrosscorrelation-get-location-in-image/5789 "2023-04-14T13:29:40Z")

</div>

Hello, I have written the following code, and obtained the correct maximum value from the FFT Normalized Cross Correlation tools in SimpleITK. I am now wondering, how I can get this maximum value location(x,y) within t…

---

## [Why is the final mutual information obtained in the registration process different from the mutual information of the image after I calculate the registration](https://discourse.itk.org/t/why-is-the-final-mutual-information-obtained-in-the-registration-process-different-from-the-mutual-information-of-the-image-after-i-calculate-the-registration/5860)

<div class="topic-metadata">

**Author:** [@ljjiayou](https://discourse.itk.org/u/ljjiayou)\
**Replies:** 2\
**Last updated:** [April 12, 2023, 3:23am UTC](https://discourse.itk.org/t/why-is-the-final-mutual-information-obtained-in-the-registration-process-different-from-the-mutual-information-of-the-image-after-i-calculate-the-registration/5860 "2023-04-12T03:23:10Z")

</div>

this is my code initial\_transform = sitk.CenteredTransformInitializer(fixed\_image, moving\_image, sitk.Eul…

---

## [Provide Your Thoughts on Kitware's Training Courses](https://discourse.itk.org/t/provide-your-thoughts-on-kitwares-training-courses/5850)

<div class="topic-metadata">

**Author:** [@matt.mccormick](https://discourse.itk.org/u/matt.mccormick)\
**Replies:** 0\
**Last updated:** [April 4, 2023, 1:04pm UTC](https://discourse.itk.org/t/provide-your-thoughts-on-kitwares-training-courses/5850 "2023-04-04T13:04:43Z")

</div>

Kitware is looking for input about our paid public training courses. Our goal is to offer the highest quality, most relevant training material to help users and developers become experts with our popular open source soft…

---

## [How to use code to implement the function of colormap image and overlay two images like itksnap](https://discourse.itk.org/t/how-to-use-code-to-implement-the-function-of-colormap-image-and-overlay-two-images-like-itksnap/5840)

<div class="topic-metadata">

**Author:** [@ljjiayou](https://discourse.itk.org/u/ljjiayou)\
**Replies:** 2\
**Last updated:** [April 4, 2023, 3:28am UTC](https://discourse.itk.org/t/how-to-use-code-to-implement-the-function-of-colormap-image-and-overlay-two-images-like-itksnap/5840 "2023-04-04T03:28:30Z")

</div>

this my code, why it goes wrong?What code should I write colormap = sitk.Colormap(4) # jet mapped\_image = sitk.ScalarToRGBColormap(im1, colormap) image\_viewer.Execute(mapped\_image)

---

## [What is the scope of mutual information](https://discourse.itk.org/t/what-is-the-scope-of-mutual-information/5811)

<div class="topic-metadata">

**Author:** [@ljjiayou](https://discourse.itk.org/u/ljjiayou)\
**Replies:** 3\
**Last updated:** [March 21, 2023, 1:00pm UTC](https://discourse.itk.org/t/what-is-the-scope-of-mutual-information/5811 "2023-03-21T13:00:42Z")

</div>

this is my code: registation=sitk.ImageRegistrationMethod() registation.SetMetricAsMattesMutualInformation(numberOfHistogramBins=50) registation.SetMetricSamplingStrategy(registation.NONE) registation.SetMetricSampli…

---

## [flip two anatomical planes of the 3D image but failed](https://discourse.itk.org/t/flip-two-anatomical-planes-of-the-3d-image-but-failed/5806)

<div class="topic-metadata">

**Author:** [@ljjiayou](https://discourse.itk.org/u/ljjiayou)\
**Replies:** 7\
**Last updated:** [March 17, 2023, 3:48am UTC](https://discourse.itk.org/t/flip-two-anatomical-planes-of-the-3d-image-but-failed/5806 "2023-03-17T03:48:25Z")

</div>

I want to mirror and flip two anatomical planes of the 3D image, using the following code. It was successful on the image size of (481481481), with two anatomical planes reversed, but failed on the other image size of (2…

---

## [applying saved transforms/registration to the subsequent channels](https://discourse.itk.org/t/applying-saved-transforms-registration-to-the-subsequent-channels/5797)

<div class="topic-metadata">

**Author:** [@banikr](https://discourse.itk.org/u/banikr)\
**Replies:** 4\
**Last updated:** [March 15, 2023, 3:20pm UTC](https://discourse.itk.org/t/applying-saved-transforms-registration-to-the-subsequent-channels/5797 "2023-03-15T15:20:59Z")

</div>

Suppose I am using the red channel of a RGB image, as it carries the most details. Now I applied a working registration method as following: initial\_transform = sitk.Euler2DTransform(sitk.CenteredTransformInitializer( …

---

## [RuntimeError: Exception thrown in SimpleITK Image\_CopyInformation: /tmp/SimpleITK/Code/Common/src/sitkImage.cxx:278: sitk::ERROR: Source Image for information does not match this image's dimension.](https://discourse.itk.org/t/runtimeerror-exception-thrown-in-simpleitk-image-copyinformation-tmp-simpleitk-code-common-src-sitkimage-cxx-sitk-source-image-for-information-does-not-match-this-images-dimension/5787)

<div class="topic-metadata">

**Author:** [@banikr](https://discourse.itk.org/u/banikr)\
**Replies:** 2\
**Last updated:** [March 10, 2023, 12:06am UTC](https://discourse.itk.org/t/runtimeerror-exception-thrown-in-simpleitk-image-copyinformation-tmp-simpleitk-code-common-src-sitkimage-cxx-sitk-source-image-for-information-does-not-match-this-images-dimension/5787 "2023-03-10T00:06:51Z")

</div>

I am working on multiscale\_demons registration and getting the following error from this line here: 66\_Registration\_Demons Error: Traceback (most recent call last): File "/home/banikr/PycharmProjects/registration/Reg…

---

## [ITK ERROR: MattesMutualInformationImageToImageMetricv4(000002CDB6B52D80): ....](https://discourse.itk.org/t/itk-error-mattesmutualinformationimagetoimagemetricv4-000002cdb6b52d80/5746)

<div class="topic-metadata">

**Author:** [@banikr](https://discourse.itk.org/u/banikr)\
**Replies:** 2\
**Last updated:** [February 23, 2023, 1:03am UTC](https://discourse.itk.org/t/itk-error-mattesmutualinformationimagetoimagemetricv4-000002cdb6b52d80/5746 "2023-02-23T01:03:07Z")

</div>

I am trying to register a segmented image on an MR image. image shapes: (22, 20) (22, 20) The MR image has intensity normalized from 0-1. The segmentation map has labels from 0-3(0 - background). Both images need som…

---

## [Rigid + Affine registration 2D implementation with iteration](https://discourse.itk.org/t/rigid-affine-registration-2d-implementation-with-iteration/5767)

<div class="topic-metadata">

**Author:** [@banikr](https://discourse.itk.org/u/banikr)\
**Replies:** 6\
**Last updated:** [March 2, 2023, 12:15am UTC](https://discourse.itk.org/t/rigid-affine-registration-2d-implementation-with-iteration/5767 "2023-03-02T00:15:23Z")

</div>

I am trying to apply Euler2D rotation with Affine registration in an iterative manner. Something done here https://itk.org/ITKSoftwareGuide/html/Book2/ITKSoftwareGuide-Book2ch3.html#x26-110175r30 at section 3.6.5. Now …

---

## [why prefer isotropic over anisotropic for medical image datasets?](https://discourse.itk.org/t/why-prefer-isotropic-over-anisotropic-for-medical-image-datasets/5751)

<div class="topic-metadata">

**Author:** [@loa2023\_fme](https://discourse.itk.org/u/loa2023_fme)\
**Replies:** 1\
**Last updated:** [February 24, 2023, 2:23pm UTC](https://discourse.itk.org/t/why-prefer-isotropic-over-anisotropic-for-medical-image-datasets/5751 "2023-02-24T14:23:18Z")

</div>

refer ResampleVolumesToBeIsotropic.cxx I am new to medical image processing. I can understand that visualization on a plane can be distorted for anisotropic data, but I cannot appreciate “I do not think 3D is informati…

---

## [After the rotation of the image, some parts will be missing. How can we enlarge the visual field of the image to get the complete image?](https://discourse.itk.org/t/after-the-rotation-of-the-image-some-parts-will-be-missing-how-can-we-enlarge-the-visual-field-of-the-image-to-get-the-complete-image/5748)

<div class="topic-metadata">

**Author:** [@ljjiayou](https://discourse.itk.org/u/ljjiayou)\
**Replies:** 1\
**Last updated:** [February 23, 2023, 10:25am UTC](https://discourse.itk.org/t/after-the-rotation-of-the-image-some-parts-will-be-missing-how-can-we-enlarge-the-visual-field-of-the-image-to-get-the-complete-image/5748 "2023-02-23T10:25:31Z")

</div>

transform = sitk.Euler3DTransform(center ,0.5,0,0,(100,0,0)) image\_resampled = sitk.Resample(moving\_image, transform) My image is private and can’t be released, my image is 3D.

---

## [Why is the image transformed into an all-black image?And the origin of the image doesn't change](https://discourse.itk.org/t/why-is-the-image-transformed-into-an-all-black-image-and-the-origin-of-the-image-doesnt-change/5731)

<div class="topic-metadata">

**Author:** [@ljjiayou](https://discourse.itk.org/u/ljjiayou)\
**Replies:** 3\
**Last updated:** [February 23, 2023, 9:02am UTC](https://discourse.itk.org/t/why-is-the-image-transformed-into-an-all-black-image-and-the-origin-of-the-image-doesnt-change/5731 "2023-02-23T09:02:50Z")

</div>

def get\_center(img): """ This function returns the physical center point of a 3d sitk image :param img: The sitk image we are trying to find the center of :return: The physical center point of the image …

---

## [Creating mask from rtstruct](https://discourse.itk.org/t/creating-mask-from-rtstruct/3826)

<div class="topic-metadata">

**Author:** [@roirodriguez](https://discourse.itk.org/u/roirodriguez)\
**Replies:** 4\
**Last updated:** [February 16, 2023, 5:45pm UTC](https://discourse.itk.org/t/creating-mask-from-rtstruct/3826 "2023-02-16T17:45:57Z")

</div>

Hi, I’m just beginning with SimpleITK and all other medical image related software. I’m actually loading some dicom series and their corresponding RTSTRUCT contours in python, manually with numpy, because as far as i kn…

[Previous page](https://discourse.itk.org/c/uncategorized/1.md?page=2)

[Next page](https://discourse.itk.org/c/uncategorized/1.md?page=4)
