Created
July 2, 2021 18:20
-
-
Save gar1t/0e5b05d1fc3c42801d34b92d6f0b1c95 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Work-around to get train flags into eval run | |
import pprint | |
import yaml | |
print("Merging training flags") | |
flags = yaml.load(open(".guild/attrs/flags")) | |
train_flags = yaml.load(open("train_flags")) | |
for name, val in train_flags.items(): | |
flags["train_%s" % name] = val | |
yaml.safe_dump(flags, open(".guild/attrs/flags", "w")) | |
print("Updated flags: %s" % pprint.pformat(flags)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
train: | |
main: guild.pass | |
flags: | |
epochs: 50 | |
lr: 0.1 | |
eval: | |
flags: | |
epochs: 5 | |
requires: | |
- operation: train | |
select: | |
- .guild/attrs/flags | |
rename: flags train_flags |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment