Skip to content

Commit 95f69de

Browse files
authored
Fix error in "test_bundle_trt_export" (#7524)
Fixes #7523 ### 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: YunLiu <[email protected]>
1 parent e9e2738 commit 95f69de

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

monai/networks/utils.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -850,7 +850,10 @@ def _onnx_trt_compile(
850850

851851
# wrap the serialized TensorRT engine back to a TorchScript module.
852852
trt_model = torch_tensorrt.ts.embed_engine_in_new_module(
853-
f.getvalue(), torch.device(f"cuda:{device}"), input_names, output_names
853+
f.getvalue(),
854+
device=torch.device(f"cuda:{device}"),
855+
input_binding_names=input_names,
856+
output_binding_names=output_names,
854857
)
855858
return trt_model
856859

0 commit comments

Comments
 (0)