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.

Clean running trials

See original GitHub issue

Motivation

You do not have to specify the number of trials in study.optimize. Then you can stop the optimization with “KeyboardInterrupt”. When your optuna is connected to a DB the trail you interruped will stay in status “running” for ever. I am not sure what this means for the optimizer but my guess is that it is not good when you restart the optimization. This is because optuna thinks that a 2nd process is running on the DB and has not ended.

Description of the new feature

What about a new parameter in the optuna.create_study function called clean_running with Falseas default. When you set it to True it removes all running trials when opening the DB. If you set it to True the load_if_exists also has to be True.

Alternatives (optional)

I don’t know.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:10 (8 by maintainers)

github_iconTop GitHub Comments

2reactions
hvycommented, Mar 13, 2020

I personally find the KeyboardInterrupt signal handler approach to be cleaner, trying to reduce zombie trials in the first place. I guess that it on the other hand requires quite a bit of work (incl. writing exhaustive tests). So, it could be tackled at a later time.

0reactions
silecommented, May 26, 2020

Thank you for the swift response!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Keep The Trails Clean: 3 Ways to do Your Part
Here are three ways to help keep trails clean. Whether you hike, trail run, or just like to take a weekend stroll through...
Read more >
Best Way to Clean Trail Runners - YouTube
When your trail runners get muddy and messy on trail, this is the best way to clean them up.https://www.instagram.com/rootsontrail ...
Read more >
How to Clean Running Shoes | REI Co-op
Cleaning Running Shoe Uppers · Remove the laces. · Remove the insoles/liners. · Use a brush to gently remove dust and dirt from...
Read more >
Adopt a Trail - Clean Trails
One can act as a spotter to locate trash on the trail and within easy reach (leave the heavy cleaning to your Trail...
Read more >
Best Trail Running Trails in Madison | AllTrails
Nice and clean paved trail with dog clean-up stations.
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