Skip to content

Commit

Permalink
update numexpr with fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Emma Ai committed Sep 18, 2024
1 parent 6a29afa commit efd6427
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 6 deletions.
10 changes: 5 additions & 5 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,11 @@ RUN micromamba create -y -p /env -f /conf/env.yaml && \
ARG MAMBA_DOCKERFILE_ACTIVATE=1
ARG UPDATE_VERSION=1
COPY requirements.txt /conf/
# required to build numexpr
# or any --no-binary
ENV CC=/env/bin/x86_64-conda_cos6-linux-gnu-gcc \
CXX=/env/bin/x86_64-conda_cos6-linux-gnu-g++ \
LDSHARED="/env/bin/x86_64-conda_cos6-linux-gnu-gcc -pthread -shared -B /env/compiler_compat -L/env/lib -Wl,-rpath=/env/lib -Wl,--no-as-needed"
RUN micromamba run -p /env pip install --no-cache-dir \
--no-build-isolation -r /conf/requirements.txt

Expand All @@ -22,11 +27,6 @@ ENV GDAL_DRIVER_PATH=/env/lib/gdalplugins \
GDAL_DATA=/env/share/gdal \
PATH=/env/bin:$PATH

# here is very hacky fix for the threading issue
# MUST follow up with package owner and further address the issue accordingly

RUN wget -q -O /env/lib/python3.10/site-packages/numexpr/necompiler.py https://raw.githubusercontent.com/emmaai/numexpr/master/numexpr/necompiler.py

WORKDIR /tmp

RUN odc-stats --version
4 changes: 3 additions & 1 deletion docker/env.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ dependencies:
- gdal>=3.8
- proj
- rasterio>=1.3.2
- gcc_linux-64
- gxx_linux-64
- binutils_linux-64
- libpq
- git
- wget
Expand Down Expand Up @@ -76,7 +79,6 @@ dependencies:
- munch
- netCDF4
- networkx
- numexpr
# for the sake of geomedian address this later
- numpy<2.0
- ordered-set
Expand Down
1 change: 1 addition & 0 deletions docker/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
--extra-index-url https://packages.dea.ga.gov.au/
datacube[performance,s3]>=1.8.17
hdstats==0.1.8.post1
numexpr @ git+https://github.com/pydata/numexpr@a99412e
odc-algo @ git+https://github.com/opendatacube/odc-algo@adb1856
odc-apps-cloud>=0.2.2
# For testing
Expand Down

0 comments on commit efd6427

Please sign in to comment.