lihaoliu-cambridge / unsupervised-medical-image-segmentation

Code for "Contrastive Registration for Unsupervised Medical Image Segmentation".
63 stars 14 forks source link

Memory #4

Closed Yc-scu closed 6 months ago

Yc-scu commented 2 years ago

Hi. Great work is done! Thank you for sharing this code. I want to know how much memory is needed, My GTX 1080ti GPU has 12G, but it is not enough. I want to know whether 16G is enough. Looking forward to your reply.

Yc-scu commented 2 years ago

Hi, I have finished running your code, and I have another problem. The MindBoggle101 dataset is mentioned in the paper. Do you train and test the new model on two datasets respectively? I would be very grateful if you could share the preprocessed MindBoggle101 dataset. Looking forward to your reply.

lihaoliu-cambridge commented 2 years ago

Hi,

Thanks for your interests in our work.

I use A100 GPU with 80 GB memory to train it. If you don’t have enough GPU memory, please try to decrease the image size to half of it, or reduce the number of layers.

On 28 Jul 2022, at 3:02 AM, Yc-scu @.***> wrote:

Hi. Great work is done! Thank you for sharing this code. I want to know how much memory is needed, My GTX 1080ti GPU has 12G, but it is not enough. I want to know whether 16G is enough. Looking forward to your reply.

— Reply to this email directly, view it on GitHub https://github.com/lihaoliu-cambridge/unsupervised-medical-image-segmentation/issues/4, or unsubscribe https://github.com/notifications/unsubscribe-auth/AESZCO3IKCQPIBHE3EOIAALVWHSZRANCNFSM543SRTCQ. You are receiving this because you are subscribed to this thread.

lihaoliu-cambridge commented 2 years ago

Hi

Yes, I train and test on the two datasets separately.

Sorry, I am not allowed to re-distribute the data. But I will upload the pre-processing code within this week. Please use the code to process the original data directly. Will let you know, when the pre-processing file is updated.

On 28 Jul 2022, at 12:43 PM, Yc-scu @.***> wrote:

Hi, I have finished running your code, and I have another problem. The MindBoggle101 dataset is mentioned in the paper. Do you train and test the new model on two datasets respectively? I would be very grateful if you could share the preprocessed MindBoggle101 dataset. Looking forward to your reply.

— Reply to this email directly, view it on GitHub https://github.com/lihaoliu-cambridge/unsupervised-medical-image-segmentation/issues/4#issuecomment-1198030627, or unsubscribe https://github.com/notifications/unsubscribe-auth/AESZCO3N647S3N7YIEBDWILVWJW6PANCNFSM543SRTCQ. You are receiving this because you are subscribed to this thread.

Yc-scu commented 2 years ago

Hi, Thank you very much for your reply, waiting for your update.

Yc-scu commented 2 years ago

Hi, I finished the training with the training code and encountered some new problems during the test. Run the given 6.Test the saved model. The following results appear: clipboard Check the code and find that the test_dice.py uses from options.train_options import TrainOptions instead of TestOptions. After I use TestOptions: First error report: test_dice.py: error: unrecognized arguments: --no_html. Second error repot: AttributeError: 'Namespace' object has no attribute 'display_ncols' Third error repot: AttributeError: 'Namespace' object has no attribute 'epoch_count' I deleted the code related to the error. I also find a problem in the registration_model_contrastive_learning.py. It shows that the 'seg_of_moving_LPBA40_rigidly_registered_pairs_histogram_standardization_small' and 'deformationfield...' cannot be found. I set this path to 'str('./CLMorph/result/l31_to_l31.nii')' and put the 'l31_to_l31.nii' under the folder. There is no errors, and the result is as follows: S)JRH)6O1(3XP~J%`41$3YU It looks something wrong. Looking forward to your reply.

lihaoliu-cambridge commented 2 years ago

Hi, Thank you very much for your reply, waiting for your update.

Hi,

the pre-processing code has been uploaded to ./script folder.

Thanks.

lihaoliu-cambridge commented 2 years ago

Hi

It looks like you didn’t change the data root.

In the picture you attached, it shows my default data root "/home/ll610/Onepiece/XXX". I think you should manually give the data folder path.

— Best regards, Lihao.

On 31 Jul 2022, at 8:36 AM, Yc-scu @.***> wrote:

Hi, I finished the training with the training code and encountered some new problems during the test. Run the given 6.Test the saved model. The following results appear: https://user-images.githubusercontent.com/109947148/182015251-1daa5b20-c137-4fb3-aa9b-c90c3fff10da.png Check the code and find that the test_dice.py uses from options.train_options import TrainOptions instead of TestOptions. After I use TestOptions: First error report: test_dice.py: error: unrecognized arguments: --no_html. Second error repot: AttributeError: 'Namespace' object has no attribute 'display_ncols' Third error repot: AttributeError: 'Namespace' object has no attribute 'epoch_count' I deleted the code related to the error. I also find a problem in the registration_model_contrastive_learning.py, and I modify the path. But it still shows that the 'seg_of_moving_LPBA40_rigidly_registered_pairs_histogram_standardization_small' and 'deformationfield...' cannot be found. Looking forward to your reply.

— Reply to this email directly, view it on GitHub https://github.com/lihaoliu-cambridge/unsupervised-medical-image-segmentation/issues/4#issuecomment-1200367907, or unsubscribe https://github.com/notifications/unsubscribe-auth/AESZCO5ONKJ6ZJFIIGEGS63VWYUGJANCNFSM543SRTCQ. You are receiving this because you commented.

Yc-scu commented 2 years ago

Hi Lihao,

Thank you for providing the pre-processing code.

Yes, I didn't modify the path at the beginning, and there will be an error that the file cannot be found. Later, I changes the path and put the 'l31_to_l31.nii' ... 'l40_to_l40.nii' into the changed path and no error will be reported. But the result is as shown in the figure above, which is very bad. In the process of modifying the test_dice.py, because there are many obvious errors, I just roughly deleted the error code. I would appreciate it if you could proofread and update the test code.

Best regards, Yc.

asifjamalcse commented 10 months ago

@Yc-scu Hi. My result generated are same result like yours. Have you improved the result? @lihaoliu-cambridge can you please comment on it. I am not clear on the deformation image. deformation_field_I31 to I31 segmentation of moving_I31 to I31

lihaoliu-cambridge commented 10 months ago

@Yc-scu Hi. My result generated are same result like yours. Have you improved the result? @lihaoliu-cambridge can you please comment on it. I am not clear on the deformation image.

Hi, I have never seen this type of deformation field before. Can you provide more detail regarding the software you use for visualization? I use ITK-Snap.

asifjamalcse commented 10 months ago

I got these pairs of files in output folder. I use 3D slicer. I have also ITK-SNAP. the result look same result pairs