示例#1
0
def print_versions():
    """Print all the versions of software that PyTables relies on."""

    print('-=' * 38)
    print("PyTables version:  %s" % tables.__version__)
    print("HDF5 version:      %s" % tables.which_lib_version("hdf5")[1])
    print("NumPy version:     %s" % numpy.__version__)
    tinfo = tables.which_lib_version("zlib")
    if numexpr.use_vml:
        # Get only the main version number and strip out all the rest
        vml_version = numexpr.get_vml_version()
        vml_version = re.findall("[0-9.]+", vml_version)[0]
        vml_avail = "using VML/MKL %s" % vml_version
    else:
        vml_avail = "not using Intel's VML/MKL"
    print("Numexpr version:   %s (%s)" % (numexpr.__version__, vml_avail))
    if tinfo is not None:
        print("Zlib version:      %s (%s)" % (tinfo[1],
                                              "in Python interpreter"))
    tinfo = tables.which_lib_version("lzo")
    if tinfo is not None:
        print("LZO version:       %s (%s)" % (tinfo[1], tinfo[2]))
    tinfo = tables.which_lib_version("bzip2")
    if tinfo is not None:
        print("BZIP2 version:     %s (%s)" % (tinfo[1], tinfo[2]))
    tinfo = tables.which_lib_version("blosc")
    if tinfo is not None:
        blosc_date = tinfo[2].split()[1]
        print("Blosc version:     %s (%s)" % (tinfo[1], blosc_date))
        blosc_cnames = tables.blosc_compressor_list()
        print("Blosc compressors: %s" % (blosc_cnames,))
    try:
        from Cython.Compiler.Main import Version as Cython_Version
        print('Cython version:    %s' % Cython_Version.version)
    except:
        pass
    print('Python version:    %s' % sys.version)
    print('Platform:          %s' % platform.platform())
    #if os.name == 'posix':
    #    (sysname, nodename, release, version, machine) = os.uname()
    #    print('Platform:          %s-%s' % (sys.platform, machine))
    print('Byte-ordering:     %s' % sys.byteorder)
    print('Detected cores:    %s' % detect_number_of_cores())
    print('Default encoding:  %s' % sys.getdefaultencoding())
    print('Default locale:    (%s, %s)' % locale.getdefaultlocale())
    print('-=' * 38)

    # This should improve readability whan tests are run by CI tools
    sys.stdout.flush()
示例#2
0
def print_versions():
    """Print all the versions of software that PyTables relies on."""

    print('-=' * 38)
    print("PyTables version:  %s" % tables.__version__)
    print("HDF5 version:      %s" % tables.which_lib_version("hdf5")[1])
    print("NumPy version:     %s" % numpy.__version__)
    tinfo = tables.which_lib_version("zlib")
    if numexpr.use_vml:
        # Get only the main version number and strip out all the rest
        vml_version = numexpr.get_vml_version()
        vml_version = re.findall("[0-9.]+", vml_version)[0]
        vml_avail = "using VML/MKL %s" % vml_version
    else:
        vml_avail = "not using Intel's VML/MKL"
    print("Numexpr version:   %s (%s)" % (numexpr.__version__, vml_avail))
    if tinfo is not None:
        print("Zlib version:      %s (%s)" % (tinfo[1],
                                              "in Python interpreter"))
    tinfo = tables.which_lib_version("lzo")
    if tinfo is not None:
        print("LZO version:       %s (%s)" % (tinfo[1], tinfo[2]))
    tinfo = tables.which_lib_version("bzip2")
    if tinfo is not None:
        print("BZIP2 version:     %s (%s)" % (tinfo[1], tinfo[2]))
    tinfo = tables.which_lib_version("blosc")
    if tinfo is not None:
        blosc_date = tinfo[2].split()[1]
        print("Blosc version:     %s (%s)" % (tinfo[1], blosc_date))
        blosc_cnames = tables.blosc_compressor_list()
        print("Blosc compressors: %s" % (blosc_cnames,))
    try:
        from Cython.Compiler.Main import Version as Cython_Version
        print('Cython version:    %s' % Cython_Version.version)
    except:
        pass
    print('Python version:    %s' % sys.version)
    print('Platform:          %s' % platform.platform())
    #if os.name == 'posix':
    #    (sysname, nodename, release, version, machine) = os.uname()
    #    print('Platform:          %s-%s' % (sys.platform, machine))
    print('Byte-ordering:     %s' % sys.byteorder)
    print('Detected cores:    %s' % detect_number_of_cores())
    print('Default encoding:  %s' % sys.getdefaultencoding())
    print('Default locale:    (%s, %s)' % locale.getdefaultlocale())
    print('-=' * 38)

    # This should improve readability whan tests are run by CI tools
    sys.stdout.flush()
示例#3
0
# =======
import warnings
import numpy

from tables import (
    utilsextension, blosc_compressor_list, blosc_compcode_to_compname)
from tables.exceptions import FiltersWarning


# Public variables
# ================
__docformat__ = 'reStructuredText'
"""The format of documentation strings in this module."""

all_complibs = ['zlib', 'lzo', 'bzip2', 'blosc']
all_complibs += ['blosc:%s' % cname for cname in blosc_compressor_list()]


"""List of all compression libraries."""

foreign_complibs = ['szip']
"""List of known but unsupported compression libraries."""

default_complib = 'zlib'
"""The default compression library."""


# Private variables
# =================
_shuffle_flag = 0x1
_fletcher32_flag = 0x2
示例#4
0
# Imports
# =======
import warnings
import numpy

from tables import (utilsextension, blosc_compressor_list,
                    blosc_compcode_to_compname)
from tables.exceptions import FiltersWarning

# Public variables
# ================
__docformat__ = 'reStructuredText'
"""The format of documentation strings in this module."""

all_complibs = ['zlib', 'lzo', 'bzip2', 'blosc']
all_complibs += ['blosc:%s' % cname for cname in blosc_compressor_list()]
"""List of all compression libraries."""

foreign_complibs = ['szip']
"""List of known but unsupported compression libraries."""

default_complib = 'zlib'
"""The default compression library."""

# Private variables
# =================
_shuffle_flag = 0x1
_fletcher32_flag = 0x2
_rounding_flag = 0x4