Skip to content

Commit 806ef25

Browse files
committed
fixed bug in interpolation procedure (spherical vector)
1 parent b283cbd commit 806ef25

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/atlas/interpolation/method/sphericalvector/SphericalVector.cc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -150,14 +150,14 @@ void SphericalVector::do_execute(const Field& sourceField, Field& targetField,
150150
ATLAS_TRACE("atlas::interpolation::method::SphericalVector::do_execute()");
151151

152152
if (targetField.size() == 0) {
153+
haloExchange(sourceField);
153154
return;
154155
}
155156

156157
const auto fieldType = sourceField.metadata().getString("type", "");
157158
if (fieldType != "vector") {
158159
auto metadata = Metadata();
159160
Method::do_execute(sourceField, targetField, metadata);
160-
161161
return;
162162
}
163163

@@ -194,14 +194,14 @@ void SphericalVector::do_execute_adjoint(Field& sourceField,
194194
"atlas::interpolation::method::SphericalVector::do_execute_adjoint()");
195195

196196
if (targetField.size() == 0) {
197+
adjointHaloExchange(sourceField);
197198
return;
198199
}
199200

200201
const auto fieldType = sourceField.metadata().getString("type", "");
201202
if (fieldType != "vector") {
202203
auto metadata = Metadata();
203204
Method::do_execute_adjoint(sourceField, targetField, metadata);
204-
205205
return;
206206
}
207207

0 commit comments

Comments
 (0)