Beispiel #1
0
bool Jet::isGood() const {
    // bool passesPt = pt() > 30; // Bristol original value
    bool passesPt = pt() > 35;  // 19.07.11 Chris's value
    bool passesEta = fabs(eta()) < 2.4;
    bool jetID = false;
    //if (usedAlgorithm == JetAlgorithm::ParticleFlow || usedAlgorithm == JetAlgorithm::PF2PAT) {
    if (usedAlgorithm == JetAlgorithm::CA08PF || usedAlgorithm == JetAlgorithm::PF2PAT) {
        bool passNOD = NOD() > 1;
        bool passCEF = CEF() < 0.99;
        bool passNHF = NHF() < 0.99;
        bool passNEF = NEF() < 0.99;
        bool passCHF = true;
        bool passNCH = true;
        if (fabs(eta()) < 2.4) {
            passCHF = CHF() > 0;
            passNCH = NCH() > 0;
        }
        jetID = passNOD && passCEF && passNHF && passNEF && passCHF && passNCH;
    }
    else{
        bool passesEMF = emf() > 0.01;
        bool passesN90Hits = n90Hits() > 1;
        bool passesFHPD = fHPD() < 0.98;
        jetID = passesEMF && passesN90Hits && passesFHPD;
    }
    return passesPt && passesEta && jetID;
}
void Matrix::exportEMF(const QString& fileName)
{
	int width = numRows();
	int height = numCols();

	EmfPaintDevice emf(QSize(width, height), fileName);
	QPainter p(&emf);
	p.drawImage (QRect(0, 0, width, height), d_matrix_model->renderImage());
	p.end();
}
Beispiel #3
0
int main(int argc, char** argv) {

  std::string email_data = "";

  std::ifstream emf("fixtures/email.txt");

  std::string line;

  while(emf) {
    line = "";
    std::getline(emf, line);
    email_data += line + "\n";
  }

  test_parse_email(email_data);

  exit(0);

}