Compute min_interval based on unique values
@@ -56,10 +56,9 @@ class Convolve(Transformation):
# Minimum interval between event onsets/duration
# Used to compute oversampling factor to prevent information loss
- min_interval = min(np.ediff1d(np.sort(df.onset)).min(),
+ min_interval = min(np.ediff1d(np.unique(np.sort(df.onset))).min(),
df.duration.min())
oversampling = np.ceil(1 / (min_interval * sampling_rate))
-
convolved = hrf.compute_regressor(
vals, model, resample_frames, fir_delays=fir_delays, min_onset=0,
oversampling=oversampling
