Skip to content

Commit

Permalink
handle libcudnn9
Browse files Browse the repository at this point in the history
  • Loading branch information
neggles committed Jul 15, 2024
1 parent 09d60ed commit 26ac80a
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
2 changes: 1 addition & 1 deletion docker-bake.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ target "base" {
}

target xformers-wheel {
inherits = ["base-cu121-torch240"]
inherits = ["base-cu124-torch240"]
target = "xformers-wheel"
tags = [
repoImage("xformers", "v0.0.27", cudaName("12.4.1"), torchName("2.4.0"))
Expand Down
12 changes: 9 additions & 3 deletions docker/base/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -91,12 +91,18 @@ RUN --mount=type=cache,target=/var/cache/apt,sharing=locked \
python3-venv\
&& apt-get clean

# Install CUDNN dev package to match existing binary package
# Install CUDNN dev package to match existing binary package (if installed)
RUN --mount=type=cache,target=/var/cache/apt,sharing=locked \
--mount=type=cache,target=/var/lib/apt,sharing=locked \
apt-get update \
&& apt-get -y install --no-install-recommends \
libcudnn8-dev=$(dpkg-query --showformat='${Version}' --show libcudnn8) \
&& if $(dpkg-query --show libcudnn8 2>&1 >/dev/null); then \
apt-get -y install --no-install-recommends \
libcudnn8-dev=$(dpkg-query --showformat='${Version}' --show libcudnn8) \
; fi \
&& if $(dpkg-query --show libcudnn9 2>&1 >/dev/null); then \
apt-get -y install --no-install-recommends \
libcudnn9-dev=$(dpkg-query --showformat='${Version}' --show libcudnn9) \
; fi \
&& apt-get clean

# Install TensorRT libraries
Expand Down

0 comments on commit 26ac80a

Please sign in to comment.