Data Loaders

qef.io.loaders.histogram_to_point_data(values)[source]

Transform histogram(s) to point data

Parameters:values (ndarray) – Array with histogram data
Returns:Array with point data
Return type:ndarray
qef.io.loaders.load_dave(file_name, to_meV=True)[source]
Parameters:
  • file_name (str) – Path to file
  • to_meV (bool) – Convert energies from micro-eV to mili-eV
Returns:

keys are q(momentum transfer), x(energy or time), y(intensities), and errors(e)

Return type:

dict

qef.io.loaders.load_nexus(file_name)[source]
Parameters:file_name (str) – Absolute path to file
qef.io.loaders.load_nexus_processed(file_name)[source]

Load data from a Mantid Nexus processed file

Parameters:file_name (str) – Path to file
Returns:keys are q(momentum transfer), x(energy or time), y(intensities), and errors(e)
Return type:dict
qef.io.loaders.search_attribute(handle, name, ignore_case=False)[source]

Find HDF5 entries containing a particular attribute

Parameters:
  • handle – Root entry from which to start the search
  • name (str) – Regular expression pattern to search in attributes’ names
Returns:

All entries with a matching attribute name. Each entry of the form (HDF5-instance, (attribute-key, attribute-vale))

Return type:

list