1

Getting this error on Anaconda Prompt, PyCharm when trying to install the "madmom" package. The error basically means that I need to install C++ 14.0, obviously. However, I got it installed in the first place since I develop C++ programs also. Things I've tried to resolve the problem:

  1. Uninstalling SDK, Compiler Build Tools (2 times)
  2. Uninstalling Visual Studio (2 times)
  3. Reinstalling everything with Visual Studio (2 times)
  4. Updating PyCharm
  5. Path corrections
  6. Permission corrections

Visual Studio and Build Tools are on the same disk as Python. C++ compilers work well on DevCpp++, Visual Studio, so I don't think they're corrupted or something. How can I fix this error?

  Running setup.py clean for madmom
Failed to build madmom
Installing collected packages: madmom
    Running setup.py install for madmom ... error
    ERROR: Command errored out with exit status 1:
     command: 'C:\ProgramData\Anaconda3\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\conda_tmp\\pip-install-4j931tyk\\madmom\\setup.py'"'"'; __file__='"'"'C:\\conda_tmp\\pip-install-4j931tyk\\madmom\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record 'C:\conda_tmp\pip-record-a57u6mpd\install-record.txt' --single-version-externally-managed --compile --install-headers 'C:\ProgramData\Anaconda3\Include\madmom'
         cwd: C:\conda_tmp\pip-install-4j931tyk\madmom\
    Complete output (143 lines):
    running install
    running build
    running build_py
    creating build
    creating build\lib.win-amd64-3.8
    creating build\lib.win-amd64-3.8\madmom
    copying madmom\conftest.py -> build\lib.win-amd64-3.8\madmom
    copying madmom\processors.py -> build\lib.win-amd64-3.8\madmom
    copying madmom\__init__.py -> build\lib.win-amd64-3.8\madmom
    creating build\lib.win-amd64-3.8\madmom\audio
    copying madmom\audio\chroma.py -> build\lib.win-amd64-3.8\madmom\audio
    copying madmom\audio\filters.py -> build\lib.win-amd64-3.8\madmom\audio
    copying madmom\audio\signal.py -> build\lib.win-amd64-3.8\madmom\audio
    copying madmom\audio\spectrogram.py -> build\lib.win-amd64-3.8\madmom\audio
    copying madmom\audio\stft.py -> build\lib.win-amd64-3.8\madmom\audio
    copying madmom\audio\__init__.py -> build\lib.win-amd64-3.8\madmom\audio
    creating build\lib.win-amd64-3.8\madmom\evaluation
    copying madmom\evaluation\beats.py -> build\lib.win-amd64-3.8\madmom\evaluation
    copying madmom\evaluation\chords.py -> build\lib.win-amd64-3.8\madmom\evaluation
    copying madmom\evaluation\key.py -> build\lib.win-amd64-3.8\madmom\evaluation
    copying madmom\evaluation\notes.py -> build\lib.win-amd64-3.8\madmom\evaluation
    copying madmom\evaluation\onsets.py -> build\lib.win-amd64-3.8\madmom\evaluation
    copying madmom\evaluation\tempo.py -> build\lib.win-amd64-3.8\madmom\evaluation
    copying madmom\evaluation\__init__.py -> build\lib.win-amd64-3.8\madmom\evaluation
    creating build\lib.win-amd64-3.8\madmom\features
    copying madmom\features\beats.py -> build\lib.win-amd64-3.8\madmom\features
    copying madmom\features\beats_hmm.py -> build\lib.win-amd64-3.8\madmom\features
    copying madmom\features\chords.py -> build\lib.win-amd64-3.8\madmom\features
    copying madmom\features\downbeats.py -> build\lib.win-amd64-3.8\madmom\features
    copying madmom\features\key.py -> build\lib.win-amd64-3.8\madmom\features
    copying madmom\features\notes.py -> build\lib.win-amd64-3.8\madmom\features
    copying madmom\features\onsets.py -> build\lib.win-amd64-3.8\madmom\features
    copying madmom\features\tempo.py -> build\lib.win-amd64-3.8\madmom\features
    copying madmom\features\__init__.py -> build\lib.win-amd64-3.8\madmom\features
    creating build\lib.win-amd64-3.8\madmom\io
    copying madmom\io\audio.py -> build\lib.win-amd64-3.8\madmom\io
    copying madmom\io\midi.py -> build\lib.win-amd64-3.8\madmom\io
    copying madmom\io\__init__.py -> build\lib.win-amd64-3.8\madmom\io
    creating build\lib.win-amd64-3.8\madmom\ml
    copying madmom\ml\crf.py -> build\lib.win-amd64-3.8\madmom\ml
    copying madmom\ml\gmm.py -> build\lib.win-amd64-3.8\madmom\ml
    copying madmom\ml\__init__.py -> build\lib.win-amd64-3.8\madmom\ml
    creating build\lib.win-amd64-3.8\madmom\models
    copying madmom\models\__init__.py -> build\lib.win-amd64-3.8\madmom\models
    creating build\lib.win-amd64-3.8\madmom\utils
    copying madmom\utils\midi.py -> build\lib.win-amd64-3.8\madmom\utils
    copying madmom\utils\__init__.py -> build\lib.win-amd64-3.8\madmom\utils
    creating build\lib.win-amd64-3.8\madmom\ml\nn
    copying madmom\ml\nn\activations.py -> build\lib.win-amd64-3.8\madmom\ml\nn
    copying madmom\ml\nn\layers.py -> build\lib.win-amd64-3.8\madmom\ml\nn
    copying madmom\ml\nn\__init__.py -> build\lib.win-amd64-3.8\madmom\ml\nn
    copying madmom\models\LICENSE -> build\lib.win-amd64-3.8\madmom\models
    copying madmom\models\README.rst -> build\lib.win-amd64-3.8\madmom\models
    creating build\lib.win-amd64-3.8\madmom\models\beats
    creating build\lib.win-amd64-3.8\madmom\models\beats\2015
    copying madmom\models\beats\2015\beats_blstm_1.pkl -> build\lib.win-amd64-3.8\madmom\models\beats\2015
    copying madmom\models\beats\2015\beats_blstm_2.pkl -> build\lib.win-amd64-3.8\madmom\models\beats\2015
    copying madmom\models\beats\2015\beats_blstm_3.pkl -> build\lib.win-amd64-3.8\madmom\models\beats\2015
    copying madmom\models\beats\2015\beats_blstm_4.pkl -> build\lib.win-amd64-3.8\madmom\models\beats\2015
    copying madmom\models\beats\2015\beats_blstm_5.pkl -> build\lib.win-amd64-3.8\madmom\models\beats\2015
    copying madmom\models\beats\2015\beats_blstm_6.pkl -> build\lib.win-amd64-3.8\madmom\models\beats\2015
    copying madmom\models\beats\2015\beats_blstm_7.pkl -> build\lib.win-amd64-3.8\madmom\models\beats\2015
    copying madmom\models\beats\2015\beats_blstm_8.pkl -> build\lib.win-amd64-3.8\madmom\models\beats\2015
    creating build\lib.win-amd64-3.8\madmom\models\beats\2016
    copying madmom\models\beats\2016\beats_lstm_1.pkl -> build\lib.win-amd64-3.8\madmom\models\beats\2016
    copying madmom\models\beats\2016\beats_lstm_2.pkl -> build\lib.win-amd64-3.8\madmom\models\beats\2016
    copying madmom\models\beats\2016\beats_lstm_3.pkl -> build\lib.win-amd64-3.8\madmom\models\beats\2016
    copying madmom\models\beats\2016\beats_lstm_4.pkl -> build\lib.win-amd64-3.8\madmom\models\beats\2016
    copying madmom\models\beats\2016\beats_lstm_5.pkl -> build\lib.win-amd64-3.8\madmom\models\beats\2016
    copying madmom\models\beats\2016\beats_lstm_6.pkl -> build\lib.win-amd64-3.8\madmom\models\beats\2016
    copying madmom\models\beats\2016\beats_lstm_7.pkl -> build\lib.win-amd64-3.8\madmom\models\beats\2016
    copying madmom\models\beats\2016\beats_lstm_8.pkl -> build\lib.win-amd64-3.8\madmom\models\beats\2016
    creating build\lib.win-amd64-3.8\madmom\models\chords
    creating build\lib.win-amd64-3.8\madmom\models\chords\2016
    copying madmom\models\chords\2016\chords_cnncrf.pkl -> build\lib.win-amd64-3.8\madmom\models\chords\2016
    copying madmom\models\chords\2016\chords_cnnfeat.pkl -> build\lib.win-amd64-3.8\madmom\models\chords\2016
    copying madmom\models\chords\2016\chords_dccrf.pkl -> build\lib.win-amd64-3.8\madmom\models\chords\2016
    creating build\lib.win-amd64-3.8\madmom\models\chroma
    creating build\lib.win-amd64-3.8\madmom\models\chroma\2016
    copying madmom\models\chroma\2016\chroma_dnn.pkl -> build\lib.win-amd64-3.8\madmom\models\chroma\2016
    creating build\lib.win-amd64-3.8\madmom\models\downbeats
    creating build\lib.win-amd64-3.8\madmom\models\downbeats\2016
    copying madmom\models\downbeats\2016\downbeats_bgru_harmonic_0.pkl -> build\lib.win-amd64-3.8\madmom\models\downbeats\2016
    copying madmom\models\downbeats\2016\downbeats_bgru_harmonic_1.pkl -> build\lib.win-amd64-3.8\madmom\models\downbeats\2016
    copying madmom\models\downbeats\2016\downbeats_bgru_harmonic_2.pkl -> build\lib.win-amd64-3.8\madmom\models\downbeats\2016
    copying madmom\models\downbeats\2016\downbeats_bgru_harmonic_3.pkl -> build\lib.win-amd64-3.8\madmom\models\downbeats\2016
    copying madmom\models\downbeats\2016\downbeats_bgru_harmonic_4.pkl -> build\lib.win-amd64-3.8\madmom\models\downbeats\2016
    copying madmom\models\downbeats\2016\downbeats_bgru_harmonic_5.pkl -> build\lib.win-amd64-3.8\madmom\models\downbeats\2016
    copying madmom\models\downbeats\2016\downbeats_bgru_rhythmic_0.pkl -> build\lib.win-amd64-3.8\madmom\models\downbeats\2016
    copying madmom\models\downbeats\2016\downbeats_bgru_rhythmic_1.pkl -> build\lib.win-amd64-3.8\madmom\models\downbeats\2016
    copying madmom\models\downbeats\2016\downbeats_bgru_rhythmic_2.pkl -> build\lib.win-amd64-3.8\madmom\models\downbeats\2016
    copying madmom\models\downbeats\2016\downbeats_bgru_rhythmic_3.pkl -> build\lib.win-amd64-3.8\madmom\models\downbeats\2016
    copying madmom\models\downbeats\2016\downbeats_bgru_rhythmic_4.pkl -> build\lib.win-amd64-3.8\madmom\models\downbeats\2016
    copying madmom\models\downbeats\2016\downbeats_bgru_rhythmic_5.pkl -> build\lib.win-amd64-3.8\madmom\models\downbeats\2016
    copying madmom\models\downbeats\2016\downbeats_blstm_1.pkl -> build\lib.win-amd64-3.8\madmom\models\downbeats\2016
    copying madmom\models\downbeats\2016\downbeats_blstm_2.pkl -> build\lib.win-amd64-3.8\madmom\models\downbeats\2016
    copying madmom\models\downbeats\2016\downbeats_blstm_3.pkl -> build\lib.win-amd64-3.8\madmom\models\downbeats\2016
    copying madmom\models\downbeats\2016\downbeats_blstm_4.pkl -> build\lib.win-amd64-3.8\madmom\models\downbeats\2016
    copying madmom\models\downbeats\2016\downbeats_blstm_5.pkl -> build\lib.win-amd64-3.8\madmom\models\downbeats\2016
    copying madmom\models\downbeats\2016\downbeats_blstm_6.pkl -> build\lib.win-amd64-3.8\madmom\models\downbeats\2016
    copying madmom\models\downbeats\2016\downbeats_blstm_7.pkl -> build\lib.win-amd64-3.8\madmom\models\downbeats\2016
    copying madmom\models\downbeats\2016\downbeats_blstm_8.pkl -> build\lib.win-amd64-3.8\madmom\models\downbeats\2016
    creating build\lib.win-amd64-3.8\madmom\models\key
    creating build\lib.win-amd64-3.8\madmom\models\key\2018
    copying madmom\models\key\2018\key_cnn.pkl -> build\lib.win-amd64-3.8\madmom\models\key\2018
    creating build\lib.win-amd64-3.8\madmom\models\notes
    creating build\lib.win-amd64-3.8\madmom\models\notes\2013
    copying madmom\models\notes\2013\notes_brnn.pkl -> build\lib.win-amd64-3.8\madmom\models\notes\2013
    creating build\lib.win-amd64-3.8\madmom\models\onsets
    creating build\lib.win-amd64-3.8\madmom\models\onsets\2013
    copying madmom\models\onsets\2013\onsets_brnn_1.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2013
    copying madmom\models\onsets\2013\onsets_brnn_2.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2013
    copying madmom\models\onsets\2013\onsets_brnn_3.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2013
    copying madmom\models\onsets\2013\onsets_brnn_4.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2013
    copying madmom\models\onsets\2013\onsets_brnn_5.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2013
    copying madmom\models\onsets\2013\onsets_brnn_6.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2013
    copying madmom\models\onsets\2013\onsets_brnn_7.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2013
    copying madmom\models\onsets\2013\onsets_brnn_8.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2013
    copying madmom\models\onsets\2013\onsets_cnn.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2013
    copying madmom\models\onsets\2013\onsets_rnn_1.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2013
    copying madmom\models\onsets\2013\onsets_rnn_2.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2013
    copying madmom\models\onsets\2013\onsets_rnn_3.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2013
    copying madmom\models\onsets\2013\onsets_rnn_4.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2013
    copying madmom\models\onsets\2013\onsets_rnn_5.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2013
    copying madmom\models\onsets\2013\onsets_rnn_6.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2013
    copying madmom\models\onsets\2013\onsets_rnn_7.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2013
    copying madmom\models\onsets\2013\onsets_rnn_8.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2013
    creating build\lib.win-amd64-3.8\madmom\models\onsets\2014
    copying madmom\models\onsets\2014\onsets_brnn_pp_1.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2014
    copying madmom\models\onsets\2014\onsets_brnn_pp_2.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2014
    copying madmom\models\onsets\2014\onsets_brnn_pp_3.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2014
    copying madmom\models\onsets\2014\onsets_brnn_pp_4.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2014
    copying madmom\models\onsets\2014\onsets_brnn_pp_5.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2014
    copying madmom\models\onsets\2014\onsets_brnn_pp_6.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2014
    copying madmom\models\onsets\2014\onsets_brnn_pp_7.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2014
    copying madmom\models\onsets\2014\onsets_brnn_pp_8.pkl -> build\lib.win-amd64-3.8\madmom\models\onsets\2014
    creating build\lib.win-amd64-3.8\madmom\models\patterns
    creating build\lib.win-amd64-3.8\madmom\models\patterns\2013
    copying madmom\models\patterns\2013\ballroom_pattern_3_4.pkl -> build\lib.win-amd64-3.8\madmom\models\patterns\2013
    copying madmom\models\patterns\2013\ballroom_pattern_4_4.pkl -> build\lib.win-amd64-3.8\madmom\models\patterns\2013
    running build_ext
    building 'madmom.audio.comb_filters' extension
    error: Microsoft Visual C++ 14.0 or greater is required. Get it with "Microsoft C++ Build Tools": https://visualstudio.microsoft.com/visual-cpp-build-tools/
    ----------------------------------------
