【发布时间】:2018-08-06 23:42:30
【问题描述】:
我正在使用 Mac OS el capitán,我正在尝试使用 quick start tutorial for OpenNMT pytorch 版本。在训练步骤中,我收到以下警告消息:
OpenNMT-py/onmt/modules/GlobalAttention.py:177: UserWarning: Implicit dimension choice for softmax has been deprecated. Change the call to include dim=X as an argument.
align_vectors = self.sm(align.view(batch*targetL, sourceL))
/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/torch/nn/modules/container.py:67: UserWarning: Implicit dimension choice for log_softmax has been deprecated. Change the call to include dim=X as an argument.
input = module(input)
第 1 步:预处理数据(按预期工作)
python preprocess.py -train_src data/src-train.txt -train_tgt data/tgt-train.txt -valid_src data/src-val.txt -valid_tgt data/tgt-val.txt -save_data data/demo
第 2 步:训练模型(产生警告消息)
python train.py -data data/demo -save_model demo-model
有没有人遇到过这个警告或有任何解决方法?
【问题讨论】:
-
也许this 适用于此。
-
我认为警告不会停止执行,只是每个时期都需要很长时间:
-
我最近得到了这个输出,就在警告之后:Epoch 1, 50/ 157; acc:4.21;人:167145.54; 37 src tok/s; 36 tgt tok/s; 2049 秒过去了 Epoch 1, 100/ 157;累积:5.52;人:8718.19; 37 src tok/s; 37 tgt tok/s; 3901 秒过去了
标签: python-3.x macos deep-learning pytorch opennmt