Skip to content

1755 improve focal loss#1765

Merged
wyli merged 17 commits intoProject-MONAI:masterfrom
yiheng-wang-nv:1755-modify-focalloss-format
Mar 17, 2021
Merged

1755 improve focal loss#1765
wyli merged 17 commits intoProject-MONAI:masterfrom
yiheng-wang-nv:1755-modify-focalloss-format

Conversation

@yiheng-wang-nv
Copy link
Copy Markdown
Contributor

@yiheng-wang-nv yiheng-wang-nv commented Mar 15, 2021

Signed-off-by: Yiheng Wang [email protected]

Fixes #1755 .

Description

Except for unifying the input parameters, some changes are made to make the class more generic:

  • Modify the type of weight parameter form torch.Tensor to a sequence or a single value. It is helpful if users need to input the parameters via a json file.

Status

Ready

Types of changes

  • 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.
  • In-line docstrings updated.
  • Documentation updated, tested make html command in the docs/ folder.

@yiheng-wang-nv yiheng-wang-nv changed the title Add to_onehot_y and include_background 1755 improve focal loss Mar 15, 2021
@yiheng-wang-nv yiheng-wang-nv requested a review from wyli March 15, 2021 12:49
Copy link
Copy Markdown
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, I put some comments inline

Copy link
Copy Markdown
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!

@wyli wyli merged commit b868087 into Project-MONAI:master Mar 17, 2021
@yiheng-wang-nv yiheng-wang-nv deleted the 1755-modify-focalloss-format branch July 2, 2021 14:14
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.

Unify the input of loss components

2 participants