Skip to content

Implement config loadig via AttributeDict #12

Description

@tramsauer

Config file parameter loading with method AttributeDict may be implemented for more readable code.

Read config via:

    def _get_config(self):
        """
        Load configuration from self.config.bb.pre_process()
           writes to self.config.
        """
        with open(self.config, 'r') as cfg:
            self.config = yaml.load(cfg)
            self.config = AttributeDict(**self.config)

and access in our case e.g.:

    self.config.Prior.priors.sm_clim.type

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions