easyvvuq.decoders package

Submodules

easyvvuq.decoders.hdf5 module

A Decoder for HDF5 format files.

class easyvvuq.decoders.hdf5.HDF5(target_filename, output_columns)[source]

Bases: object

HDF5 Decoder.

Parameters:
  • target_filename (str) – Filename of an HDF5 file to decode.
  • ouput_columns (list) – A list of column names that will be selected to appear in the output.
parse_sim_output(run_info={})[source]

Parses the HDF5 file and converts it to the EasyVVUQ internal dictionary based format. The file is parsed in such a way that each column will appear as a vector QoI in the output dictionary.

For example if the file contains the following data a,b 1,2 3,4

And both a and b are specified as output_columns the output will look as follows {‘a’: [1, 3], ‘b’: [2, 4]}.

Parameters:run_info (dict) – Information about the run (used to retrieve construct the absolute path to the CSV file that needs decoding.

easyvvuq.decoders.json module

A basic JSON format decoder.

Will read a JSON file and will output select values. Values have to be either numeric or lists. In case of lists it will treat those as vector-valued quantities of interest.

class easyvvuq.decoders.json.JSONDecoder(target_filename, output_columns)[source]

Bases: object

parse_sim_output(run_info={})[source]

easyvvuq.decoders.simple_csv module

A Decoder for CSV format files.

class easyvvuq.decoders.simple_csv.SimpleCSV(target_filename, output_columns, dialect='excel')[source]

Bases: object

CSV Decoder.

Parameters:
  • target_filename (str) – Filename of a CSV file to decode.
  • ouput_columns (list) – A list of column names that will be selected to appear in the output.
parse_sim_output(run_info={})[source]

Parses the CSV file and converts it to the EasyVVUQ internal dictionary based format. The file is parsed in such a way that each column will appear as a vector QoI in the output dictionary.

For example if the file contains the following data a,b 1,2 3,4

And both a and b are specified as output_columns the output will look as follows {‘a’: [1, 3], ‘b’: [2, 4]}.

Parameters:run_info (dict) – Information about the run (used to retrieve construct the absolute path to the CSV file that needs decoding.

easyvvuq.decoders.yaml module

A Decoder that can be used to get information from a YAML file. Works identically to the JSON decoder. Look at the documentation of that class for more information

class easyvvuq.decoders.yaml.YAMLDecoder(target_filename, output_columns)[source]

Bases: easyvvuq.decoders.json.JSONDecoder

Module contents