Gentoo Archives: gentoo-science

From: "Sébastien Fabbro" <bicatali@g.o>
To: gentoo-science@l.g.o
Subject: Re: [gentoo-science] liblapack, libblas, numpy, and python virtualenvs
Date: Thu, 17 Apr 2014 17:11:34
Message-Id: CAA-OU2r15YjpF_NVGRUtcegXb5DUEhEctH3_85uJ1j4S2Uv9oA@mail.gmail.com
1 On Thu, Apr 17, 2014 at 8:29 AM, Grant Goodyear <g2boojum@×××××.com> wrote:
2
3 > For reproducibility, I like to have a python virtualenv that has all of
4 > the python libraries that I use, relying on portage just for python,
5 > virtualenv, and virtualenvwrapper. Building numpy using "pip install numpy"
6 > fails if I use the science-overlay versions of the reference lapack and
7 > blas libraries, because pip can't find liblapack to link to it.
8 >
9 > Right now I'm cheating and using the non-overlay versions, but I'm sure
10 > that somebody has a better solution of how to help pip find the right
11 > libraries. Help?
12 >
13
14 The problem lies in the broken design of numpy.distutils trying to do way
15 too much autodetection, and our ways to manage around it while keeping our
16 linear algebra modularity.
17 A possible workaround if you really want to use pip and the gentoo-science
18 overlay framework is to simply link your selected blas and lapack libraries
19 to /usr/lib/lib{blas,lapack}.so. I have not tested it, but I suspect this
20 should work for openblas and {blas,lapack}-reference since they only have
21 one library to link.
22
23 Are you trying to do cross-distro reproducibility?
24
25 Sebastien