Skip to content

Commit 6a305b0

Browse files
Merge pull request #34 from gregory-halverson/main
fixing verification
2 parents 4baa0fc + b33e094 commit 6a305b0

6 files changed

+2561
-2311
lines changed

PTJPLSM/ECOv002-cal-val-PT-JPL-SM-inputs.csv

Lines changed: 1066 additions & 1066 deletions
Large diffs are not rendered by default.

PTJPLSM/ECOv002-cal-val-PT-JPL-SM-outputs.csv

Lines changed: 1066 additions & 1066 deletions
Large diffs are not rendered by default.
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
import os
2+
import pandas as pd
3+
4+
def load_ECOv002_static_tower_PTJPLSM_inputs() -> pd.DataFrame:
5+
"""
6+
Load the input data for the PT-JPL-SM model from the ECOSTRESS Collection 2 Cal-Val dataset.
7+
8+
Returns:
9+
pd.DataFrame: A DataFrame containing the input data.
10+
"""
11+
12+
# Define the path to the input CSV file relative to this module's directory
13+
module_dir = os.path.dirname(os.path.abspath(__file__))
14+
input_file_path = os.path.join(module_dir, "ECOv002-static-tower-PT-JPL-SM-inputs.csv")
15+
16+
# Load the input data into a DataFrame
17+
inputs_df = pd.read_csv(input_file_path)
18+
19+
return inputs_df

PTJPLSM/PTJPLSM.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,5 @@
22
from .generate_PTJPLSM_inputs import generate_PTJPLSM_inputs
33
from .process_PTJPLSM_table import process_PTJPLSM_table
44
from .ECOv002_calval_PTJPLSM_inputs import load_ECOv002_calval_PTJPLSM_inputs
5+
from .ECOv002_static_tower_PTJPLSM_inputs import load_ECOv002_static_tower_PTJPLSM_inputs
56
from .verify import verify

PTJPLSM/verify.py

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,14 @@ def verify() -> bool:
2929

3030
# Columns to compare (model outputs)
3131
output_columns = [
32-
'G', 'Rn_soil', 'LE_soil', 'Rn_canopy', 'PET',
33-
'LE_canopy', 'LE_interception', 'LE'
32+
"G_Wm2",
33+
"Rn_soil_Wm2",
34+
"LE_soil_Wm2",
35+
"Rn_canopy_Wm2",
36+
"PET_Wm2",
37+
"LE_canopy_Wm2",
38+
"LE_interception_Wm2",
39+
"LE_Wm2"
3440
]
3541

3642
# Compare each output column and collect mismatches

notebooks/Tower Input Data for PT-JPL-SM from ECOSTRESS Collection 2 Cal-Val copy.ipynb

Lines changed: 401 additions & 177 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)