[optimizer] one copy for the optimizer in optimizer_array, use this instead of _set|get_params_transformed

This commit is contained in:
mzwiessele 2014-05-22 11:39:04 +01:00
parent 43ee8ce614
commit 5a2bc4863b
7 changed files with 158 additions and 79 deletions

View file

@ -39,7 +39,7 @@ class ObsAr(np.ndarray, Pickleable, Observable):
s = self.__new__(self.__class__, input_array=self.view(np.ndarray).copy())
memo[id(self)] = s
import copy
s.__dict__.update(copy.deepcopy(self.__dict__, memo))
Pickleable.__setstate__(s, copy.deepcopy(self.__getstate__(), memo))
return s
def __reduce__(self):