Home | Trees | Indices | Help |
|
---|
|
This module provides a bunch of user-friendly wrappers to the HDF5 data format, for reading and writing SWIG-bound TimeSeries and FrequencySeries objects from LAL. Issues should be raised on redmine: https://bugs.ligo.org/redmine/projects/lalsuite
Version: 8cbd1b7187ce3ed9a825d6ed11cc432f3cfde9a5
Date: 2017-12-05 15:29:36 +0000
Author: Duncan M. Macleod <duncan.macleod@ligo.org>
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|
|||
_numpy_lal_typemap = {numpy.int16: lal.LAL_I2_TYPE_CODE, numpy
|
|||
_lal_numpy_typemap = dict((v, k) for k, v in _numpy_lal_typema
|
|
Read a 1-D array from an HDF5 file into a LAL TimeSeries. Returns SWIG-bound LAL TimeSeries. Arguments: h5file : [ h5py.File | str ] open HDF5 file object, or path to HDF5 file on disk. name : str name of data object in HDF5 file relative in it's group. Keyword arguments: group : str name of HDF5 Group containing data object required. start : LIGOTimeGPS GPS start time of data requested, defaults to first data point. duration : float length of data (seconds) requested, default to all data. datatype : int LAL typecode for output datatype, defaults to type of data found. |
Read FrequencySeries object from HDF5 file. Returns SWIG-bound LAL FrequencySeries. Arguments: h5file : [ h5py.File | str ] open HDF5 file object, or path to HDF5 file on disk. name : str name of data object in HDF5 file relative in it's group. Keyword arguments: group : str name of HDF5 Group containing data object required. fmin : float lower frequency bound on data returned fmax : float upper frequency bound on data returned datatype : int LAL typecode for output datatype, defaults to type of data found. |
Read VectorSequence object from HDF5 file. Returns SWIG-bound LAL VectorSequence, LIGOTimeGPS epoch, float deltaT, float f0, float deltaF. Arguments: h5file : [ h5py.File | str ] open HDF5 file object, or path to HDF5 file on disk. name : str name of data object in HDF5 file relative in it's group. Keyword arguments: group : str name of HDF5 Group containing data object required. start : LIGOTimeGPS GPS start time of data requested, defaults to first data point. duration : float length of data (seconds) requested, default to all data. fmin : float lower frequency bound on data returned fmax : float upper frequency bound on data returned datatype : int LAL typecode for output datatype, defaults to type of data found. |
Read numpy.ndarray from h5py.File object h5file. Returns numpy.ndarray and metadata dict. Arguments: h5file : [ h5py.File | str ] open HDF5 file object, or path to HDF5 file on disk. name : str name of data object in HDF5 file relative in it's group. Keyword arguments: group : str name of HDF5 Group containing data object required. |
Write TimeSeries object to the given h5py.File object h5file. No return. Arguments: h5file : h5py.File open HDF5 file object series : TimeSeries SWIG-bound LAL TimeSeries object Keyword arguments: group : str name of HDF5 Group to write to, group is generated if required. All other keyword arguments are passed to h5py.highlevel.Group.create_dataset. |
Write FrequencySeries object to the given h5py.File object h5file. No return. Arguments: h5file : h5py.File open HDF5 file object series : FrequencySeries SWIG-bound LAL FrequencySeries object Keyword arguments: group : str name of HDF5 Group to write to, group is generated if required. All other keyword arguments are passed to h5py.highlevel.Group.create_dataset. |
Write {Time,Frequency}Series object to a new data set in the given h5py.Group object h5group. Returns h5py.highlevel.Dataset. Arguments: h5group : h5py.highlevel.Group Group object inside an HDF5 file series : [ TimeSeries | FrequencySeries ] LAL Time or FrequencySeries object All kwargs are passed to h5py.highlevel.Group.create_dataset. |
Write the given numpy array object to a new data set in the given h5py.highlevel.Group object h5group, including each element in the metadata dict. Returns h5py.highlevel.Dataset. Arguments: h5group : h5py.highlevel.Group Group object inside an HDF5 file name : str descriptive name for the new dataset. array: numpy.ndarray data object to write to dataset Keyword arguments: metadata: dict dict containing metadata to write as attributes in the dataset, default={} (empty) All kwargs are passed to h5py.highlevel.Group.create_dataset. |
Helper to return a group from an h5py.File object, creating all parents and the group itself if needed. Returns a new h5py.highlevel.Group, except in the special case of group=None, in which case the original h5py.File is returned. Argument: h5file : [ h5py.File | str ] open HDF5 file object, or path to HDF5 file on disk. group : str name of Group to create. If a composite group is given (e.g. "/data/spectra") the full tree will be generated as appropriate. |
|
_numpy_lal_typemap
|
_lal_numpy_typemap
|
Home | Trees | Indices | Help |
|
---|
Generated by Epydoc 3.0.1 on Tue Dec 12 01:21:41 2017 | http://epydoc.sourceforge.net |