Fix EdgeTPU output directory (#7399)

* Fix EdgeTPU output directory

Outputs to same directory as --weights

* Update export.py
pull/7402/head
Glenn Jocher 2022-04-12 15:08:53 +02:00 committed by GitHub
parent 5333b55e74
commit 2da2466168
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -387,7 +387,7 @@ def export_edgetpu(keras_model, im, file, prefix=colorstr('Edge TPU:')):
f = str(file).replace('.pt', '-int8_edgetpu.tflite') # Edge TPU model
f_tfl = str(file).replace('.pt', '-int8.tflite') # TFLite model
cmd = f"edgetpu_compiler -s {f_tfl}"
cmd = f"edgetpu_compiler -s -o {file.parent} {f_tfl}"
subprocess.run(cmd, shell=True, check=True)
LOGGER.info(f'{prefix} export success, saved as {f} ({file_size(f):.1f} MB)')