Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
abb7c23
Implement a LHCInfo inspired class with just a few variables needed f…
wpcarvalho Feb 25, 2022
cade95d
Merged pps_lhcInfo from repository wpcarvalho with cms-merge-topic
JanChyczynski Jul 13, 2022
0f20d39
renamed LHCInfoForPPS to LHCInfoPerLS
JanChyczynski Jul 13, 2022
b820dfc
moved LHCInfoPerLS from PPS to RunInfo
JanChyczynski Jul 13, 2022
3fda01a
split betaStar and crossingAngle for x and y
JanChyczynski Jul 13, 2022
698c472
LHCInfoPerFill class implemented
JanChyczynski Jul 13, 2022
a09b1b6
other files for LHCInfoPerFill condtions object definition aded/modified
JanChyczynski Jul 13, 2022
3a30c89
moved vectorized fields handling to a new class LHCInfoVectorizedFields
JanChyczynski Jul 18, 2022
f34c528
exctracted common code to LHCInfoVectorizedFields, added empty m_time…
JanChyczynski Jul 19, 2022
7b5b102
removed explicit values in enums
JanChyczynski Jul 19, 2022
2bfe104
changed throwing std::out_of_range to cond::Exception
JanChyczynski Jul 19, 2022
11b7d3d
added setup READMY.md
JanChyczynski Jul 19, 2022
d59bfd6
added fields definitions to classes_def.xml
JanChyczynski Jul 21, 2022
552bea1
simple tests: writing and retrieving objects of new classes in sqlite DB
JanChyczynski Jul 22, 2022
7e07683
improved tests data and removed old commented code
JanChyczynski Jul 26, 2022
6f9f141
Added new CondFormats to Module_2XML.cc and CondFormats.h
JanChyczynski Aug 1, 2022
6a2e73e
fixed PopCon lumisection query limit
JanChyczynski Aug 10, 2022
6b3501c
added fill number field to LHCInfoPerLS
JanChyczynski Aug 12, 2022
190a475
added run number field to LHCInfoPerLS
JanChyczynski Aug 16, 2022
10cbd4a
created perLS PopCon: cloned old one, removed irrelevant code and adj…
JanChyczynski Aug 18, 2022
821d773
populating crossing angle Y and beta* Y
JanChyczynski Aug 18, 2022
dc39517
populating run number
JanChyczynski Aug 19, 2022
89aa690
implemented startFill mode of perLS PopCon
JanChyczynski Aug 29, 2022
b7820e8
implemented perFill PopCon
JanChyczynski Sep 1, 2022
0df2189
removed unused code, made some debug info be printed only in debug mode
JanChyczynski Sep 2, 2022
acc22e4
moved populating run number from getLumiData to getCTPSData
JanChyczynski Sep 5, 2022
d001950
added payload at start of SB in perFill endfill PopCon, removed 1 cas…
JanChyczynski Sep 5, 2022
d2d4366
added greater or equal and less or equal filters to OMSServiceQuery
JanChyczynski Sep 5, 2022
7cf8bac
fixed perFill and perLS PopCons skipping fills
JanChyczynski Sep 5, 2022
dece499
changed beta star unit in print method to meters
JanChyczynski Sep 5, 2022
fde9ee5
TMP py scripts changes and old popcon debug
JanChyczynski Sep 6, 2022
59248bb
LHCInfoCombined and its use in CTPPSProtonProducer
JanChyczynski Sep 7, 2022
f3b8229
changed proton reconstruction functions to use only energy instead of…
JanChyczynski Sep 12, 2022
1feaa36
update test_express_AlCaRecoProducer.sh for Run3
JanChyczynski Sep 16, 2022
23597a2
added print to LHCInfoCombined
JanChyczynski Sep 16, 2022
5e99b08
printing debug info in CTPPSProtonProducer
JanChyczynski Sep 16, 2022
11ccfd7
CTPPSProton debug changed from LogInfo to LogWarning, energy debug pr…
JanChyczynski Sep 20, 2022
9545c44
added optics file to test_express_AlCaRecoProducer.sh
JanChyczynski Sep 21, 2022
d334850
removed getters and setters from LHCInfoCombined
JanChyczynski Sep 21, 2022
ad057e8
removed the new records from dlasses_def.xml
JanChyczynski Sep 23, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CalibPPS/ESProducers/python/ctppsLHCInfo_cff.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

