$10 GRAYBYTE WORDPRESS FILE MANAGER $94

SERVER : premium201.web-hosting.com #1 SMP Wed Mar 26 12:08:09 UTC 2025
SERVER IP : 104.21.15.130 | ADMIN IP 216.73.216.85
OPTIONS : CRL = ON | WGT = ON | SDO = OFF | PKEX = OFF
DEACTIVATED : NONE

/opt/cloudlinux/venv/lib/python3.11/site-packages/numpy/linalg/

HOME
Current File : /opt/cloudlinux/venv/lib/python3.11/site-packages/numpy/linalg//setup.py
import os
import sys
import sysconfig

def configuration(parent_package='', top_path=None):
    from numpy.distutils.misc_util import Configuration
    from numpy.distutils.system_info import get_info, system_info
    config = Configuration('linalg', parent_package, top_path)

    config.add_subpackage('tests')

    # Configure lapack_lite

    src_dir = 'lapack_lite'
    lapack_lite_src = [
        os.path.join(src_dir, 'python_xerbla.c'),
        os.path.join(src_dir, 'f2c_z_lapack.c'),
        os.path.join(src_dir, 'f2c_c_lapack.c'),
        os.path.join(src_dir, 'f2c_d_lapack.c'),
        os.path.join(src_dir, 'f2c_s_lapack.c'),
        os.path.join(src_dir, 'f2c_lapack.c'),
        os.path.join(src_dir, 'f2c_blas.c'),
        os.path.join(src_dir, 'f2c_config.c'),
        os.path.join(src_dir, 'f2c.c'),
    ]
    all_sources = config.paths(lapack_lite_src)

    if os.environ.get('NPY_USE_BLAS_ILP64', "0") != "0":
        lapack_info = get_info('lapack_ilp64_opt', 2)
    else:
        lapack_info = get_info('lapack_opt', 0)  # and {}

    use_lapack_lite = not lapack_info

    if use_lapack_lite:
        # This makes numpy.distutils write the fact that lapack_lite
        # is being used to numpy.__config__
        class numpy_linalg_lapack_lite(system_info):
            def calc_info(self):
                info = {'language': 'c'}
                size_t_size = sysconfig.get_config_var("SIZEOF_SIZE_T")
                if size_t_size:
                    maxsize = 2**(size_t_size - 1) - 1
                else:
                    # We prefer using sysconfig as it allows cross-compilation
                    # but the information may be missing (e.g. on windows).
                    maxsize = sys.maxsize
                if maxsize > 2**32:
                    # Build lapack-lite in 64-bit integer mode.
                    # The suffix is arbitrary (lapack_lite symbols follow it),
                    # but use the "64_" convention here.
                    info['define_macros'] = [
                        ('HAVE_BLAS_ILP64', None),
                        ('BLAS_SYMBOL_SUFFIX', '64_')
                    ]
                self.set_info(**info)

        lapack_info = numpy_linalg_lapack_lite().get_info(2)

    def get_lapack_lite_sources(ext, build_dir):
        if use_lapack_lite:
            print("### Warning:  Using unoptimized lapack ###")
            return all_sources
        else:
            if sys.platform == 'win32':
                print("### Warning:  python_xerbla.c is disabled ###")
                return []
            return [all_sources[0]]

    config.add_extension(
        'lapack_lite',
        sources=['lapack_litemodule.c', get_lapack_lite_sources],
        depends=['lapack_lite/f2c.h'],
        extra_info=lapack_info,
    )

    # umath_linalg module
    config.add_extension(
        '_umath_linalg',
        sources=['umath_linalg.cpp', get_lapack_lite_sources],
        depends=['lapack_lite/f2c.h'],
        extra_info=lapack_info,
        libraries=['npymath'],
    )
    config.add_data_files('*.pyi')
    return config

if __name__ == '__main__':
    from numpy.distutils.core import setup
    setup(configuration=configuration)


Current_dir [ NOT WRITEABLE ] Document_root [ WRITEABLE ]


[ Back ]
NAME
SIZE
LAST TOUCH
USER
CAN-I?
FUNCTIONS
..
--
11 Feb 2026 9.30 AM
root / root
0755
__pycache__
--
11 Feb 2026 9.33 AM
root / root
0755
tests
--
11 Feb 2026 9.30 AM
root / root
0755
__init__.py
1.771 KB
20 Jan 2026 1.01 PM
root / root
0644
__init__.pyi
0.605 KB
20 Jan 2026 1.01 PM
root / root
0644
_umath_linalg.cpython-311-x86_64-linux-gnu.so
215.914 KB
20 Jan 2026 1.18 PM
root / root
0755
lapack_lite.cpython-311-x86_64-linux-gnu.so
30.594 KB
20 Jan 2026 1.18 PM
root / root
0755
linalg.py
88.792 KB
20 Jan 2026 1.01 PM
root / root
0644
linalg.pyi
7.329 KB
20 Jan 2026 1.01 PM
root / root
0644
setup.py
3.135 KB
20 Jan 2026 1.01 PM
root / root
0644

GRAYBYTE WORDPRESS FILE MANAGER @ 2025 CONTACT ME
Static GIF