On Thu, Nov 5, 2015 at 1:37 AM, Ralf Gommers <ralf.gomm...@gmail.com> wrote:
> > > On Thu, Nov 5, 2015 at 5:11 AM, Nathaniel Smith <n...@pobox.com> wrote: > >> On Wed, Nov 4, 2015 at 4:40 PM, Stefan Seefeld <ste...@seefeld.name> >> wrote: >> > Hello, >> > >> > is there a way to query Numpy for information about backends (BLAS, >> > LAPACK, etc.) that it was compiled against, including compiler / linker >> > flags that were used ? >> > Consider the use-case where instead of calling a function such as >> > numpy.dot() I may want to call the appropriate backend directly using >> > the C API as an optimization technique. Is there a straight-forward way >> > to do that ? >> > >> > In a somewhat related line of thought: Is there a way to see what >> > backends are available during Numpy compile-time ? I'm looking for a >> > list of flags to pick ATLAS/OpenBLAS/LAPACK/MKL or any other backend >> > that might be available, combined with variables (compiler and linker >> > flags, notably) I might have to set. Is that information available at >> all ? >> >> NumPy does reveal some information about its configuration and >> numpy.distutils does provide helper methods, but I'm not super >> familiar with it so I'll let others answer that part. >> > > np.show_config() > > Gives: > > lapack_opt_info: > libraries = ['lapack', 'f77blas', 'cblas', 'atlas'] > library_dirs = ['/usr/lib/atlas-base/atlas', '/usr/lib/atlas-base'] > define_macros = [('NO_ATLAS_INFO', -1)] > language = f77 > include_dirs = ['/usr/include/atlas'] > openblas_lapack_info: > NOT AVAILABLE > .... > <etc> > > It's a function with no docstring and not in the html docs (I think), so > that can certainly be improved. > > Ralf > I don't think that show_config is what you want. Those are built time values that aren't necessarily true at run time. For instance, numpy from conda references directories that are not on my machine. Eric
_______________________________________________ NumPy-Discussion mailing list NumPy-Discussion@scipy.org https://mail.scipy.org/mailman/listinfo/numpy-discussion