Fork me on GitHub

Changeset 341014c in git for converters/pileup2root.cpp


Ignore:
Timestamp:
Feb 12, 2019, 9:29:17 PM (6 years ago)
Author:
Pavel Demin <pavel-demin@…>
Branches:
ImprovedOutputFile, Timing, llp, master
Children:
6455202
Parents:
45e58be
Message:

apply .clang-format to all .h, .cc and .cpp files

File:
1 edited

Legend:

Unmodified
Added
Removed
  • converters/pileup2root.cpp

    r45e58be r341014c  
    1717 */
    1818
    19 
    20 #include <stdexcept>
    2119#include <iostream>
    2220#include <sstream>
    23 
    24 #include <stdlib.h>
     21#include <stdexcept>
     22
    2523#include <signal.h>
    2624#include <stdio.h>
    27 
     25#include <stdlib.h>
     26
     27#include "TApplication.h"
    2828#include "TROOT.h"
    29 #include "TApplication.h"
    30 
     29
     30#include "TDatabasePDG.h"
    3131#include "TFile.h"
     32#include "TLorentzVector.h"
    3233#include "TObjArray.h"
     34#include "TParticlePDG.h"
    3335#include "TStopwatch.h"
    34 #include "TDatabasePDG.h"
    35 #include "TParticlePDG.h"
    36 #include "TLorentzVector.h"
    37 
    38 #include "classes/DelphesStream.h"
     36
    3937#include "classes/DelphesClasses.h"
    4038#include "classes/DelphesFactory.h"
    4139#include "classes/DelphesPileUpReader.h"
    42 
     40#include "classes/DelphesStream.h"
     41
     42#include "ExRootAnalysis/ExRootProgressBar.h"
     43#include "ExRootAnalysis/ExRootTreeBranch.h"
    4344#include "ExRootAnalysis/ExRootTreeWriter.h"
    44 #include "ExRootAnalysis/ExRootTreeBranch.h"
    45 #include "ExRootAnalysis/ExRootProgressBar.h"
    4645
    4746using namespace std;
     
    6261  while(reader->ReadParticle(pid, x, y, z, t, px, py, pz, e))
    6362  {
    64     particle = static_cast<GenParticle*>(branch->NewEntry());
     63    particle = static_cast<GenParticle *>(branch->NewEntry());
    6564
    6665    particle->PID = pid;
     
    8483
    8584    pdgParticle = pdg->GetParticle(pid);
    86     particle->Charge = pdgParticle ? Int_t(pdgParticle->Charge()/3.0) : -999;
     85    particle->Charge = pdgParticle ? Int_t(pdgParticle->Charge() / 3.0) : -999;
    8786
    8887    particle->Mass = pdgParticle ? pdgParticle->Mass() : -999.9;
     
    9291    cosTheta = TMath::Abs(momentum.CosTheta());
    9392    signPz = (momentum.Pz() >= 0.0) ? 1.0 : -1.0;
    94     eta = (cosTheta == 1.0 ? signPz*999.9 : momentum.Eta());
    95     rapidity = (cosTheta == 1.0 ? signPz*999.9 : momentum.Rapidity());
     93    eta = (cosTheta == 1.0 ? signPz * 999.9 : momentum.Eta());
     94    rapidity = (cosTheta == 1.0 ? signPz * 999.9 : momentum.Rapidity());
    9695
    9796    particle->Eta = eta;
     
    126125  if(argc != 3)
    127126  {
    128     cout << " Usage: " << appName << " output_file" << " input_file" << endl;
     127    cout << " Usage: " << appName << " output_file"
     128         << " input_file" << endl;
    129129    cout << " output_file - output file in ROOT format," << endl;
    130130    cout << " input_file - input binary pile-up file." << endl;
     
    199199  }
    200200}
    201 
    202 
Note: See TracChangeset for help on using the changeset viewer.