Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
liaogulou committed Oct 25, 2023
1 parent d5e80f5 commit 699a850
Showing 1 changed file with 8 additions and 9 deletions.
17 changes: 8 additions & 9 deletions easycv/apis/export.py
Original file line number Diff line number Diff line change
Expand Up @@ -369,16 +369,15 @@ def _export_yolox(model, cfg, filename):
json.dump(config, ofile)

torch.onnx.export(
model,
input.to(device),
model,
input.to(device),
filename if filename.endswith('onnx') else filename +
'.onnx',
export_params=
True,
opset_version=12,
do_constant_folding=True,
input_names=['input'],
output_names=['output'],
'.onnx',
export_params=True,
opset_version=12,
do_constant_folding=True,
input_names=['input'],
output_names=['output'],
)

if export_type == 'jit':
Expand Down

0 comments on commit 699a850

Please sign in to comment.