Assembles and returns a spill information record.
512 auto const& [ MWR_times, unpacked_MWR ] = MWRdata;
531 double TOR860_time = 0;
537 try{
bfp->GetNamedData(time,
"E:TOR860@",&TOR860,&TOR860_time);}
catch (WebAPIException &we) {mf::LogDebug(
"BNBRetriever")<<
"At time : " << time <<
" " <<
"got exception: " << we.what() <<
"\n";}
538 try{
bfp->GetNamedData(time,
"E:TOR875",&TOR875);}
catch (WebAPIException &we) {mf::LogDebug(
"BNBRetriever")<<
"At time : " << time <<
" " <<
"got exception: " << we.what() <<
"\n";}
539 try{
bfp->GetNamedData(time,
"E:LM875A",&LM875A);}
catch (WebAPIException &we) {mf::LogDebug(
"BNBRetriever")<<
"At time : " << time <<
" " <<
"got exception: " << we.what() <<
"\n";}
540 try{
bfp->GetNamedData(time,
"E:LM875B",&LM875B);}
catch (WebAPIException &we) {mf::LogDebug(
"BNBRetriever")<<
"At time : " << time <<
" " <<
"got exception: " << we.what() <<
"\n";}
541 try{
bfp->GetNamedData(time,
"E:LM875C",&LM875C);}
catch (WebAPIException &we) {mf::LogDebug(
"BNBRetriever")<<
"At time : " << time <<
" " <<
"got exception: " << we.what() <<
"\n";}
542 try{
bfp->GetNamedData(time,
"E:HP875",&HP875);}
catch (WebAPIException &we) {mf::LogDebug(
"BNBRetriever")<<
"At time : " << time <<
" " <<
"got exception: " << we.what() <<
"\n";}
543 try{
bfp->GetNamedData(time,
"E:VP875",&VP875);}
catch (WebAPIException &we) {mf::LogDebug(
"BNBRetriever")<<
"At time : " << time <<
" " <<
"got exception: " << we.what() <<
"\n";}
544 try{
bfp->GetNamedData(time,
"E:HPTG1",&HPTG1);}
catch (WebAPIException &we) {mf::LogDebug(
"BNBRetriever")<<
"At time : " << time <<
" " <<
"got exception: " << we.what() <<
"\n";}
545 try{
bfp->GetNamedData(time,
"E:VPTG1",&VPTG1);}
catch (WebAPIException &we) {mf::LogDebug(
"BNBRetriever")<<
"At time : " << time <<
" " <<
"got exception: " << we.what() <<
"\n";}
546 try{
bfp->GetNamedData(time,
"E:HPTG2",&HPTG2);}
catch (WebAPIException &we) {mf::LogDebug(
"BNBRetriever")<<
"At time : " << time <<
" " <<
"got exception: " << we.what() <<
"\n";}
547 try{
bfp->GetNamedData(time,
"E:VPTG2",&VPTG2);}
catch (WebAPIException &we) {mf::LogDebug(
"BNBRetriever")<<
"At time : " << time <<
" " <<
"got exception: " << we.what() <<
"\n";}
548 try{
bfp->GetNamedData(time,
"E:BTJT2",&BTJT2);}
catch (WebAPIException &we) {mf::LogDebug(
"BNBRetriever")<<
"At time : " << time <<
" " <<
"got exception: " << we.what() <<
"\n";}
549 try{
bfp->GetNamedData(time,
"E:THCURR",&THCURR);}
catch (WebAPIException &we) {mf::LogDebug(
"BNBRetriever")<<
"At time : " << time <<
" " <<
"got exception: " << we.what() <<
"\n";}
552 unsigned long int time_closest_int = (int) TOR860_time;
553 double time_closest_ns = (TOR860_time - time_closest_int)*1e9;
557 beamInfo.
TOR860 = TOR860*1e12;
558 beamInfo.
TOR875 = TOR875*1e12;
562 beamInfo.
HP875 = HP875;
563 beamInfo.
VP875 = VP875;
564 beamInfo.
HPTG1 = HPTG1;
565 beamInfo.
VPTG1 = VPTG1;
566 beamInfo.
HPTG2 = HPTG2;
567 beamInfo.
VPTG2 = VPTG2;
568 beamInfo.
BTJT2 = BTJT2;
573 for(
auto const& MWRdata: unpacked_MWR){
574 std::ignore = MWRdata;
575 assert(!MWRdata.empty());
578 if(unpacked_MWR[0].
empty()){
583 beamInfo.
M875BB = unpacked_MWR[0][matched_MWR[0]];
587 if(unpacked_MWR[1].
empty()){
592 beamInfo.
M876BB = unpacked_MWR[1][matched_MWR[1]];
596 if(unpacked_MWR[2].
empty()){
601 beamInfo.
MMBTBB = unpacked_MWR[2][matched_MWR[2]];
608 beamInfo.
event = eventID.event();
float M876BB_spill_time_diff
the time difference between M876BB and the matched spill
std::vector< int > M876BB
Multiwire station after Mag 875...?
float LM875C
Loss Monitor after the RWM, unit R/s.
float VPTG2
Horizontal Position Monitor at Target Station 2, closest to target, units mm.
float VPTG1
Horizontal Position Monitor at Target Station 1, units mm.
unsigned long int spill_time_ns
The IFDB Beam Spill Time, unit nsec.
float MMBTBB_spill_time_diff
the time difference between MMBTBB and the matched spill
float TOR875
Toroid after Mag 875, units e12 Protons.
float LM875A
Loss Monitor before the RWM, unit R/s.
std::unique_ptr< ifbeam_ns::BeamFolder > bfp
float BTJT2
Temperature of air exiting target, units Deg C.
std::vector< int > MMBTBB
Multiwire station at the target station,.
float HP875
Horizontal Position Monitor after Mag 875, units mm.
float HPTG2
Horizontal Position Monitor at Target Station 2, closest to target, units mm.
float THCURR
Current applied to Horn, units kiloAmperes.
unsigned long int spill_time_s
The IFDB Beam Spill Time, unit sec.
float VP875
Verticle Position Monitor after Mag 875, units mm.
float TOR860
Toroid before Mag 875, units e12 Protons.
std::vector< int > M875BB
Multiwire station before Mag 875...?
float LM875B
Loss Monitor after the RWM, unit R/s.
bool empty(FixedBins< T, C > const &) noexcept
float M875BB_spill_time_diff
the time difference between M875BB and the matched spill
float HPTG1
Horizontal Position Monitor at Target Station 1, units mm.