protyposis / Aurio

Audio Fingerprinting & Retrieval for .NET
GNU Affero General Public License v3.0
128 stars 28 forks source link

Matching and fingerprinting #10

Closed Johndirr closed 5 years ago

Johndirr commented 5 years ago
protyposis commented 5 years ago

Hi,

As I understand every match you find is only the size of a fingerprint (or the sum of subfingerprints) and therefore only some seconds long (or shorter?). What happens if you try to find matches for a very short snippet, e.g. two seconds of a whole track?

Yes every match is "only" the size of a fingerprint. A snippet must be at least as long as a fingerprint to find a match. The longer the snippet is, the more potential matches are possible, and the higher the chance to find a match.

Is there a method that directly returns the timestamp for a fully matching audio sample inside a whole track?

There is no "fully matching audio sample", but each match will tell you its position within the two matched tracks and you can calculate from that data where the sample is positioned within the reference track. To check if a sample is "fully matching", e.g. it's not missing pieces or containing unexpected pieces, you need to analyze multiple matches along the sample and check if the offsets between the tracks stay constant.

And can I define a part of a track that shall be matched with another one?

You can use the CropStream to define a start and end point and pass that into the fingerprinter.