Tweak algorithm parameters

This commit is contained in:
ConfusedPolarBear 2022-06-01 02:51:57 -05:00
parent a7469db2df
commit eb1b781768

View File

@ -23,12 +23,12 @@ public class FingerprinterTask : IScheduledTask
/// Maximum number of bits (out of 32 total) that can be different between segments before they are considered dissimilar. /// Maximum number of bits (out of 32 total) that can be different between segments before they are considered dissimilar.
/// 8 bits means the audio must be at least 75% similar (1 - 8 / 32). /// 8 bits means the audio must be at least 75% similar (1 - 8 / 32).
/// </summary> /// </summary>
private const double MaximumDifferences = 8; private const double MaximumDifferences = 6;
/// <summary> /// <summary>
/// Maximum time (in seconds) permitted between timestamps before they are considered non-contiguous. /// Maximum time (in seconds) permitted between timestamps before they are considered non-contiguous.
/// </summary> /// </summary>
private const double MaximumDistance = 2.5; private const double MaximumDistance = 3.5;
/// <summary> /// <summary>
/// Seconds of audio in one fingerprint point. This value is defined by the Chromaprint library and should not be changed. /// Seconds of audio in one fingerprint point. This value is defined by the Chromaprint library and should not be changed.
@ -457,7 +457,7 @@ public class FingerprinterTask : IScheduledTask
lContiguous.End -= 2 * MaximumDistance; lContiguous.End -= 2 * MaximumDistance;
rContiguous.End -= 2 * MaximumDistance; rContiguous.End -= 2 * MaximumDistance;
} }
else if (lContiguous.Duration >= 35) else if (lContiguous.Duration >= 30)
{ {
lContiguous.End -= MaximumDistance; lContiguous.End -= MaximumDistance;
rContiguous.End -= MaximumDistance; rContiguous.End -= MaximumDistance;