vibeqc.resolve_progress¶
- vibeqc.resolve_progress(progress, *, verbose=None, use_logging=False)[source]¶
Normalize the
progress=argument every SCF entry point takes.True-> a freshProgressLoggerwriting to stdout at the requestedverboselevel (default 4).FalseorNone-> a shared, silent no-op logger.ProgressLogger-> returned unchanged (verbose/use_loggingkwargs are ignored – the caller-supplied logger is fully under the caller’s control).
This indirection lets every SCF driver accept any of the four forms via a one-line normalisation at the top of the function, and threads the
verbose=Nknob through without each entry point having to construct its own logger by hand.A fifth form is a transparent wrapper around a
ProgressLogger– e.g. the live-checkpointing proxy fromvibeqc.output.checkpoint.wrap_progress_for_checkpoints(), which forwards every method to a real logger but also fires a QVF snapshot on eachiteration. Such a wrapper is not aProgressLoggerinstance, but it is a caller-supplied sink: any object exposing a callableiterationis returned unchanged so the wrapper survives each driver’sresolve_progressnormalisation (otherwise the per-iteration checkpoint hook would be silently stripped before the SCF loop ran).- Parameters:
progress (bool | ProgressLogger | None)
use_logging (bool)
- Return type: