Serialize selected config groups at runtime #2431
Answered
by
Jasha10
addisonklinke
asked this question in
Q&A
-
Similar to how Hydra automatically tracks |
Beta Was this translation helpful? Give feedback.
Answered by
Jasha10
Oct 24, 2022
Replies: 1 comment
-
Yes, see from omegaconf import DictConfig
import hydra
from hydra.core.hydra_config import HydraConfig
@hydra.main(version_base=None, config_path="conf", config_name="config")
def my_app(cfg: DictConfig) -> None:
print(HydraConfig.get().runtime.choices)
if __name__ == "__main__":
my_app() |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
addisonklinke
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Yes, see
hydra.runtime.choices
.You can access it using the hydra resolver (
${hydra:runtime.choices}
) or in your python code as below: