ZauggGroup / DeePiCt

Pipeline for the automatic detection and segmentation of particles and cellular structures in 3D Cryo-ET data, based on deep learning (convolutional neural networks).
Apache License 2.0
29 stars 8 forks source link

Test Data for 2D and 3D CNN #9

Closed stefanoliver closed 1 year ago

stefanoliver commented 1 year ago

After installing DeePiCt, I would like to verify its functionality on my workstation but I don't see a full complement of files to run training or predictions for 2d_cnn or 3d_cnn. I've downloaded the DeePiCt_models folder but in the Test_data subfolder there are only two files, a reconstruction and a subvolume of the same reconstruction. It's not clear how to use these files to test both the 2d_cnn and 3d_cnn functionality. I have a question and a request. Firstly, are more files needed? Secondly, please write a clearer set of instructions on how to use the test data. This will be wonderfully helpful. Thanks!

stefanoliver commented 1 year ago

An update. I did finally manage to get the 2d_cnn predictions to work with the available models on my workstation and on the Google Colab. Unfortunately, the 3d_cnn does not work in my hands with either my workstation install or the Google Colab. The process gets stuck at the patch segmentation stage and throws the same error...

GPU is available Model trained under the following original settings: Traceback (most recent call last): File "/content/DeePiCt/3d_cnn/scripts/segment.py", line 85, in print("Model trained under the following original settings:", File "/usr/lib/python3.8/dataclasses.py", line 368, in wrapper result = user_function(self) File "", line 3, in repr AttributeError: 'ModelDescriptor' object has no attribute 'loss'

What is causing this error? Is it my tomogram or is there something else that I'm missing?

frosinastojanovska commented 1 year ago

Hi @stefanoliver, thank you for reporting the issue. This is a problem with the trained models that are not updated with the new version of the code. I will fix this soon and you can find the new updated versions of the trained models' files in the same sharing folder. Thank you for your patience!

stefanoliver commented 1 year ago

Fantastic! Thanks, Frosina. I look forward to testing out the new trained models.

From: Frosina Stojanovska @.> Sent: Saturday, December 3, 2022 05:09 To: ZauggGroup/DeePiCt @.> Cc: Stefan Lyne Oliver @.>; Author @.> Subject: Re: [ZauggGroup/DeePiCt] Test Data for 2D and 3D CNN (Issue #9)

Hi Stefan, thank you for reporting the issue. This is a problem with the trained models that are not updated with the new version of the code. I will fix this soon and you can find the new updated versions of the trained models' files in the same sharing folder. Thank you for your patience!

— Reply to this email directly, view it on GitHubhttps://github.com/ZauggGroup/DeePiCt/issues/9#issuecomment-1336157586, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ADTRRG3GCLPURNQZJVULI7DWLNA47ANCNFSM6AAAAAARVU67Z4. You are receiving this because you authored the thread.Message ID: @.**@.>>

frosinastojanovska commented 1 year ago

A new version of the trained models is available, which should solve this issue.

stefanoliver commented 1 year ago

Hi Frosina,

Thanks for the update. I can confirm the Google Colab is functional. I’ll will test my workstation version later today.

Best wishes,

Stefan

From: Frosina Stojanovska @.> Sent: Thursday, 8 December, 2022 02:18 To: ZauggGroup/DeePiCt @.> Cc: Stefan Lyne Oliver @.>; Mention @.> Subject: Re: [ZauggGroup/DeePiCt] Test Data for 2D and 3D CNN (Issue #9)

A new version of the trained models is available, which should solve this issue.

— Reply to this email directly, view it on GitHubhttps://github.com/ZauggGroup/DeePiCt/issues/9#issuecomment-1342459448, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ADTRRG33M6GGSP676SKXSZLWMGYXDANCNFSM6AAAAAARVU67Z4. You are receiving this because you were mentioned.Message ID: @.**@.>>

stefanoliver commented 1 year ago

Hi Frosina,

After further testing on the Google Colab the microtubule model appears to have an issue (see below). I’ve not tested the FAS model.

Microtubule model error for Segment Patches… GPU is available /content/DeePiCt/3d_cnn/scripts/segment.py:73: UserWarning: Model without model descriptor... it will be added warnings.warn("Model without model descriptor... it will be added") WARNING: model without model descriptor... it will be added Traceback (most recent call last): File "/content/DeePiCt/3d_cnn/scripts/segment.py", line 118, in model.load_state_dict(checkpoint['model_state_dict']) File "/usr/local/lib/python3.8/dist-packages/torch/nn/modules/module.py", line 1667, in load_state_dict raise RuntimeError('Error(s) in loading state_dict for {}:\n\t{}'.format( RuntimeError: Error(s) in loading state_dict for UNet3D: Missing key(s) in state_dict: "encoder.0.2.weight", "encoder.0.2.bias", "encoder.0.2.running_mean", "encoder.0.2.running_var", "encoder.0.4.weight", "encoder.0.4.bias", "encoder.0.6.weight", "encoder.0.6.bias", "encoder.0.6.running_mean", "encoder.0.6.running_var", "encoder.1.2.weight", "encoder.1.2.bias", "encoder.1.2.running_mean", "encoder.1.2.running_var", "encoder.1.4.weight", "encoder.1.4.bias", "encoder.1.6.weight", "encoder.1.6.bias", "encoder.1.6.running_mean", "encoder.1.6.running_var", "decoder.0.2.weight", "decoder.0.2.bias", "decoder.0.2.running_mean", "decoder.0.2.running_var", "decoder.0.4.weight", "decoder.0.4.bias", "decoder.0.6.weight", "decoder.0.6.bias", "decoder.0.6.running_mean", "decoder.0.6.running_var", "decoder.1.2.weight", "decoder.1.2.bias", "decoder.1.2.running_mean", "decoder.1.2.running_var", "decoder.1.4.weight", "decoder.1.4.bias", "decoder.1.6.weight", "decoder.1.6.bias", "decoder.1.6.running_mean", "decoder.1.6.running_var". Unexpected key(s) in state_dict: "encoder.0.3.weight", "encoder.0.3.bias", "encoder.1.3.weight", "encoder.1.3.bias", "decoder.0.3.weight", "decoder.0.3.bias", "decoder.1.3.weight", "decoder.1.3.bias".

From: Stefan Lyne Oliver Sent: Thursday, 8 December, 2022 08:09 To: ZauggGroup/DeePiCt @.>; ZauggGroup/DeePiCt @.> Cc: Mention @.***> Subject: RE: [ZauggGroup/DeePiCt] Test Data for 2D and 3D CNN (Issue #9)

Hi Frosina,

Thanks for the update. I can confirm the Google Colab is functional. I’ll will test my workstation version later today.

Best wishes,

Stefan

From: Frosina Stojanovska @.**@.>> Sent: Thursday, 8 December, 2022 02:18 To: ZauggGroup/DeePiCt @.**@.>> Cc: Stefan Lyne Oliver @.**@.>>; Mention @.**@.>> Subject: Re: [ZauggGroup/DeePiCt] Test Data for 2D and 3D CNN (Issue #9)

A new version of the trained models is available, which should solve this issue.

— Reply to this email directly, view it on GitHubhttps://github.com/ZauggGroup/DeePiCt/issues/9#issuecomment-1342459448, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ADTRRG33M6GGSP676SKXSZLWMGYXDANCNFSM6AAAAAARVU67Z4. You are receiving this because you were mentioned.Message ID: @.**@.>>

frosinastojanovska commented 1 year ago

Hi @stefanoliver, now it should work :)

stefanoliver commented 1 year ago

Thanks, Frosina.

From: Frosina Stojanovska @.> Sent: Saturday, December 17, 2022 14:59 To: ZauggGroup/DeePiCt @.> Cc: Stefan Lyne Oliver @.>; Mention @.> Subject: Re: [ZauggGroup/DeePiCt] Test Data for 2D and 3D CNN (Issue #9)

Hi @stefanoliverhttps://github.com/stefanoliver, now it should work :)

— Reply to this email directly, view it on GitHubhttps://github.com/ZauggGroup/DeePiCt/issues/9#issuecomment-1356493830, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ADTRRG2NJR3NZOBQCHJDDC3WNZAUTANCNFSM6AAAAAARVU67Z4. You are receiving this because you were mentioned.Message ID: @.**@.>>