for some shots, no valid_indices are found in the _get_end_of_shot class method:
|
valid_indices = np.where((polarized_signal >= threshold) & (signal_time > 0.0)) |
|
duration = signal_time[np.max(valid_indices)] |
and thus we fail with:
ValueError: zero-size array to reduction operation maximum which has no identity
a couple of examples:
# on DIII-D
poetry run disruption-py 173927
# on EAST
poetry run disruption-py 59684
since this happens when setting up the timebase, such an exception is handled as critical and any further computation is impossible.
is there any fix? do these shots really deserve to be discarded?
otherwise we might just add a check on valid_indices and raise a user-friendlier exception.
for some shots, no
valid_indicesare found in the_get_end_of_shotclass method:disruption-py/disruption_py/settings/time_setting.py
Lines 462 to 463 in e414215
and thus we fail with:
a couple of examples:
since this happens when setting up the timebase, such an exception is handled as critical and any further computation is impossible.
is there any fix? do these shots really deserve to be discarded?
otherwise we might just add a check on
valid_indicesand raise a user-friendlier exception.