question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

not using all CPU

See original GitHub issue

Hi there,

I’m running a ML tuning with optuna on an instance with 48 cores and has set n_jobs=-1:

study.optimize(OptunaObjective(clf=self.clf,
                                       X=X,
                                       y=y,
                                       sample_weight=sample_weight,
                                       scoring=self.scoring,
                                       cv=self.cv,
                                       decay_f=decay_f),
                       self.n_trials, n_jobs=-1)

I noticed that cpu utilization is around 20% and ram is around 4%.

I’m wondering if i set it up correctly or is there is another way to increase performance. Regarding the “Distributed Optimization tutorial”, I do not know if i can set it up an sql database as i’m using instances on my university cluster.

If you need more code, let me know. Thank you for any help.

Best regards

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:1
  • Comments:11 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
lschneidprocommented, Aug 29, 2019

I could try.

In the mean time, I started renting a Postgre SQL server online (30 first days free)

1reaction
lschneidprocommented, Aug 29, 2019

Thanks again for spoting such a mistake. It seems that the author of your example is running 10**2 trials then

Yes, it’s a typical way to run optimization in parallel. If you don’t want to use shell, you can spawn multiple optimization processes within Python script by using a process management library such as joblib (please see quadratic_joblib_simple.py for an example).

Read more comments on GitHub >

github_iconTop Results From Across the Web

Why won't my CPU operate at its max potential ... - Super User
Just from a developer's perspective, the CPU will do whatever you tell it to. If it's not maxed out at 100%, it's because...
Read more >
How to Fix High CPU Usage - Intel
Find out all the reasons why your PC displays high CPU usage. Our step-by-step guide will show you how to fix your CPU...
Read more >
[SOLVED] How to fix CPU usage 100% issue - Driver Easy
A complete guide to troubleshooting high CPU usage issue on Windows 10 · Try these fixes · Fix potential Windows stability issues ·...
Read more >
How To Enable All Cores in Windows - Alphr
Core Settings In Windows 10 · Type 'msconfig' into the Windows Search Box and hit Enter. · Select the Boot tab and then...
Read more >
FIX: CPU not showing all cores in Task Manager
2. Make sure all of your CPU cores are enabled · Press Windows + R. · Type in MSConfig. · Go to the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found