Skip to content

Commit

Permalink
Merge pull request #475 from QutEcoacoustics/Issue466-FixWritingOfVoi…
Browse files Browse the repository at this point in the history
…dList

Fix bug in EventFilters.cs
  • Loading branch information
atruskie authored Apr 9, 2021
2 parents e1a6784 + 9cda490 commit 17a6c1c
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/AudioAnalysisTools/Events/EventFilters.cs
Original file line number Diff line number Diff line change
Expand Up @@ -256,9 +256,6 @@ public static List<EventCommon> FilterEventsOnSyllableCountAndPeriodicity(List<E
}
}

string formatString = "{0:f2}";
Log.Debug($" Event[{count}] actual periods: {actualPeriodSeconds.JoinFormatted(", ", formatString)}");

// reject composite events whose total syllable count exceeds the user defined max.
if (syllableCount > maxSyllableCount)
{
Expand All @@ -276,6 +273,10 @@ public static List<EventCommon> FilterEventsOnSyllableCountAndPeriodicity(List<E
}
else
{
// There are two or more syllables/events.
string formatString = "{0:f2}";
Log.Debug($" Event[{count}] actual periods: {actualPeriodSeconds.JoinFormatted(", ", formatString)}");

// If there are only two events, with one interval, THEN ...
var actualAvPeriod = actualPeriodSeconds[0];

Expand Down

0 comments on commit 17a6c1c

Please sign in to comment.