Hafnium49 commited on
Commit
fb59bf6
·
verified ·
1 Parent(s): 389eaa5

Fix: keep numpy 1.26 for TF/MEGNet compat (fairchem works despite metadata)

Browse files
Files changed (1) hide show
  1. Dockerfile +4 -4
Dockerfile CHANGED
@@ -41,10 +41,10 @@ RUN pip install --no-cache-dir --force-reinstall \
41
  # CRITICAL: Re-install setuptools with pkg_resources AFTER TF downgrade.
42
  # The --force-reinstall above installs setuptools>=82 which removed pkg_resources,
43
  # but torchtnt (fairchem dep) needs it at runtime. Pin to <72 where it still exists.
44
- # Also fix numpy: fairchem-core 2.13.0 requires numpy>=2.0 but TF 2.15 pulled numpy 1.26.
45
- RUN pip install --no-cache-dir "setuptools<72" "numpy>=2.0,<2.4" && \
46
- python -c "import pkg_resources; print('pkg_resources OK')" && \
47
- python -c "import numpy; print(f'numpy {numpy.__version__}')"
48
 
49
  COPY . .
50
 
 
41
  # CRITICAL: Re-install setuptools with pkg_resources AFTER TF downgrade.
42
  # The --force-reinstall above installs setuptools>=82 which removed pkg_resources,
43
  # but torchtnt (fairchem dep) needs it at runtime. Pin to <72 where it still exists.
44
+ # Note: TF 2.15 pins numpy<2.0 (1.26.4), while fairchem-core 2.13 wants numpy>=2.0.
45
+ # We keep numpy 1.26 (TF's pin) — fairchem works fine at runtime despite the metadata.
46
+ RUN pip install --no-cache-dir "setuptools<72" && \
47
+ python -c "import pkg_resources; print('pkg_resources OK')"
48
 
49
  COPY . .
50