当前位置: 首页>>代码示例>>Python>>正文


Python numpy.get_include方法代码示例

本文整理汇总了Python中numpy.get_include方法的典型用法代码示例。如果您正苦于以下问题:Python numpy.get_include方法的具体用法?Python numpy.get_include怎么用?Python numpy.get_include使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在numpy的用法示例。


在下文中一共展示了numpy.get_include方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: configuration

# 需要导入模块: import numpy [as 别名]
# 或者: from numpy import get_include [as 别名]
def configuration(parent_package='', top_path=None):
    import numpy
    from numpy.distutils.misc_util import Configuration

    config = Configuration('stimuli', parent_package, top_path)
    libraries = []
    if os.name == 'posix':
        libraries.append('m')

    if platform.python_implementation() != 'PyPy':
        config.add_extension('_base',
                             sources=['_base.pyx'],
                             include_dirs=[numpy.get_include()],
                             libraries=libraries)
    config.add_subpackage('tests')
    config.add_data_dir('data')

    return config 
开发者ID:pulse2percept,项目名称:pulse2percept,代码行数:20,代码来源:setup.py

示例2: configuration

# 需要导入模块: import numpy [as 别名]
# 或者: from numpy import get_include [as 别名]
def configuration(parent_package='', top_path=None):
    import numpy
    from numpy.distutils.misc_util import Configuration

    config = Configuration('models', parent_package, top_path)
    libraries = []
    if os.name == 'posix':
        libraries.append('m')

    if platform.python_implementation() != 'PyPy':
        config.add_extension('_beyeler2019',
                             sources=['_beyeler2019.pyx'],
                             include_dirs=[numpy.get_include()],
                             libraries=libraries)
        config.add_extension('_horsager2009',
                             sources=['_horsager2009.pyx'],
                             include_dirs=[numpy.get_include()],
                             libraries=libraries)
        config.add_extension('_nanduri2012',
                             sources=['_nanduri2012.pyx'],
                             include_dirs=[numpy.get_include()],
                             libraries=libraries)
    config.add_subpackage("tests")

    return config 
开发者ID:pulse2percept,项目名称:pulse2percept,代码行数:27,代码来源:setup.py

示例3: configuration

# 需要导入模块: import numpy [as 别名]
# 或者: from numpy import get_include [as 别名]
def configuration(parent_package="", top_path=None):
    config = Configuration("metrics", parent_package, top_path)

    cblas_libs, blas_info = get_blas_info()
    if os.name == 'posix':
        cblas_libs.append('m')

    config.add_extension("_kernel_fast",
                         sources=["_kernel_fast.c"],
                         include_dirs=[os.path.join('..', 'src', 'cblas'),
                                       numpy.get_include(),
                                       blas_info.pop('include_dirs', [])],
                         libraries=cblas_libs,
                         extra_compile_args=blas_info.pop('extra_compile_args',
                                                          []),
                         **blas_info)
    config.add_subpackage('tests')

    return config 
开发者ID:tgsmith61591,项目名称:skutil,代码行数:21,代码来源:setup.py

示例4: configuration

# 需要导入模块: import numpy [as 别名]
# 或者: from numpy import get_include [as 别名]
def configuration(parent_package='', top_path=None):
    from numpy import get_include
    from numpy.distutils.system_info import get_info, NotFoundError
    from numpy.distutils.misc_util import Configuration

    lapack_opt = get_info('lapack_opt')

    if not lapack_opt:
        raise NotFoundError('no lapack/blas resources found')

    config = Configuration('_trlib', parent_package, top_path)
    config.add_extension('_trlib',
                         sources=['_trlib.c', 'trlib_krylov.c',
                                  'trlib_eigen_inverse.c', 'trlib_leftmost.c',
                                  'trlib_quadratic_zero.c', 'trlib_tri_factor.c'],
                         include_dirs=[get_include(), 'trlib'],
                         extra_info=lapack_opt,
                         )
    return config 
开发者ID:ryfeus,项目名称:lambda-packs,代码行数:21,代码来源:setup.py

示例5: configuration

# 需要导入模块: import numpy [as 别名]
# 或者: from numpy import get_include [as 别名]
def configuration(parent_package="", top_path=None):
    cblas_libs, blas_info = get_blas_info()

    # Use this rather than cblas_libs so we don't fail on Windows
    libraries = []
    if os.name == 'posix':
        cblas_libs.append('m')
        libraries.append('m')

    config = Configuration("utils", parent_package, top_path)
    config.add_extension("_array",
                         sources=["_array.pyx"],
                         include_dirs=[numpy.get_include(),
                                       blas_info.pop('include_dirs', [])],
                         libraries=libraries,
                         extra_compile_args=blas_info.pop(
                             'extra_compile_args', []),
                         **blas_info)

    config.add_subpackage('tests')

    return config 
