DLR-RM / AugmentedAutoencoder

Official Code: Implicit 3D Orientation Learning for 6D Object Detection from RGB Images
MIT License
338 stars 97 forks source link

Attempted to use a closed Session #48

Closed lingxiaoZHONG closed 4 years ago

lingxiaoZHONG commented 4 years ago

Describe the bug

  1. After the output picture success display when I use "ae_train exp_group/my_autoencoder -d", the program wait and throw me "Qt: Cannot set locale modifiers"
  2. When I try the order "ae_train exp_group/my_autoencoder" with obj_05.ply model, I meet the "Attempted to use a closed Session" problem from "queue.py". The problem not happens when I use tensorflow CPU version, but happens in GPU version, from 1.7.0 to 1.12.0. I don't know if these two problems have relationship, so I submit them together. Very expecting your solutions!

Problem Info

Exception in thread Thread-3 (and other threads): Traceback (most recent call last): File "/home//anaconda3/envs//lib/python2.7/threading.py", line 801, in bootstrap_inner self.run() File "/home//anaconda3/envs//lib/python2.7/threading.py", line 754, in run self.target(*self.args, *self.__kwargs) File "/home//.local/lib/python2.7/site-packages/auto_pose/ae/queue.py", line 66, in run__ session.run(self.enqueue_op, feed_dict) File "/home//anaconda3/envs//lib/python2.7/site-packages/tensorflow/python/client/session.py", line 900, in run run_metadata_ptr) File "/home//anaconda3/envs//lib/python2.7/site-packages/tensorflow/python/client/session.py", line 1058, in _run raise RuntimeError('Attempted to use a closed Session.') RuntimeError: Attempted to use a closed Session.

Describe the characteristic of your environment:

flugenheimer commented 4 years ago

I'm running into a similar message " Attempted to use a closed Session" using Ubuntu 18.04, CUDA 10, tested with tensorflow-gpu 1.13.1, 1.13.2, 1.14.0, works with CPU,

"ae_train exp_group/my_autoencoder -d" works as normal for me displaying the renderings.

lingxiaoZHONG commented 4 years ago

I solved this problem by setting NUM_THREADS = 1 in .cfg file. But I still don't understand why using multi-thread in gpu not work.