Skip to content

Commit

Permalink
Ubuntu 24.04 updates
Browse files Browse the repository at this point in the history
  • Loading branch information
jrmaddison committed Sep 2, 2024
1 parent 9904db3 commit 8cba73b
Show file tree
Hide file tree
Showing 6 changed files with 25 additions and 10 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/test-fenics_ice.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ concurrency:

jobs:
test:
runs-on: ubuntu-22.04
runs-on: ubuntu-24.04
timeout-minutes: 60
env:
OMP_NUM_THREADS: 1
Expand All @@ -41,7 +41,7 @@ jobs:
run: |
export PYTHONPATH=$PYTHONPATH:$GITHUB_WORKSPACE/tlm_adjoint
cd fenics_ice
pytest-3 -v --order-scope=module --timeout=300 --timeout-method=thread
pytest-3 -v -k tv --order-scope=module --timeout=300 --timeout-method=thread
mpirun -n 2 pytest-3 -v --order-scope=module --timeout=300 --timeout-method=thread
mpirun -n 2 pytest-3 -m key --key=smith --timeout=300 --timeout-method=thread
pytest -v --order-scope=module --timeout=300 --timeout-method=thread
pytest -v -k tv --order-scope=module --timeout=300 --timeout-method=thread
mpirun -n 2 pytest -v --order-scope=module --timeout=300 --timeout-method=thread
mpirun -n 2 pytest -m key --key=smith --timeout=300 --timeout-method=thread
5 changes: 4 additions & 1 deletion fenics_ice/model.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,10 @@
from . import mesh as fice_mesh

import os.path
import ufl
try:
import ufl_legacy as ufl
except ModuleNotFoundError:
import ufl
import numpy as np
from pathlib import Path
from numpy.random import randn
Expand Down
5 changes: 4 additions & 1 deletion fenics_ice/prior.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,10 @@


from abc import ABC, abstractmethod
import ufl
try:
import ufl_legacy as ufl
except ModuleNotFoundError:
import ufl

class Prior(ABC):
"""Abstraction for prior used by both comp_J_inv and run_eigendec.py"""
Expand Down
5 changes: 4 additions & 1 deletion fenics_ice/solver.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,10 @@
import numpy as np
from pathlib import Path
import time
import ufl
try:
import ufl_legacy as ufl
except ModuleNotFoundError:
import ufl
import weakref

log = logging.getLogger("fenics_ice")
Expand Down
5 changes: 4 additions & 1 deletion fenics_ice/sqrt_matrix_action.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,10 @@
from fenics import TestFunction, TrialFunction, assemble, dx, inner, split

import numpy as np
import ufl
try:
import ufl_legacy as ufl
except ModuleNotFoundError:
import ufl

__all__ = \
[
Expand Down
5 changes: 4 additions & 1 deletion runs/run_obs_sens_prop.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,10 @@
from fenics_ice import model, solver, inout
from fenics_ice import mesh as fice_mesh
from fenics_ice.config import ConfigParser
from ufl import split
try:
from ufl_legacy import split
except ModuleNotFoundError:
from ufl import split
from fenics_ice.solver import Amat_obs_action

import matplotlib as mpl
Expand Down

0 comments on commit 8cba73b

Please sign in to comment.