From f8444c5588755b4a8483ec873148f9a3bcf311e7 Mon Sep 17 00:00:00 2001 From: Stephane Chavin <stephane.chavin@lis-lab.fr> Date: Fri, 31 Jan 2025 14:01:18 +0100 Subject: [PATCH] Update file get_train_annot.py --- get_train_annot.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/get_train_annot.py b/get_train_annot.py index a4ea16e..6d680fe 100755 --- a/get_train_annot.py +++ b/get_train_annot.py @@ -34,13 +34,12 @@ def main(entry, arguments, species_list): # Create the list of all possible offset to compute spectrogram offset_list = np.arange( 0, file_duration, arguments.duration - arguments.overlap) - grp = utils.split_annotations( - grp, arguments.duration) + grp = utils.split_annotations(grp, arguments.duration) grp = grp.reset_index(drop=True) while len(grp) != 0: # collect all the data between the offset and duration-overlap if len(offset_list) >= 1: - table = grp[grp.start <= offset_list[0] + arguments.duration] + table = grp[grp.start < offset_list[0] + arguments.duration] else: continue -- GitLab