From 62a97cdf9d6f1bb6df1216b412f3881f368b582d Mon Sep 17 00:00:00 2001 From: Huamonarch Date: Sat, 9 May 2026 13:31:22 +0800 Subject: [PATCH] Remove remaining comments (exp_times, STA.h, gb_item_memory) --- eqpalg/algs/exp_times.cc | 7 ++----- eqpalg/feature_extraction/STA.h | 2 +- eqpalg/feature_extraction/distribution.cc | 1 - eqpalg/gb_item_memory.cc | 1 + 4 files changed, 4 insertions(+), 7 deletions(-) diff --git a/eqpalg/algs/exp_times.cc b/eqpalg/algs/exp_times.cc index 5215a91..b78c45f 100644 --- a/eqpalg/algs/exp_times.cc +++ b/eqpalg/algs/exp_times.cc @@ -32,7 +32,6 @@ int ExpTimes::init() { ret += -1; } /*查db2 ---延迟查询*/ ret += this->reload_params(); /*1.上限;2.初始值*/ - // this->get_history_times(); logger_->Debug() << "ExpTimes::init()," << "shear_times:" << rule_stat_.shear_times << ",running_time:" << rule_stat_.running_time << endl; @@ -177,8 +176,7 @@ int ExpTimes::update_times() { if (!this->act_triggered_) { this->act_started_ = false; this->rule_stat_.running_time += - mm_vars["time"] / (60.0 * 60000); ///<小时 - this->logger_->Debug() + mm_vars["time"] / (60.0 * 60000); this->logger_->Debug() << "计时结束:" << mix_cc::mix_time_t(now_time_).to_formatted_time() << " 本次统计的使用时间:" << mm_vars["time"] / 60000.0 << " minites" << std::endl; @@ -187,8 +185,7 @@ int ExpTimes::update_times() { mm_vars["stime"] = duration_cast(now_time_.time_since_epoch()).count(); this->rule_stat_.running_time += - mm_vars["time"] / (60.0 * 60000); ///<小时 - this->logger_->Debug() + mm_vars["time"] / (60.0 * 60000); this->logger_->Debug() << "计时结束:" << mix_cc::mix_time_t(now_time_).to_formatted_time() << " 本次统计的使用时间:" << mm_vars["time"] / 60000.0 diff --git a/eqpalg/feature_extraction/STA.h b/eqpalg/feature_extraction/STA.h index 7a63925..38f5c4c 100644 --- a/eqpalg/feature_extraction/STA.h +++ b/eqpalg/feature_extraction/STA.h @@ -226,4 +226,4 @@ private: int get_seq(); }; -} // namespace DAA \ No newline at end of file +} \ No newline at end of file diff --git a/eqpalg/feature_extraction/distribution.cc b/eqpalg/feature_extraction/distribution.cc index c6410b8..6316500 100644 --- a/eqpalg/feature_extraction/distribution.cc +++ b/eqpalg/feature_extraction/distribution.cc @@ -44,7 +44,6 @@ double Dist::get_shifted_prob() const { return prob_; } */ int Dist::auto_test(dlib::running_stats rs, const std::vector& tmp_data) { - // int ret = 0; try { this->rs_ = rs; std::tuple> test; diff --git a/eqpalg/gb_item_memory.cc b/eqpalg/gb_item_memory.cc index 1a9acf3..ba869cb 100644 --- a/eqpalg/gb_item_memory.cc +++ b/eqpalg/gb_item_memory.cc @@ -22,6 +22,7 @@ struct DoubleBufferArrays { read_array.resize(size); write_array.resize(size); } + void swap_buffers() { std::swap(read_array, write_array); } std::vector& get_write_array() { return write_array; } };