Skip to content

Commit f7aab56

Browse files
authored
fix: remove TRT version restriction (#3435)
1 parent 5071c8d commit f7aab56

File tree

3 files changed

+16
-24
lines changed

3 files changed

+16
-24
lines changed

.github/scripts/generate-tensorrt-test-matrix.py

-8
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,6 @@
2828
# please update the future tensorRT version you want to test here
2929
TENSORRT_VERSIONS_DICT = {
3030
"windows": {
31-
"10.6.0": {
32-
"urls": "https://developer.nvidia.com/downloads/compute/machine-learning/tensorrt/10.6.0/zip/TensorRT-10.6.0.26.Windows.win10.cuda-12.6.zip",
33-
"strip_prefix": "TensorRT-10.6.0.26",
34-
},
3531
"10.7.0": {
3632
"urls": "https://developer.nvidia.com/downloads/compute/machine-learning/tensorrt/10.7.0/zip/TensorRT-10.7.0.23.Windows.win10.cuda-12.6.zip",
3733
"strip_prefix": "TensorRT-10.7.0.23",
@@ -46,10 +42,6 @@
4642
},
4743
},
4844
"linux": {
49-
"10.6.0": {
50-
"urls": "https://developer.nvidia.com/downloads/compute/machine-learning/tensorrt/10.6.0/tars/TensorRT-10.6.0.26.Linux.x86_64-gnu.cuda-12.6.tar.gz",
51-
"strip_prefix": "TensorRT-10.6.0.26",
52-
},
5345
"10.7.0": {
5446
"urls": "https://developer.nvidia.com/downloads/compute/machine-learning/tensorrt/10.7.0/tars/TensorRT-10.7.0.23.Linux.x86_64-gnu.cuda-12.6.tar.gz",
5547
"strip_prefix": "TensorRT-10.7.0.23",

packaging/pre_build_script.sh

+8-8
Original file line numberDiff line numberDiff line change
@@ -22,14 +22,14 @@ export TORCH_BUILD_NUMBER=$(python -c "import torch, urllib.parse as ul; print(u
2222
export TORCH_INSTALL_PATH=$(python -c "import torch, os; print(os.path.dirname(torch.__file__))")
2323

2424
if [[ ${TENSORRT_VERSION} != "" ]]; then
25-
# this is the upgraded TensorRT version, replace current tensorrt version to the upgrade tensorRT version in the pyproject.toml
26-
# example: __tensorrt_version__: ">=10.3.0,<=10.6.0"
27-
# replace: tensorrt-cu12>=10.3.0,<=10.6.0 to tensorrt-cu12==10.8.0
28-
current_version=$(cat dev_dep_versions.yml | grep __tensorrt_version__ | sed 's/__tensorrt_version__: //g' | sed 's/"//g')
29-
sed -i -e "s/tensorrt-cu12${current_version}/tensorrt-cu12==${TENSORRT_VERSION}/g" \
30-
-e "s/tensorrt-cu12-bindings${current_version}/tensorrt-cu12-bindings==${TENSORRT_VERSION}/g" \
31-
-e "s/tensorrt-cu12-libs${current_version}/tensorrt-cu12-libs==${TENSORRT_VERSION}/g" \
32-
pyproject.toml
25+
# Replace dependencies in the original pyproject.toml with the current TensorRT version. It is used for CI tests of different TensorRT versions.
26+
# For example, if the current testing TensorRT version is 10.7.0, but the pyproject.toml tensorrt>=10.8.0,<10.9.0, then the following sed command
27+
# will replace tensorrt>=10.8.0,<10.9.0 with tensorrt==10.7.0
28+
sed -i -e "s/tensorrt>=.*,<.*\"/tensorrt>=${TENSORRT_VERSION},<$(echo "${TENSORRT_VERSION}" | awk -F. '{print $1"."$2+1".0"}')\"/g" \
29+
-e "s/tensorrt-cu12>=.*,<.*\"/tensorrt-cu12>=${TENSORRT_VERSION},<$(echo "${TENSORRT_VERSION}" | awk -F. '{print $1"."$2+1".0"}')\"/g" \
30+
-e "s/tensorrt-cu12-bindings>=.*,<.*\"/tensorrt-cu12-bindings>=${TENSORRT_VERSION},<$(echo "${TENSORRT_VERSION}" | awk -F. '{print $1"."$2+1".0"}')\"/g" \
31+
-e "s/tensorrt-cu12-libs>=.*,<.*\"/tensorrt-cu12-libs>=${TENSORRT_VERSION},<$(echo "${TENSORRT_VERSION}" | awk -F. '{print $1"."$2+1".0"}')\"/g" \
32+
pyproject.toml
3333
fi
3434

3535
if [[ "${CU_VERSION::4}" < "cu12" ]]; then

packaging/pre_build_script_windows.sh

+8-8
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,14 @@ choco install bazelisk -y
77
echo TENSORRT_VERSION=${TENSORRT_VERSION}
88

99
if [[ ${TENSORRT_VERSION} != "" ]]; then
10-
# this is the upgraded TensorRT version, replace current tensorrt version to the upgrade tensorRT version in the pyproject.toml
11-
# example: __tensorrt_version__: ">=10.3.0,<=10.6.0"
12-
# replace: tensorrt-cu12>=10.3.0,<=10.6.0 to tensorrt-cu12==10.8.0
13-
current_version=$(cat dev_dep_versions.yml | grep __tensorrt_version__ | sed 's/__tensorrt_version__: //g' | sed 's/"//g')
14-
sed -i -e "s/tensorrt-cu12${current_version}/tensorrt-cu12==${TENSORRT_VERSION}/g" \
15-
-e "s/tensorrt-cu12-bindings${current_version}/tensorrt-cu12-bindings==${TENSORRT_VERSION}/g" \
16-
-e "s/tensorrt-cu12-libs${current_version}/tensorrt-cu12-libs==${TENSORRT_VERSION}/g" \
17-
pyproject.toml
10+
# Replace dependencies in the original pyproject.toml with the current TensorRT version. It is used for CI tests of different TensorRT versions.
11+
# For example, if the current testing TensorRT version is 10.7.0, but the pyproject.toml tensorrt>=10.8.0,<10.9.0, then the following sed command
12+
# will replace tensorrt>=10.8.0,<10.9.0 with tensorrt==10.7.0
13+
sed -i -e "s/tensorrt>=.*,<.*\"/tensorrt>=${TENSORRT_VERSION},<$(echo "${TENSORRT_VERSION}" | awk -F. '{print $1"."$2+1".0"}')\"/g" \
14+
-e "s/tensorrt-cu12>=.*,<.*\"/tensorrt-cu12>=${TENSORRT_VERSION},<$(echo "${TENSORRT_VERSION}" | awk -F. '{print $1"."$2+1".0"}')\"/g" \
15+
-e "s/tensorrt-cu12-bindings>=.*,<.*\"/tensorrt-cu12-bindings>=${TENSORRT_VERSION},<$(echo "${TENSORRT_VERSION}" | awk -F. '{print $1"."$2+1".0"}')\"/g" \
16+
-e "s/tensorrt-cu12-libs>=.*,<.*\"/tensorrt-cu12-libs>=${TENSORRT_VERSION},<$(echo "${TENSORRT_VERSION}" | awk -F. '{print $1"."$2+1".0"}')\"/g" \
17+
pyproject.toml
1818
fi
1919

2020
if [[ "${CU_VERSION::4}" < "cu12" ]]; then

0 commit comments

Comments
 (0)