forked from extern/easydiffusion
Include onnx and polygraphy for TRT, and allow skipping the wheels for TRT
This commit is contained in:
parent
b6e512e65f
commit
20b06db359
@ -25,7 +25,7 @@ installing = []
|
|||||||
# remove this once TRT releases on pypi
|
# remove this once TRT releases on pypi
|
||||||
if platform.system() == "Windows":
|
if platform.system() == "Windows":
|
||||||
trt_dir = os.path.join(app.ROOT_DIR, "tensorrt")
|
trt_dir = os.path.join(app.ROOT_DIR, "tensorrt")
|
||||||
if os.path.exists(trt_dir):
|
if os.path.exists(trt_dir) and os.path.isdir(trt_dir) and len(os.listdir(trt_dir)) > 0:
|
||||||
files = os.listdir(trt_dir)
|
files = os.listdir(trt_dir)
|
||||||
|
|
||||||
packages = manifest["tensorrt"]["install"]
|
packages = manifest["tensorrt"]["install"]
|
||||||
@ -61,6 +61,10 @@ def install(module_name):
|
|||||||
raise RuntimeError(f"Can't install unknown package: {module_name}!")
|
raise RuntimeError(f"Can't install unknown package: {module_name}!")
|
||||||
|
|
||||||
commands = manifest[module_name]["install"]
|
commands = manifest[module_name]["install"]
|
||||||
|
if module_name == "tensorrt":
|
||||||
|
commands += [
|
||||||
|
"protobuf==3.20.3 polygraphy==0.47.1 onnx==1.14.0 --extra-index-url=https://pypi.ngc.nvidia.com --trusted-host pypi.ngc.nvidia.com"
|
||||||
|
]
|
||||||
commands = [f"python -m pip install --upgrade {cmd}" for cmd in commands]
|
commands = [f"python -m pip install --upgrade {cmd}" for cmd in commands]
|
||||||
|
|
||||||
installing.append(module_name)
|
installing.append(module_name)
|
||||||
|
Loading…
Reference in New Issue
Block a user