Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

6676 port losses from monai-generative #6729

Merged
merged 26 commits into from
Aug 3, 2023
Merged

6676 port losses from monai-generative #6729

merged 26 commits into from
Aug 3, 2023

Conversation

marksgraham
Copy link
Contributor

@marksgraham marksgraham commented Jul 14, 2023

Work towards addressing issue #6676

Description

This PR ports spectral, perceptual and patch adversial losses from MONAI Generative.

Types of changes

  • Non-breaking change (fix or new feature that would not break existing functionality).
  • Breaking change (fix or new feature that would cause existing functionality to change).
  • New tests added to cover the changes.
  • Integration tests passed locally by running ./runtests.sh -f -u --net --coverage.
  • Quick tests passed locally by running ./runtests.sh --quick --unittests --disttests.
  • In-line docstrings updated.
  • Documentation updated, tested make html command in the docs/ folder.

@marksgraham marksgraham marked this pull request as ready for review July 19, 2023 13:20
@marksgraham marksgraham changed the title [WIP] 6676 port losses from monai-generative 6676 port losses from monai-generative Jul 19, 2023
@marksgraham
Copy link
Contributor Author

This PR requires a new package, lpips. I've updated requirements-dev.txt, but all the automated checks fails because the package isn't found. I'm not sure how to fix this - any tips @wyli or @mingxin-zheng ?

@wyli
Copy link
Contributor

wyli commented Jul 19, 2023

sure, probably there are a few places to be updated with the new package, please see https://github.com/Project-MONAI/MONAI/blob/dev/CONTRIBUTING.md#adding-new-optional-dependencies

@mingxin-zheng
Copy link
Contributor

Hi @marksgraham the min and package tests do not install packages in requirements-dev.txt, because they are just doing "fast" checks. So, the first step to try is to exclude the new tests in this PR from the min tests in this file.

marksgraham and others added 15 commits July 19, 2023 15:22
I, Mark Graham <[email protected]>, hereby add my Signed-off-by to this commit: a21c7f1
I, Mark Graham <[email protected]>, hereby add my Signed-off-by to this commit: 79a3784
I, Mark Graham <[email protected]>, hereby add my Signed-off-by to this commit: 89c4e83
I, Mark Graham <[email protected]>, hereby add my Signed-off-by to this commit: 3faaca5
I, Mark Graham <[email protected]>, hereby add my Signed-off-by to this commit: 086b8a9
I, Mark Graham <[email protected]>, hereby add my Signed-off-by to this commit: 105c3b8
I, Mark Graham <[email protected]>, hereby add my Signed-off-by to this commit: 700096d
I, Mark Graham <[email protected]>, hereby add my Signed-off-by to this commit: cd01b59
I, Mark Graham <[email protected]>, hereby add my Signed-off-by to this commit: a5e092e

Signed-off-by: Mark Graham <[email protected]>
I, Mark Graham <[email protected]>, hereby add my Signed-off-by to this commit: 36d7ed6

Signed-off-by: Mark Graham <[email protected]>
@wyli
Copy link
Contributor

wyli commented Jul 31, 2023

/build

@wyli
Copy link
Contributor

wyli commented Jul 31, 2023

/build

Copy link
Contributor

@wyli wyli left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks, it looks good to me, there's a minor issue about the torch.hub.set_dir usage

monai/losses/perceptual.py Show resolved Hide resolved
monai/losses/adversarial_loss.py Outdated Show resolved Hide resolved
monai/losses/adversarial_loss.py Outdated Show resolved Hide resolved
monai/losses/perceptual.py Outdated Show resolved Hide resolved
monai/losses/perceptual.py Outdated Show resolved Hide resolved
monai/losses/perceptual.py Show resolved Hide resolved
@mingxin-zheng
Copy link
Contributor

Hi @marksgraham , none of my commented items is critical to fix. Please feel free to skip and close them as you see fit.

@wyli
Copy link
Contributor

wyli commented Aug 3, 2023

/build

@wyli wyli enabled auto-merge (squash) August 3, 2023 13:19
@wyli wyli merged commit 6f5cea3 into Project-MONAI:dev Aug 3, 2023
25 of 30 checks passed
@marksgraham marksgraham mentioned this pull request Jul 6, 2023
7 tasks
@marksgraham marksgraham mentioned this pull request Nov 3, 2023
7 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants