Skip to content

Commit

Permalink
Add possibility to specify ecgeps and meps geometry
Browse files Browse the repository at this point in the history
  • Loading branch information
mpartio committed Jan 17, 2024
1 parent 99f8578 commit 70916e9
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 3 deletions.
15 changes: 14 additions & 1 deletion doc/plugin-frost.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,17 @@ According to method provided by Juha Jantunen.

# Per-plugin configuration options

None
All options are optional.

ecmwf_geometry: define geometry for ecmwf data

"ecmwf_geometry" : "..."

ecmwfeps_geometry: define geometry for ecmwf eps data

"ecmwfeps_geometry" : "..."

meps_geometry: define geometry for meps data

"meps_geometry" : "..."

20 changes: 18 additions & 2 deletions himan-plugins/source/frost.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,16 @@ void frost::Calculate(shared_ptr<info<double>> myTargetInfo, unsigned short thre
ec_forecastTime.OriginDateTime().Adjust(kHourResolution, adjustment);

cnf->SourceProducers({producer(242, 86, 242, "ECM_PROB")});
cnf->SourceGeomNames({"ECGLO0200", "ECEUR0200"});

if (cnf->GetValue("ecmwfeps_geometry").empty() == false)
{
cnf->SourceGeomNames({cnf->GetValue("ecmwfeps_geometry")});
}
else
{
cnf->SourceGeomNames({"ECGLO0200", "ECEUR0200"});
}

shared_ptr<info<double>> T0ECInfo =
BackwardsFetchFromProducer(cnf, stat_type, ec_forecastTime, level(kHeight, 2), T0Param, -12);

Expand All @@ -212,7 +221,14 @@ void frost::Calculate(shared_ptr<info<double>> myTargetInfo, unsigned short thre
if (meps_forecastTime.Step().Hours() <= 66)
{
cnf->SourceProducers({producer(260, 86, 204, "MEPSMTA")});
cnf->SourceGeomNames({"MEPS2500D"});
if (cnf->GetValue("meps_geometry").empty() == false)
{
cnf->SourceGeomNames({cnf->GetValue("meps_geometry")});
}
else
{
cnf->SourceGeomNames({"MEPS2500D"});
}

T0MEPSInfo = BackwardsFetchFromProducer(cnf, stat_type, meps_forecastTime, level(kHeight, 2), T0Param, -3);
}
Expand Down

0 comments on commit 70916e9

Please sign in to comment.