Closed drodarie closed 1 month ago
Currently the origin parameter of CylindricalTargetting is a list[float]. However, its get_targets function use it as a numpy array (line 200):
origin
CylindricalTargetting
get_targets
[...] simdata.placement[model].load_positions()[:, axes] - self.origin**2, # <- exponential operation does not work here. [...]
I suggest to change origin type to a numpy array.
origin: np.ndarray[float] = config.attr(type=types.ndarray(dtype=float))
Also the filtering of the cells is not performed correctly: the axis to sum the distances should be 1 instead of 0 line 198:
np.sum( simdata.placement[model].load_positions()[:, axes] - self.origin**2, axis=1, )
Currently the
origin
parameter ofCylindricalTargetting
is a list[float]. However, itsget_targets
function use it as a numpy array (line 200):I suggest to change
origin
type to a numpy array.Also the filtering of the cells is not performed correctly: the axis to sum the distances should be 1 instead of 0 line 198: