foamgen.generation

Generation module

synopsis

Organizes creation of foam morphology.

Functions

generate(cfg)

Generate foam morphology.

parse_cli_and_generate()

Parse CLI arguments and call generate() function.

parse_config_file(fname)

Parse configurational file.

foamgen.generation.generate(cfg)[source]

Generate foam morphology.

Parameters

cfg (Namespace) – parsed inputs

foamgen.generation.parse_cli_and_generate()[source]

Parse CLI arguments and call generate() function.

Parsing is done using yamlargparse. This function is called by the foamgen executable.

foamgen.generation.parse_config_file(fname)[source]

Parse configurational file.

Parsed options can be accessed as arguments of the returned object. For more information see Munch.

Parameters

fname (str) – config filename

Returns

parsed config file

Return type

Munch