File tree Expand file tree Collapse file tree 2 files changed +3
-2
lines changed
Expand file tree Collapse file tree 2 files changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -123,7 +123,7 @@ def construct_refit_mapping_from_weight_name_map(
123123 engine_weight_map [engine_weight_name ] = (
124124 state_dict [sd_weight_name ]
125125 if state_dict [sd_weight_name ].device == device
126- else state_dict [sd_weight_name ].to (" device" )
126+ else state_dict [sd_weight_name ].to (device )
127127 )
128128
129129 engine_weight_map [engine_weight_name ] = (
Original file line number Diff line number Diff line change 77import numpy as np
88import torch
99import torch_tensorrt
10+ from torch .export ._trace import _export
1011from torch_tensorrt ._Device import Device
1112from torch_tensorrt .dynamo import _defaults
1213from torch_tensorrt .dynamo ._compiler import compile as dynamo_compile
@@ -309,7 +310,7 @@ def refit_gm(self) -> None:
309310
310311 def get_exported_program (self ) -> torch .export .ExportedProgram :
311312 if self .allow_complex_guards_as_runtime_asserts :
312- return torch . export . _trace . _export (
313+ return _export (
313314 self .original_model ,
314315 self .arg_inputs ,
315316 kwargs = self .kwarg_inputs ,
You can’t perform that action at this time.
0 commit comments