Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
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
2 changes: 1 addition & 1 deletion .github/workflows/conda.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
strategy:
fail-fast: false
matrix:
platform: [ubuntu-latest, macos-13]
platform: [ubuntu-24.04, macos-13]
python-version: ["3.9"]

runs-on: ${{ matrix.platform }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ on:

jobs:
docker:
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
steps:
- name: Checkout
uses: actions/checkout@v4
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/docs_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on: [push, pull_request]

jobs:
CI:
runs-on: ubuntu-latest
runs-on: ubuntu-24.04

strategy:
fail-fast: false
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/extensive_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ on:

jobs:
test:
runs-on: ubuntu-22.04
runs-on: ubuntu-24.04

env:
OMPI_ALLOW_RUN_AS_ROOT: 1
Expand Down Expand Up @@ -247,7 +247,7 @@ jobs:
include-hidden-files: true

coverage:
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
needs: [ test ]
steps:

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/linting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on: [push, pull_request]

jobs:
CI:
runs-on: ubuntu-latest
runs-on: ubuntu-24.04

strategy:
fail-fast: false
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/non_simd_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ on:

jobs:
test:
runs-on: ubuntu-latest
runs-on: ubuntu-24.04

env:
OMPI_ALLOW_RUN_AS_ROOT: 1
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/singularity.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ on:

jobs:
build-containers:
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
# container:
# image: quay.io/singularity/singularity:v3.9.3
# options: --security-opt seccomp=unconfined --security-opt systempaths=unconfined
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ on:

jobs:
test:
runs-on: ubuntu-latest
runs-on: ubuntu-24.04

env:
OMPI_ALLOW_RUN_AS_ROOT: 1
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/wheel.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
fail-fast: false
matrix:
# macos-13 is an intel runner, macos-14 is apple silicon
os: [ubuntu-latest, ubuntu-24.04-arm, macos-13, macos-14]
os: [ubuntu-24.04, ubuntu-24.04-arm, macos-13, macos-14]

steps:
- uses: actions/checkout@v4
Expand All @@ -38,7 +38,7 @@ jobs:

build_sdist:
name: Build source distribution
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v4

Expand All @@ -52,7 +52,7 @@ jobs:

upload_pypi:
needs: [build_wheels, build_sdist]
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
environment: pypi
permissions:
id-token: write
Expand Down
5 changes: 4 additions & 1 deletion tests/field/test_biotsavart.py
Original file line number Diff line number Diff line change
Expand Up @@ -383,7 +383,10 @@ def f(t, r):
r = 0.15
fluxB = integrate.dblquad(f, 0, r, 0, 2*np.pi, epsabs=1e-15, epsrel=1e-15)

for num in range(20, 60):
# num range used to be (20, 60) but this fails for num <= 20-30 for certain
# random coil initializations since don't have enough quadrature points
# to integrate to numerical precision.
for num in range(40, 100):
npoints = num
angles = np.linspace(0, 2*np.pi, npoints, endpoint=False).reshape((-1, 1))
t = np.concatenate((-np.sin(angles), np.cos(angles), np.zeros((angles.size, 1))), axis=1) @ rot.T
Expand Down
11 changes: 6 additions & 5 deletions tests/geo/test_boozersurface.py
Original file line number Diff line number Diff line change
Expand Up @@ -253,8 +253,9 @@ def subtest_boozer_surface_optimisation_convergence(self, surfacetype,
from simsopt.geo.curve import RotatedCurve
curves_flipped = [RotatedCurve(c, 0, True) for c in curves]
currents_flipped = [-cur for cur in currents]
rng = np.random.default_rng(12345)
for c in curves_flipped:
c.rotmat += 0.001*np.random.uniform(low=-1., high=1.,
c.rotmat += 0.001*rng.uniform(low=-1., high=1.,
size=c.rotmat.shape)
c.rotmatT = c.rotmat.T
coils = coils_via_symmetries(curves + curves_flipped,
Expand Down Expand Up @@ -293,18 +294,18 @@ def subtest_boozer_surface_optimisation_convergence(self, surfacetype,
boozer_surface.recompute_bell()
if second_stage == 'ls':
res = boozer_surface.minimize_boozer_penalty_constraints_ls(
tol=1e-11, maxiter=100, constraint_weight=1000./cw,
tol=1e-10, maxiter=100, constraint_weight=1000./cw,
iota=res['iota'], G=res['G'])
elif second_stage == 'newton':
res = boozer_surface.minimize_boozer_penalty_constraints_newton(
tol=1e-10, maxiter=20, constraint_weight=100./cw,
tol=1e-10, maxiter=100, constraint_weight=100./cw,
iota=res['iota'], G=res['G'], stab=1e-4, vectorize=vectorize)
elif second_stage == 'newton_exact':
res = boozer_surface.minimize_boozer_exact_constraints_newton(
tol=1e-10, maxiter=15, iota=res['iota'], G=res['G'])
tol=1e-10, maxiter=100, iota=res['iota'], G=res['G'])
elif second_stage == 'residual_exact':
res = boozer_surface.solve_residual_equation_exactly_newton(
tol=1e-12, maxiter=15, iota=res['iota'], G=res['G'])
tol=1e-10, maxiter=100, iota=res['iota'], G=res['G'])

print('Residual norm after second stage', np.linalg.norm(res['residual']))
assert res['success']
Expand Down
Loading