tf_gpu_manager icon indicating copy to clipboard operation
tf_gpu_manager copied to clipboard

called by multiprocessing[suggestion]

Open wenhel opened this issue 8 years ago • 1 comments

Hi, I am trying to use the code for a multiprocessing job. The major task is that there are several processes and some of them might call the gpu_manager at a time. The problem is the shared unspecified_gpu (dict) need to be locked when calling by one process. I suggest adding a lock in your code to make sure it is working in multiprocessing task.

Actually, the lock should be shared by gpu_manager and the other processes. It can be claimed as global variable in init().

wenhel avatar Aug 28 '17 22:08 wenhel

Thank you for this issue,i will try to fix it.

QuantumLiu avatar Aug 29 '17 02:08 QuantumLiu