Closed guyer closed 8 months ago
LGTM, I get similar to @tkphd.
I see that the Timer context is being repeated in many different places. Suggests that the context should be in a single place and then what's inside the context should be what is unique to each subclass.
I see that the Timer context is being repeated in many different places. Suggests that the context should be in a single place and then what's inside the context should be what is unique to each subclass.
I see your point. The thing is that what's inside the context is highly dependent on the broader context of ._solve_()
. I guess that could be stored as a bunch of Solver
member variables... I'll think about this in my broader solver refactorization.
Originally tried to make
Timer()
do logging, too, but I couldn't figure out how to get it to log in the correct scope. Separating timing from logging substantially simplifies the logic at a modest cost in LoC at point of use.