开发者ID:alkaline-ml,项目名称:pmdarima,代码行数:24,代码来源:setup.py

示例6: configuration

# 需要导入模块: import numpy [as 别名]
# 或者: from numpy import get_include [as 别名]
def configuration(parent_package="", top_path=None):
    cblas_libs, blas_info = get_blas_info()

    # Use this rather than cblas_libs so we don't fail on Windows
    libraries = []
    if os.name == 'posix':
        cblas_libs.append('m')
        libraries.append('m')

    config = Configuration("arima", parent_package, top_path)
    config.add_extension("_arima",
                         sources=["_arima.pyx"],
                         include_dirs=[numpy.get_include(),
                                       # Should this be explicitly included?:
                                       '_arima_fast_helpers.h',
                                       blas_info.pop('include_dirs', [])],
                         libraries=libraries,
                         extra_compile_args=blas_info.pop(
                             'extra_compile_args', []),
                         **blas_info)

    config.add_subpackage('tests')
    config.add_data_dir('tests/data')

    return config 
开发者ID:alkaline-ml,项目名称:pmdarima,代码行数:27,代码来源:setup.py

示例7: configuration

# 需要导入模块: import numpy [as 别名]
# 或者: from numpy import get_include [as 别名]
def configuration(parent_package="", top_path=None):
    cblas_libs, blas_info = get_blas_info()

    # Use this rather than cblas_libs so we don't fail on Windows
    libraries = []
    if os.name == 'posix':
        cblas_libs.append('m')
        libraries.append('m')

    config = Configuration("exog", parent_package, top_path)
    config.add_extension("_fourier",
                         sources=["_fourier.pyx"],
                         include_dirs=[numpy.get_include(),
                                       blas_info.pop('include_dirs', [])],
                         libraries=libraries,
                         extra_compile_args=blas_info.pop(
                             'extra_compile_args', []),
                         **blas_info)

    config.add_subpackage('tests')

    return config 
开发者ID:alkaline-ml,项目名称:pmdarima,代码行数:24,代码来源:setup.py

示例8: configuration

# 需要导入模块: import numpy [as 别名]
# 或者: from numpy import get_include [as 别名]
def configuration(parent_package="", top_path=None):
    config = Configuration("metrics", parent_package, top_path)

    libraries = []
    if os.name == 'posix':
        libraries.append('m')

    config.add_extension("_confusion_matrix",
                         sources=["_confusion_matrix.pyx"],
                         include_dirs=[numpy.get_include()],
                         libraries=libraries,
                         extra_compile_args=["-O3"])
    config.add_extension("_classification_performance_evaluator",
                         sources=["_classification_performance_evaluator.pyx"],
                         include_dirs=[numpy.get_include()],
                         libraries=libraries,
                         extra_compile_args=["-O3"])

    return config 
开发者ID:scikit-multiflow,项目名称:scikit-multiflow,代码行数:21,代码来源:setup.py

示例9: finalize_options

# 需要导入模块: import numpy [as 别名]
# 或者: from numpy import get_include [as 别名]
def finalize_options(self):
                _build_ext.finalize_options(self)
                # Prevent numpy from thinking it is still in its setup process:
                try:
                    __builtins__.__NUMPY_SETUP__ = False
                except:
                    try:
                        # For python 3
                        import builtins
                        builtins.__NUMPY_SETUP__ = False
                    except:
                        warn("Skipping numpy hack; if installation fails, try installing numpy first")
                import numpy
                self.include_dirs.append(numpy.get_include())
                if numpy.__dict__.get('quaternion') is not None:
                    from distutils.errors import DistutilsError
                    raise DistutilsError('The target NumPy already has a quaternion type') 
开发者ID:moble,项目名称:quaternion,代码行数:19,代码来源:setup.py

示例10: configuration

# 需要导入模块: import numpy [as 别名]
# 或者: from numpy import get_include [as 别名]
def configuration(parent_package='', top_path=None):
    import numpy
    from numpy.distutils.misc_util import Configuration

    config = Configuration('csgraph', parent_package, top_path)

    config.add_data_dir('tests')

    config.add_extension('_shortest_path',
         sources=['_shortest_path.c'],
         include_dirs=[numpy.get_include()])

    config.add_extension('_traversal',
         sources=['_traversal.c'],
         include_dirs=[numpy.get_include()])

    config.add_extension('_min_spanning_tree',
         sources=['_min_spanning_tree.c'],
         include_dirs=[numpy.get_include()])

    config.add_extension('_tools',
         sources=['_tools.c'],
         include_dirs=[numpy.get_include()])

    return config 
