Skip to content

Commit

Permalink
Make config_path accessible
Browse files Browse the repository at this point in the history
  • Loading branch information
JMGaljaard committed Sep 18, 2022
1 parent 652d459 commit ca14ccf
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions fltk/util/config/experiment_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -273,13 +273,13 @@ class ExperimentParser: # pylint: disable=too-few-public-methods
"""Simple parser to load experiment configuration into a programmatic objects."""

def __init__(self, config_path: Path):
self.__config_path = config_path
self._config_path = config_path

def parse(self) -> ExperimentConfig:
"""Parse function to load JSON conf into JobDescription objects. Any changes to the JSON file format
should be reflected by the classes used. For more information refer to the dataclasses JSON
documentation https://pypi.org/project/dataclasses-json/.
"""
with open(self.__config_path, 'r') as config_file:
with open(self._config_path, 'r') as config_file:
experiment = ExperimentConfig.from_json(config_file.read())
return experiment

0 comments on commit ca14ccf

Please sign in to comment.