Skip to content

Commit 3fbb7a2

Browse files
committed
Set default elevation gradient to 0 in -c oi
1 parent 6b22f26 commit 3fbb7a2

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/Calibrator/Oi.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ CalibratorOi::CalibratorOi(Variable iVariable, const Options& iOptions):
1515
mMinRho(0.0013),
1616
mEpsilon(0.5),
1717
mEpsilonC(0.5),
18-
mElevGradient(-0.0065),
18+
mElevGradient(-999),
1919
mBiasVariable(""),
2020
mSigma(1),
2121
mSigmaC(1),
@@ -355,7 +355,7 @@ bool CalibratorOi::calibrateCore(File& iFile, const ParameterFile* iParameterFil
355355
for(int i = 0; i < gS; i++) {
356356
gY[i].resize(nEns, 0);
357357
float elevCorr = 0;
358-
if(Util::isValid(mElevGradient)) {
358+
if(Util::isValid(mElevGradient) && mElevGradient != 0) {
359359
float nnElev = elevs[gYi[i]][gXi[i]];
360360
assert(Util::isValid(nnElev));
361361
assert(Util::isValid(gLocations[i].elev()));
@@ -1064,8 +1064,8 @@ std::string CalibratorOi::description(bool full) {
10641064
ss << Util::formatDescription(" extrapolate=0","Allow OI to extrapolate increments. If 0, then increments are bounded by the increments at the observation sites.") << std::endl;
10651065
ss << Util::formatDescription(" minRho=0.0013","Perform localization by requiring this minimum rho value") << std::endl;
10661066
ss << Util::formatDescription(" maxBytes=6442450944","Don't allocate more than this many bytes when creating the localization information") << std::endl;
1067-
ss << Util::formatDescription(" minEns=5","Switch to single-member mode if fewer than this number of members") << std::endl;
1068-
ss << Util::formatDescription(" elevGradient=-0.0065","Use this elevation gradient to downscale background to obs") << std::endl;
1067+
ss << Util::formatDescription(" minEns=5","Switch to single-member mode if fewer than this number of members available") << std::endl;
1068+
ss << Util::formatDescription(" elevGradient=0","Elevation gradient when downscaling background to obs. Use -0.0065 for temperature.") << std::endl;
10691069
ss << Util::formatDescription(" useEns=1","Enable ensemble-mode. If 0, use single-member mode.") << std::endl;
10701070
ss << Util::formatDescription(" wmin=0.5","") << std::endl;
10711071
ss << Util::formatDescription(" epsilon=0.5","") << std::endl;

0 commit comments

Comments
 (0)