numpy.show_config

numpy.show_config()[源代码]

显示构建NumPy的系统中的库。

打印有关NumPy构建所基于的系统中的各种资源(库、库目录、包含目录等)的信息。

参见

get_include

返回包含NumPy C头文件的目录。

笔记

指定要打印的信息的类在 numpy.distutils.system_info 模块。

信息可能包括:

  • language :用于编写库的语言(主要是C或f77)

  • libraries :在系统中找到的库的名称

  • library_dirs :包含库的目录

  • include_dirs :包含库头文件的目录

  • src_dirs :包含库源文件的目录

  • define_macros: preprocessor macros used by distutils.setup

实例

>>> import numpy as np
>>> np.show_config()
blas_opt_info:
    language = c
    define_macros = [('HAVE_CBLAS', None)]
    libraries = ['openblas', 'openblas']
    library_dirs = ['/usr/local/lib']