hsokooti / regnet Goto Github PK
View Code? Open in Web Editor NEWNonrigid image registration using multi-scale 3D convolutional neural networks
License: Apache License 2.0
Nonrigid image registration using multi-scale 3D convolutional neural networks
License: Apache License 2.0
RuntimeError: Exception thrown in SimpleITK ReadImage: C:\Users\dashboard\Miniconda3\conda-bld\simpleitk_1521730316398\work\Code\IO\src\sitkImageReaderBase.cxx:89:
sitk::ERROR: The file "/srv/2-lkeb-16-reg1/hsokooti/DL/Elastix/LungExp/ExpLung11/Result/MovingImageFullRS1.mha" does not exist.
Hi .I want to run your code.but how to get the dataset ?Thank you .
Traceback (most recent call last):
File "/usr/lib/python3.5/runpy.py", line 184, in _run_module_as_main
"__main__", mod_spec)
File "/usr/lib/python3.5/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/home/markemus/dev/RegNet/RegNet3D.py", line 17, in <module>
import functions.RegNetModel as RegNetModel
File "/home/markemus/dev/RegNet/functions/RegNetModel/__init__.py", line 17, in <module>
from .crop1_connection import crop1_connection
ImportError: No module named 'functions.RegNetModel.crop1_connection'
I got this error trying to run RegNet3D.py. Commenting those imports fixed the error, and grep doesn't show any usage for them.
Do I need to adjust the landmark coordinate after I resample the origin image?
Hi, thank you for that your code have helped me a lot.
However, I am confused about some of your ideas, especially about patch.
How to solve this problem?
Thanks a lot if you could answer my doubts.
1
The code is great. Is the used CT dataset SPREAD for experiments publicly available?
Do I haven't to use the "index_elx_new_address_list" and "point_elx_new_address_list" if I don't want to use the elastix?
Hi @hsokooti I'm having trouble figuring out how to preprocess and load data into the net. I saw your post linking some datasets, but the model seems to load *.mha files and they all seem to be in other formats. Additionally, I'm not sure where to put the data in the directory structure; the documentation seems to be outdated and the setting["DLFolder"] key doesn't exist anymore.
What is the version of Dependencies used for this project? Also which version of Python is used?
Dear Hsokooti,
thanks for creating this repo. I have read your paper and it looks interesting... hence I would like to replicate it myself. However I do notice that (IMO) your code can be improved. Both in terms of readability as well as reduction in redundancy. Since I want to help to improve it, I would like to offer my suggestions. However I don't know how to 'post' these.. are you able to help me with that?
Besides that I have, for now, one question that I want to ask. In the script where you create synthetic DVFs, there is a option for blob() and smooth(). Both create a DVFb, but blob(), in addition, creates an DeformedArea surface.
As far as I could tell, the DVFb is introduced to transform one set of images to a transformed version. This fixed and moved image are then used to train the model.
However, I cant find where the DeformedArea object is used again. I believe you do show an image of that in the README.md, but I don't see that it transform some original image like DVFb does. Am I missing something?
Thanks for sharing the source code which is super helpful for understanding the method. Based on my understanding the network takes patches as input. May I ask how to estimate the DVF during testing given a pair of input images, ideally in a single shot?
What's the meaning of "The superior-inferior axis needs to be flipped"? Why have to do that?
I'm trying to load the DIR-lab 4DCT dataset, but I've run into some trouble.
I downloaded the dataset from dir-lab.com, and applied the following pre-processing steps:
-downloaded all 10 data sets.
-renamed *-ssm.img to *_s.img (to silence errors from dirlab.py).
-ran the dirlab.py module on the img files.
-copied the resulting mha directory to /srv/mymachine/hsokooti/Data/DIR-Lab/4DCT/.
However, running RegNet3D.py throws the following error:
[MainThread ] ---------------------------------Fri Nov 9 11:21:44 2018--------------------------------
[MainThread ] ----------------------------------start experiment------------------------------
[MainThread ] number of images in the last chunk=12
[MainThread ] SyntheticDeformation[generation]: start DIR-Lab_4D/3D_max7_D9//T40/case2/Dsmooth0/DNext3/nextIm.mha
[MainThread ] Process Process-1:
[MainThread ] Traceback (most recent call last):
[MainThread ] File "/usr/lib/python3.5/multiprocessing/process.py", line 249, in _bootstrap
[MainThread ] self.run()
[MainThread ] File "/usr/lib/python3.5/multiprocessing/process.py", line 93, in run
[MainThread ] self._target(*self._args, **self._kwargs)
[MainThread ] File "/home/markemus/dev/RegNet/functions/reading/direct_1st_epoch.py", line 49, in run
[MainThread ] self.fill()
[MainThread ] File "/home/markemus/dev/RegNet/functions/reading/direct_1st_epoch.py", line 85, in fill
[MainThread ] mode_synthetic_dvf='generation'
[MainThread ] File "/home/markemus/dev/RegNet/functions/synthetic_deformation.py", line 63, in get_dvf_and_deformed_images
[MainThread ] generate_next_im(setting, im_info=im_info)
[MainThread ] File "/home/markemus/dev/RegNet/functions/synthetic_deformation.py", line 495, in generate_next_im
[MainThread ] original_im_sitk = sitk.ReadImage(su.address_generator(setting, 'originalIm', **im_info_su))
[MainThread ] File "/home/markemus/.local/lib/python3.5/site-packages/SimpleITK/SimpleITK.py", line 8614, in ReadImage
[MainThread ] return _SimpleITK.ReadImage(*args)
[MainThread ] RuntimeError: Exception thrown in SimpleITK ReadImage: /tmp/SimpleITK/Code/IO/src/sitkImageReaderBase.cxx:89:
[MainThread ] sitk::ERROR: The file "/srv/markemus-VirtualBox/hsokooti/Data/DIR-Lab/4DCT/mha/case2/case2_T40_RS1.mha" does not exist.
[MainThread ] total number of variables 1116164
[Thread-4 ] SyntheticDeformation[reading]: waiting 5s for DIR-Lab_4D/3D_max7_D9//T40/case2/Dsmooth0/DNext3/nextIm.mha
Is there an additional/different preprocessing step I need to do? Renaming */case2_T40.mha to */case2_T40_RS1.mha seems to fix this error and creates a nextIm.mha file, but there are more errors after that.
Dear @hsokooti and everyone,
I followed your paper and your paper used three datasets. They included:
Where website can we download it? I also follow this link(https://www.resmedjournal.com/article/S0954-6111(07)00186-2/fulltext) but I don't know, how to download SPREAD (Stolk et al, 2007)? Please help me.
2)3) I download them from https://www.dir-lab.com/Downloads.html. okay with me.
Thank you, @hsokooti and everyone.
Hello,I found a performance issue in functions/registration/multi_stage.py
,
sess = tf.Session() was repeatedly called in for i_stage, stage in enumerate and was not closed.
I think it will increase the efficiency and avoid out of memory if you close this session after using it.
Here are two files to support this issue,support1 and support2
Looking forward to your reply. Btw, I am very glad to create a PR to fix it if you are too busy.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.