Skip to content

Commit

Permalink
7 to 8 fix
Browse files Browse the repository at this point in the history
  • Loading branch information
glenn-jocher committed Jan 5, 2022
1 parent 6b7ca60 commit c02be31
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion export.py
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ def export_engine(model, im, file, train, half, simplify, workspace=4, verbose=F
export_onnx(model, im, file, 12, train, False, simplify) # opset 12
model.model[-1].anchor_grid = grid
else: # TensorRT >= 8
check_version(trt.__version__, '7.0.0', hard=True) # require tensorrt>=8.0.0
check_version(trt.__version__, '8.0.0', hard=True) # require tensorrt>=8.0.0
export_onnx(model, im, file, 13, train, False, simplify) # opset 13
onnx = file.with_suffix('.onnx')
assert onnx.exists(), f'failed to export ONNX file: {onnx}'
Expand Down

0 comments on commit c02be31

Please sign in to comment.