Package hdf5pickle :: Module base
[hide private]
[frames] | no frames]

Module base

source code

Classes [hide private]
  UnicodeType
unicode(string [, encoding[, errors]]) -> object
  _FileInterface
Internal interface to a tables.File object.
  Pickler
Pickles Python objects to a HDF5 file.
  Unpickler
Unpickles Python objects from a HDF5 file.
  _EmptyClass

Functions [hide private]
  _DEBUG(*args)
  checkflavor(flavor, x=None, y=None)
  _checkNameValidity(name)
Check the validity of the name of a PyTables object, so that PyTables won't spew warnings or exceptions...
  _check_pytables_name(key)
  dump(obj, file, path, type_map=None)
Dump a Python object to an open PyTables HDF5 file.
  load(file, path)
Load a Python object from an open PyTables HDF5 file.
  dump_many(file, desc, type_map=None)
Dump multiple Python objects to an open PyTables HDF5 file, preserving any references between the objects.
  load_many(file, paths)
Load multiple Python objects from the file, preserving any references between them.

Variables [hide private]
  BOOL = 'BB'
  REF = 'RR'
  COMPLEX = 'CC'
  NUMARRAY = 'NA'
  NUMPY = 'NP'
  NUMERIC = 'NU'
  HIGHEST_PROTOCOL = 2
The pickling (programming) protocol supported by this module
  PyStringMap = None
  NoSuchNodeError
  NumericArrayType_native = False
  NumarrayArrayType_native = True
  NumpyArrayType_native = True
  HDF5PICKLE_PROTOCOL = 1
Identifier for the current HDF5 pickling protocol
  pythonIdRE = <_sre.SRE_Pattern object at 0x8350980>
  reservedIdRE = <_sre.SRE_Pattern object at 0x8583260>

Function Details [hide private]

_DEBUG(*args)

source code 
None

checkflavor(flavor, x=None, y=None)

source code 
None

_checkNameValidity(name)

source code 
Check the validity of the name of a PyTables object, so that PyTables won't spew warnings or exceptions...

_check_pytables_name(key)

source code 
None

dump(obj, file, path, type_map=None)

source code 
Dump a Python object to an open PyTables HDF5 file.
Parameters:
  • obj - the object to dump
  • file (tables.File) - where to dump
  • path - path where to dump in the file
  • type_map - mapping of Python basic types (str, int, ...) to numpy types. If None, numpy's default mapping is used.

load(file, path)

source code 
Load a Python object from an open PyTables HDF5 file.
Parameters:
  • file (tables.File) - where to load from
  • path - path to the object in the file
Returns:
loaded object

dump_many(file, desc, type_map=None)

source code 

Dump multiple Python objects to an open PyTables HDF5 file, preserving any references between the objects.

Calling dump(file, path) many times for objects keeping references to each other would result in duplicated data.

Parameters:
  • file (tables.File) - where to dump
  • desc - a list of (path, obj)
  • type_map - mapping of Python basic types (str, int, ...) to numpy types. If None, numpy's default mapping is used.

load_many(file, paths)

source code 

Load multiple Python objects from the file, preserving any references between them.

Calling load(file, path) many times for objects keeping references to each other would result to duplicated data.

Parameters:
  • file (tables.File) - where to dump
  • paths - a list of paths where to load from
Returns:
list of (path, object)

Variables Details [hide private]

BOOL

None
Value:
'BB'                                                                   
      

REF

None
Value:
'RR'                                                                   
      

COMPLEX

None
Value:
'CC'                                                                   
      

NUMARRAY

None
Value:
'NA'                                                                   
      

NUMPY

None
Value:
'NP'                                                                   
      

NUMERIC

None
Value:
'NU'                                                                   
      

HIGHEST_PROTOCOL

The pickling (programming) protocol supported by this module
Value:
2                                                                     
      

PyStringMap

None
Value:
None                                                                  
      

NoSuchNodeError

None
Value:
<class 'tables.exceptions.NoSuchNodeError'>                            
      

NumericArrayType_native

None
Value:
False                                                                  
      

NumarrayArrayType_native

None
Value:
True                                                                   
      

NumpyArrayType_native

None
Value:
True                                                                   
      

HDF5PICKLE_PROTOCOL

Identifier for the current HDF5 pickling protocol
Value:
1                                                                     
      

pythonIdRE

None
Value:
^[a-zA-Z_][a-zA-Z0-9_]*$                                               
      

reservedIdRE

None
Value:
^_[cfgv]_