Skip to content

Commit 2bf9bdb

Browse files
committed
Remove system GDAL packages and pin flash-attn to prevent build conflicts
- Remove libgdal-dev from apt-get to prevent conflict with compiled GDAL 3.11.5 - Add GDAL version verification to ensure correct version is available - Pin flash-attn to 2.8.2 to match pre-built wheel on jetson-ai-lab.io Fixes GDAL version detection issue where rasterio was finding system GDAL 3.4.1 instead of compiled 3.11.5, and flash-attn build failures when uv tried to compile 2.8.3 from source.
1 parent 175d61a commit 2bf9bdb

File tree

3 files changed

+9
-3
lines changed

3 files changed

+9
-3
lines changed

docker/dockerfiles/Dockerfile.onnx.jetson.6.2.0

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,9 @@ RUN apt-get update -y && \
3434
libwebp-dev \
3535
libzstd-dev \
3636
liblzma-dev \
37-
&& rm -rf /var/lib/apt/lists/*
37+
&& \
38+
apt-get remove -y libgdal-dev gdal-bin libgdal30 2>/dev/null || true && \
39+
rm -rf /var/lib/apt/lists/*
3840

3941
# Compile GDAL from source to get version >= 3.5 for rasterio 1.4.0 compatibility
4042
RUN wget https://github.com/OSGeo/gdal/releases/download/v3.11.5/gdal-3.11.5.tar.gz && \
@@ -61,6 +63,10 @@ ENV GDAL_CONFIG=/usr/local/bin/gdal-config \
6163
LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH \
6264
PATH=/usr/local/bin:$PATH
6365

66+
# Verify GDAL installation
67+
RUN gdal-config --version && \
68+
test "$(gdal-config --version | cut -d. -f1,2)" = "3.11" || (echo "GDAL version mismatch!" && exit 1)
69+
6470
RUN wget -q https://github.com/Kitware/CMake/releases/download/v3.30.5/cmake-3.30.5-linux-aarch64.sh && \
6571
chmod +x cmake-3.30.5-linux-aarch64.sh && \
6672
./cmake-3.30.5-linux-aarch64.sh --prefix=/usr/local --skip-license && \

requirements/requirements.sam.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@ rasterio~=1.4.0
44
pycocotools>=2.0.10
55
torch>=2.8.0
66
torchvision>=0.23.0
7-
flash-attn>=2.8.2
7+
flash-attn==2.8.2

requirements/requirements.transformers.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
torch>=2.8.0
22
torchvision>=0.23.0
3-
flash-attn>=2.8.2
3+
flash-attn==2.8.2
44
transformers>=4.53.3,<4.57.0
55
timm~=1.0.0
66
#accelerate>=0.32,<1.0.0

0 commit comments

Comments
 (0)