Skip to content

Indiamai/fuse quads #4075

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 24 commits into
base: indiamai/new_def_integration
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
eb3da67
Make mesh cells all be cell complexes
indiamai Sep 10, 2024
6504f8d
DROP BEFORE MERGE
indiamai Nov 25, 2024
c1f99e1
First try at adding redefining_fe to packages
indiamai Nov 26, 2024
f8e8c20
Fix import accidently deleted in merge
indiamai Dec 2, 2024
713e54b
DROP BEFORE MERGE remove finat and tsfc branches
indiamai Dec 9, 2024
7ab504e
Rename redefining fe to fuse (#3960)
indiamai Jan 11, 2025
a579713
Add original code back in as comment
indiamai Jan 13, 2025
d02072f
Clean up mesh.py
indiamai Jan 17, 2025
fc1f72e
lint
indiamai Jan 17, 2025
c2da373
temp testing file
indiamai Jan 20, 2025
dbf22d4
Add small subset of tests for easy temporary fuse testing
indiamai Jan 22, 2025
a12e9e7
hex: add tests for interior facet integration of geometric quantities…
ksagiyam Jan 22, 2025
24e24f1
Do not run report action on forks to avoid permissions issues (#3976)
connorjward Jan 22, 2025
7c3f20b
Improve kernel caching (#3982)
connorjward Jan 22, 2025
92861f5
Transpose interpolation -> adjoint interpolation (#3965)
jrmaddison Jan 23, 2025
834db29
Test suite clean up (#3385)
JDBetteridge Jan 23, 2025
71280c6
Always upload CI logs (#3991)
connorjward Jan 24, 2025
cbc6cda
Fix assembly of split forms with subdomain ids (#3993)
pbrubeck Jan 24, 2025
32b4e4c
Use xdist for serial tests (#3996)
connorjward Jan 29, 2025
eea2c06
Brute forcing a fuse quad in
indiamai Feb 4, 2025
22cc1fa
move more things to generic as cell, further work on qudas
indiamai Feb 20, 2025
3c12de7
clean up
indiamai Feb 26, 2025
da0b3f2
lint
indiamai Feb 26, 2025
571128d
Fix small issue in interpolation
indiamai Feb 27, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 7 additions & 5 deletions .github/workflows/build-mac.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,14 +46,16 @@ jobs:
--venv-name firedrake_venv \
--disable-ssh \
|| (cat firedrake-install.log && /bin/false)
- name: Install test dependencies
run: |
. ../firedrake_venv/bin/activate
python -m pip install pytest-timeout

- name: Run smoke tests
run: |
. ../firedrake_venv/bin/activate
python -m pytest -v tests/firedrake/regression/ -k "poisson_strong or stokes_mini or dg_advection"
# also test for 'problem libraries' (spatialindex and libsupermesh)
python -m pytest -v tests/firedrake/regression/test_locate_cell.py
python -m pytest -v tests/firedrake/supermesh/test_assemble_mixed_mass_matrix.py
timeout-minutes: 30
make check CHECK_PYTEST_ARGS="--timeout 60"
timeout-minutes: 10
- name: Post-run cleanup
if: ${{ always() }}
run: |
Expand Down
104 changes: 81 additions & 23 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,14 @@ env:
RELEASE_TAG: latest

jobs:
build:
name: "Build Firedrake"
# Run on our self-hosted machines
test:
name: "Run Firedrake tests (Linux)"
runs-on: [self-hosted, Linux]
container:
image: firedrakeproject/firedrake-env:latest
strategy:
# Don't immediately kill real if complex fails and vice versa.
# We want to know all of the tests which fail, so don't kill real if
# complex fails and vice-versa
fail-fast: false
matrix:
include:
Expand All @@ -47,13 +47,16 @@ jobs:
OPENBLAS_NUM_THREADS: 1
COMPLEX: ${{ matrix.complex }}
RDMAV_FORK_SAFE: 1
EXTRA_PYTEST_ARGS: --splitting-algorithm least_duration --timeout=1800 --timeout-method=thread -o faulthandler_timeout=1860 tests/firedrake
steps:
- uses: actions/checkout@v4

- name: Cleanup
if: ${{ always() }}
run: |
cd ..
rm -rf firedrake_venv

- name: Build Firedrake
run: |
cd ..
Expand Down Expand Up @@ -84,57 +87,111 @@ jobs:
--install defcon \
--install gadopt \
--install asQ \
--package-branch fiat indiamai/integrate_fuse \
--package-branch fuse main \
|| (cat firedrake-install.log && /bin/false)

- name: Install test dependencies
id: build
run: |
sudo apt update
sudo apt -y install parallel
. ../firedrake_venv/bin/activate
python "$(which firedrake-clean)"
python -m pip install \
pytest-xdist pytest-timeout ipympl
python -m pip install pytest-timeout ipympl pytest-split pytest-xdist
python -m pip list
- name: Test Firedrake

- name: Run tests (nprocs = 1)
run: |
: # Use pytest-xdist here so we can have a single collated output (not possible
: # for parallel tests)
. ../firedrake_venv/bin/activate
echo OMP_NUM_THREADS is "$OMP_NUM_THREADS"
echo OPENBLAS_NUM_THREADS is "$OPENBLAS_NUM_THREADS"
python -m pytest -v tests/firedrake/test_0init.py
python -m pytest \
--durations=200 \
--timeout=1800 \
--timeout-method=thread \
-o faulthandler_timeout=1860 \
-n 12 --dist worksteal \
--junit-xml=firedrake.xml \
-sv tests/firedrake
timeout-minutes: 120
firedrake-run-split-tests 1 1 "-n 12 $EXTRA_PYTEST_ARGS --junit-xml=firedrake1_{#}.xml"

- name: Run tests (nprocs = 2)
# Run even if earlier tests failed
if: ${{ success() || steps.build.conclusion == 'success' }}
run: |
. ../firedrake_venv/bin/activate
firedrake-run-split-tests 2 6 "$EXTRA_PYTEST_ARGS --junit-xml=firedrake2_{#}.xml"

- name: Run tests (nprocs = 3)
if: ${{ success() || steps.build.conclusion == 'success' }}
run: |
. ../firedrake_venv/bin/activate
firedrake-run-split-tests 3 4 "$EXTRA_PYTEST_ARGS --junit-xml=firedrake3_{#}.xml"

- name: Run tests (nprocs = 4)
if: ${{ success() || steps.build.conclusion == 'success' }}
run: |
. ../firedrake_venv/bin/activate
firedrake-run-split-tests 4 3 "$EXTRA_PYTEST_ARGS --junit-xml=firedrake4_{#}.xml"

- name: Run tests (nprocs = 5)
if: ${{ success() || steps.build.conclusion == 'success' }}
run: |
. ../firedrake_venv/bin/activate
firedrake-run-split-tests 5 2 "$EXTRA_PYTEST_ARGS --junit-xml=firedrake5_{#}.xml"

- name: Run tests (nprocs = 6)
if: ${{ success() || steps.build.conclusion == 'success' }}
run: |
. ../firedrake_venv/bin/activate
firedrake-run-split-tests 6 2 "$EXTRA_PYTEST_ARGS --junit-xml=firedrake6_{#}.xml"

- name: Run tests (nprocs = 7)
if: ${{ success() || steps.build.conclusion == 'success' }}
run: |
. ../firedrake_venv/bin/activate
firedrake-run-split-tests 7 1 "$EXTRA_PYTEST_ARGS --junit-xml=firedrake7_{#}.xml"

- name: Run tests (nprocs = 8)
if: ${{ success() || steps.build.conclusion == 'success' }}
run: |
. ../firedrake_venv/bin/activate
firedrake-run-split-tests 8 1 "$EXTRA_PYTEST_ARGS --junit-xml=firedrake8_{#}.xml"

- name: Publish Test Report
uses: mikepenz/[email protected]
if: ${{ always() && ( github.ref != 'refs/heads/master') }}
# To avoid permissions issues do not run with forked repos
# (see https://github.com/mikepenz/action-junit-report/issues/23)
if: ${{ always() && (github.ref != 'refs/heads/master') && (github.event.pull_request.head.repo.full_name == github.repository) }}
with:
report_paths: '/__w/firedrake/firedrake/firedrake.xml'
report_paths: 'firedrake*.xml'
comment: true
check_name: "Firedrake ${{ matrix.scalar-type }}"
updateComment: true
flaky_summary: true

- name: Upload log files
uses: actions/upload-artifact@v4
if: always()
with:
name: firedrake-logs-${{ matrix.scalar-type }}
path: pytest_*.log

- name: Test pyadjoint
if: ${{ matrix.scalar-type == 'real' }}
run: |
. ../firedrake_venv/bin/activate
cd ../firedrake_venv/src/pyadjoint
python -m pytest \
--strict-markers \
--durations=200 \
--timeout=600 \
--timeout-method=thread \
-o faulthandler_timeout=660 \
-n 12 --dist worksteal \
-sv tests/firedrake_adjoint
timeout-minutes: 30

- name: Cleanup
# Belt and braces: clean up before and after the run.
if: ${{ always() }}
run: |
cd ..
rm -rf firedrake_venv

docker_tag:
name: "Set the Docker release tag"
runs-on: [self-hosted, Linux]
Expand All @@ -151,14 +208,15 @@ jobs:
echo The release tag is "$RELEASE_TAG"
outputs:
tag: ${{ env.RELEASE_TAG }}

docker:
name: "Build Docker containers"
# Only run on master, but always generate firedrake-env image,
# even if build fails (see docker.yml)
if: ${{ (github.ref == 'refs/heads/master') && always() }}
needs: [build, docker_tag]
needs: [test, docker_tag]
uses: ./.github/workflows/docker.yml
with:
tag: ${{ needs.docker_tag.outputs.tag }}
status: ${{ needs.build.result }}
status: ${{ needs.test.result }}
secrets: inherit
9 changes: 3 additions & 6 deletions .github/workflows/pip-mac.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ jobs:
# Only run this action if we are pushing to master or the PR is labelled "macOS"
if: ${{ (github.ref == 'refs/heads/master') || contains(github.event.pull_request.labels.*.name, 'macOS') }}
env:
FIREDRAKE_CI_TESTS: 1
OMP_NUM_THREADS: 1
OPENBLAS_NUM_THREADS: 1
steps:
Expand Down Expand Up @@ -98,12 +99,8 @@ jobs:
run: |
source pip_venv/bin/activate
cd pip_venv/src/firedrake
python -m pytest --timeout=1800 -v tests/firedrake/regression \
-k "poisson_strong or stokes_mini or dg_advection"
# also test for 'problem libraries' (spatialindex and libsupermesh)
python -m pytest -v tests/firedrake/regression/test_locate_cell.py
python -m pytest -v tests/firedrake/supermesh/test_assemble_mixed_mass_matrix.py
timeout-minutes: 30
make check CHECK_PYTEST_ARGS="--timeout 60"
timeout-minutes: 10

- name: Cleanup (post)
if: ${{ always() }}
Expand Down
16 changes: 5 additions & 11 deletions .github/workflows/pip.yml
Original file line number Diff line number Diff line change
Expand Up @@ -83,20 +83,14 @@ jobs:
run: |
source pip_venv/bin/activate
cd pip_venv/src/firedrake
pytest -v tests/firedrake/test_0init.py
pytest \
--durations=200 \
--timeout=1800 \
--timeout-method=thread \
-o faulthandler_timeout=1860 \
-n 12 --dist worksteal \
--junit-xml=firedrake.xml \
-sv tests/firedrake/regression -k "poisson_strong or stokes_mini or dg_advection"
timeout-minutes: 120
make check CHECK_PYTEST_ARGS="--timeout 60"
timeout-minutes: 10

- name: Publish Test Report
uses: mikepenz/[email protected]
if: ${{ always() && ( github.ref != 'refs/heads/master') }}
# To avoid permissions issues do not run with forked repos
# (see https://github.com/mikepenz/action-junit-report/issues/23)
if: ${{ always() && (github.ref != 'refs/heads/master') && (github.event.pull_request.head.repo.full_name == github.repository) }}
with:
report_paths: '/home/firedrake/pip_venv/src/firedrake/firedrake.xml'
comment: true
Expand Down
Loading