8440894e621e3922a394da25b4a0806bdabee21c,12_5_char_rnn.py,,,#,113
Before Change
print("Training for %d epochs..." % n_epochs)
for epoch in range(1, n_epochs + 1):
for i, (lines, _) in enumerate(train_loader):
for line in lines:
loss = train(line)
print("[(%d %d%%) %.4f]" % (epoch, epoch / n_epochs * 100, loss))
print(generate(decoder, "Wh", 100), "\n")
print("Saving...")
After Change
for i, (lines, _) in enumerate(train_loader):
loss = train(lines[0]) // Batch size is 1
if i % 100 == 0:
print("[(%d %d%%) %.4f]" %
(epoch, epoch / n_epochs * 100, loss))
print(generate(decoder, "Wh", 100), "\n")
print("Saving...")
save()
except KeyboardInterrupt:
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 8
Instances Project Name: hunkim/PyTorchZeroToAll
Commit Name: 8440894e621e3922a394da25b4a0806bdabee21c
Time: 2017-11-02
Author: hunkim@gmail.com
File Name: 12_5_char_rnn.py
Class Name:
Method Name:
Project Name: hunkim/PyTorchZeroToAll
Commit Name: 8440894e621e3922a394da25b4a0806bdabee21c
Time: 2017-11-02
Author: hunkim@gmail.com
File Name: 13_1_seq2seq.py
Class Name:
Method Name:
Project Name: hunkim/PyTorchZeroToAll
Commit Name: 8440894e621e3922a394da25b4a0806bdabee21c
Time: 2017-11-02
Author: hunkim@gmail.com
File Name: 13_2_seq2seq_att.py
Class Name:
Method Name: