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

ART Compatibility #42

Closed
wants to merge 3 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion mart/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

import hydra
import pyrootutils
from omegaconf import DictConfig
from omegaconf import DictConfig, OmegaConf

from mart import utils

Expand Down Expand Up @@ -40,6 +40,9 @@ def main(cfg: DictConfig) -> float:
log.fatal("")
return 0

# Dump interpolated configs.
OmegaConf.save(cfg, "config.yaml", resolve=True)

# imports can be nested inside @hydra.main to optimize tab completion
# https://github.com/facebookresearch/hydra/issues/934
from mart.tasks.lightning import lightning
Expand Down
4 changes: 4 additions & 0 deletions mart/models/modular.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ def __init__(
test_sequence=None,
test_step_log=None,
test_metrics=None,
loss_sequence=None,
prediction_sequence=None,
weights_fpath=None,
strict=True,
):
Expand All @@ -44,6 +46,8 @@ def __init__(
"training": training_sequence,
"validation": validation_sequence,
"test": test_sequence,
"loss": loss_sequence,
"prediction": prediction_sequence,
}
self.model = SequentialDict(modules, sequences)

Expand Down