Skip to content

Conversation

@a-parida12
Copy link
Contributor

Fixes #6032 .

Description

A few sentences describing the changes proposed in this pull request.

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.

atbenmurray and others added 7 commits April 2, 2023 22:34
Fixes Project-MONAI#6223 .

### Types of changes
<!--- Put an `x` in all the boxes that apply, and remove the not
applicable items -->
- [x] Non-breaking change (fix or new feature that would not break
existing functionality).
- [x] 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.

---------

Signed-off-by: Ben Murray <ben.murray@gmail.com>
Signed-off-by: a-parida12 <abhijeet.parida@tum.de>
Fixes Project-MONAI#6255

### Description

upgrade pytorch to 23.03

### Types of changes
<!--- Put an `x` in all the boxes that apply, and remove the not
applicable items -->
- [x] 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.

---------

Signed-off-by: YanxuanLiu <yanxuanl@nvidia.com>
Signed-off-by: a-parida12 <abhijeet.parida@tum.de>
Signed-off-by: a-parida12 <abhijeet.parida@tum.de>
Signed-off-by: a-parida12 <abhijeet.parida@tum.de>
Signed-off-by: a-parida12 <abhijeet.parida@tum.de>
Signed-off-by: a-parida12 <abhijeet.parida@tum.de>
for more information, see https://pre-commit.ci

Signed-off-by: a-parida12 <abhijeet.parida@tum.de>
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.

looks good to me cc @yiheng-wang-nv @binliunls @Nic-Ma

@wyli
Copy link
Contributor

wyli commented Apr 3, 2023

/black

monai-bot and others added 2 commits April 3, 2023 17:32
Signed-off-by: monai-bot <monai.miccai2019@gmail.com>
@wyli wyli enabled auto-merge April 3, 2023 19:01
Signed-off-by: Wenqi Li <wenqil@nvidia.com>
auto-merge was automatically disabled April 3, 2023 19:57

Merge queue setting changed

@wyli wyli enabled auto-merge (squash) April 3, 2023 22:25
@wyli wyli merged commit 9e33ff2 into Project-MONAI:dev Apr 3, 2023
@wyli
Copy link
Contributor

wyli commented Apr 4, 2023

this doesn't seem to work, I'll revert this change

[2023-04-04T00:52:49.442Z] ======================================================================
[2023-04-04T00:52:49.442Z] ERROR: test_script_15 (tests.test_vit.TestViT)
[2023-04-04T00:52:49.442Z] ----------------------------------------------------------------------
[2023-04-04T00:52:49.442Z] Traceback (most recent call last):
[2023-04-04T00:52:49.442Z]   File "/opt/conda/lib/python3.8/site-packages/parameterized/parameterized.py", line 620, in standalone_func
[2023-04-04T00:52:49.442Z]     return func(*(a + p.args), **p.kwargs, **kw)
[2023-04-04T00:52:49.442Z]   File "/home/jenkins/agent/workspace/Monai-latest-image/tests/test_vit.py", line 148, in test_script
[2023-04-04T00:52:49.442Z]     torch.jit.script(net)
[2023-04-04T00:52:49.442Z]   File "/opt/conda/lib/python3.8/site-packages/torch/jit/_script.py", line 1286, in script
[2023-04-04T00:52:49.442Z]     return torch.jit._recursive.create_script_module(
[2023-04-04T00:52:49.442Z]   File "/opt/conda/lib/python3.8/site-packages/torch/jit/_recursive.py", line 476, in create_script_module
[2023-04-04T00:52:49.442Z]     return create_script_module_impl(nn_module, concrete_type, stubs_fn)
[2023-04-04T00:52:49.442Z]   File "/opt/conda/lib/python3.8/site-packages/torch/jit/_recursive.py", line 538, in create_script_module_impl
[2023-04-04T00:52:49.442Z]     script_module = torch.jit.RecursiveScriptModule._construct(cpp_module, init_fn)
[2023-04-04T00:52:49.442Z]   File "/opt/conda/lib/python3.8/site-packages/torch/jit/_script.py", line 615, in _construct
[2023-04-04T00:52:49.442Z]     init_fn(script_module)
[2023-04-04T00:52:49.442Z]   File "/opt/conda/lib/python3.8/site-packages/torch/jit/_recursive.py", line 516, in init_fn
[2023-04-04T00:52:49.442Z]     scripted = create_script_module_impl(orig_value, sub_concrete_type, stubs_fn)
[2023-04-04T00:52:49.442Z]   File "/opt/conda/lib/python3.8/site-packages/torch/jit/_recursive.py", line 538, in create_script_module_impl
[2023-04-04T00:52:49.442Z]     script_module = torch.jit.RecursiveScriptModule._construct(cpp_module, init_fn)
[2023-04-04T00:52:49.442Z]   File "/opt/conda/lib/python3.8/site-packages/torch/jit/_script.py", line 615, in _construct
[2023-04-04T00:52:49.442Z]     init_fn(script_module)
[2023-04-04T00:52:49.442Z]   File "/opt/conda/lib/python3.8/site-packages/torch/jit/_recursive.py", line 516, in init_fn
[2023-04-04T00:52:49.442Z]     scripted = create_script_module_impl(orig_value, sub_concrete_type, stubs_fn)
[2023-04-04T00:52:49.442Z]   File "/opt/conda/lib/python3.8/site-packages/torch/jit/_recursive.py", line 538, in create_script_module_impl
[2023-04-04T00:52:49.442Z]     script_module = torch.jit.RecursiveScriptModule._construct(cpp_module, init_fn)
[2023-04-04T00:52:49.442Z]   File "/opt/conda/lib/python3.8/site-packages/torch/jit/_script.py", line 615, in _construct
[2023-04-04T00:52:49.442Z]     init_fn(script_module)
[2023-04-04T00:52:49.442Z]   File "/opt/conda/lib/python3.8/site-packages/torch/jit/_recursive.py", line 516, in init_fn
[2023-04-04T00:52:49.442Z]     scripted = create_script_module_impl(orig_value, sub_concrete_type, stubs_fn)
[2023-04-04T00:52:49.442Z]   File "/opt/conda/lib/python3.8/site-packages/torch/jit/_recursive.py", line 542, in create_script_module_impl
[2023-04-04T00:52:49.442Z]     create_methods_and_properties_from_stubs(concrete_type, method_stubs, property_stubs)
[2023-04-04T00:52:49.442Z]   File "/opt/conda/lib/python3.8/site-packages/torch/jit/_recursive.py", line 393, in create_methods_and_properties_from_stubs
[2023-04-04T00:52:49.442Z]     concrete_type._create_methods_and_properties(property_defs, property_rcbs, method_defs, method_rcbs, method_defaults)
[2023-04-04T00:52:49.442Z] RuntimeError: Can't redefine method: forward on class: __torch__.monai.networks.blocks.selfattention.___torch_mangle_1850.SABlock (of Python compilation unit at: 0x55ed2d9ec270)
[2023-04-04T00:52:49.442Z] 
[2023-04-04T00:52:49.442Z] ----------------------------------------------------------------------

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.

Access self-attention matrix of vision transformer

5 participants