@@ -6,7 +6,7 @@ FROM ${BASE_IMAGE}:${BASE_IMAGE_TAG}
66ADD kaggle_requirements.txt /kaggle_requirements.txt
77
88# Freeze existing requirements from base image for critical packages:
9- RUN pip freeze | grep -E 'tensorflow| keras| torch| jax' > /colab_requirements.txt
9+ RUN pip freeze | grep -E 'tensorflow| keras| torch| jax| numpy ' > /colab_requirements.txt
1010
1111# Merge requirements files:
1212RUN cat /colab_requirements.txt >> /requirements.txt
@@ -29,31 +29,14 @@ RUN uv pip install --system --force-reinstall --prerelease=allow "kagglehub[pand
2929# to avoid affecting the larger build, we'll post-install it.
3030RUN uv pip install --no-build-isolation --system " git+https://github.com/Kaggle/learntools"
3131
32- # b/408281617: Torch is adamant that it can not install cudnn 9.3.x , only 9.1.x , but Tensorflow can only support 9.3.x.
33- # This conflict causes a number of package downgrades, which are handled in this command
34- RUN uv pip install \
35- --index -url https://pypi.nvidia.com --extra-index -url https://pypi.org /simple/ --index -strategy unsafe-first-match \
36- --system --force-reinstall " cuml-cu12==25.2.1" \
37- " nvidia-cudnn-cu12==9.3.0.75" " nvidia-cublas-cu12==12.5.3.2" " nvidia-cusolver-cu12==11.6.3.83" \
38- " nvidia-cuda-cupti-cu12==12.5.82" " nvidia-cuda-nvrtc-cu12==12.5.82" " nvidia-cuda-runtime-cu12==12.5.82" \
39- " nvidia-cufft-cu12==11.2.3.61" " nvidia-curand-cu12==10.3.6.82" " nvidia-cusparse-cu12==12.5.1.3" \
40- " nvidia-nvjitlink-cu12==12.5.82"
41- RUN uv pip install --system --force-reinstall " pynvjitlink-cu12==0.5.2"
42-
43- # b/385145217 Latest Colab lacks mkl numpy, install it.
44- # RUN uv pip install --system --force-reinstall --index -url https://pypi.anaconda.org /intel/simple numpy== 2.0
45- # RUN uv pip install --system --force-reinstall -i https://pypi.anaconda.org /intel/simple numpy
46- # https://software.repos.intel.com /python/pypi
47-
4832# newer daal4py requires tbb>= 2022, but libpysal is downgrading it for some reason
4933RUN uv pip install --system " tbb>=2022" " libpysal==4.9.2"
5034
5135# b/404590350: Ray and torchtune have conflicting tune cli, we will prioritize torchtune.
5236# b/415358158: Gensim removed from Colab image to upgrade scipy
5337# b/456239669: remove huggingface-hub pin when pytorch-lighting and transformer are compatible
5438# b/315753846: Unpin translate package, currently conflicts with adk 1.17.0
55- RUN uv pip install --system --force-reinstall --no-deps torchtune gensim " scipy<=1.15.3" " huggingface-hub==0.36.0" " google-cloud-translate==3.12.1"
56-
39+ RUN uv pip install --system --force-reinstall --no-deps torchtune gensim " scipy<=1.15.3" " huggingface-hub==0.36.0" " google-cloud-translate==3.12.1" " numpy==2.0.2"
5740
5841RUN uv pip install --system --force-reinstall " protobuf==5.29.5"
5942
0 commit comments