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

3938 enhance milmodel for torchscript #3939

Draft
wants to merge 8 commits into
base: dev
Choose a base branch
from

Conversation

yiheng-wang-nv
Copy link
Contributor

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

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

Fixes #3938 .

Description

With the changes, MILModel will support torchscript for all mil_mode.

Status

Work in progress

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.

@yiheng-wang-nv yiheng-wang-nv requested a review from myron March 15, 2022 09:51
@myron
Copy link
Collaborator

myron commented Mar 23, 2022

this looks good, but shouldn't we support all modes?

@yiheng-wang-nv
Copy link
Contributor Author

this looks good, but shouldn't we support all modes?

Hi @myron , sure. To support att_trans_pyramid mode, the hook based method may need to be replaced. Let me update this PR for you to take a look.

Signed-off-by: Yiheng Wang <[email protected]>
Signed-off-by: Yiheng Wang <[email protected]>
@yiheng-wang-nv
Copy link
Contributor Author

Hi @myron , to support att_trans_pyramid mode, the way of using def calc_head seems not feasible. Therefore I defined a new class and put everything of the att_trans_pyramid mode into it. The code may look quite different from your original version, could you please help to review it? Feel free to ask if you have any questions, thanks!

@yiheng-wang-nv
Copy link
Contributor Author

/black

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.

MILModel does not fully support torchscript
3 participants