Throughout the codebase of flint Options classes are created as a sub-class from typing.NamedTuple. Their general use has been to hold default values of known arguments into external programs (eg. wsclean, casa's gaincal etc.). Since they have only contain optional arguments, and not mandatory ones, it is straight forward to:
generate / obtain the defaults of an Options class when generating a template strategy
load in non-standard options when creating a Options class throughout processing.
The PotatoPeelOptions class currently contains a small set of arguments without default values, which breaks the use cases in the above situations.
The mandatory arguments should be separated out from this Options class and be represented by a separate structure, or passed as normal positional arguments into appropriate functions. The former would probably be easier as it helps with the creation of the CLI.
Throughout the codebase of flint
Options
classes are created as a sub-class fromtyping.NamedTuple
. Their general use has been to hold default values of known arguments into external programs (eg. wsclean, casa's gaincal etc.). Since they have only contain optional arguments, and not mandatory ones, it is straight forward to:The
PotatoPeelOptions
class currently contains a small set of arguments without default values, which breaks the use cases in the above situations.The mandatory arguments should be separated out from this Options class and be represented by a separate structure, or passed as normal positional arguments into appropriate functions. The former would probably be easier as it helps with the creation of the CLI.