seasonSH / DocFace

Face recognition system for ID photos
MIT License
371 stars 124 forks source link

queue().empy! #20

Open Wentao795 opened 5 years ago

Wentao795 commented 5 years ago

Hi: @seasonSH Yichun thank you for your work .i trained the base model,how can i do?


essing/queues.py", line 105, in get
    raise Empty
queue.Empty
Process Process-3:
Traceback (most recent call last):
  File "/home/a302/laojiu/anaconda3/envs/tensorflow1.2.0/lib/python3.6/multiprocessing/process.py", line 249, in _bootstrap
    self.run()
  File "/home/a302/laojiu/anaconda3/envs/tensorflow1.2.0/lib/python3.6/multiprocessing/process.py", line 93, in run
    self._target(*self._args, **self._kwargs)
  File "/home/a302/laojiu/github/DocFace/src/utils.py", line 245, in batch_queue_worker
    batch = self.get_batch(config.batch_size, config.batch_format)
  File "/home/a302/laojiu/github/DocFace/src/utils.py", line 202, in get_batch
    indices_batch.extend(self.index_queue.get(block=True, timeout=30))
  File "/home/a302/laojiu/anaconda3/envs/tensorflow1.2.0/lib/python3.6/multiprocessing/queues.py", line 105, in get
    raise Empty
queue.Empty
Traceback (most recent call last):
  File "src/train_base.py", line 111, in <module>
    main(args)
  File "src/train_base.py", line 80, in main
    batch = trainset.pop_batch_queue()
  File "/home/a302/laojiu/github/DocFace/src/utils.py", line 260, in pop_batch_queue
    batch = self.batch_queue.get(block=True, timeout=60)
  File "/home/a302/laojiu/anaconda3/envs/tensorflow1.2.0/lib/python3.6/multiprocessing/queues.py", line 105, in get
    raise Empty
queue.Empty
(tensorflow1.2.0) a302@a302-DGX-Station:~/laojiu/github/DocFace$ 
``` @
ChrisZJingL commented 5 years ago

Have you solved this problem?I had the same problem.

ibarbech commented 5 years ago

I checked if the worker raises any exceptions, ending the 4 workers and not generating any more batch

src/utils.py

    def batch_queue_worker(seed):
        np.random.seed(seed)
        while True:
            try:
                batch = self.get_batch(config.batch_size, config.batch_format)
                if batch is not None:
                    batch['image_paths'] = batch['images']
                    batch['images'] = preprocess(batch['image_paths'], config, is_training)
                self.batch_queue.put(batch)
            except Exception as e:
                print(e)
Leonliou commented 4 years ago

Have you solved this problem?I had the same problem.

朋友你解决了吗?交流一下

ChrisZJingL commented 4 years ago

你好,我之前向作者问过,作者给了我以下答复: seems like your batch_queue is not defined there (it's None). You need to initialize the queue. 我后面不做人脸识别了,就没有继续修改。

15732072757

15732072757@163.com | 签名由网易邮箱大师定制 On 11/12/2019 09:51,Leonliounotifications@github.com wrote:

Have you solved this problem?I had the same problem.

朋友你解决了吗?交流一下

— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.