Skip to content

TensorRT throws warning during conversion #7713

@binliunls

Description

@binliunls

Describe the bug
TensorRT conversion throws warning:

WARNING:torch_tensorrt._compile:Input graph is a Torchscript module but the ir provided is default (dynamo). Please set ir=torchscript to suppress the warning. Compiling the module with ir=torchscript

To Reproduce
Run the command shown below with the spleen_ct_segmentation bundle in model zoo:

python -m monai.bundle trt_export --net_id network_def --filepath models/model_trt.ts --ckpt_file models/model.pt --meta_file configs/metadata.json --config_file configs/inference.json --precision fp32 --dynamic_batchsize "[1, 4, 8]" --use_onnx "False" --use_trace "False"

Expected behavior
Update the code as the warning suggested.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions