CMS 3D CMS Logo

Functions
PFEnergyCalibration.cc File Reference
#include "RecoParticleFlow/PFClusterTools/interface/PFEnergyCalibration.h"
#include "CondFormats/PhysicsToolsObjects/interface/PerformancePayloadFromTFormula.h"
#include "CondFormats/ESObjects/interface/ESEEIntercalibConstants.h"
#include <TMath.h>
#include <cmath>
#include <vector>
#include <map>
#include <algorithm>
#include <numeric>

Go to the source code of this file.

Functions

std::ostream & operator<< (std::ostream &out, const PFEnergyCalibration &calib)
 

Function Documentation

◆ operator<<()

std::ostream& operator<< ( std::ostream &  out,
const PFEnergyCalibration calib 
)

Definition at line 534 of file PFEnergyCalibration.cc.

534  {
535  if (!out)
536  return out;
537 
538  out << "PFEnergyCalibration -- " << endl;
539 
540  if (calib.pfCalibrations) {
541  static const std::map<std::string, PerformanceResult::ResultType> functType = {
542  {"PFfa_BARREL", PerformanceResult::PFfa_BARREL},
543  {"PFfa_ENDCAP", PerformanceResult::PFfa_ENDCAP},
544  {"PFfb_BARREL", PerformanceResult::PFfb_BARREL},
545  {"PFfb_ENDCAP", PerformanceResult::PFfb_ENDCAP},
546  {"PFfc_BARREL", PerformanceResult::PFfc_BARREL},
547  {"PFfc_ENDCAP", PerformanceResult::PFfc_ENDCAP},
548  {"PFfaEta_BARRELH", PerformanceResult::PFfaEta_BARRELH},
549  {"PFfaEta_ENDCAPH", PerformanceResult::PFfaEta_ENDCAPH},
550  {"PFfbEta_BARRELH", PerformanceResult::PFfbEta_BARRELH},
551  {"PFfbEta_ENDCAPH", PerformanceResult::PFfbEta_ENDCAPH},
552  {"PFfaEta_BARRELEH", PerformanceResult::PFfaEta_BARRELEH},
553  {"PFfaEta_ENDCAPEH", PerformanceResult::PFfaEta_ENDCAPEH},
554  {"PFfbEta_BARRELEH", PerformanceResult::PFfbEta_BARRELEH},
555  {"PFfbEta_ENDCAPEH", PerformanceResult::PFfbEta_ENDCAPEH},
556  {"PFfcEta_BARRELH", PerformanceResult::PFfcEta_BARRELH},
557  {"PFfcEta_ENDCAPH", PerformanceResult::PFfcEta_ENDCAPH},
558  {"PFfdEta_ENDCAPH", PerformanceResult::PFfdEta_ENDCAPH},
559  {"PFfcEta_BARRELEH", PerformanceResult::PFfcEta_BARRELEH},
560  {"PFfcEta_ENDCAPEH", PerformanceResult::PFfcEta_ENDCAPEH},
561  {"PFfdEta_ENDCAPEH", PerformanceResult::PFfdEta_ENDCAPEH}
562 
563  };
564 
565  for (std::map<std::string, PerformanceResult::ResultType>::const_iterator func = functType.begin();
566  func != functType.end();
567  ++func) {
568  cout << "Function: " << func->first << endl;
569  PerformanceResult::ResultType fType = func->second;
570  calib.pfCalibrations->printFormula(fType);
571  }
572 
573  } else {
574  std::cout << "Default calibration functions : " << std::endl;
575 
576  calib.faBarrel->Print();
577  calib.fbBarrel->Print();
578  calib.fcBarrel->Print();
579  calib.faEtaBarrelEH->Print();
580  calib.fbEtaBarrelEH->Print();
581  calib.faEtaBarrelH->Print();
582  calib.fbEtaBarrelH->Print();
583  calib.faEndcap->Print();
584  calib.fbEndcap->Print();
585  calib.fcEndcap->Print();
586  calib.faEtaEndcapEH->Print();
587  calib.fbEtaEndcapEH->Print();
588  calib.faEtaEndcapH->Print();
589  calib.fbEtaEndcapH->Print();
590  //
591  }
592 
593  return out;
594 }

References gather_cfg::cout, TrackCollections2monitor_cff::func, MillePedeFileConverter_cfg::out, PerformanceResult::PFfa_BARREL, PerformanceResult::PFfa_ENDCAP, PerformanceResult::PFfaEta_BARRELEH, PerformanceResult::PFfaEta_BARRELH, PerformanceResult::PFfaEta_ENDCAPEH, PerformanceResult::PFfaEta_ENDCAPH, PerformanceResult::PFfb_BARREL, PerformanceResult::PFfb_ENDCAP, PerformanceResult::PFfbEta_BARRELEH, PerformanceResult::PFfbEta_BARRELH, PerformanceResult::PFfbEta_ENDCAPEH, PerformanceResult::PFfbEta_ENDCAPH, PerformanceResult::PFfc_BARREL, PerformanceResult::PFfc_ENDCAP, PerformanceResult::PFfcEta_BARRELEH, PerformanceResult::PFfcEta_BARRELH, PerformanceResult::PFfcEta_ENDCAPEH, PerformanceResult::PFfcEta_ENDCAPH, PerformanceResult::PFfdEta_ENDCAPEH, and PerformanceResult::PFfdEta_ENDCAPH.

PerformanceResult::PFfbEta_ENDCAPEH
Definition: PerformanceResult.h:58
PerformanceResult::PFfaEta_ENDCAPEH
Definition: PerformanceResult.h:56
gather_cfg.cout
cout
Definition: gather_cfg.py:144
PerformanceResult::PFfcEta_BARRELH
Definition: PerformanceResult.h:60
PerformanceResult::PFfa_ENDCAP
Definition: PerformanceResult.h:42
PerformanceResult::PFfa_BARREL
Definition: PerformanceResult.h:41
PerformanceResult::PFfcEta_BARRELEH
Definition: PerformanceResult.h:61
PerformanceResult::PFfb_ENDCAP
Definition: PerformanceResult.h:44
PerformanceResult::PFfc_BARREL
Definition: PerformanceResult.h:45
PerformanceResult::PFfaEta_BARRELH
Definition: PerformanceResult.h:51
calib
Definition: CalibElectron.h:12
PerformanceResult::PFfbEta_BARRELEH
Definition: PerformanceResult.h:57
PerformanceResult::PFfc_ENDCAP
Definition: PerformanceResult.h:46
PerformanceResult::ResultType
ResultType
Definition: PerformanceResult.h:8
PerformanceResult::PFfdEta_ENDCAPH
Definition: PerformanceResult.h:64
PerformanceResult::PFfbEta_BARRELH
Definition: PerformanceResult.h:53
PerformanceResult::PFfcEta_ENDCAPEH
Definition: PerformanceResult.h:63
PerformanceResult::PFfaEta_BARRELEH
Definition: PerformanceResult.h:55
TrackCollections2monitor_cff.func
func
Definition: TrackCollections2monitor_cff.py:359
PerformanceResult::PFfdEta_ENDCAPEH
Definition: PerformanceResult.h:65
PerformanceResult::PFfaEta_ENDCAPH
Definition: PerformanceResult.h:52
PerformanceResult::PFfcEta_ENDCAPH
Definition: PerformanceResult.h:62
PerformanceResult::PFfb_BARREL
Definition: PerformanceResult.h:43
MillePedeFileConverter_cfg.out
out
Definition: MillePedeFileConverter_cfg.py:31
PerformanceResult::PFfbEta_ENDCAPH
Definition: PerformanceResult.h:54