Skip to content

Commit

Permalink
Mchornyi krish 24.04 (#7149)
Browse files Browse the repository at this point in the history
* Enable TensorRT-LLM build outside of CMake

* TensorRT-LLM requires lower version of cuDNN
  • Loading branch information
mc-nv authored Apr 23, 2024
1 parent f364766 commit fb2b2e5
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion build.py
Original file line number Diff line number Diff line change
Expand Up @@ -819,6 +819,8 @@ def fastertransformer_cmake_args():


def tensorrtllm_cmake_args(images):
cmake_script.cmd("apt-get update && apt-get install -y libcudnn8-dev && ldconfig")
cmake_script.cmd("python3 ../tensorrt_llm/scripts/build_wheel.py --trt_root /usr/local/tensorrt")
cargs = [
cmake_backend_arg(
"tensorrtllm",
Expand All @@ -830,7 +832,6 @@ def tensorrtllm_cmake_args(images):
"tensorrtllm", "TRT_INCLUDE_DIR", None, "${TRT_ROOT}/include"
),
]
cargs.append(cmake_backend_enable("tensorrtllm", "TRITON_BUILD", True))
cargs.append(cmake_backend_enable("tensorrtllm", "USE_CXX11_ABI", True))
return cargs

Expand Down Expand Up @@ -1094,6 +1095,8 @@ def create_dockerfile_linux(
if "tensorrtllm" in backends:
df += """
# Remove TRT contents that are not needed in runtime
RUN apt-get update && apt-get install -y libcudnn8-dev && ldconfig
RUN ARCH="$(uname -i)" \\
&& rm -fr ${TRT_ROOT}/bin ${TRT_ROOT}/targets/${ARCH}-linux-gnu/bin ${TRT_ROOT}/data \\
&& rm -fr ${TRT_ROOT}/doc ${TRT_ROOT}/onnx_graphsurgeon ${TRT_ROOT}/python \\
Expand Down

0 comments on commit fb2b2e5

Please sign in to comment.