Skip to content

Commit 408d612

Browse files
committed
fix oceanval calls in a couple of tests
1 parent e9bb0d0 commit 408d612

2 files changed

Lines changed: 4 additions & 9 deletions

File tree

tests/test_gridded_matchups.py

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -23,16 +23,16 @@ def test_gridded(self):
2323
model_variable = "votemper",
2424
obs_variable = "votemper",
2525
climatology = True,
26-
vertical = True,
2726
start = 2000,
28-
end = 2010
27+
end = 2000
2928
)
3029

3130
oceanval.matchup(
3231
sim_dir = "data/example",
3332
start = 2000,
3433
end = 2000,
3534
ask = False,
35+
thickness = "data/example/e3t.nc",
3636
cores = 1)
3737

3838
assert os.path.exists("oceanval_matchups/gridded/temperature/foo_temperature_surface.nc")
@@ -58,11 +58,6 @@ def test_gridded(self):
5858
max_diff = np.abs(df['diff']).max()
5959
assert max_diff < 1e-5
6060

61-
ds = nc.open_data("oceanval_matchups/gridded/temperature/foo_temperature_vertical.nc")
62-
df = ds.to_dataframe().assign(diff = lambda x: x.model - x.observation)
63-
# get absolute max difference
64-
max_diff = np.abs(df['diff']).max()
65-
assert max_diff < 1e-5
6661
# shutil.rmtree("oceanval_matchups/gridded/temperature", ignore_errors=True)
6762
shutil.rmtree("oceanval_matchups", ignore_errors=True)
6863

@@ -159,8 +154,7 @@ def test_gridded(self):
159154
name = "temperature",
160155
obs_path="data/evaldata/point/nws/all/temperature",
161156
source = "foo",
162-
model_variable = "votemper",
163-
vertical = True
157+
model_variable = "votemper"
164158
)
165159
oceanval.matchup(
166160
sim_dir = "data/example",

tests/test_short_simulations.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ def test_a_short_one(self):
1919
climatology = True
2020
)
2121
oceanval.matchup("data/monthly",
22+
ask = False,
2223
start = 2000, end = 2000)
2324

2425
import nctoolkit as nc

0 commit comments

Comments
 (0)