SCALE icon indicating copy to clipboard operation
SCALE copied to clipboard

CPU control

Open TheSallyGardens opened this issue 5 years ago • 6 comments

Hello, I've try your SCALE tools.I want to know how you can control the CPU usage.

TheSallyGardens avatar Nov 26 '19 03:11 TheSallyGardens

SCALE can only use single core of CPU for now while supports multi-GPUs on cuda device.

jsxlei avatar Nov 27 '19 01:11 jsxlei

SCALE can only use single core of CPU for now while supports multi-GPUs on cuda device. I have 56 cores on my server.When I use SCALE,It takes up the whole core.

TheSallyGardens avatar Nov 27 '19 01:11 TheSallyGardens

SCALE can only use single core of CPU for now while supports multi-GPUs on cuda device.

For training data.

TheSallyGardens avatar Nov 27 '19 01:11 TheSallyGardens

Try torch.set_num_threads(1) or refer to this link: https://github.com/pytorch/pytorch/issues/16894.

jsxlei avatar Nov 27 '19 04:11 jsxlei

Add OMP_NUM_THREADS=1 or MKL_NUM_THREADS=1 before SCALE.py. e.g. OMP_NUM_THREADS=1 SCALE.py -d xx which works on our centos system, to use multi-cores, just modify the OMP_NUM_THREADS=num you want

jsxlei avatar Nov 27 '19 05:11 jsxlei

Add OMP_NUM_THREADS=1 or MKL_NUM_THREADS=1 before SCALE.py. e.g. OMP_NUM_THREADS=1 SCALE.py -d xx which works on our centos system, to use multi-cores, just modify the OMP_NUM_THREADS=num you want

Thank you for your answer.

TheSallyGardens avatar Nov 27 '19 05:11 TheSallyGardens