lasdi.inputs

Attributes

verbose

Classes

InputParser

Functions

getDictFromList(list_, inputDict)

get a dict with {key: val} from a list of dicts

Module Contents

lasdi.inputs.verbose = False
class lasdi.inputs.InputParser(dict, name='')
dict_ = None
name = ''
getInput(keys, fallback=None, datatype=None)

Find the value corresponding to the list of keys. If the specified keys do not exist, use the fallback value. If the fallback value does not exist, returns an error. If the datatype is specified, enforce the output value has the right datatype.

lasdi.inputs.getDictFromList(list_, inputDict)

get a dict with {key: val} from a list of dicts NOTE: it returns only the first item in the list, even if the list has more than one dict with {key: val}.