Update export.py (#2909)

This commit is contained in:
Glenn Jocher 2021-04-23 23:50:02 +02:00 committed by GitHub
parent 28db237639
commit a2a514dec8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -112,7 +112,7 @@ if __name__ == '__main__':
try:
import coremltools as ct
print(f'{prefix} starting export with coremltools {onnx.__version__}...')
print(f'{prefix} starting export with coremltools {ct.__version__}...')
# convert model from torchscript and apply pixel scaling as per detect.py
model = ct.convert(ts, inputs=[ct.ImageType(name='image', shape=img.shape, scale=1 / 255.0, bias=[0, 0, 0])])
f = opt.weights.replace('.pt', '.mlmodel') # filename