File tree 4 files changed +26
-7
lines changed
4 files changed +26
-7
lines changed Original file line number Diff line number Diff line change @@ -32,8 +32,16 @@ RUN uv pip uninstall --system google-cloud-bigquery-storage
32
32
# to avoid affecting the larger build, we'll post-install it.
33
33
RUN uv pip install --no-build-isolation --system "git+https://github.com/Kaggle/learntools"
34
34
35
+ # b/385161357 Latest Colab uses tf 2.17.1, but tf decision forests only has a version for 2.17.0.
36
+ # Instead, we'll install tfdf with its deps and hope that 2.17.0 compat tfdf works with tf 2.17.1.
37
+ RUN uv pip install --system --no-deps tensorflow-decision-forests==1.10.0 wurlitzer==3.1.1 ydf==0.9.0
38
+
39
+ # b/385145217 Latest Colab lacks mkl numpy, install it.
40
+ RUN uv pip install --system --force-reinstall -i https://pypi.anaconda.org/intel/simple numpy
41
+
35
42
# b/328788268 We install an incompatible pair of libs (shapely<2, libpysal==4.9.2) so we can't put this one in the requirements.txt
36
- RUN uv pip install --system "libpysal==4.9.2"
43
+ # newer daal4py requires tbb>=2022, but libpysal is downgrading it for some reason
44
+ RUN uv pip install --system "tbb>=2022" "libpysal==4.9.2"
37
45
38
46
# Adding non-package dependencies:
39
47
Original file line number Diff line number Diff line change 1
1
BASE_IMAGE=us-docker.pkg.dev/colab-images/public/runtime
2
- BASE_IMAGE_TAG=release-colab_20240920-060127_RC00
2
+ BASE_IMAGE_TAG=release-colab_20241217-060132_RC00
3
3
LIGHTGBM_VERSION=4.5.0
4
4
CUDA_MAJOR_VERSION=12
5
5
CUDA_MINOR_VERSION=2
Original file line number Diff line number Diff line change @@ -85,6 +85,7 @@ libpysal<=4.9.2
85
85
lime
86
86
line_profiler
87
87
mamba
88
+ matplotlib<3.8
88
89
mlcrate
89
90
mne
90
91
mpld3
@@ -142,7 +143,8 @@ squarify
142
143
tensorflow-cloud
143
144
tensorflow-io
144
145
tensorflow-text
145
- tensorflow_decision_forests
146
+ # b/385161357: tf 2.17.1 does not have matching tensorflow_decision_forests release
147
+ # tensorflow_decision_forests
146
148
timm
147
149
torchinfo
148
150
torchmetrics
Original file line number Diff line number Diff line change 3
3
from distutils .version import StrictVersion
4
4
5
5
import numpy as np
6
- from numpy .distutils .system_info import get_info
6
+ import io
7
+ from contextlib import redirect_stdout
7
8
8
- class TestNumpy (unittest .TestCase ):
9
+ class TestNumpy (unittest .TestCase ):
9
10
def test_version (self ):
10
11
# b/370860329: newer versions are not capable with current tensorflow
11
12
self .assertEqual (StrictVersion (np .__version__ ), StrictVersion ("1.26.4" ))
@@ -18,5 +19,13 @@ def test_array(self):
18
19
# Numpy must be linked to the MKL. (Occasionally, a third-party package will muck up the installation
19
20
# and numpy will be reinstalled with an OpenBLAS backing.)
20
21
def test_mkl (self ):
21
- # This will throw an exception if the MKL is not linked correctly or return an empty dict.
22
- self .assertTrue (get_info ("blas_mkl" ))
22
+ try :
23
+ from numpy .distutils .system_info import get_info
24
+ # This will throw an exception if the MKL is not linked correctly or return an empty dict.
25
+ self .assertTrue (get_info ("blas_mkl" ))
26
+ except :
27
+ # Fallback to check if mkl is present via show_config()
28
+ config_out = io .StringIO ()
29
+ with redirect_stdout (config_out ):
30
+ np .show_config ()
31
+ self .assertIn ("mkl_rt" , config_out .getvalue ())
You can’t perform that action at this time.
0 commit comments