ERROR: Command errored out with exit status 1: 'C:\ProgramData\Anaconda3\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\conda_tmp\\pip-install-4j931tyk\\madmom\\setup.py'"'"'; __file__='"'"'C:\\conda_tmp\\pip-install-4j931tyk\\madmom\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record 'C:\conda_tmp\pip-record-a57u6mpd\install-record.txt' --single-version-externally-managed --compile --install-headers 'C:\ProgramData\Anaconda3\Include\madmom' Check the logs for full command output.

Here I verify that If I have a C++ compiler, and it's verified. However, still the same error.

(base) C:\Users\UserName>cl
x86 için Microsoft (R) C/C++ İyileştirmeli Derleyicisi Sürüm 19.00.24245
Telif Hakkı (C) Microsoft Corporation. Tüm hakları saklıdır.

kullanım: cl [ seçenek... ] dosyaadı... [ /link bağlantıseçeneği... ]

(base) C:\Users\UserName>pip install madmom
Collecting madmom
  Using cached madmom-0.16.1.tar.gz (20.0 MB)
Requirement already satisfied: numpy>=1.13.4 in c:\programdata\anaconda3\lib\site-packages (from madmom) (1.18.5)
Requirement already satisfied: scipy>=0.16 in c:\programdata\anaconda3\lib\site-packages (from madmom) (1.5.0)
Requirement already satisfied: cython>=0.25 in c:\programdata\anaconda3\lib\site-packages (from madmom) (0.29.21)
Requirement already satisfied: mido>=1.2.8 in c:\programdata\anaconda3\lib\site-packages (from madmom) (1.2.10)
Building wheels for collected packages: madmom
  Building wheel for madmom (setup.py) ... error
  ERROR: Command errored out with exit status 1:
   command: 'C:\ProgramData\Anaconda3\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\conda_tmp\\pip-install-y05eq_e0\\madmom\\setup.py'"'"'; __file__='"'"'C:\\conda_tmp\\pip-install-y05eq_e0\\madmom\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d 'C:\conda_tmp\pip-wheel-07uw_9wk'
       cwd: C:\conda_tmp\pip-install-y05eq_e0\madmom\
  Complete output (143 lines):
  running bdist_wheel
  running build
  running build_py
  creating build
Cactuser
  • 98
  • 9
  • Have you tried updating setuptools? (`pip install --upgrade setuptools`) [see this answer](https://stackoverflow.com/a/40888720/4954687) – cellularegg Jun 11 '21 at 09:23
  • @cellularegg Thanks for the reply. Yes, I tried it in the first place, changes nothing. Now even reinstalled conda, python, and pycharm. Still the same, unbelievable. – Cactuser Jun 11 '21 at 09:36
  • Did you install all prerequisites? [see here](https://madmom.readthedocs.io/en/latest/installation.html#install-prerequisites) (numpy, scipy, cython, mido) – cellularegg Jun 11 '21 at 13:30
  • @cellularegg Yeah, I did in the first place. However, the problem still occurs. I think I'm going to format the computer, that seems to be the best solution for now. – Cactuser Jun 11 '21 at 13:39
  • Okay, have you tried installing a C++ Redistributable? Maybe the issue is because you are using Python 32 or 64 bit. In your answer it says something about x86 C++ maybe you need a Python x86 version. – cellularegg Jun 11 '21 at 13:51
  • @cellularegg Just tried with 32bit Python, still the same. – Cactuser Jun 11 '21 at 14:00

0 Answers0