开发者ID:ktraunmueller,项目名称:Computable,代码行数:27,代码来源:setup.py

示例11: run

# 需要导入模块: import numpy [as 别名]
# 或者: from numpy import get_include [as 别名]
def run(self):
        # add numpy headers
        import numpy
        self.include_dirs.append(numpy.get_include())

        # add dimod headers
        include = os.path.join(os.path.dirname(__file__), 'dimod', 'include')
        self.include_dirs.append(include)

        if self.build_tests:

            test_extensions = [Extension('*', ['tests/test_*'+ext])]
            if USE_CYTHON:
                test_extensions = cythonize(test_extensions,
                                            # annotate=True
                                            )
            self.extensions.extend(test_extensions)

        super().run() 
开发者ID:dwavesystems,项目名称:dimod,代码行数:21,代码来源:setup.py

示例12: configuration

# 需要导入模块: import numpy [as 别名]
# 或者: from numpy import get_include [as 别名]
def configuration(parent_package='', top_path=None):
    import numpy
    from numpy.distutils.misc_util import Configuration

    config = Configuration('feature_extraction', parent_package, top_path)
    libraries = []
    if os.name == 'posix':
        libraries.append('m')

    if platform.python_implementation() != 'PyPy':
        config.add_extension('_hashing',
                             sources=['_hashing.pyx'],
                             include_dirs=[numpy.get_include()],
                             libraries=libraries)
    config.add_subpackage("tests")

    return config 
开发者ID:PacktPublishing,项目名称:Mastering-Elasticsearch-7.0,代码行数:19,代码来源:setup.py

示例13: configuration

# 需要导入模块: import numpy [as 别名]
# 或者: from numpy import get_include [as 别名]
def configuration(parent_package="", top_path=None):
    from numpy.distutils.misc_util import Configuration

    config = Configuration("manifold", parent_package, top_path)

    libraries = []
    if os.name == 'posix':
        libraries.append('m')

    config.add_extension("_utils",
                         sources=["_utils.pyx"],
                         include_dirs=[numpy.get_include()],
                         libraries=libraries,
                         extra_compile_args=["-O3"])

    config.add_extension("_barnes_hut_tsne",
                         sources=["_barnes_hut_tsne.pyx"],
                         include_dirs=[numpy.get_include()],
                         libraries=libraries,
                         extra_compile_args=['-O3'])

    config.add_subpackage('tests')

    return config 
开发者ID:PacktPublishing,项目名称:Mastering-Elasticsearch-7.0,代码行数:26,代码来源:setup.py

示例14: configuration

# 需要导入模块: import numpy [as 别名]
# 或者: from numpy import get_include [as 别名]
def configuration(parent_package="", top_path=None):
    config = Configuration("decomposition", parent_package, top_path)

    libraries = []
    if os.name == 'posix':
        libraries.append('m')

    config.add_extension("_online_lda",
                         sources=["_online_lda.pyx"],
                         include_dirs=[numpy.get_include()],
                         libraries=libraries)

    config.add_extension('cdnmf_fast',
                         sources=['cdnmf_fast.pyx'],
                         include_dirs=[numpy.get_include()],
                         libraries=libraries)

    config.add_subpackage("tests")

    return config 
开发者ID:PacktPublishing,项目名称:Mastering-Elasticsearch-7.0,代码行数:22,代码来源:setup.py

示例15: configuration

# 需要导入模块: import numpy [as 别名]
# 或者: from numpy import get_include [as 别名]
def configuration(parent_package='', top_path=None):
    import numpy
    from numpy.distutils.misc_util import Configuration

    config = Configuration('preprocessing', parent_package, top_path)
    libraries = []
    if os.name == 'posix':
        libraries.append('m')

    config.add_extension('_csr_polynomial_expansion',
                         sources=['_csr_polynomial_expansion.pyx'],
                         include_dirs=[numpy.get_include()],
                         libraries=libraries)

    config.add_subpackage('tests')

    return config 
开发者ID:PacktPublishing,项目名称:Mastering-Elasticsearch-7.0,代码行数:19,代码来源:setup.py


注:本文中的numpy.get_include方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。