-
Notifications
You must be signed in to change notification settings - Fork 41
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refine debug #370
Refine debug #370
Conversation
…stuff with symbols.
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #370 +/- ##
=======================================
Coverage 99.73% 99.73%
=======================================
Files 73 73
Lines 6839 6876 +37
=======================================
+ Hits 6821 6858 +37
Misses 18 18 ☔ View full report in Codecov by Sentry. |
Oh I just noticed the mechanism with Until now it “activated” the sub solvers output “for the next iteration” since it was called in the iteration debug after the iteration. The two things that have to work is
The problem is that the |
…activates this, Iteration activates next.
I found a solution, the |
Here is the new feature summarised https://manoptjl.org/previews/PR370/tutorials/HowToDebug/#Specifying-when-to-print-something – the next section can now also show an even nicer print for sub-solvers, since the iteration number can now first be printed, before the subsolver starts printing. |
…opt.jl into kellertuer/more-debug # Conflicts: # docs/src/tutorials/HowToDebug.md
Yesterday I was a bit annoyed, when trying to help @flgoyens on a debug issue.
Especially, besides the
:Stop
to debug the stopping criterion, everything was added to:All
which still meant it was only reset on start and called in the iteration.This aims to resolve this.
:All
entry, that was used (exclusively) until nowdebug=
withPair
s to allow more control where to put Debug.Since all this is internal and none of the other tests broke, I would consider this still non-breaking (since I assume besides me no one explicitly used
:All
). All old arrays ofdebug=
still workI started a few examples in the docs. The new possibilities are now
debug = [:Iteration, " | ", :Cost, :Stop]
works as before butdebug = [ :BeforeIteration => :Iteration, " | ", :Cost]
is the new notation that specifically adds:Iteration
printing to before calling a step.debug = [:BeforeIteration => :Iteration, :Iteration => [" | ", :Cost], :Stop => :Stop]
is now also new but equivalent to the previous one , since:Stop
is always added to the end of the algorithm (stored in:Stop
) and by default all other things are added to the iteration step (now) at:Iteration
.The last point also shows that this is basically debugception. We can have sequences of debug in single sub-spaces.
So this is more precise, but we keep the simplicity from before (all old debug specifications work as before), but also more flexible.
ToDo