Skip to content

Commit

Permalink
ATLAS-353 MIR-467 much nicer
Browse files Browse the repository at this point in the history
  • Loading branch information
pmaciel committed Mar 14, 2022
1 parent 5a009e3 commit 350f4cc
Showing 1 changed file with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -195,9 +195,10 @@ void StructuredInterpolation2D<Kernel>::setup( const FunctionSpace& source ) {
auto inp_npts_owned = src_fs.sizeOwned();

for (auto& t : triplets) {
ATLAS_ASSERT(t.col() < inp_npts && gidx_src(t.col()) >= 1);
t = {t.row(), eckit::linalg::Size(gidx_src(t.col()) - 1), t.value()};
ATLAS_ASSERT(t.col() < inp_npts_owned);
auto& col = t.col();
ATLAS_ASSERT(col < inp_npts && gidx_src(col) >= 1);
col = gidx_src(col) - 1;
ATLAS_ASSERT(col < inp_npts_owned);
}

inp_npts = inp_npts_owned;
Expand Down

0 comments on commit 350f4cc

Please sign in to comment.