# by default, LHCInfo is now loaded from CondDB using a GT
ctppsLHCInfoLabel = cms.string("")
ctppsLHCInfoPerLSLabel = cms.string("")
ctppsLHCInfoPerFillLabel = cms.string("")

## minimal LHCInfo for 2016 data
#ctppsLHCInfoLabel = cms.string("ctpps_minimal")
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
print("in file ALCARECOPPSCalMaxTracks_cff.py")

import FWCore.ParameterSet.Config as cms

# 1. HLT filter
Expand All @@ -14,9 +16,12 @@
from EventFilter.CTPPSRawToDigi.ctppsRawToDigi_cff import totemTimingRawToDigi as _totemTimingRawToDigi
from EventFilter.CTPPSRawToDigi.ctppsRawToDigi_cff import ctppsPixelDigis as _ctppsPixelDigis

ctppsDiamondRawToDigiAlCaRecoProducer = _ctppsDiamondRawToDigi.clone(rawDataTag = 'hltPPSCalibrationRaw')
totemTimingRawToDigiAlCaRecoProducer = _totemTimingRawToDigi.clone(rawDataTag = 'hltPPSCalibrationRaw')
ctppsPixelDigisAlCaRecoProducer = _ctppsPixelDigis.clone(inputLabel = 'hltPPSCalibrationRaw')
# ctppsDiamondRawToDigiAlCaRecoProducer = _ctppsDiamondRawToDigi.clone(rawDataTag = 'hltPPSCalibrationRaw')
# totemTimingRawToDigiAlCaRecoProducer = _totemTimingRawToDigi.clone(rawDataTag = 'hltPPSCalibrationRaw')
# ctppsPixelDigisAlCaRecoProducer = _ctppsPixelDigis.clone(inputLabel = 'hltPPSCalibrationRaw')
ctppsDiamondRawToDigiAlCaRecoProducer = _ctppsDiamondRawToDigi.clone(rawDataTag = 'rawDataCollector')
totemTimingRawToDigiAlCaRecoProducer = _totemTimingRawToDigi.clone(rawDataTag = 'rawDataCollector')
ctppsPixelDigisAlCaRecoProducer = _ctppsPixelDigis.clone(inputLabel = 'rawDataCollector')

ctppsRawToDigiTaskAlCaRecoProducer = cms.Task(
ctppsDiamondRawToDigiAlCaRecoProducer,
Expand Down Expand Up @@ -85,7 +90,8 @@
)

from RecoPPS.ProtonReconstruction.ctppsProtons_cff import ctppsProtons as _ctppsProtons
ctppsProtonsAlCaRecoProducer = _ctppsProtons.clone(tagLocalTrackLite = 'ctppsLocalTrackLiteProducerAlCaRecoProducer')
ctppsProtonsAlCaRecoProducer = _ctppsProtons.clone(tagLocalTrackLite = 'ctppsLocalTrackLiteProducerAlCaRecoProducer',
verbosity = cms.untracked.uint32(2))

# 5. RECO - final task assembly
#------------------------------------------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,16 @@
function die { echo $1: status $2; exit $2; }

