Skip to content

Commit

Permalink
Merge pull request #6 from equinor/subsheat3D/test_from_grids
Browse files Browse the repository at this point in the history
Subsheat3 d/test from grids
  • Loading branch information
adamchengtkc authored Nov 20, 2023
2 parents 1c6a41b + d6f27ec commit 714432f
Show file tree
Hide file tree
Showing 22 changed files with 348 additions and 873 deletions.
35 changes: 17 additions & 18 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM dolfinx/dolfinx:v0.7.0
FROM dolfinx/dolfinx:v0.6.0
# FROM mcr.microsoft.com/devcontainers/base:jammy
ARG DEBIAN_FRONTEND=noninteractive
# RUN useradd -ms /bin/bash vscode
Expand All @@ -25,23 +25,22 @@ RUN DEBIAN_FRONTEND=noninteractive \
libffi-dev \
liblzma-dev

# Python and poetry installation
USER $USER
ARG HOME="/home/$USER"
# # Python and poetry installation
# # USER $USER
# # ARG HOME="/home/$USER"

# Don't change. Dolfinx in the base image is only compiled with 3.10
ARG PYTHON_VERSION=3.10

# Use poetry pyenv
ENV PYENV_ROOT="${HOME}/.pyenv"
ENV PATH="${PYENV_ROOT}/shims:${PYENV_ROOT}/bin:${HOME}/.local/bin:$PATH"
# # Don't change. Dolfinx in the base image is only compiled with 3.10
# #ARG PYTHON_VERSION=3.10.6

# # Use poetry pyenv
# #ENV PYENV_ROOT="${HOME}/.pyenv"
# #ENV PATH="${PYENV_ROOT}/shims:${PYENV_ROOT}/bin:${HOME}/.local/bin:/root/.local/bin:$PATH"
ENV PATH="/root/.local/bin:$PATH"
RUN echo "done 0" \
&& curl https://pyenv.run | bash \
&& echo "done 1" \
&& pyenv install ${PYTHON_VERSION} \
&& echo "done 2" \
&& pyenv global ${PYTHON_VERSION} \
&& echo "done 3" \
&& curl -sSL https://install.python-poetry.org | python3 - \
&& poetry config virtualenvs.in-project true
# # && curl https://pyenv.run | bash \
# # && echo "done 1" \
# # && pyenv install ${PYTHON_VERSION} \
# # && echo "done 2" \
# # && pyenv global ${PYTHON_VERSION} \
# # && echo "done 3" \
&& curl -sSL https://install.python-poetry.org | python3 -
4 changes: 3 additions & 1 deletion .devcontainer/postCreate.sh
Original file line number Diff line number Diff line change
@@ -1,2 +1,4 @@
poetry config virtualenvs.create false
poetry env use system
poetry install --with dev --no-interaction
poetry run pip install petsc4py==3.20.0 mpi4py==3.1.5 https://github.com/FEniCS/ufl/archive/refs/tags/2023.2.0.zip https://github.com/FEniCS/ffcx/archive/v0.7.0.zip https://github.com/FEniCS/basix/archive/v0.7.0.zip
#poetry run pip install petsc4py==3.20.0 mpi4py==3.1.5 https://github.com/FEniCS/ufl/archive/refs/tags/2023.2.0.zip https://github.com/FEniCS/ffcx/archive/v0.7.0.zip https://github.com/FEniCS/basix/archive/v0.7.0.zip
6 changes: 3 additions & 3 deletions .github/workflows/python-test-3d.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
name: Tests3D

on:
workflow_dispatch:
workflow_call:
inputs:
event_type:
Expand All @@ -23,12 +24,11 @@ jobs:
- name: Run
uses: tj-actions/docker-run@v2
with:
image: dolfinx/dolfinx:v0.7.0
image: dolfinx/dolfinx:v0.6.0
name: dolfinx
options: -v ${{ github.workspace }}:/home/warmth
args: |
bash -c "cd /home/warmth" && pip install . pytest==7.4.2 pytest-cov==4.1.0 && pytest --cov-report=term-missing --cov=warmth/3d tests/3d | tee pytest-coverage.txt
bash -c "cd /home/warmth" && pip install . pytest==7.4.2 pytest-cov==4.1.0 && pytest --cov-report=term-missing --cov=warmth tests | tee pytest-coverage.txt
- name: Comment coverage
if: ${{ github.event_name == 'pull_request' && github.event.action == 'opened' }}
Expand Down
Binary file modified docs/notebooks/data/0.gri
Binary file not shown.
Binary file modified docs/notebooks/data/100.gri
Binary file not shown.
Binary file modified docs/notebooks/data/163.gri
Binary file not shown.
Binary file modified docs/notebooks/data/168.gri
Binary file not shown.
Binary file modified docs/notebooks/data/170.gri
Binary file not shown.
Binary file modified docs/notebooks/data/182.gri
Binary file not shown.
Binary file modified docs/notebooks/data/66.gri
Binary file not shown.
Loading

0 comments on commit 714432f

Please sign in to comment.