Skip to content

Commit

Permalink
Fix setup, test function parameter
Browse files Browse the repository at this point in the history
  • Loading branch information
upskyy committed May 22, 2022
1 parent 7e65135 commit 0e95f67
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions openspeech_cli/hydra_train.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@

import os
import hydra
import wandb
import pytorch_lightning as pl
from omegaconf import DictConfig, OmegaConf
from pytorch_lightning.utilities import rank_zero_info
Expand All @@ -45,13 +44,13 @@ def hydra_main(configs: DictConfig) -> None:
data_module.prepare_data()
tokenizer = TOKENIZER_REGISTRY[configs.tokenizer.unit](configs)

data_module.setup(tokenizer=tokenizer)
data_module.setup()

model = MODEL_REGISTRY[configs.model.model_name](configs=configs, tokenizer=tokenizer)

trainer = get_pl_trainer(configs, num_devices, logger)
trainer.fit(model, data_module)
trainer.test()
trainer.test(model, data_module)


if __name__ == '__main__':
Expand Down

0 comments on commit 0e95f67

Please sign in to comment.