Skip to content

Commit

Permalink
Consistency with SphericalVector: rename 'ancillary_scheme' to 'scheme'
Browse files Browse the repository at this point in the history
  • Loading branch information
wdeconinck committed Jun 10, 2024
1 parent c0b8577 commit d766d88
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
9 changes: 5 additions & 4 deletions src/atlas/interpolation/method/binning/Binning.cc
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,11 @@ MethodBuilder<Binning> __builder("binning");


Binning::Binning(const Config& config) : Method(config) {
const auto* ptr_config = dynamic_cast<const eckit::LocalConfiguration*>(&config);
interpAncillaryScheme_ = ptr_config->getSubConfiguration("ancillary_scheme");
halo_exchange_ = ptr_config->getBool("halo_exchange", true);
adjoint_ = ptr_config->getBool("adjoint", false);
const auto* conf = dynamic_cast<const eckit::LocalConfiguration*>(&config);
ATLAS_ASSERT(conf, "config must be derived from eckit::LocalConfiguration");
interpAncillaryScheme_ = conf->getSubConfiguration("scheme");
adjoint_ = conf->getBool("adjoint", false);
halo_exchange_ = conf->getBool("halo_exchange", true);
}


Expand Down
6 changes: 3 additions & 3 deletions src/tests/interpolation/test_interpolation_binning.cc
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ CASE("rigridding from high to low resolution; grid type: CS-LFR") {


const auto scheme = util::Config("type", "binning") |
util::Config("ancillary_scheme", option::type("cubedsphere-bilinear"));
util::Config("scheme", option::type("cubedsphere-bilinear"));

Interpolation regrid_high2low(scheme, csfs_s, csfs_t);

Expand Down Expand Up @@ -179,7 +179,7 @@ CASE("rigridding from high to low resolution; grid type: O") {


const auto scheme = util::Config("type", "binning") |
util::Config("ancillary_scheme", option::type("structured-bilinear"));
util::Config("scheme", option::type("structured-bilinear"));

Interpolation regrid_high2low(scheme, ncfs_s, ncfs_t);

Expand Down Expand Up @@ -232,7 +232,7 @@ CASE("dot-product test for the rigridding from high to low resolution; grid type
fs_t.add(field_01_t);

const auto scheme = util::Config("type", "binning") |
util::Config("ancillary_scheme", option::type("cubedsphere-bilinear")) |
util::Config("scheme", option::type("cubedsphere-bilinear")) |
util::Config("adjoint", true);

Interpolation regrid_high2low(scheme, csfs_s, csfs_t);
Expand Down

0 comments on commit d766d88

Please sign in to comment.