File indexing completed on 2025-01-18 10:17:41
0001
0002
0003
0004
0005
0006
0007 #ifndef _JEventProcessor_regressiontest_
0008 #define _JEventProcessor_regressiontest_
0009
0010 #include <JANA/JEventProcessor.h>
0011
0012 #include <fstream>
0013 #include <map>
0014 #include <string>
0015
0016
0017 class JEventProcessor_regressiontest : public JEventProcessor
0018 {
0019 public:
0020 void Init() override;
0021 void BeginRun(const std::shared_ptr<const JEvent>& event) override;
0022 void Process(const std::shared_ptr<const JEvent>& event) override;
0023 void EndRun() override;
0024 void Finish() override;
0025
0026 private:
0027 std::mutex m_mutex;
0028
0029 bool interactive = true;
0030 bool have_old_log_file = false;
0031 std::ifstream old_log_file;
0032 std::string old_log_file_name = "regression_log_old.tsv";
0033 std::ofstream new_log_file;
0034 std::string new_log_file_name = "regression_log_new.tsv";
0035 std::ifstream blacklist_file;
0036 std::string blacklist_file_name = "blacklist.tsv";
0037 std::set<std::string> blacklist;
0038 std::map<std::string, int> discrepancy_counts;
0039
0040 std::vector<JFactory*> GetFactoriesTopologicallyOrdered(const JEvent& event);
0041 std::pair<std::string, int> ParseFactorySummary(std::string line);
0042 };
0043
0044 #endif