Skip to content

Commit

Permalink
[MAINT] Update Ubuntu runner versions (#54)
Browse files Browse the repository at this point in the history
  • Loading branch information
tsbinns authored Feb 13, 2025
1 parent 0779b03 commit 6558292
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/unit_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ jobs:

test_conda:
timeout-minutes: 90
runs-on: ubuntu-20.04
runs-on: ubuntu-latest
defaults:
run:
shell: bash -el {0}
Expand Down
12 changes: 6 additions & 6 deletions tests/test_results.py
Original file line number Diff line number Diff line change
Expand Up @@ -128,10 +128,10 @@ def test_results_cfc_runs() -> None:
data=data[subset], indices=indices_subset, f1s=f1s, f2s=f2s, name=name
)
results_array, array_indices = results.get_results(form="compact")
assert np.max(array_indices) == np.unique(indices_subset).max()
assert np.max(array_indices) == len(np.unique(indices_subset)) - 1
# Check that the results array is NaN for missing nodes
array_subset_mask = np.zeros(results_array.shape[:2], dtype=bool)
array_subset_mask[indices_subset[0], indices_subset[1]] = True
array_subset_mask[array_indices[0], array_indices[1]] = True
assert not np.isnan(results_array[array_subset_mask]).all()
assert np.isnan(results_array[~array_subset_mask]).all()

Expand Down Expand Up @@ -311,10 +311,10 @@ def test_results_tde_runs(freq_bands: tuple) -> None:

results_array, array_indices = results.get_results(form="compact")

assert np.max(array_indices) == np.unique(indices_subset).max()
assert np.max(array_indices) == len(np.unique(indices_subset)) - 1
# Check that the results array is NaN for missing nodes
array_subset_mask = np.zeros(results_array.shape[:2], dtype=bool)
array_subset_mask[indices_subset[0], indices_subset[1]] = True
array_subset_mask[array_indices[0], array_indices[1]] = True
assert not np.isnan(results_array[array_subset_mask]).all()
assert np.isnan(results_array[~array_subset_mask]).all()

Expand Down Expand Up @@ -533,9 +533,9 @@ def test_results_general_runs() -> None:
data=data[subset], indices=indices_subset, f1s=f1s, f2s=f2s, name=name
)
results_array, array_indices = results.get_results(form="compact")
assert np.max(array_indices) == np.unique(indices_subset).max()
assert np.max(array_indices) == len(np.unique(indices_subset)) - 1
# Check that the results array is NaN for missing nodes
array_subset_mask = np.zeros(results_array.shape[:3], dtype=bool)
array_subset_mask[indices_subset[0], indices_subset[1], indices_subset[2]] = True
array_subset_mask[array_indices[0], array_indices[1], array_indices[2]] = True
assert not np.isnan(results_array[array_subset_mask]).all()
assert np.isnan(results_array[~array_subset_mask]).all()

0 comments on commit 6558292

Please sign in to comment.