我使用以下行来跨不同的工作者创建共享队列。
with tf.device("/job:ps/task:0"):
with tf.variable_scope("global"):
self.queue = tf.FIFOQueue(20, None)
在ps工作者中:
self.queue.dequeue()
在其他工人中,
self.queue.enqueue(somethings)
然而,我发现有时入队操作不起作用,没有任何入队,并且没有错误或期望。有没有人有想法?