diff --git a/pyop2/types/dat.py b/pyop2/types/dat.py index ce263575bf..3c5220d2af 100644 --- a/pyop2/types/dat.py +++ b/pyop2/types/dat.py @@ -797,10 +797,10 @@ def vec_context(self, access): :param access: Access descriptor: READ, WRITE, or RW.""" size = self.dataset.size if self.dataset._apply_local_global_filter and access is not Access.WRITE: - self._data_filtered[:] = self._data[:size][self._data_filter] + self._data_filtered[:] = self._data[:size][self._data_filter] yield self._vec if self.dataset._apply_local_global_filter and access is not Access.READ: - self._data[:size][self._data_filter] = self._data_filtered[:] + self._data[:size][self._data_filter] = self._data_filtered[:] if access is not Access.READ: self.halo_valid = False