NVIDIA / OpenSeq2Seq

Toolkit for efficient experimentation with Speech Recognition, Text2Speech and NLP
https://nvidia.github.io/OpenSeq2Seq
Apache License 2.0
1.54k stars 369 forks source link

"ValueError: Unknown parameter: automatic_loss_scaling" while training en-de-nmt-small.py with mixed precision #309

Closed rnyak closed 5 years ago

rnyak commented 5 years ago

I trained en-de-nmt-small.py with single precision inside the TF container (version 18.11-py3), and now I would like to train en-de-nmt-small.py with mixed precision running the following command:

python run.py --config_file=example_configs/text2text/en-de/en-de-nmt-small.py --mode=train_eval --num_gpus=2 --use_horovod=False

I am getting the following error:

File "run.py", line 75, in main restore_best_checkpoint) File "/opt/OpenSeq2Seq/open_seq2seq/utils/utils.py", line 777, in create_model model = base_model(params=train_config, mode="train", hvd=hvd) File "/opt/OpenSeq2Seq/open_seq2seq/models/encoder_decoder.py", line 66, in init super(EncoderDecoderModel, self).init(params=params, mode=mode, hvd=hvd) File "/opt/OpenSeq2Seq/open_seq2seq/models/model.py", line 225, in init check_params(params, self.get_required_params(), self.get_optional_params()) File "/opt/OpenSeq2Seq/open_seq2seq/utils/utils.py", line 429, in check_params raise ValueError("Unknown parameter: {}".format(pm)) ValueError: Unknown parameter: automatic_loss_scaling

Please advise. Thanks.

okuchaiev commented 5 years ago

should be called "loss_scaling". I've updated config file.

Btw, I recommend bigger model if your card is Volta or Turing. (mixed precision only makes sense on these cards)