diff --git a/src/Acoustics.Shared/Extensions/EnumerableExtensions.cs b/src/Acoustics.Shared/Extensions/EnumerableExtensions.cs index 1507036a1..34e9be436 100644 --- a/src/Acoustics.Shared/Extensions/EnumerableExtensions.cs +++ b/src/Acoustics.Shared/Extensions/EnumerableExtensions.cs @@ -316,5 +316,19 @@ public static string Join(this IEnumerable items, string delimiter = " ") // return one delimiter length less because we always add a delimiter on the end return result.ToString(0, result.Length - delimiter.Length); } + + public static string JoinFormatted(this IEnumerable items, string delimiter = " ") + { + var result = new StringBuilder(); + foreach (var item in items) + { + string number = string.Format("{0:f2}", item); + result.Append(number); + result.Append(delimiter); + } + + // return one delimiter length less because we always add a delimiter on the end + return result.ToString(0, result.Length - delimiter.Length); + } } } \ No newline at end of file diff --git a/src/AnalysisConfigFiles/RecognizerConfigFiles/Towsey.NinoxBoobook.yml b/src/AnalysisConfigFiles/RecognizerConfigFiles/Towsey.NinoxBoobook.yml index 3e6f1c5cb..c377882cf 100644 --- a/src/AnalysisConfigFiles/RecognizerConfigFiles/Towsey.NinoxBoobook.yml +++ b/src/AnalysisConfigFiles/RecognizerConfigFiles/Towsey.NinoxBoobook.yml @@ -62,10 +62,10 @@ PostProcessing: # 5: Filter the events for excess activity in their sidebands, i.e. upper and lower buffer zones #SidebandAcousticActivity: - LowerSidebandWidth: 150 - UpperSidebandWidth: 400 - MaxBackgroundDecibels: 12 - MaxActivityDecibels: 12 + # LowerSidebandWidth: 150 + # UpperSidebandWidth: 400 + # MaxBackgroundDecibels: 12 + # MaxActivityDecibels: 12 # Options to save results files # 1: Available options for saving spectrograms (case-sensitive): [False/Never | True/Always | WhenEventsDetected] diff --git a/src/AnalysisPrograms/Recognizers/GenericRecognizer.cs b/src/AnalysisPrograms/Recognizers/GenericRecognizer.cs index bf8bf038c..e72662879 100644 --- a/src/AnalysisPrograms/Recognizers/GenericRecognizer.cs +++ b/src/AnalysisPrograms/Recognizers/GenericRecognizer.cs @@ -159,10 +159,10 @@ public override RecognizerResults Recognize( // Running profiles with multiple dB thresholds produces nested (Russian doll) events. // Remove all but the outermost event. - Log.Debug($"\nFLATTEN RUSSIAN DOLL EVENTS."); - Log.Debug($"## Event count BEFORE removing enclosed events = {postEvents.Count}."); + Log.Debug($"\nREMOVE EVENTS ENCLOSED BY LONGER EVENTS."); + Log.Debug($"Event count BEFORE removing enclosed events = {postEvents.Count}."); results.NewEvents = CompositeEvent.RemoveEnclosedEvents(postEvents); - Log.Debug($"## Event count AFTER removing enclosed events = {postEvents.Count}."); + Log.Debug($"Event count AFTER removing enclosed events = {postEvents.Count}."); // Write out the events to log. if (postEvents.Count > 0) diff --git a/src/AudioAnalysisTools/Events/EventFilters.cs b/src/AudioAnalysisTools/Events/EventFilters.cs index 9befc3b02..86be9e2cc 100644 --- a/src/AudioAnalysisTools/Events/EventFilters.cs +++ b/src/AudioAnalysisTools/Events/EventFilters.cs @@ -234,7 +234,7 @@ public static List FilterEventsOnSyllableCountAndPeriodicity(List FilterEventsOnSyllableCountAndPeriodicity(List maxSyllableCount) { - Log.Debug($" Event{count} rejected: Actual syllable count > max: {syllableCount} > {maxSyllableCount}"); + Log.Debug($" Event[{count}] rejected: Actual syllable count > max: {syllableCount} > {maxSyllableCount}"); continue; } @@ -275,7 +271,7 @@ public static List FilterEventsOnSyllableCountAndPeriodicity(List FilterEventsOnSyllableCountAndPeriodicity(List= minExpectedPeriod && actualAvPeriod <= maxExpectedPeriod) { - Log.Debug($" Event{count} accepted: Actual average syllable interval = {actualAvPeriod:F3}"); + Log.Debug($" Event[{count}] accepted: Actual average syllable interval = {actualAvPeriod:F3}"); filteredEvents.Add(ev); } else { - Log.Debug($" Event{count} rejected: Actual average syllable interval = {actualAvPeriod:F3}"); + Log.Debug($" Event[{count}] rejected: Actual average syllable interval = {actualAvPeriod:F3}"); } } }