Skip to content

Commit f30acb7

Browse files
committed
Using python lib for download to make it platform agnostic
1 parent 3469736 commit f30acb7

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

py/torch_tensorrt/dynamo/utils.py

+3-2
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
import shutil
88
import subprocess
99
import sys
10+
import urllib.request
1011
import warnings
1112
from dataclasses import fields, replace
1213
from enum import Enum
@@ -827,10 +828,10 @@ def download_plugin_lib_path(py_version: str, platform: str) -> str:
827828
base_url = "https://pypi.nvidia.com/tensorrt-llm/"
828829
file_name = f"tensorrt_llm-0.18.0-{py_version}-{py_version}-{platform}.whl"
829830
download_url = base_url + file_name
830-
cmd = ["wget", download_url]
831831
if not (os.path.exists(file_name)):
832832
try:
833-
subprocess.run(cmd, check=True)
833+
logger.debug(f"Downloading {download_url} ...")
834+
urllib.request.urlretrieve(download_url, file_name)
834835
logger.debug("Download succeeded and TRT-LLM wheel is now present")
835836
except subprocess.CalledProcessError as e:
836837
logger.error(

0 commit comments

Comments
 (0)