Skip to content
Snippets Groups Projects
Commit fd459df1 authored by Zhenyu Ye's avatar Zhenyu Ye
Browse files

Debug TOF

parent 222c07ea
Branches
No related tags found
1 merge request!92Draft: Resolve "Add TOF benchmark"
......@@ -96,6 +96,7 @@ int sim_tof_hits(const char* fname = "sim_tof_hits.root")
.Define("N_VertexBarrelHits", [](std::vector<dd4pod::TrackerHitData> hits) { return hits.size();}, {"VertexBarrelHits"})
.Define("N_VertexEndcapHits", [](std::vector<dd4pod::TrackerHitData> hits) { return hits.size();}, {"VertexEndcapHits"})
.Define("N_BarrelHits", [](std::vector<dd4pod::TrackerHitData> hits) { return hits.size();}, {"TrackerBarrelHits"})
.Define("p_barrelhits", momentum, {"BarrelTOFHits.momentum"})
.Define("N_EndcapHits", [](std::vector<dd4pod::TrackerHitData> hits) { return hits.size();}, {"TrackerEndcapHits"})
.Define("N_BarrelTOFHits", [](std::vector<dd4pod::TrackerHitData> hits) { return hits.size();}, {"BarrelTOFHits"})
.Define("N_ForwardTOFHits", [](std::vector<dd4pod::TrackerHitData> hits) { return hits.size();}, {"ForwardTOFHits"})
......@@ -147,9 +148,9 @@ int sim_tof_hits(const char* fname = "sim_tof_hits.root")
auto hVertexEndcap_N_vs_theta = df0.Histo1D({"hVertexEndcap_N_vs_theta", "; #theta [deg.]", 20, 0, 180 }, "theta0", "N_VertexEndcapHits");
auto hBarrelTof_time_vs_length = df0.Histo2D(
{"hBarrelTof_time_vs_length", "; time ; length ", 100, 0, 10, 100, 0, 2},
"BarrelTOFHits.truth.time", "BarrelTOFHits.length");
auto hBarrelTof_time_vs_momentum = df0.Histo2D(
{"hBarrelTof_time_vs_momentum", "; time ; momentum ", 100, 0, 3, 100, 0, 5},
"BarrelTOFHits.truth.time", "p_barrelhits");
auto hBarrelTof_x_vs_y = df0.Histo2D(
{"hBarrelTof_x_vs_y", "; x ; y ", 100, -600, 600, 100, -600, 600},
......@@ -290,9 +291,9 @@ int sim_tof_hits(const char* fname = "sim_tof_hits.root")
c = new TCanvas();
hBarrelTof_time_vs_length->DrawCopy("colz");
c->SaveAs("results/tof/sim_tof_hits_tofBarrel_tl.png");
c->SaveAs("results/tof/sim_tof_hits_tofBarrel_tl.pdf");
hBarrelTof_time_vs_momentum->DrawCopy("colz");
c->SaveAs("results/tof/sim_tof_hits_tofBarrel_tp.png");
c->SaveAs("results/tof/sim_tof_hits_tofBarrel_tp.pdf");
c = new TCanvas();
hBarrelTof_x_vs_y->DrawCopy("colz");
c->SaveAs("results/tof/sim_tof_hits_tofBarrel_xy.png");
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment