Skip to content

Commit 5f0c2c4

Browse files
committed
fix error catching in surge lookup
1 parent d2f07d4 commit 5f0c2c4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pyCIAM/run.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -341,14 +341,14 @@ def _check_vals(rh_diff_arr, lslr_arr, seg):
341341
"(initial adaptation) table if it was generated for a different "
342342
"set of SLR scenarios or years."
343343
)
344+
# lslr is allowed to be below min surge lookup value b/c we created
345+
# lookup such that < min value will be 0 impact
344346
if rh_diff_arr.max() > this_surge_lookup.rh_diff.max():
345347
raise ValueError(error_str.format("rh_diff", "higher", "maximum"))
346348
if rh_diff_arr.min() < this_surge_lookup.rh_diff.min():
347349
raise ValueError(error_str.format("rh_diff", "lower", "minimum"))
348350
if lslr_arr.max() > this_surge_lookup.lslr.max():
349351
raise ValueError(error_str.format("lslr", "higher", "maximum"))
350-
if lslr_arr.min() < this_surge_lookup.lslr.min():
351-
raise ValueError(error_str.format("lslr", "lower", "minimum"))
352352

353353
for seg in inputs.seg.values:
354354
this_surge_lookup = (

0 commit comments

Comments
 (0)