Note that there are some explanatory texts on larger screens.

plurals
  1. PORunning Scipy on Heroku
    text
    copied!<p>I got Numpy and Matplotlib running on Heroku, and I'm trying to install Scipy as well. However, Scipy requires BLAS[1] to install, which is not presented on the Heroku platform. After contacting Heroku support, they suggested me to build BLAS as a static library to deploy, and setup the necessary environment variables.</p> <p>So, I compiled libblas.a on a 64bit Linux box, and set the following variables as described in [2] :</p> <pre><code>$ heroku config BLAS =&gt; .heroku/vendor/lib/libfblas.a LD_LIBRARY_PATH =&gt; .heroku/vendor/lib LIBRARY_PATH =&gt; .heroku/vendor/lib PATH =&gt; bin:/usr/local/bin:/usr/bin:/bin PYTHONUNBUFFERED =&gt; true </code></pre> <p>After adding scipy==0.10.1 in my requirements.txt, the push still fails. </p> <pre><code> File "scipy/integrate/setup.py", line 10, in configuration blas_opt = get_info('blas_opt',notfound_action=2) File "/tmp/build_h5l5y31i49e8/lib/python2.7/site-packages/numpy/distutils/system_info.py", line 311, in get_info return cl().get_info(notfound_action) File "/tmp/build_h5l5y31i49e8/lib/python2.7/site-packages/numpy/distutils/system_info.py", line 462, in get_info raise self.notfounderror(self.notfounderror.__doc__) numpy.distutils.system_info.BlasNotFoundError: Blas (http://www.netlib.org/blas/) libraries not found. Directories to search for the libraries can be specified in the numpy/distutils/site.cfg file (section [blas]) or by setting the BLAS environment variable. </code></pre> <p>It seem that pip is not aware of the BLAS environment variable, so I check the environment using heroku run python: </p> <pre><code>(venv)bash-3.2$ heroku run python Running python attached to terminal... import up, run.1 Python 2.7.2 (default, Oct 31 2011, 16:22:04) [GCC 4.4.3] on linux2 Type "help", "copyright", "credits" or "license" for more information. &gt;&gt;&gt; import os &gt;&gt;&gt; os.system('bash') ~ $ echo $BLAS .heroku/vendor/lib/libfblas.a ~ $ ls .heroku/vendor/lib/libfblas.a .heroku/vendor/lib/libfblas.a ~ $ </code></pre> <p>And it seems fine. Now I have no idea how to solve this.</p> <p>[1] <a href="http://www.netlib.org/blas/">http://www.netlib.org/blas/</a> [2] <a href="http://www.scipy.org/Installing_SciPy/Linux">http://www.scipy.org/Installing_SciPy/Linux</a></p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload