---
title: "Migrate from Chromaprint, AcoustID, Dejavu, or audfprint to AudD"
description: "For teams that run open-source audio fingerprinting: when to stay on Chromaprint with AcoustID, Dejavu, or audfprint, how their concepts map to AudD, the code before and after for an AcoustID lookup and a Dejavu recognize call, MusicBrainz IDs with return=musicbrainz, your own recordings in a custom catalog, and long files and streams."
slug: "/resources/migrate/from-open-source-fingerprinting"
section: "migrate"
keywords: [audd, acoustid, chromaprint, fpcalc, pyacoustid, dejavu, audfprint, open source audio fingerprinting, musicbrainz, migration, custom catalog]
---

# Migrate from Chromaprint, AcoustID, Dejavu, or audfprint to AudD

If you use Chromaprint and AcoustID, Dejavu, or audfprint to identify music, you can use the AudD API instead. With these tools, you make the fingerprints on your side, and with Dejavu and audfprint you also keep the database. With AudD, you send us the audio file or its URL, and we send you the recognized song. Our server will download the file, make the fingerprint, and search for it in our DB of 160 million songs. If you want MusicBrainz data, ask for it in the `return` parameter, and the result will have the MusicBrainz recording IDs.

```python
from audd import AudD

audd = AudD("your-api-token")  # get your own token at dashboard.audd.io

result = audd.recognize("https://audd.tech/example.mp3", return_metadata=["musicbrainz"])
if result is None:
    print("no match")
else:
    print(result.artist, "-", result.title)
    for recording in result.musicbrainz or []:
        print("MusicBrainz recording:", recording.id)
```

> **Note.** The facts about the open-source tools are from their READMEs and the AcoustID website, as of November 24, 2026.

## When to stay on open source

The open-source tools are the better choice in some cases. Keep them if one of these is true for you:

- You want to recognize music offline, or on a network that isn't connected to the internet. Our API needs an internet connection. If you need it on your own servers, contact us: api@audd.io.
- All the songs you want to recognize are your own, and there aren't many of them.
- You don't want to pay for requests. With the open-source tools, you pay only for the servers.
- You want to change the algorithm, its parameters, and its index yourself.
- You want to tag full music files with MusicBrainz data, and your app is non-commercial. The AcoustID service is free for non-commercial apps, and it was made for this.

## What each tool does

### Chromaprint and AcoustID

Chromaprint is an audio fingerprint library developed for the AcoustID project. It's designed to identify near-identical audio, and it's made for full audio files, duplicate files, and long audio streams. You make a fingerprint with the `fpcalc` tool, which by default reads the first 120 seconds of the file. Then you send the fingerprint and the duration of the file to the AcoustID web service. The service returns the AcoustID track IDs, and the MusicBrainz recordings if you ask for them in the `meta` parameter. The database is crowd-sourced, and you can download it. Note that the service has been designed for identifying full audio files, not short audio snippets.

