Does the default TensorFlow job use multiple cores?

I am launching an image from the TensorFlow repository models . I measured sess.run as described in a Github comment and got the following view in chrome: // tracing

enter image description here

I am wondering if TF ever uses multiple cores or single core cores. I think that it uses several cores when operators can work in parallel, as shown in the red frame of the picture. However, all of these 6 threads are listed under / job: localhost / replicate: 0 / task: 0 / cpu: 0, which makes me question my interpretation. Cpu: 0 means all processor cores?

I work on a desktop with 8 cores. I run htop to see kernel usage during TF startup, and I see that only one core gets a saturated 95-100%.

+4
source share
1 answer

I found an existing answer to this question. All cores are wrapped in CPU: 0, i.e. TensorFlow uses several processor cores by default.

+8
source

Source: https://habr.com/ru/post/1672502/


All Articles