ONNX Simplifier (#2815)

* ONNX Simplifier

Add ONNX Simplifier to ONNX export pipeline in export.py. Will auto-install onnx-simplifier if onnx is installed but onnx-simplifier is not.

* Update general.py
This commit is contained in:
Glenn Jocher authored and GitHub committed 2021-04-16 14:03:27 +02:00
1 parent e5d71223b8
commit 1f3e482bce
2 files changed
+31 -16

No files matched your search

+1 -1
View File
@@ -111,7 +111,7 @@ def check_requirements(requirements='requirements.txt', exclude=()):
except Exception as e: # DistributionNotFound or VersionConflict if requirements not met
n += 1
print(f"{prefix} {e.req} not found and is required by YOLOv5, attempting auto-update...")
print(subprocess.check_output(f"pip install '{e.req}'", shell=True).decode())
print(subprocess.check_output(f"pip install {e.req}", shell=True).decode())
if n: # if packages updated
source = file.resolve() if 'file' in locals() else requirements