The AcoustID web service is free for non-commercial use only. If you want to use the service in a commercial application, you sign up for a plan with AcoustID OÜ at [acoustid.biz](https://acoustid.biz/). The free service has a rate limit: no more than 3 requests per second. If you expect significant traffic, they ask you to let them know in advance.

### Dejavu

Dejavu is written in Python. First, you create a MySQL or PostgreSQL database. Then you fingerprint the songs you want to recognize, and Dejavu adds them to the database. After that, you can recognize a file on disk, or a few seconds from the microphone, and Dejavu returns the matching song from the database.

### audfprint

audfprint is also written in Python. It's landmark-based audio fingerprinting: you build a database of fingerprints from your reference audio files with the `new` command, and you can add more songs to it later with `add`. To identify a noisy recording, you use `match`. It tells you which song it is and where in the song the recording starts.

## Concept map

| Open-source tool | AudD |
|---|---|
| `fpcalc`, `fingerprint_file` | Not needed: we make the fingerprint |
| AcoustID application API key (`client`) | `api_token` |
| `/v2/lookup` with `fingerprint` and `duration` | `recognize(source)` |
| `meta=recordingids` | `return_metadata=["musicbrainz"]` |
| MusicBrainz recording ID | `result.musicbrainz[i].id` |
| AcoustID track ID | No equivalent |
| Lookup `score` | Match score: an enterprise feature, on a Startup plan or higher, on request |
| No match in the lookup | `None` (`"result": null`) |
| Dejavu `fingerprint_directory`, audfprint `new` and `add` | Custom catalog upload, on request |
| Dejavu `song_name`, audfprint reference file name | Your own `audio_id` |
| Time in the reference track where the excerpt starts | `timecode` |
| MySQL, PostgreSQL, or `fpdbase.pklz` | Our DB of 160 million songs, and your custom catalog |
| Dejavu `MicrophoneRecognizer` | Your own recording code, or `audd listen` in the CLI |
| Your code for a long file or a stream | Enterprise endpoint, or streams |

## Replace an AcoustID lookup

### Before: pyacoustid

With pyacoustid, you don't have to call `fpcalc` and the web service yourself. Call the `match` function with your API key and the path to the file:

```python
import acoustid

for score, recording_id, title, artist in acoustid.match("your-acoustid-api-key", "song.mp3"):
    print(score, recording_id, title, artist)
```

### After: AudD with MusicBrainz data

With AudD, you send the file itself. Our server will make the fingerprint, so you don't need Chromaprint, `fpcalc`, or the duration of the file. To get the MusicBrainz data, add `musicbrainz` to `return_metadata`:

```python
from audd import AudD

audd = AudD("your-api-token")  # get your own token at dashboard.audd.io

result = audd.recognize("song.mp3", return_metadata=["musicbrainz"])
if result is None:
    print("no match")
else:
    for recording in result.musicbrainz or []:
        print(recording.id, recording.title, result.artist)
```

The result gets a `musicbrainz` field: an array of objects, which are the matching MusicBrainz recordings. A single recognized song can generate more than one MusicBrainz match. The recording MBID is the `id` field, as in the recordings of an AcoustID lookup.

### Read artist and release group IDs

Other MusicBrainz fields, like the artist credits and the releases, are in `model_extra`:

```python
from audd import AudD

audd = AudD("your-api-token")

result = audd.recognize("song.mp3", return_metadata=["musicbrainz"])
recordings = result.musicbrainz if result else None
for recording in recordings or []:
    extra = recording.model_extra or {}
    artists = [c.get("artist") or {} for c in extra.get("artist-credit") or []]
    groups = [r.get("release-group") or {} for r in extra.get("releases") or []]
    print(recording.id, recording.length)
    print("  artists:", [a.get("id") for a in artists])
    print("  release groups:", sorted({g["id"] for g in groups if g.get("id")}))
    print("  ISRCs:", extra.get("isrcs"))
```

There's no AcoustID track ID in our results. The match score is an enterprise feature, available on a Startup plan or higher. Let us know if you want access to it: send an email to api@audd.io.

### When `result` is None

If the server has successfully processed the request, but there are no matches, the `result` field is `null`, and the SDK returns `None`. If the server has successfully processed the request but MusicBrainz has no match for the recording, the `musicbrainz` block can be `null` or absent, even if you asked for it.

### When the file is a full track

Our standard endpoint is for a short clip: it analyzes up to the first 12 seconds of audio, and it accepts uploaded files up to 10 MB. One minute of CD-quality WAV is already about 10 MB. If you upload a larger file, you'll get error #400 (`AudDInvalidAudioError` in the SDK). Send a 12-second clip instead, cut from the part of the track you want, for example from 0:30:

```python
import subprocess

from audd import AudD

audd = AudD("your-api-token")

clip = subprocess.run(
    ["ffmpeg", "-v", "error", "-ss", "30", "-t", "12", "-i", "song.flac", "-f", "mp3", "-"],
    capture_output=True, check=True,
).stdout
result = audd.recognize(clip, return_metadata=["musicbrainz"])
```

## Replace a Dejavu recognize call

### Before: Dejavu

Here's how you do it with Dejavu, from its README (we filled in the placeholders and added the comments):

```python
from dejavu import Dejavu
from dejavu.logic.recognizer.file_recognizer import FileRecognizer

config = {
    "database": {
        "host": "127.0.0.1",
        "user": "root",
        "password": "your-db-password",
        "database": "dejavu",
    },
}
djv = Dejavu(config)

# Once: fingerprint the reference files into the database
djv.fingerprint_directory("va_us_top_40/mp3", [".mp3"], 3)

# Then: recognize a file against them
song = djv.recognize(FileRecognizer, "va_us_top_40/wav/Mirrors - Justin Timberlake.wav")
```

### After: commercial releases

The README fingerprints the July 2013 US Top 40. If your reference files are commercial releases like these, you can skip the fingerprinting step and the database, and match against our DB instead:

```python
from audd import AudD

audd = AudD("your-api-token")  # get your own token at dashboard.audd.io

song = audd.recognize("clip.wav")
if song is None:
    print("no match")
else:
    print(song.artist, "-", song.title, "at", song.timecode)
```

`timecode` is the time in the recognized song when the fragment you sent is played.

### After: your own recordings in a custom catalog

If you want to recognize music among your own recordings, upload them to a custom catalog. To get access to the upload endpoint, contact the AudD representative that you work with, or email api@audd.io. Access to this endpoint isn't available by default. The songs you upload will be available for recognition only to you.

> **Note.** By uploading any audio files, you confirm that you have the rights to do so and to give us the rights to process these files, to store the files for up to 72 hours, to make digital "fingerprints" from the files and to store and process those fingerprints for an unrestricted period of time.

Send an integer ID of the song in the `audio_id` parameter. You will get the ID you set with the recognition results. We strongly recommend storing any metadata on your side and sending us integer IDs linked to the metadata:

```python
import json
from pathlib import Path

from audd import AudD

audd = AudD("your-api-token")

catalog = {}
for audio_id, path in enumerate(sorted(Path("my_recordings").glob("*.mp3")), start=1):
    audd.custom_catalog.add(audio_id=audio_id, source=path)
    catalog[audio_id] = path.name
    Path("catalog.json").write_text(json.dumps(catalog, indent=2))
```

Please don't retry failed uploads automatically: check the error first, and then send the file again. The SDK doesn't retry uploads.

If the recognized song is one of yours, you'll get the `audio_id` you set. We check both your songs and our DB, so look at the `audio_id` first:

```python
import json
from pathlib import Path

from audd import AudD

audd = AudD("your-api-token")
catalog = json.loads(Path("catalog.json").read_text())

song = audd.recognize("clip.wav")
if song is None:
    print("no match")
elif song.audio_id is not None:
    print("your recording:", catalog.get(str(song.audio_id)), "at", song.timecode)
else:
    print("public release:", song.artist, "-", song.title)
```

For how the two databases work together, see "[Public database vs your custom catalog](/resources/concepts/custom-vs-public-db)."

### From a microphone

Dejavu's `MicrophoneRecognizer` records from the microphone for you. The SDK doesn't record audio: record a few seconds with your own code, and send the bytes to `recognize()`. To identify the song playing near your computer from a terminal, run `audd listen` in the AudD CLI.

## Long files and streams

We have a separate endpoint that handles large files: on the free trial, you can upload files to it, and to send it a URL, you need a paid plan. When you upload a file, our servers consider it to be a group of 12-second-long audio chunks, and we count it as 1 request per 12 seconds of audio. Set `limit` to cap the number of chunks that we recognize:

```python
from audd import AudD

audd = AudD("your-api-token")

matches = audd.recognize_enterprise("https://audd.tech/example.mp3", limit=10)
for m in matches:
    print(m.start_seconds, m.end_seconds, m.artist, "-", m.title)
```

The positions of the match in your file are in `start_seconds` and `end_seconds`. By default, the enterprise endpoint doesn't return the MusicBrainz block. If you need it with the enterprise results, contact us: api@audd.io.

See "[Controlling enterprise endpoint cost](/resources/concepts/enterprise-cost-control)" for more info on `limit`, `skip`, and `every`.

For a live stream, the open-source tools give you the matching, and reading the stream is your code. With AudD, you send us the URL of the stream, and we send you the recognition results in callbacks. We support most of the stream formats, including DASH, Icecast, HLS, and m3u/m3u8, and Twitch and YouTube live streams:

```python
from audd import AudD

audd = AudD("your-api-token")

audd.streams.set_callback_url("https://yourapp.example/audd-callback")
audd.streams.add(url="https://npr-ice.streamguys1.com/live.mp3", radio_id=1)
```

If something happens to a stream, we'll let you know by sending a notification so you can fix the stream or change its URL. If you don't have a server, you can get the results with longpoll. Please set the callback URL even if you want to use longpoll only (`https://audd.tech/empty/` if you don't have one): longpoll might never return any events if no callback URL is configured.

See "[Webhook callbacks vs longpoll for stream results](/resources/concepts/callback-vs-longpoll)" for more info.

## What you give up

- You'll need an internet connection: all the requests are sent to our servers.
- You pay for the requests, not for the servers. The plans and prices are at [audd.io/pricing](https://audd.io/pricing/).
- There are no parameters to tune, like Dejavu's `config/settings.py` or audfprint's `--density`: we do the fingerprinting and the search on our side.
- You won't get the AcoustID track IDs.
- You can download the AcoustID database; with AudD, you use our DB through the API.

## Run both while you switch

1. Get a token from the API Dashboard at [dashboard.audd.io](https://dashboard.audd.io). New accounts get 300 free requests, where available.
2. Send the same files to your current lookup and to AudD, and compare the results. For how to test on your own audio, see "[Testing your integration](/resources/concepts/testing-your-integration)."
3. If you have your own recordings, ask us for custom catalog access and upload them.
4. When the results look right on your own audio, switch the lookup over.

---

**Related**

- [Music recognition API vs building your own](/resources/articles/music-recognition-api-vs-building-your-own)
- [Public database vs your custom catalog](/resources/concepts/custom-vs-public-db)
- [MusicBrainz metadata block](/resources/reference/musicbrainz)
- [Standard, enterprise, or streams: how to choose](/resources/concepts/standard-vs-enterprise-vs-streams)
- [Run a one-week pilot on your own audio](/resources/articles/evaluate-music-recognition-on-your-audio)
- [Upload endpoint docs](https://docs.audd.io/upload_audio_endpoint)

## Sitemap

See the [resources sitemap](https://audd.io/resources/sitemap.md) for every guide and the [glossary](https://audd.io/resources/reference/glossary.md) for AudD terms.
