# Trying to use chroma plugin but keep getting the same error

**URL:** https://discourse.beets.io/t/trying-to-use-chroma-plugin-but-keep-getting-the-same-error/1419
**Category:** Help
**Created:** [July 20, 2020, 7:29pm UTC](https://discourse.beets.io/t/trying-to-use-chroma-plugin-but-keep-getting-the-same-error/1419 "2020-07-20T19:29:40Z")
**Posts on this page:** 12
**Page:** 1

<div class="post-metadata">

### Author: ![HisMessengerDAB](https://avatars.discourse-cdn.com/v4/letter/h/48db29/32.png) [@HisMessengerDAB](https://discourse.beets.io/u/HisMessengerDAB)
#### Post date: [July 20, 2020, 7:29pm UTC](https://discourse.beets.io/t/trying-to-use-chroma-plugin-but-keep-getting-the-same-error/1419/1 "2020-07-20T19:29:40Z")

</div>

I was suggested to come over here from github. I followed the instructions to install the latest snapshot of beets but still have an error when using the `chroma` plugin. Here is my `config.yaml` file; maybe you can see an error that my untrained eyes do not. I also had to comment out the `smartplaylist` and `emebdart` plugins because they were working incorrectly.

```auto
directory: D:/medialibrary/music
library: ~/data/musiclibrary.db
Import:
        copy: no
        move: yes
        log: beetslog.txt
        bell: yes
art_filename: albumart

plugins: 
    - bpd 
    - chroma 
    - fromfilename 
    - acousticbrainz 
    - fetchart
    # - emebdart
    - lastgenre
    - lyrics
    - mbsync
    - the
    - duplicates
    - mbcollection
    - mbsubmit 
    - fuzzy
    - missing
    - spotify
    - web
    - popularity
    # - smartplaylist 
    # - barcode

pluginpath: ~/beets/myplugins

#Plugins list
chroma:
    auto: true
acoustid:
    apikey: <key>
fetchart:
    cautious: true
    cover_names: 
        - cover 
        - front 
        - art 
        - album 
        - folder
    enforce_ratio: 0.5%
lyrics:
    google_API_key: <key>
    sources: musixmatch google
bpd:
    host: 127.0.0.1
    port: 6600
    password: <password>
    volume: 100
musicbrainz:
    user: <username>
    pass: <password>
# smartplaylist:
# relative_to: D:/medialibrary/music
# playlist_dir: D:/medialibrary/music/Playlists
# forward_slash: yes
# playlists:
# - name: all.m3u
# query: ''
# - name: beatles.m3u
# query: 'artist:Beatles'
# - name: popular.m3u
# query: 'popularity:70..'
# - name: popular_rock.m3u
# query: 'popularity:60.. genre:Rock'
# - name: 'Chronological Beatles'
# query: 'artist:Beatles year+'
# match:
# distance_weights:
# barcode: 1.0

ui:
    color: yes
    colors:
        text_success: green
        text_warning: yellow
        text_error: red
        text_highlight: red
        text_highlight_minor: lightgray
        action_default: turquoise
        action: blue

paths:
    default: $genre/$albumartist/$album/$track $title
    singleton: Singletons/$artist - $title
    comp: $genre/$album/$track $title
    albumtype:soundtrack: Soundtracks/$album/$track $title

```

I’m just curious if I just need to place fpcalc at a different folder so that it _can_ be found. I followed the instructions to make sure the path leads to where the `fpcalc.exe` is found as well.

Here’s the error that I get when I run the program

```auto
PS C:\Users\[USER]> beet import F:\Music
Import of the directory:
F:\Music
was interrupted. Resume (Y/n)? y
Resuming interrupted import of F:\Music
chroma: fingerprinting of b'F:\\Music\\01 Marvins Room.m4a' failed: fpcalc not found
chroma: fingerprinting of b'F:\\Music\\01 Summer Nights.mp3' failed: fpcalc not found
chroma: fingerprinting of b"F:\\Music\\02 I'm Coming Home In A Flash (Avicii's Ultra Bootleg).mp3" failed: fpcalc not found
<so on and so forth with songs until I hit Ctrl-C>

```

Otherwise, the program seems to work ok when I comment out the `chroma` plugin and its options.

---

<div class="post-metadata">

### Author: ![adrian](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.beets.io/adrian/32/4_2.png) [@adrian](https://discourse.beets.io/u/adrian)
#### Post date: [July 21, 2020, 12:31am UTC](https://discourse.beets.io/t/trying-to-use-chroma-plugin-but-keep-getting-the-same-error/1419/2 "2020-07-21T00:31:28Z")

</div>

Yo! Can you explain a little more about what you’ve tried so far? Where did you put `fpcalc`? Can you invoke it already by typing `fpcalc` at the command line? That’s what you need to do—make sure it’s in a location that’s on your [`%PATH%`](https://superuser.com/questions/284342/what-are-path-and-other-environment-variables-and-how-can-i-set-or-use-them).

---

<div class="post-metadata">

### Author: ![HisMessengerDAB](https://avatars.discourse-cdn.com/v4/letter/h/48db29/32.png) [@HisMessengerDAB](https://discourse.beets.io/u/HisMessengerDAB)
#### Post date: [July 21, 2020, 3:01am UTC](https://discourse.beets.io/t/trying-to-use-chroma-plugin-but-keep-getting-the-same-error/1419/3 "2020-07-21T03:01:15Z")

</div>

Hey there,

I’ll do my best to write down everything I tried.  
I started with Python 3.8.4. Following the instructions on [this page](https://beets.readthedocs.io/en/stable/plugins/chroma.html), I attempted to install Chromaprint as a dynamic library but couldn’t figure out how so I ended up downloading the binary package `fpcalc.exe` and placing it both in my `C:\Program Files\chromaprint-fpcalc-1.5.0-windows-x86_64` and `C:\Users\<user>\AppData\Roaming\beets` while making sure to add both of these folders to my shell search path (or at least I think that’s what I did based on [these instructions](https://www.howtogeek.com/118594/how-to-edit-your-system-path-for-easy-command-line-access/)). Then I made sure that the `chroma` plugin was active by trying to follow the instructions listed in this page on how to add in plugins (as you can see from my config.yaml) file above.

After none of that working, I scoured the web for an answer and the best I could find was to downgrade to python 3.8.3; which I tried without success (sadly). Then I posted on the github forum (which ended up leading me here) and was suggested I follow [these instructions](https://beets.readthedocs.io/en/stable/faq.html#run-the-latest-source-version-of-beets) to make sure I have the latest version of beets. After following these instructions and getting no success, I figured maybe I should try to update to 3.8.4, but that didn’t help either. At this point, the only way to get the program to run on my Windows 10 (2004 update) is to comment out the plugins that you see above (including the chroma plugin), which is a little sad because I have different tracks that I could _really_ use the audio fingerprinting for and I’d rather give this a shot than using different software.

I am not sure how to check if I can invoke `fpcalc` or not unfortunately. I am 99.999% sure that the file is in a folder that is on my %PATH%.

Thank you for your prompt response, I really hope that we can get this straightened out, as I don’t believe I can be the only one experiencing this situation.

---

<div class="post-metadata">

### Author: ![adrian](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.beets.io/adrian/32/4_2.png) [@adrian](https://discourse.beets.io/u/adrian)
#### Post date: [July 21, 2020, 11:20am UTC](https://discourse.beets.io/t/trying-to-use-chroma-plugin-but-keep-getting-the-same-error/1419/4 "2020-07-21T11:20:22Z")

</div>

> [@HisMessengerDAB](#):
>
> I am not sure how to check if I can invoke `fpcalc` or not unfortunately. I am 99.999% sure that the file is in a folder that is on my %PATH%.

The thing to do is to open a new command-line window and try typing `fpcalc`. If that works (and prints a help message or something), then you’re all set. If it says “command not found” or similar, then the `%PATH%` settings need more fiddling.

That’s the crux of it! Python versions and such are a red herring here.

---

<div class="post-metadata">

### Author: ![HisMessengerDAB](https://avatars.discourse-cdn.com/v4/letter/h/48db29/32.png) [@HisMessengerDAB](https://discourse.beets.io/u/HisMessengerDAB)
#### Post date: [July 21, 2020, 1:54pm UTC](https://discourse.beets.io/t/trying-to-use-chroma-plugin-but-keep-getting-the-same-error/1419/5 "2020-07-21T13:54:40Z")

</div>

Hey there @adrian,

When I type `fpcalc` in a `cmd` prompt I get this (which makes me thing that the %PATH% settings are correct:

```auto
 C:\Users\[USER]>fpcalc
ERROR: No input files

C:\Users\,[USER]>fpcalc F:\Music
ERROR: Could not open the input file (Permission denied)

C:\Users\[USER]>fpcalc "F:\Music\VA - VH1 100 Greatest Hard Rock Songs (2020) Mp3 320kbps [PMEDIA] ⭐️"
ERROR: Could not open the input file (No such file or directory)

C:\Users\[USER]>fpcalc "F:\Music"
ERROR: Could not open the input file (Permission denied)

```

Theoretically speaking, it should work right?

---

<div class="post-metadata">

### Author: ![adrian](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.beets.io/adrian/32/4_2.png) [@adrian](https://discourse.beets.io/u/adrian)
#### Post date: [July 21, 2020, 2:18pm UTC](https://discourse.beets.io/t/trying-to-use-chroma-plugin-but-keep-getting-the-same-error/1419/6 "2020-07-21T14:18:03Z")

</div>

Weird! It certainly seems as if everything’s in order.

If the `PATH` settings aren’t working (although I do not immediately see why they are not), an alternate is to set the environment variable `FPCALC` to point to the executable, i.e., to the `fpcalc.exe` file, wherever it may be.

---

<div class="post-metadata">

### Author: ![HisMessengerDAB](https://avatars.discourse-cdn.com/v4/letter/h/48db29/32.png) [@HisMessengerDAB](https://discourse.beets.io/u/HisMessengerDAB)
#### Post date: [July 22, 2020, 5:09am UTC](https://discourse.beets.io/t/trying-to-use-chroma-plugin-but-keep-getting-the-same-error/1419/7 "2020-07-22T05:09:31Z")

</div>

Hey @adrian, I sincerely appreciate all of the help trying to untangle this web. I tried adding `fpcalc.exe` to the `PATH` settings as suggested but got this error:

```auto
PS C:\Users\[user]> beet imp F:\Music
Import of the directory:
F:\Music
was interrupted. Resume (Y/n)? y
Resuming interrupted import of F:\Music
chroma: fingerprinting of b'F:\\Music\\Eminem - Guilty Conscience.mp3' failed: fpcalc exited with status 3

```

Suggestions?

---

<div class="post-metadata">

### Author: ![arogl](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.beets.io/arogl/32/455_2.png) [@arogl](https://discourse.beets.io/u/arogl)
#### Post date: [July 22, 2020, 6:31am UTC](https://discourse.beets.io/t/trying-to-use-chroma-plugin-but-keep-getting-the-same-error/1419/8 "2020-07-22T06:31:22Z")

</div>

Can you try?

```auto
fpcalc "F:\Music\Eminem - Guilty Conscience.mp3"

```

I think the error is related to permission errors.

I notice a new fpcalc binary was released, so I’ll test as well.

Tested win10 - fpcaclv1.5.0 (latest) and all worked.  
Tested WSL (Ubuntu 20.04) - fpcalcv1.4.3 on the same file and all worked, same output for both files.

---

<div class="post-metadata">

### Author: ![HisMessengerDAB](https://avatars.discourse-cdn.com/v4/letter/h/48db29/32.png) [@HisMessengerDAB](https://discourse.beets.io/u/HisMessengerDAB)
#### Post date: [July 22, 2020, 1:44pm UTC](https://discourse.beets.io/t/trying-to-use-chroma-plugin-but-keep-getting-the-same-error/1419/9 "2020-07-22T13:44:53Z")

</div>

> [@arogl](#):
>
> `fpcalc "F:\Music\Eminem - Guilty Conscience.mp3"`

Hey there man,

Here’s what happened when I ran that command (I have a sneaking suspicion, the issue may be due to the file itself not the program)

```auto
❯ fpcalc "F:\5tb\Music\Eminem - Guilty Conscience.mp3"
ERROR: Error decoding audio frame (Invalid data found when processing input)
DURATION=199
FINGERPRINT=AQAAbUmkJEuUJIkSDdau4vUFPT56_NBy9EeO_zLMd9h5mPyQlBfCN0fTzfiP_MSj_HC05FKQXHpw9OHRHMm1KNgVPZCWXYbzI-defD7cY89xUUejM6iP_IeWKksl5LzgnQibnPhRUvCaJBRCbzLxSNdRKzd8psSzjKiD3UV_hHl2qLmQNxE45Z1xpcedwN8iEixyQRWPXEo2tNQFKy4TpBVRqYT0oGGPsPkwVyJyQQ8rpCf2HIejRJIVdFGkw89T9B1yQZpy5Epy5Wh6Bf3wHSyPPH2g7-LwTOGK-ygfEUzYBz_8bLiyHM8SSlD1CM-H5iRqNYibrMcTynijZAtK6gqaiCRyhcWcV9A5xAYGhBAmCQSUAUIII4wBiEAgHAAMEAISAAAIRYwRSjhDADESEaGAkggBgAwgggkggAAIUEGoAIIKB4EhsAghpBEAKAqVEIIQABQThBIkgCMGCSKEARw

```

Thoughts?

edit: So, I ended up stumbling on a potential solution: using `MP3val-frontend 0.1.1` to identify which mp3 files might have been corrupted and which ones were ok. It can even fix many of the ones which seem to have problems. I have a sneaking suspicion that the problem is due to the files being corrupted. Once I clean up my library (which will take a while), I will try the fix again and report back with what I found.

---

<div class="post-metadata">

### Author: ![arogl](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.beets.io/arogl/32/455_2.png) [@arogl](https://discourse.beets.io/u/arogl)
#### Post date: [July 23, 2020, 7:57am UTC](https://discourse.beets.io/t/trying-to-use-chroma-plugin-but-keep-getting-the-same-error/1419/10 "2020-07-23T07:57:51Z")

</div>

I have used that program as well to clean up my library. 🙂

I was going to suggest to use ffmpeg to verify like this

```auto
ffmpeg.exe -i "F:\5tb\Music\Eminem - Guilty Conscience.mp3" -f null -

```

I find this useful for a “quick” verify of integrity.

I have also used foobar2000 to verify the integrity of files. It is very quick.

Good luck, shout out if you need any more help

---

<div class="post-metadata">

### Author: ![HisMessengerDAB](https://avatars.discourse-cdn.com/v4/letter/h/48db29/32.png) [@HisMessengerDAB](https://discourse.beets.io/u/HisMessengerDAB)
#### Post date: [July 23, 2020, 5:56pm UTC](https://discourse.beets.io/t/trying-to-use-chroma-plugin-but-keep-getting-the-same-error/1419/11 "2020-07-23T17:56:13Z")

</div>

Hey @arogl, which component did you use through foobar2000 to verify file integrity?

---

<div class="post-metadata">

### Author: ![arogl](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.beets.io/arogl/32/455_2.png) [@arogl](https://discourse.beets.io/u/arogl)
#### Post date: [July 23, 2020, 11:35pm UTC](https://discourse.beets.io/t/trying-to-use-chroma-plugin-but-keep-getting-the-same-error/1419/12 "2020-07-23T23:35:47Z")

</div>

install this component if not already installed  
[File Integrity Verifier](https://www.foobar2000.org/components/view/foo_verifier)

In foobar2000:

1. select all tracks you wish to verify
2. Right click and choose verify integrity

Hope that helps.
