Skip to content

Commit c9590c9

Browse files
committed
Remove .pyi deletion - lazy_loader (skimage) requires stub files
1 parent 3a82a14 commit c9590c9

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

docker/dockerfiles/Dockerfile.onnx.jetson.6.2.0

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -201,16 +201,15 @@ RUN ln -sf /usr/bin/python3 /usr/bin/python && \
201201

202202
# Remove test directories, development tools, and unnecessary packages to reduce image size
203203
# This happens AFTER all package installations to ensure everything gets cleaned
204-
# Note: Keep numpy/torch test dirs (public APIs depend on them), remove from other packages
204+
# Note: Keep numpy/torch test dirs (public APIs depend on them), keep .pyi files (lazy_loader needs them)
205205
RUN cd /usr/local/lib/python3.10/dist-packages && \
206206
find . -type d -name __pycache__ -exec rm -rf {} + 2>/dev/null || true && \
207207
rm -rf debugpy* jupyterlab* jupyter_* notebook* ipython* ipykernel* || true && \
208208
rm -rf torch/bin torch/include || true && \
209209
rm -rf onnx/backend/test onnx/test || true && \
210210
rm -rf scipy/*/tests pandas/tests || true && \
211211
rm -rf */examples */benchmarks */docs || true && \
212-
rm -rf skimage/data || true && \
213-
find . -name "*.pyi" -delete 2>/dev/null || true
212+
rm -rf skimage/data || true
214213

215214
# Stage 2: Runtime
216215
FROM nvcr.io/nvidia/l4t-cuda:12.6.11-runtime

0 commit comments

Comments
 (0)