Commit 08631989 authored by theos's avatar theos

Improved performance by inserting thitherto missing `copy` argument.

Made get_axes_local_distribution_strategy more robust.
parent ebaea3a7
......@@ -1034,7 +1034,8 @@ class _slicing_distributor(distributor):
if isinstance(data_update, distributed_data_object):
selected_update = data_update.get_data(
key=update_slice,
local_keys=True)
local_keys=True,
copy=copy)
local_data_update = selected_update.get_local_data(copy=False)
local_data_update = local_data_update.astype(self.dtype,
copy=False)
......@@ -1992,7 +1993,12 @@ class _slicing_distributor(distributor):
def get_axes_local_distribution_strategy(self, axes):
if 0 in axes:
return self.distribution_strategy
if self.distribution_strategy in STRATEGIES['local']:
raise ValueError(about_cstring(
"ERROR: axes_local_distribution_strategy is not uniquely "
"defined for local-type distribution strategies."))
else:
return self.distribution_strategy
else:
return 'not'
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment