Skip to content
Snippets Groups Projects
Commit 548652be authored by benoit-cty's avatar benoit-cty
Browse files

valid_time

parent a8f6bd4b
Branches
No related tags found
1 merge request!52Prepare prod
......@@ -10,7 +10,7 @@ from datacirco import utilitaires
from datetime import datetime
# START_YEAR = 1960
START_YEAR = 2022
START_YEAR = 2024
END_YEAR = datetime.today().year - 1
MONTH = [str(i + 1).zfill(2) for i in range(12)]
years = range(START_YEAR, END_YEAR + 1)
......@@ -119,8 +119,14 @@ def process_one_month(
def convert_to_pandas(ds):
df = ds.to_dataframe().dropna().reset_index().drop(["spatial_ref"], axis=1)
df.rename(
{"time": "date", "t2m": "temperature", "tp": "precipitation"},
{
"time": "date",
"valid_time": "date",
"t2m": "temperature",
"tp": "precipitation",
},
axis=1,
inplace=True,
)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment