Class AnalyzerConfig
Any analysis that works with the Analyze Long Recordings command will use this class as a base.
SegmentDuration & SegmentOverlap
The default values are 60 and 0 seconds respectively and these seldom need to be changed. You may wish to work at finer resolution by reducing SegmentDuration to 20 or 30 seconds.
If your target call is comparatively long (such as a koala bellow, e.g. greater than 10 - 15 seconds), you could increase SegmentOverlap to 10 seconds. This actually increases the segment duration to 70 seconds (60+10) so reducing the probability that a call will be split across segments. It also maintains a 60-second interval between segment-starts, which helps to identify where you are in a recording.
Audio resampling
Specifies the sample rate at which the recording will be processed.
ResampleRate: 22050
If this parameter is not specified in the config file, the default is to resample each recording segment (up or down) to 22050 samples per second. This has the effect of limiting the maximum frequency (the Nyquist) to 11025 Hertz. ResampleRate must be twice the desired Nyquist. Specify the resample rate that gives the best result for your target call. If the target call is in a low frequency band (e.g. < 2kHz), then lower the resample rate to somewhat more than twice the maximum frequency of interest. This will reduce processing time and produce better focused spectrograms. If you down-sample, you will lose high frequency content. If you up-sample, there will be undefined "noise" in spectrograms above the original Nyquist.
Saving results
Each of the parameters controls whether extra diagnostic files are saved while doing an analysis.
Important
If you are doing a lot of analysis you'll want to disable this extra diagnostic output. It will produce files that are in total larger than the input audio data—you'll fill your harddrive quick.
SaveSonogramImages
will save a spectrogram for analysis segments (typically one-minute)SaveIntermediateWavFiles
will save the converted WAVE file used to analyze each segment
Both parameters accept three values:
Never
: disables the output.WhenEventsDetected
: only outputs the spectrogram/WAVE file when an event is found in the current segment. This choice is the most useful for debugging a new recognizer.Always
: always save the diagnostic files. Don't use this option if you're going to analyze a lot of files
Inheritance
Implements
Inherited Members
Namespace: AnalysisBase
Assembly: AnalysisBase.dll
Syntax
public class AnalyzerConfig : Config, IConfig
Fields
| Improve this Doc View SourceEventThresholdDefault
Declaration
public const double EventThresholdDefault = 0.2
Field Value
Type | Description |
---|---|
Double |
Properties
| Improve this Doc View SourceAnalysisName
Declaration
[Obsolete("The AnalysisName property is no longer used")]
public string AnalysisName { get; set; }
Property Value
Type | Description |
---|---|
String |
EventThreshold
Declaration
public virtual double EventThreshold { get; set; }
Property Value
Type | Description |
---|---|
Double |
RequireDateInFilename
Gets or sets a value indicating whether a file must have a date in the file name.
Declaration
public bool RequireDateInFilename { get; set; }
Property Value
Type | Description |
---|---|
Boolean |
Remarks
If true, an unambiguous date-time must be provided in the source file's name. If true, an exception will be thrown if no such date is found. If false, and a valid date is still found in file name, it will still be parsed. Supports formats like: prefix_20140101T235959+1000.wav, where +1000 is in this case the time-zone offset for Brisbane. prefix_20140101T235959+Z.wav, where +Z is the zero time-zone offset. prefix_20140101-235959+1000.wav prefix_20140101-235959+Z.wav For more info on dates, see "dates.md" at https://github.com/QutEcoacoustics/audio-analysis/tree/master/docs.
ResampleRate
Gets or sets the default sample rate to re-encode all input audio as.
Declaration
public int? ResampleRate { get; set; }
Property Value
Type | Description |
---|---|
Nullable<Int32> | The resample rate measured in samples. |
Remarks
ResampleRate must be 2× the desired Nyquist.
Default value = 22050.
Once upon a time we used 17640.
Units=samples.
Users of this value should always fallback to a default appropriate for the analysis. Currently that default must be non-null, but we're considering allowing it to be null to support variable sample rate analysis.
SaveIntermediateCsvFiles
Declaration
public bool SaveIntermediateCsvFiles { get; set; }
Property Value
Type | Description |
---|---|
Boolean |
SaveIntermediateWavFiles
Declaration
public SaveBehavior SaveIntermediateWavFiles { get; set; }
Property Value
Type | Description |
---|---|
SaveBehavior |
SaveSonogramImages
Declaration
public SaveBehavior SaveSonogramImages { get; set; }
Property Value
Type | Description |
---|---|
SaveBehavior |
SegmentDuration
Gets or sets the length of audio block to process.
Declaration
public double? SegmentDuration { get; set; }
Property Value
Type | Description |
---|---|
Nullable<Double> |
SegmentOverlap
Gets or sets the amount that each audio block should overlap.
Declaration
public double? SegmentOverlap { get; set; }
Property Value
Type | Description |
---|---|
Nullable<Double> |