CMS 3D CMS Logo

Functions
Forest.cc File Reference
#include "L1Trigger/L1TMuonEndCap/interface/bdt/Forest.h"
#include "L1Trigger/L1TMuonEndCap/interface/bdt/Utilities.h"
#include "FWCore/ParameterSet/interface/FileInPath.h"
#include "TStopwatch.h"
#include "TString.h"
#include <iostream>
#include <sstream>
#include <algorithm>
#include <iterator>
#include <fstream>
#include <utility>

Go to the source code of this file.

Functions

bool compareEvents (Event *e1, Event *e2)
 
bool compareEventsById (Event *e1, Event *e2)
 

Function Documentation

◆ compareEvents()

bool compareEvents ( Event e1,
Event e2 
)

Definition at line 165 of file Forest.cc.

165  {
166  // Sort the events according to the variable given by the sortingIndex.
167  return e1->data[Event::sortingIndex] < e2->data[Event::sortingIndex];
168 }

References emtf::Event::data, StorageManager_cfg::e1, and emtf::Event::sortingIndex.

Referenced by emtf::Forest::sortEventVectors().

◆ compareEventsById()

bool compareEventsById ( Event e1,
Event e2 
)

Definition at line 173 of file Forest.cc.

173  {
174  // Sort the events by ID. We need this to produce rate plots.
175  return e1->id < e2->id;
176 }

References StorageManager_cfg::e1, and emtf::Event::id.

emtf::Event::data
std::vector< double > data
Definition: Event.h:29
StorageManager_cfg.e1
e1
Definition: StorageManager_cfg.py:16
emtf::Event::id
int id
Definition: Event.h:28