Function that parses the binary_c version info. Length function with a lot of branches
Function that parses the binary_c version info. Long function with a lot of branches
Args:
version_info_string: raw output of version_info call to binary_c
Returns:
Parsed version of the version info, which is a dictionary containing the keys: 'isotopes' for isotope info, 'argpairs' for argument pair info (TODO: explain), 'ensembles' for ensemble settings/info, 'macros' for macros, 'elements' for atomic element info, 'DTlimit' for (TODO: explain), 'nucleosynthesis_sources' for nucleosynthesis sources, and 'miscellaneous' for all those that were not caught by the previous groups. 'git_branch', 'git_build', 'revision' and 'email' are also keys, but its clear what those contain.
Function that reads out the output of the help_all api call to binary_c
Function that reads out the output of the return_help_all api call to binary_c. This return_help_all binary_c returns all the information for the parameters, their descriptions and other properties. The output is categorized in sections.
print_help: bool, prints all the parameters and their descriptions.
Args:
print_help: (optional, default = Tru) prints all the parameters and their descriptions.
return_dict: returns a dictionary
Returns:
returns a dictionary containing dictionaries per section. These dictionaries contain the parameters and descriptions etc for all the parameters in that section
Function to (recursively) inspect a (nested) dictionary.
The object that is returned is a dictionary containing the key of the input_dict, but as value it will return the type of what the value would be in the input_dict
Works recursively if there is a nested dict.
In this way we inspect the structure of these dictionaries, rather than the exact contents.
Args:
input_dict: dictionary you want to inspect
print_structure: (optional, default = True)
indent: (optional, default = 0) indent of the first output
Prints out keys and their value types
Returns:
Dictionary that has the same structure as the input_dict, but as values it has the type(input_dict[key]) (except if the value is a dict)