fastMRI icon indicating copy to clipboard operation
fastMRI copied to clipboard

A upgrade to PytorchLightning 2.0 and PyTorch 2.0

Open YuyangXueEd opened this issue 1 year ago • 2 comments

Hello all!

Since PyTorch and PytorchLightning is upgraded to 2.0 and above, the fastmri_examples code such as unet is now deprecated. I am wondering that whether there is a plan to update the code to compatible to 2.0.

There are some changes like:

  • used LightningDataModule.parse_argparser(), LightningDataModule.from_argparse_args() and Trainer.from_argparse_args() method now switch to using LightningCLI.
  • had any logic except reducing the DP outputs in LightningModule.validation_step_end hook now port it to LightningModule.on_validation_batch_end hook
  • had any logic except reducing the DP outputs in LightningModule.test_step_end hook now port it to LightningModule.on_test_batch_end hook
  • no resume_from_checkpoint for the Trainer but changed to ckpt_path
  • ...

I will try to pull a request when ready.

Please:

  • [*] Check for duplicate requests.
  • [*] Describe your goal, and if possible provide a code snippet with a motivating example.

YuyangXueEd avatar May 25 '23 08:05 YuyangXueEd

Hello @YuyangXueEd, are you still working on this?

mmuckley avatar Jun 26 '23 16:06 mmuckley

@mmuckley Hi, I worked on this. However, it wasn't possible to make it using the same structure. I added a yaml file as a config file. I have tested only on single-coil knee images

amirshamaei avatar Oct 09 '23 05:10 amirshamaei