include cps in batch ended

This commit is contained in:
proitlab committed 2026-07-07 16:06:27 +07:00
1 parent a5c146ec98
commit 0317a44001
2 files changed
+4 -1

No files matched your search

+4 -1
View File
@@ -287,9 +287,12 @@ bool BatchStore::record_talenan_crossing(int track_id) {
duration_sec = std::chrono::duration_cast<std::chrono::seconds>(end_tp - start_tp).count();
}
std::ostringstream msg;
msg << "Batch closed by talenan crossing"
int bn = current_state_["batch_number"].get<int>();
double cps = duration_sec > 0 ? static_cast<double>(count) / duration_sec : 0.0;
msg << "Batch #" << bn << " ended"
<< " | count=" << count
<< " | duration=" << duration_sec << "s"
<< " | cps=" << std::fixed << std::setprecision(2) << cps
<< " | start=" << start_time
<< " | end=" << end_time;
logger_(msg.str());