customise_commands="process.GlobalTag.toGet = cms.VPSet()\
\nprocess.GlobalTag.toGet.append(cms.PSet(record = cms.string(\"LHCInfoPerLSRcd\"),tag = cms.string(\"LHCInfoPerLS_end_2\"), connect = cms.string(\"sqlite_file:/eos/home-j/jchyczyn/new/CMSSW_12_5_0_pre3/src/CondTools/RunInfo/python/lhcinfo_pop_test.db\")))\
\nprocess.GlobalTag.toGet.append(cms.PSet(record = cms.string(\"CTPPSOpticsRcd\"),tag = cms.string(\"PPSOpticalFunctions_test\"), connect = cms.string(\"sqlite_file:/afs/cern.ch/user/w/wcarvalh/public/CTPPS/optical_functions/validation/Aug22/PPSOpticalFunctions_singleIOV_2022_with_verticals.db\")))\
\nprocess.GlobalTag.toGet.append(cms.PSet(record = cms.string(\"LHCInfoPerFillRcd\"),tag = cms.string(\"LHCInfoPerFill_end_2\"), connect = cms.string(\"sqlite_file:/eos/home-j/jchyczyn/new/CMSSW_12_5_0_pre3/src/CondTools/RunInfo/python/lhcinfo_pop_test.db\")))\
\nprocess.GlobalTag.toGet.append(cms.PSet(record = cms.string(\"LHCInfoRcd\"),tag = cms.string(\"LHCInfo_end_2\"), connect = cms.string(\"sqlite_file:/eos/home-j/jchyczyn/new/CMSSW_12_5_0_pre3/src/CondTools/RunInfo/python/lhcinfo_pop_test.db\")))\
\nprocess.GlobalTag.toGet.append(cms.PSet(record = cms.string(\"AlCaRecoTriggerBitsRcd\"),tag = cms.string(\"AlCaRecoHLTpaths_PPS2022_express_v1\"), connect = cms.string(\"frontier://FrontierProd/CMS_CONDITIONS\")))\
\nprocess.GlobalTag.toGet.append(cms.PSet(record = cms.string(\"PPSTimingCalibrationLUTRcd\"),tag = cms.string(\"PPSDiamondTimingCalibrationLUT_test\"), connect = cms.string(\"frontier://FrontierProd/CMS_CONDITIONS\")))\
\nprocess.ALCARECOPPSCalMaxTracksFilter.TriggerResultsTag = cms.InputTag(\"TriggerResults\",\"\",\"HLTX\")"
\nprocess.GlobalTag.toGet.append(cms.PSet(record = cms.string(\"PPSTimingCalibrationLUTRcd\"),tag = cms.string(\"PPSDiamondTimingCalibrationLUT_test\"), connect = cms.string(\"frontier://FrontierProd/CMS_CONDITIONS\")))"
# \nprocess.ALCARECOPPSCalMaxTracksFilter.TriggerResultsTag = cms.InputTag(\"TriggerResults\",\"\",\"HLT\")"

INPUTFILE="/store/group/alca_global/pps_alcareco_producer_tests/outputALCAPPS_single.root"
INPUTFILE="/store/data/Run2022C/ZeroBias/RAW/v1/000/356/615/00000/a4076bff-3bec-459e-bd44-b66538bf5c2b.root"
# INPUTFILE="/store/group/alca_global/pps_alcareco_producer_tests/outputALCAPPS_single.root"
COMMMAND=`xrdfs cms-xrd-global.cern.ch locate $INPUTFILE`
STATUS=$?
echo "xrdfs command status = "$STATUS
Expand All @@ -15,13 +20,13 @@ if [ $STATUS -eq 0 ]; then
(cmsDriver.py testExpressPPSAlCaRecoProducer -s ALCAPRODUCER:PPSCalMaxTracks,ENDJOB \
--process ALCARECO \
--scenario pp \
--era ctpps_2018 \
--era run3_HB \
--conditions auto:run3_data_express \
--data \
--datatier ALCARECO \
--eventcontent ALCARECO \
--nThreads 8 \
--number 100 --filein ${INPUTFILE} \
--number 10000 --filein ${INPUTFILE} \
--fileout file:outputALCAPPS_RECO_express.root \
--customise_commands="$customise_commands") || die 'failed running test_express_AlCaRecoProducer' $?
else
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
import FWCore.ParameterSet.Config as cms

# load era modifier to run on 2018 data
from Configuration.Eras.Modifier_ctpps_2018_cff import ctpps_2018
# from Configuration.Eras.Modifier_ctpps_2018_cff import ctpps_2018
from Configuration.Eras.Modifier_ctpps_2022_cff import ctpps_2022

process = cms.Process( 'TEST',ctpps_2018)
process = cms.Process( 'TEST',ctpps_2022)

# LHCInfo plotter
process.load("Validation.CTPPS.ctppsLHCInfoPlotter_cfi")
Expand Down
6 changes: 6 additions & 0 deletions CondCore/RunInfoPlugins/src/plugin.cc
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,16 @@
#include "CondFormats/RunInfo/interface/FillInfo.h"
#include "CondFormats/DataRecord/interface/LHCInfoRcd.h"
#include "CondFormats/RunInfo/interface/LHCInfo.h"
#include "CondFormats/DataRecord/interface/LHCInfoPerLSRcd.h"
#include "CondFormats/RunInfo/interface/LHCInfoPerLS.h"
#include "CondFormats/DataRecord/interface/LHCInfoPerFillRcd.h"
#include "CondFormats/RunInfo/interface/LHCInfoPerFill.h"

REGISTER_PLUGIN(RunSummaryRcd, RunSummary);
REGISTER_PLUGIN(RunInfoRcd, RunInfo);
REGISTER_PLUGIN(L1TriggerScalerRcd, L1TriggerScaler);
REGISTER_PLUGIN(MixingRcd, MixingModuleConfig);
REGISTER_PLUGIN(FillInfoRcd, FillInfo);
REGISTER_PLUGIN(LHCInfoRcd, LHCInfo);
REGISTER_PLUGIN(LHCInfoPerLSRcd, LHCInfoPerLS);
REGISTER_PLUGIN(LHCInfoPerFillRcd, LHCInfoPerFill);
2 changes: 2 additions & 0 deletions CondCore/Utilities/plugins/Module_2XML.cc
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,8 @@ PAYLOAD_2XML_MODULE(pluginUtilities_payload2xml) {
PAYLOAD_2XML_CLASS(L1TriggerKeyExt);
PAYLOAD_2XML_CLASS(L1TriggerKeyListExt);
PAYLOAD_2XML_CLASS(LHCInfo);
PAYLOAD_2XML_CLASS(LHCInfoPerFill);
PAYLOAD_2XML_CLASS(LHCInfoPerLS);
PAYLOAD_2XML_CLASS(METCorrectorParametersCollection);
PAYLOAD_2XML_CLASS(MEtXYcorrectParametersCollection);
PAYLOAD_2XML_CLASS(MagFieldConfig);
Expand Down
3 changes: 3 additions & 0 deletions CondCore/Utilities/src/CondFormats.h
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,9 @@
#include "CondFormats/RecoMuonObjects/interface/DYTParamObject.h"
#include "CondFormats/RunInfo/interface/RunInfo.h"
#include "CondFormats/RunInfo/interface/LHCInfo.h"
#include "CondFormats/RunInfo/interface/LHCInfoVectorizedFields.h"
#include "CondFormats/RunInfo/interface/LHCInfoPerFill.h"
#include "CondFormats/RunInfo/interface/LHCInfoPerLS.h"
#include "CondFormats/RunInfo/interface/MixingModuleConfig.h"
#include "CondFormats/SiPixelObjects/interface/SiPixelCalibConfiguration.h"
#include "CondFormats/SiPixelObjects/interface/SiPixelCPEGenericErrorParm.h"
Expand Down
25 changes: 25 additions & 0 deletions CondFormats/DataRecord/interface/LHCInfoPerFillRcd.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
#ifndef LHCInfoPerFillRcd_LHCInfoPerFillRcd_h
#define LHCInfoPerFillRcd_LHCInfoPerFillRcd_h
// -*- C++ -*-
//
// Package: CondFormats/DataRecord
// Class : LHCInfoPerFillRcd
//
/**\class LHCInfoPerFillRcd LHCInfoPerFillRcd.h CondFormats/DataRecord/interface/LHCInfoPerFillRcd.h

Description: [one line class summary]

Usage:
<usage>

*/
//
// Author: Jan Krzysztof Chyczynski
// Created: Wed, 13 Jul 2022 16:36:24 GMT
//

#include "FWCore/Framework/interface/EventSetupRecordImplementation.h"

class LHCInfoPerFillRcd : public edm::eventsetup::EventSetupRecordImplementation<LHCInfoPerFillRcd> {};

#endif
26 changes: 26 additions & 0 deletions CondFormats/DataRecord/interface/LHCInfoPerLSRcd.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
#ifndef DataRecord_LHCInfoPerLSRcd_h
#define DataRecord_LHCInfoPerLSRcd_h
// -*- C++ -*-
//
// Package: DataRecord
// Class : LHCInfoPerLSRcd
//
/**\class LHCInfoPerLSRcd LHCInfoPerLSRcd.h CondFormats/DataRecord/interface/LHCInfoPerLSRcd.h

Description: [one line class summary]

Usage:
<usage>

*/
//
// Author:
// Created: Tue Feb 15 2022
// $Id$
//

#include "FWCore/Framework/interface/EventSetupRecordImplementation.h"

class LHCInfoPerLSRcd : public edm::eventsetup::EventSetupRecordImplementation<LHCInfoPerLSRcd> {};

#endif
15 changes: 15 additions & 0 deletions CondFormats/DataRecord/src/LHCInfoPerFillRcd.cc
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
// -*- C++ -*-
//
// Package: CondFormats/DataRecord
// Class : LHCInfoPerFillRcd
//
// Implementation:
// [Notes on implementation]
//
// Author: Jan Krzysztof Chyczynski
// Created: Wed, 13 Jul 2022 16:36:24 GMT

#include "CondFormats/DataRecord/interface/LHCInfoPerFillRcd.h"
#include "FWCore/Framework/interface/eventsetuprecord_registration_macro.h"

EVENTSETUP_RECORD_REG(LHCInfoPerFillRcd);
16 changes: 16 additions & 0 deletions CondFormats/DataRecord/src/LHCInfoPerLSRcd.cc
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
// -*- C++ -*-
//
// Package: DataRecord
// Class : LHCInfoPerLSRcd
//
// Implementation:
// [Notes on implementation]
//
// Author:
// Created: Tue Feb 15 2022
// $Id$

#include "CondFormats/DataRecord/interface/LHCInfoPerLSRcd.h"
#include "FWCore/Framework/interface/eventsetuprecord_registration_macro.h"

EVENTSETUP_RECORD_REG(LHCInfoPerLSRcd);
3 changes: 3 additions & 0 deletions CondFormats/RunInfo/BuildFile.xml
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
<use name="CondFormats/Common"/>
<use name="CondFormats/Serialization"/>
<use name="CondCore/CondDB"/>
<use name="FWCore/ParameterSet"/>
<use name="FWCore/Utilities"/>
<use name="CoralBase"/>
<use name="boost_serialization"/>
<use name="FWCore/Framework"/>
<use name="CondFormats/DataRecord"/>
<export>
<lib name="1"/>
</export>
56 changes: 56 additions & 0 deletions CondFormats/RunInfo/interface/LHCInfoCombined.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
#ifndef CondFormats_RunInfo_LHCInfoCombined_H
#define CondFormats_RunInfo_LHCInfoCombined_H

#include "FWCore/Framework/interface/Frameworkfwd.h"
#include "FWCore/Framework/interface/one/EDAnalyzer.h"
#include "FWCore/Framework/interface/Event.h"
#include "FWCore/Framework/interface/EventSetup.h"
#include "FWCore/Framework/interface/ESHandle.h"
#include "FWCore/Framework/interface/ESWatcher.h"
#include "FWCore/Framework/interface/MakerMacros.h"
#include "FWCore/Framework/interface/ConsumesCollector.h"

#include "CondFormats/RunInfo/interface/LHCInfo.h"
#include "CondFormats/RunInfo/interface/LHCInfoPerLS.h"
#include "CondFormats/RunInfo/interface/LHCInfoPerFill.h"

#include "CondFormats/DataRecord/interface/LHCInfoPerLSRcd.h"
#include "CondFormats/DataRecord/interface/LHCInfoPerFillRcd.h"
#include "CondFormats/DataRecord/interface/LHCInfoRcd.h"

#include "CondCore/CondDB/interface/Types.h"

#include <bitset>
#include <iostream>
#include <string>
#include <sstream>
#include <vector>

class LHCInfoCombined {
public:

LHCInfoCombined() = default;

LHCInfoCombined(const LHCInfo& lhcInfo);
LHCInfoCombined(const LHCInfoPerLS& infoPerLS, const LHCInfoPerFill& infoPerFill);
LHCInfoCombined(const edm::EventSetup &iSetup,
const edm::ESGetToken<LHCInfoPerLS, LHCInfoPerLSRcd>& tokenInfoPerLS,
const edm::ESGetToken<LHCInfoPerFill, LHCInfoPerFillRcd>& tokenInfoPerFill,
const edm::ESGetToken<LHCInfo, LHCInfoRcd>& tokenInfo);

void setFromLHCInfo(const LHCInfo& lhcInfo);
void setFromPerLS(const LHCInfoPerLS& infoPerLS);
void setFromPerFill(const LHCInfoPerFill& infoPerFill);

float crossingAngleX;
float crossingAngleY;
float betaStarX;
float betaStarY;
float energy;

void print(std::stringstream& ss) const;
};

std::ostream& operator<<(std::ostream& os, LHCInfoCombined beamInfo);

#endif // CondFormats_RunInfo_LHCInfoCombined_H
Loading