3

So I am trying to install bottleneck (by doing pip install bottleneck) in comand promt and I keep getting the error:

    ERROR: Command errored out with exit status 1:
   command: 'c:\users\benito\appdata\local\programs\python\python36\python.exe' 'c:\users\benito\appdata\local\programs\python\python36\lib\site-packages\pip\_vendor\pep517\_in_process.py' build_wheel 'C:\Users\Benito\AppData\Local\Temp\tmp3cb_deoe'
       cwd: C:\Users\Benito\AppData\Local\Temp\pip-install-hrd3bsvr\bottleneck
  Complete output (51 lines):
  running bdist_wheel
  running build
  running build_py
  creating build
  creating build\lib.win-amd64-3.6
  creating build\lib.win-amd64-3.6\bottleneck
  copying bottleneck\_pytesttester.py -> build\lib.win-amd64-3.6\bottleneck
  copying bottleneck\_version.py -> build\lib.win-amd64-3.6\bottleneck
  copying bottleneck\__init__.py -> build\lib.win-amd64-3.6\bottleneck
  creating build\lib.win-amd64-3.6\bottleneck\benchmark
  copying bottleneck\benchmark\autotimeit.py -> build\lib.win-amd64-3.6\bottleneck\benchmark
  copying bottleneck\benchmark\bench.py -> build\lib.win-amd64-3.6\bottleneck\benchmark
  copying bottleneck\benchmark\bench_detailed.py -> build\lib.win-amd64-3.6\bottleneck\benchmark
  copying bottleneck\benchmark\__init__.py -> build\lib.win-amd64-3.6\bottleneck\benchmark
  creating build\lib.win-amd64-3.6\bottleneck\slow
  copying bottleneck\slow\move.py -> build\lib.win-amd64-3.6\bottleneck\slow
  copying bottleneck\slow\nonreduce.py -> build\lib.win-amd64-3.6\bottleneck\slow
  copying bottleneck\slow\nonreduce_axis.py -> build\lib.win-amd64-3.6\bottleneck\slow
  copying bottleneck\slow\reduce.py -> build\lib.win-amd64-3.6\bottleneck\slow
  copying bottleneck\slow\__init__.py -> build\lib.win-amd64-3.6\bottleneck\slow
  creating build\lib.win-amd64-3.6\bottleneck\src
  copying bottleneck\src\bn_config.py -> build\lib.win-amd64-3.6\bottleneck\src
  copying bottleneck\src\bn_template.py -> build\lib.win-amd64-3.6\bottleneck\src
  copying bottleneck\src\__init__.py -> build\lib.win-amd64-3.6\bottleneck\src
  creating build\lib.win-amd64-3.6\bottleneck\tests
  copying bottleneck\tests\input_modification_test.py -> build\lib.win-amd64-3.6\bottleneck\tests
  copying bottleneck\tests\list_input_test.py -> build\lib.win-amd64-3.6\bottleneck\tests
  copying bottleneck\tests\memory_test.py -> build\lib.win-amd64-3.6\bottleneck\tests
  copying bottleneck\tests\move_test.py -> build\lib.win-amd64-3.6\bottleneck\tests
  copying bottleneck\tests\nonreduce_axis_test.py -> build\lib.win-amd64-3.6\bottleneck\tests
  copying bottleneck\tests\nonreduce_test.py -> build\lib.win-amd64-3.6\bottleneck\tests
  copying bottleneck\tests\reduce_test.py -> build\lib.win-amd64-3.6\bottleneck\tests
  copying bottleneck\tests\scalar_input_test.py -> build\lib.win-amd64-3.6\bottleneck\tests
  copying bottleneck\tests\util.py -> build\lib.win-amd64-3.6\bottleneck\tests
  copying bottleneck\tests\__init__.py -> build\lib.win-amd64-3.6\bottleneck\tests
  UPDATING build\lib.win-amd64-3.6\bottleneck/_version.py
  set build\lib.win-amd64-3.6\bottleneck/_version.py to '1.3.1'
  running build_ext
  running config
  compiling '_configtest.c':



  int __attribute__((optimize("O3"))) have_attribute_optimize_opt_3(void*);

  int main(void)
  {
      return 0;
  }

  error: Microsoft Visual C++ 14.0 is required. Get it with "Build Tools for Visual Studio": https://visualstudio.microsoft.com/downloads/
  ----------------------------------------
  ERROR: Failed building wheel for bottleneck
  Running setup.py clean for bottleneck
Failed to build bottleneck
ERROR: Could not build wheels for bottleneck which use PEP 517 and cannot be installed directly

I have also installed Microsoft Visual C++ 14.0, resset my computer and lanuched the program and done the same thing in the program and I am getting the same error. I also have done pip install wheel and then done pip install bottleneck and I recive the same error. Also I have python 3.6

benito.cano
  • 797
  • 1
  • 8
  • 23
  • How did you install Microsoft Visual C++ 14.0? It seems like that's still the issue, right? See: https://stackoverflow.com/questions/29846087/microsoft-visual-c-14-0-is-required-unable-to-find-vcvarsall-bat. – AMC Feb 13 '20 at 00:27
  • Thank you so much. this worked for me, I am sorry about the confusion – benito.cano Feb 13 '20 at 01:41
  • Does this answer your question? [Microsoft Visual C++ 14.0 is required (Unable to find vcvarsall.bat)](https://stackoverflow.com/questions/29846087/microsoft-visual-c-14-0-is-required-unable-to-find-vcvarsall-bat) – AMC Feb 13 '20 at 01:42

3 Answers3

1

I got it to work by installing the bottleneck manually with the respective wheel from this site: www.lfd.uci.edu/~gohlke/pythonlibs/.

Simply download the file for your Python version (in my case Bottleneck‑1.3.2‑cp38‑cp38‑win_amd64.whl) and install it:

pip install C:\Users\...
Heka
  • 73
  • 1
  • 8
1

All you need to do at first install PyPI then pyinstaller

pip install PyPI
pip install pyinstaller

PyPI installation screen capture

enter image description here

MT-FreeHK
  • 2,462
  • 1
  • 13
  • 29
1

I also faced the same problem trying to install pycaret on a Windows machine. Got the error

ERROR: Failed building wheel for bottleneck
Failed to build bottleneck
ERROR: Could not build wheels for bottleneck which use PEP 517 and cannot be installed directly

Reading the output it seams that the installation process was unable to install bottleneck, so you have to do that manually. Pip failed doing that, so because I was using Anaconda env the conda install is the way to go. Also installing p5py and pep517 is a good idea.

I could resolve the problem with the following steps:

  1. conda install bottleneck
  2. pip install p5py
  3. pip install pep517
  4. pip install pycaret
Dharman
  • 30,962
  • 25
  • 85
  • 135
b0zg0r
  • 85
  • 5