RuntimeError: main thread is not in main loop
ManivannanMurugavel opened this issue · 9 comments
When i ran the train.py
(python3 train.py --data-root=./datapath/ljspeech/ --hparams="batch_size=10")
This error is came:
Exception ignored in: <bound method Image.del of <tkinter.PhotoImage object at 0x7f1b5f86a710>>
Traceback (most recent call last):
File "/usr/lib/python3.5/tkinter/init.py", line 3359, in del
self.tk.call('image', 'delete', self.name)
RuntimeError: main thread is not in main loop
What line of train.py causes the error?
it did not show what the line.
only show the error is
Exception ignored in: <bound method Image.del of <tkinter.PhotoImage object at 0x7f1b5f86a710>>
Traceback (most recent call last):
File "/usr/lib/python3.5/tkinter/init.py", line 3359, in del
self.tk.call('image', 'delete', self.name)
RuntimeError: main thread is not in main loop
Well, after some googling, It seems there's a problem in your GUI backend for matplotlib. Does the following code work for you?
import matplotlib
import matplotlib.pyplot as plt
plt.plot([1,2,3])
and
import matplotlib
matplotlib.use('Agg')
import matplotlib.pyplot as plt
plt.plot([1,2,3])
i tried this way but the same error is came.
i also googling.
please help me.
(plese send your mail id to manivannanmca2012@gmail.com)
So the issue is not related to deepvoice3_pytorch. Please ask a question or file an issue to matplotlib community. I cannot reproduce.
I have solved this error.
Thank you
@ManivannanMurugavel I have the same problem as you. Could you show me the way to fix it? Really appreciate!
@toannhu Please remove matplotlib for loss and accuracy graph.
Just see the what training acc and loss in terminal.
Solution:
Please command the all save_alignment() def inside train.py.
@ManivannanMurugavel I have encountered the same error
Error in atexit._run_exitfuncs:
Traceback (most recent call last):
File "/usr/lib/python3.6/tkinter/init.py", line 772, in after_cancel
data = self.tk.call('after', 'info', id)
RuntimeError: main thread is not in main loop
can you please help me with this ?