Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pyhocon: Cannot resolve variable ${t5_3b_ace05_wu08} #10

Open
Niklss opened this issue Jun 4, 2023 · 0 comments
Open

pyhocon: Cannot resolve variable ${t5_3b_ace05_wu08} #10

Niklss opened this issue Jun 4, 2023 · 0 comments

Comments

@Niklss
Copy link

Niklss commented Jun 4, 2023

ere.conf missing subconfig t5_3b_ace05_wu08

On
python ./run_ere.py t0_3b_conll04 0

06/04/2023 20:04:34 - INFO - util.func - Running experiment: t0_3b_conll04
Traceback (most recent call last):
File "/opt/conda/lib/python3.10/site-packages/pyhocon/config_parser.py", line 478, in _resolve_variable
return True, config.get(variable)
File "/opt/conda/lib/python3.10/site-packages/pyhocon/config_tree.py", line 236, in get
return self._get(ConfigTree.parse_key(key), 0, default)
File "/opt/conda/lib/python3.10/site-packages/pyhocon/config_tree.py", line 176, in _get
raise ConfigMissingException(
pyhocon.exceptions.ConfigMissingException: 'No configuration setting found for key t5_3b_ace05_wu08'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/home/jovyan/au/ASP/./run_ere.py", line 99, in
runner = ERERunner(
File "/home/jovyan/au/ASP/util/runner.py", line 50, in init
self.config = util.initialize_config(config_name, config_file=config_file)
File "/home/jovyan/au/ASP/util/func.py", line 24, in initialize_config
config = pyhocon.ConfigFactory.parse_file(join("./", config_file))[config_name]
File "/opt/conda/lib/python3.10/site-packages/pyhocon/config_parser.py", line 142, in parse_file
return cls.parse_string(content, os.path.dirname(filename), resolve, unresolved_value)
File "/opt/conda/lib/python3.10/site-packages/pyhocon/config_parser.py", line 192, in parse_string
return ConfigParser().parse(content, basedir, resolve, unresolved_value)
File "/opt/conda/lib/python3.10/site-packages/pyhocon/config_parser.py", line 460, in parse
has_unresolved = cls.resolve_substitutions(config, allow_unresolved)
File "/opt/conda/lib/python3.10/site-packages/pyhocon/config_parser.py", line 646, in resolve_substitutions
is_optional_resolved, resolved_value = cls._resolve_variable(config, substitution)
File "/opt/conda/lib/python3.10/site-packages/pyhocon/config_parser.py", line 487, in _resolve_variable
raise ConfigSubstitutionException(
pyhocon.exceptions.ConfigSubstitutionException: Cannot resolve variable ${t5_3b_ace05_wu08} (line: 191, col: 20)

To fix it

  • Add a subconfig t5_3b_ace05_wu08 to ere.conf
  • Remove flant5_xxl_ace05 subconfig
  • Change ${t5_3b_ace05_wu08} to ${t5_3b_ace05} (link to another subconfig)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant