[h5py] 98/455: Docs and setup kwds
Ghislain Vaillant
ghisvail-guest at moszumanska.debian.org
Thu Jul 2 18:19:21 UTC 2015
This is an automated email from the git hooks/post-receive script.
ghisvail-guest pushed a commit to annotated tag 1.3.0
in repository h5py.
commit f253feca57514c2803ed669ecf2b29cf9b14c6b6
Author: andrewcollette <andrew.collette at gmail.com>
Date: Tue Aug 12 04:58:44 2008 +0000
Docs and setup kwds
---
docs/source/build.rst | 8 ++++----
docs/source/index.rst | 15 ++++-----------
docs/source/threads.rst | 13 ++++++++-----
docs/windows_build.txt | 45 ---------------------------------------------
h5py/__init__.py | 2 +-
h5py/h5.pyx | 10 +++++-----
h5py/h5t.pyx | 4 ++--
setup.py | 43 ++++++++++++++++++++++++++++++++++++++++---
8 files changed, 64 insertions(+), 76 deletions(-)
diff --git a/docs/source/build.rst b/docs/source/build.rst
index 98b800e..aed82c5 100644
--- a/docs/source/build.rst
+++ b/docs/source/build.rst
@@ -118,13 +118,13 @@ Compile h5py
If you get the message "DLL import failed: configuration incorrect" or
some variant, you need to install the package
"Microsoft Visual C++ 2005 SP1 Redistributable" from Microsoft's
- web site. This is needed by the pre-built HDF5 library for some
- reason.
+ web site. This is because the pre-compiled HDF5 library requires
+ a specific C runtime library distributed with Visual Studio.
5. Install via ``python setup.py install --hdf5=C:\hdf5``.
-After you're done, you can delete the ``C:\hdf5`` directory. It isn't needed at
-runtime.
+After you're done, you can delete the ``C:\hdf5`` and ``C:\h5py`` directories.
+They aren't needed at runtime.
diff --git a/docs/source/index.rst b/docs/source/index.rst
index 4d67bfd..0ddd7c5 100644
--- a/docs/source/index.rst
+++ b/docs/source/index.rst
@@ -1,6 +1,4 @@
-.. h5py documentation master file, created by sphinx-quickstart on Tue Aug 5 14:14:15 2008.
- You can adapt this file completely to your liking, but it should at least
- contain the root `toctree` directive.
+
Python bindings for the HDF5 library
====================================
@@ -23,11 +21,13 @@ Important links:
* `Main project page`__
* `Auto-generated API docs`__
* `Google Code development page`__
+ * `Windows installers`__
* Mail: "h5py" at the domain "alfven" dot "org"
__ http://h5py.alfven.org
-__ http://h5py.alfven.org/docs
+__ http://h5py.alfven.org/docs/
__ http://h5py.googlecode.com
+__ http://h5py.alfven.org/windows/
Contents:
@@ -38,10 +38,3 @@ Contents:
threads
-Indices and tables
-==================
-
-* :ref:`genindex`
-* :ref:`modindex`
-* :ref:`search`
-
diff --git a/docs/source/threads.rst b/docs/source/threads.rst
index 1efd03f..9cb8352 100644
--- a/docs/source/threads.rst
+++ b/docs/source/threads.rst
@@ -29,7 +29,8 @@ Non-Blocking Routines
By default, all low-level HDF5 routines will lock the entire interpreter
until they complete, even in the case of lengthy I/O operations. This is
-unnecessarily restrictive, as it means even non-HDF5 threads cannot execute.
+unnecessarily restrictive, as it means even non-HDF5 threads cannot execute
+while a lengthy HDF5 read or write is in progress.
When the package is compiled with the option ``--io-nonblock``, a few C methods
involving I/O will release the global interpreter lock. These methods always
@@ -42,11 +43,13 @@ However, this defeats the thread safety provided by the GIL. If another thread
skips acquiring the HDF5 lock and blindly calls a low-level HDF5 routine while
such I/O is in progress, the results are undefined. In the worst case,
irreversible data corruption and/or a crash of the interpreter is possible.
-Therefore, it's very important to always acquire the global HDF5 lock before
-calling into the h5py.h5* API when all the following are true:
- 1. More than one thread is performing HDF5 operations
- 2. Non-blocking I/O is enabled
+**You must acquire the global lock (h5py.config.lock) when all the following
+are true:**
+
+ 1. You are using the low-level (h5py.h5*) API
+ 2. More than one thread is performing HDF5 operations
+ 3. Non-blocking I/O (``--io-nonblock``) is enabled
This is not an issue for the h5py.highlevel components (Dataset, Group,
File objects, etc.) as they acquire the lock automatically.
diff --git a/docs/windows_build.txt b/docs/windows_build.txt
deleted file mode 100644
index 2e781c6..0000000
--- a/docs/windows_build.txt
+++ /dev/null
@@ -1,45 +0,0 @@
-Building on Windows (experimental)
-
-Python setup:
-1. Install Python 2.5
-2. Go into c:\Python25\Lib\distutils and create distutils.cfg containing:
-[build]
-compiler=mingw32
-
-MinGW setup:
-1. Download and install MinGW to C:\MinGW
-2. Download "pexports" (google for it) utility and put in c:\MinGW\bin
-3. Add C:\MinGW\bin to Windows PATH
-
-HDF5 setup:
-You MUST use the versions build with VS2005!
-
-1. Download pre-build HDF5 1.8.1 (with DLLS) compiled with VS2005:
-ftp://ftp.hdfgroup.org/HDF5/current/bin/windows/5-181-win-vs2005.zip
-2. Download SZIP
-ftp://ftp.hdfgroup.org/lib-external/szip/2.1/bin/windows/szip21-vs2005-enc.zip
-3. Download ZLIB
-ftp://ftp.hdfgroup.org/lib-external/zlib/1.2/bin/windows/zlib123-vs2005.zip
-
-4. Unzip HDF5 to "C:\h181" You should now have C:\h181\include, etc.
-5. Open SZIP and ZLIB archives and copy their dlls to "C:\h181\dll"
-
-6. Download and install "Microsoft Visual C++ 2005 SP1 Redistributable Package"
- It must be EXACTLY this, note it's **SP1**, or the HDF5 dll won't load.
- This is available from Microsoft's web site.
-
-Create import library
-1. Open a terminal and cd to C:\h181\dll
-2. Run "pexports hdf5dll.dll > hdf5dll.def" to get the list of HDF5 exports
-3. Run "dlltool -D hdf5dll.dll -d hdf5dll.def -l hdf5dll.dll.a" to create
- an import library that MinGW can handle.
-3. Create the directory C:\h181\dll2
-4. Copy the new file c:\h181\dll\hdf5dll.dll.a into c:\h181\dll2
-5. Add the directory c:\h181\dll (NOT c:\h181\dll2) to your Windows PATH
-
-Compile h5py
-1. Extract h5py to c:\h5py
-2. Run python setup.py build --hdf5=c:\h181
-3. Run python setup.py test --hdf5=c:\h181
-
-Isn't Windows easy to use?
diff --git a/h5py/__init__.py b/h5py/__init__.py
index cb1499c..08030b2 100644
--- a/h5py/__init__.py
+++ b/h5py/__init__.py
@@ -14,7 +14,7 @@
__doc__ = \
"""
- This is the h5py package, a Python interface to the NCSA HDF5
+ This is the h5py package, a Python interface to the HDF5
scientific data format.
Version %s
diff --git a/h5py/h5.pyx b/h5py/h5.pyx
index e1403f1..6d1604c 100644
--- a/h5py/h5.pyx
+++ b/h5py/h5.pyx
@@ -74,18 +74,18 @@ cdef class H5PYConfig:
Global configuration object for the h5py package.
Properties:
- lock Global reentrant lock for threading
- RLock Constructor for lock
+ lock Global reentrant lock for threading support
compile_opts Dictionary of compile-time flags
"""
def __init__(self):
self._complex_names = ('r','i')
- self.compile_opts = {'IO_NONBLOCK': H5PY_NONBLOCK}
+ self.compile_opts = {'IO_NONBLOCK': H5PY_NONBLOCK,
+ 'DEBUG': H5PY_DEBUG}
self._lock = threading.RLock()
property lock:
- """ Reentrant lock for threading (default is threading.RLock()).
+ """ Reentrant lock instance; default is threading.RLock().
Whatever you provide MUST support the Python context manager
protocol, and provide the methods acquire() and release(). It
@@ -106,7 +106,7 @@ cdef class H5PYConfig:
current_lock.release()
property complex_names:
- """ Tuple (real, img) indicating names used to save complex types.
+ """ Unused
"""
def __get__(self):
return self._complex_names
diff --git a/h5py/h5t.pyx b/h5py/h5t.pyx
index 01a5172..79c99e4 100644
--- a/h5py/h5t.pyx
+++ b/h5py/h5t.pyx
@@ -51,8 +51,8 @@
4. Variable-length types
- VLEN types, including VLEN strings, are not currently supported.
- This may eventually change.
+ VLEN types can be manipulated, but reading and writing data in VLEN
+ format is not supported. This applies to VLEN strings as well.
"""
include "conditions.pxi"
diff --git a/setup.py b/setup.py
index f6d736e..827d936 100644
--- a/setup.py
+++ b/setup.py
@@ -249,7 +249,8 @@ DEF H5PY_NONBLOCK = %(IO_NONBLOCK)d
except ImportError:
fatal("Pyrex recompilation required, but Pyrex not installed.")
else:
- print "Skipping Pyrex..."
+ pass
+ #print "Skipping Pyrex..."
# One extension is built for each module
extensions = []
@@ -344,6 +345,8 @@ class dev(Command):
if retval != 0:
warn("Could not run Sphinx doc generator")
else:
+ if op.exists('docs/manual-html'):
+ shutil.rmtree('docs/manual-html')
shutil.copytree('docs/build/html', 'docs/manual-html')
# New commands for setup (e.g. "python setup.py test")
@@ -358,17 +361,51 @@ else:
# print "%-20s %s" % (key, opts.__dict__[key])
-# Run setup
+cls_txt = \
+"""
+Development Status :: 4 - Beta
+Intended Audience :: Developers
+Intended Audience :: Information Technology
+Intended Audience :: Science/Research
+License :: OSI Approved :: BSD License
+Programming Language :: Python
+Topic :: Scientific/Engineering
+Topic :: Software Development :: Libraries :: Python Modules
+Operating System :: Unix
+Operating System :: POSIX :: Linux
+Operating System :: MacOS :: MacOS X
+Operating System :: Microsoft :: Windows
+"""
+
+short_desc = "General-purpose Python bindings for the HDF5 library"
+
+long_desc = \
+"""
+The h5py package provides both a high- and low-level interface to the HDF5
+library from Python. The low-level interface is intended to be a complete
+wrapping of the HDF5 API, while the high-level component supports Python-style
+object-oriented access to HDF5 files, datasets and groups.
+
+A strong emphasis on automatic conversion between Python (Numpy) datatypes and
+data structures and their HDF5 equivalents vastly simplifies the process of
+reading and writing data from Python.
+"""
+
setup(
name = NAME,
version = VERSION,
+ description = short_desc,
+ long_description = long_desc,
+ classifiers = [x for x in cls_txt.split("\n") if x],
author = 'Andrew Collette',
+ author_email = '"h5py" at the domain "alfven.org"',
+ maintainer = 'Andrew Collette',
+ maintainer_email = '"h5py" at the domain "alfven.org"',
url = 'h5py.alfven.org',
packages = ['h5py','h5py.tests'],
package_data = package_data,
ext_modules = extensions,
requires = ['numpy (>=1.0.3)'],
- provides = ['h5py'],
cmdclass = CMD_CLASS
)
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/h5py.git
More information about the debian-science-commits
mailing list