Search code examples
pythonjupyter-notebookgoogle-cloud-datalab

GCP Datalab - Increasing CPU utilization to ~100%


I'm using n1-highcpu-8 machine and running single notebook. the CPU utilization is always below ~20%. is it possible to use multi CPUs for utilization increasing?


Solution

  • There's nothing that automatically makes your notebook use multiple CPU cores; The notebook kernel will only ever use a single CPU core.

    If you want to use multiple cores, then you have to either make your code explicitly run in parallel (e.g. take a look at the multiprocessing library ), or use a framework which does that for you.