31using Timing = std::map<std::string, double>;
51 using Clock = std::chrono::steady_clock;
52 [[nodiscard]]
double elapsed()
const;
55 std::vector<std::string> phases_;
56 Clock::time_point start_ = Clock::now();
57 Clock::time_point phase_start_ = Clock::now();
Thrown by a solve whose progress callback returned false.
Definition progress.hpp:34
Definition progress.hpp:42
ProgressReporter(ProgressCallback callback, std::vector< std::string > phases)
Definition axisymmetric_estimator.hpp:39
std::map< std::string, double > Timing
Wall-clock seconds per phase by name, plus "total".
Definition progress.hpp:31
std::function< bool(const ProgressEvent &)> ProgressCallback
Definition progress.hpp:28
A phase of a solve starting (or, with step == num_steps, the solve being done).
Definition progress.hpp:19
int num_steps
phases of this solve
Definition progress.hpp:22
std::string phase
"assembly", "constraints", "factorisation", "solve", "post", "done"
Definition progress.hpp:20
double seconds
wall-clock seconds since the solve began
Definition progress.hpp:23
int step
index of the phase, 0-based; num_steps when done
Definition progress.hpp:21