Comments (12)
It seems JoinSeriesImageFilter does not have support for 4D images at all. This is a bug. Will fix it.
from simpleelastix.
Hi gattia, JoinSeriesImageFilter should now have support for 4D images. Run git pull
in the SimpleElastix source directory and rebuild. Let me know how it goes.
from simpleelastix.
Thanks for the fix! That did the trick to running the JoinSeries.
Though, I ended up having issues using it because the images have different origins and slightly different axes. Is this common? I got around it by relaxing the tolerances using these commands:
sitk.ProcessObject.SetGlobalDefaultDirectionTolerance(1)
sitk.ProcessObject.SetGlobalDefaultCoordinateTolerance(1)
I also had to set all of the origins to the same as one of the images. I am assuming these changes aren't best practice? Your example doesn't talk about any of these problems but with using any group for MRI or other data I am assuming it would be the case. What is typical practice?
Thanks,
Anthony.
from simpleelastix.
It is certainly not best practice but I do it myself all the time. I believe the issue is with the origin and direction being slightly modified as they pass through the ITK pipeline, see e.g. this discussion on the ITK mailing list. You may also have to do it after elastix registration (I know I do). I usually just
resultImage.CopyInformation(fixedImage)
because the result image is being transformed to the fixed image domain so these should be equal anyway. The documentation could indeed be improved in this area. You are very welcome to submit a PR, otherwise I will do it when I get the time.
from simpleelastix.
Thanks for the response. I will take an attempt at a pull request/edit to that portion of the document. It will be my first :).
Anthony.
from simpleelastix.
Hi !
I built SimpleElastix with the latest git version. Nonetheless I experience exactly the same issue that gattia exposed in his first message.
I hope that you will be able to help me,
Pierre
from simpleelastix.
Did you set the SimpleITK_4D_IMAGES
CMake variable to ON
?
from simpleelastix.
Yes I did.
from simpleelastix.
What is the error message you are seeing?
from simpleelastix.
I got the following error for any pixel type :
Traceback (most recent call last): File "dose_tracking_pierre_2.py", line 36, in <module> image = sitk.JoinSeries(image_vector) File "/usr/lib/python2.7/site-packages/SimpleITK/SimpleITK.py", line 39910, in JoinSeries return _SimpleITK.JoinSeries(*args) RuntimeError: Exception thrown in SimpleITK JoinSeries: /home/pgranger/Documents/Stage_M1/SimpleElastix/Code/Common/include/sitkMemberFunctionFactory.hxx:196: sitk::ERROR: Pixel type: 32-bit signed integer is not supported in 3D byN3itk6simple21JoinSeriesImageFilterE
I just load 3D images and try to Join them in a 4D image.
from simpleelastix.
Try to pull and rebuild the develop branch and let me know how it goes.
from simpleelastix.
I did as you said and it perfectly solved my issue, thank you very much !
from simpleelastix.
Related Issues (20)
- RuntimeError: Exception thrown in SimpleITK Elastix HOT 1
- AffineDTITransform does not return the CenterOfRotationPoint
- windows user :thank you very much
- Gradient based optimizer: how to control learning rate HOT 2
- Rigid transformation warping with "TransformixImageFilter"
- error of compiling on linux
- Fatal error LNK1181
- Error while installing SimpleElastix on Windows. HOT 1
- Shearing matrix composition in Affine DTI 3D Transform
- Failed to build on Win10 HOT 3
- affine registration outcome measurement
- A lot of console output even after turning it off HOT 1
- Registration with initial transform obtained using SimpleITK/etc. (.tfm file) HOT 1
- The ElastixImageFilter stuck when using iterative InitialTransformParameterFileName.
- Unable to create/compile/build SimpleElastix C++ dynamic or static library in 32bit or 64-bit.
- Trouble understanding basic usage
- Is there a way to save the transform to a .tfm file?
- AttributeError: module 'SimpleITK' has no attribute 'VesselnessMeasureImageFilter'
- Use only corresponding points based transformation
- SimpleElastix no longer maintained, use SimpleITK or ITKElastix!
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from simpleelastix.