Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PPS lhcInfo split: per fill and per LS PopCon #40817

Merged
merged 1 commit into from Apr 27, 2023

Conversation

JanChyczynski
Copy link
Contributor

@JanChyczynski JanChyczynski commented Feb 20, 2023

PR description:

Populator of Conditions for the new records, LHCInfoPerLS and LHCInfoPerFill introduced in PR39495, to be used instead of LHCInfo. Manages the data sources (OMS, CTPPS OnlineDB, DIP), creates objects of the new classes and writes them to the ofline database (CondDB). Heavily based on original LHCInfo PopCon.

The main mechanism is to take fills data from OMS (filtered by time and having stable beam), iterate through them and for every fill (meeting certian coditions depending on the mode and record) get data from all the sources, create payloads and write them to the offline database.

There are separate programs for ...perLS and ...perFill classess. Both of them have 2 modes: duringFill and endFill.

The duringFill mode, when ran, writes data (just 1 payload of most recent data) only for ongoing fills and only during stable beam. PerFill PopCon writes the payload only once per fill, and perLS PopCon writes a payload every time it's run during a stable beam.

The endFill processes a fill only once, after it's ended. PerFill PopCon writes payloads corresponding to all the lumisections of the fill (filtered for duplicates), and perLS PopCon writes 2 payloads: corresponding to the start, and the end of the stable beam of the fill.

The worklows are ment to be run by python scripts located in CondTools/RunInfo/python:

LHCInfoPerFillPopConAnalyzerDuringFill.py
LHCInfoPerFillPopConAnalyzerEndFill.py
LHCInfoPerLSPopConAnalyzerDuringFill.py
LHCInfoPerLSPopConAnalyzerEndFill.py

more info: presentation on LHCInfo update from AlCaDBmeeting

PR validation:

The python scripts running the workflow were tested on several defferent periods of time (set by the startTime and endTime parameters) by analysing the logs and data in the written payloads.

cd CondTools/RunInfo/python
cmsRun LHCInfoPerFillPopConAnalyzerDuringFill.py = tag=lhcInfoPerFill_during
cmsRun LHCInfoPerFillPopConAnalyzerEndFill.py = tag=lhcInfoPerFill_end
cmsRun LHCInfoPerLSPopConAnalyzerDuringFill.py = tag=lhcInfoPerLS_during
cmsRun LHCInfoPerLSPopConAnalyzerEndFill.py = tag=lhcInfoPerLS_end

To run the PopCon the PPS database keys are required (located in .cms_cond folder in path you can specify in authenticationPath argument in the python script).

The new PopCon was also used in further development (update of proton reconstruction, to be submitted in the next PR).

@cmsbuild
Copy link
Contributor

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-40817/34268

@cmsbuild
Copy link
Contributor

A new Pull Request was created by @JanChyczynski (jan_chyczynski) for master.

It involves the following packages:

  • CondTools/RunInfo (db)

@malbouis, @cmsbuild, @saumyaphor4252, @ggovi, @francescobrivio, @tvami can you please review it and eventually sign? Thanks.
@mmusich this is something you requested to watch as well.
@perrotta, @dpiparo, @rappoccio you are the release manager for this.

cms-bot commands are listed here

@JanChyczynski JanChyczynski changed the title lhcInfo split: per fill and per LS PopCon PPS lhcInfo split: per fill and per LS PopCon Feb 20, 2023
@JanChyczynski JanChyczynski marked this pull request as ready for review February 21, 2023 23:30
Copy link
Contributor

@tvami tvami left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let me send you a partial review. I also didn't comment on each places, but there are a few recurring problems, please fix them at each occurance

CondTools/RunInfo/src/LHCInfoPerFillPopConSourceHandler.cc Outdated Show resolved Hide resolved
CondTools/RunInfo/src/LHCInfoPerFillPopConSourceHandler.cc Outdated Show resolved Hide resolved
Comment on lines 6 to 10
#include "CondCore/PopCon/interface/PopConSourceHandler.h"
#include "CondFormats/RunInfo/interface/LHCInfoPerLS.h"
#include "FWCore/ParameterSet/interface/ParameterSetfwd.h"
#include "CondCore/CondDB/interface/Types.h"
#include "CondTools/RunInfo/interface/OMSAccess.h"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please alpha order this

@@ -0,0 +1,535 @@
#include "FWCore/MessageLogger/interface/MessageLogger.h"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

alpha order

}
//L1: try with different m_dipSchema
//L2: try with different m_name
LHCInfoPerLSPopConSourceHandler::~LHCInfoPerLSPopConSourceHandler() {}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

default as earlier

CondTools/RunInfo/src/LHCInfoPerFillPopConSourceHandler.cc Outdated Show resolved Hide resolved
@tvami
Copy link
Contributor

tvami commented Feb 23, 2023

To run the PopCon the PPS database keys are required

I'm a bit confused.. In the end we dont want to upload to a private PPD DB, right? We want to upload to the main CondDB, so why are PPS specific keys needed?

@vavati
Copy link

vavati commented Feb 27, 2023

@tvami : Several data are coming from PPS database -> PopCon -> LHCInfo

@tvami
Copy link
Contributor

tvami commented Feb 27, 2023

ciao @vavati thanks! I'm just wondering how we could have some tests in CMSSW. The bot has some credentials but I dont know if it has the PPS keys, @smuzaffar do you recall anything connected to PPS in the bot credentials?

@smuzaffar
Copy link
Contributor

smuzaffar commented Feb 28, 2023

bot has ~/.cms_cond/db.key but I do not know if it contains PPS keys or not

@francescobrivio
Copy link
Contributor

bot has ~/.cms_cond/db.key but I do not know if it contains PPS keys or not

ok I think I have fixed this (i.e. given the permission to read the needed DBs to the IB key), so the next round of tests (after the comments are addressed) should work fine.

@tvami
Copy link
Contributor

tvami commented Mar 1, 2023

bot has ~/.cms_cond/db.key but I do not know if it contains PPS keys or not

ok I think I have fixed this (i.e. given the permission to read the needed DBs to the IB key), so the next round of tests (after the comments are addressed) should work fine.

Great! So @JanChyczynski let's add unit tests that runs

LHCInfoPerFillPopConAnalyzerDuringFill.py
LHCInfoPerFillPopConAnalyzerEndFill.py
LHCInfoPerLSPopConAnalyzerDuringFill.py
LHCInfoPerLSPopConAnalyzerEndFill.py

in CMSSW

@tvami
Copy link
Contributor

tvami commented Mar 13, 2023

@JanChyczynski do you have any updates on this PR?

@JanChyczynski
Copy link
Contributor Author

@JanChyczynski do you have any updates on this PR?

I made all the suggested changes but I'm still working on the unit tests.

@JanChyczynski
Copy link
Contributor Author

I've just pushed a few commits with the suggested changes and the unit tests (I'll squash them after the review).
It will still need some work because of the problem with fillDescritpion I described in the answer to your comment.

@cmsbuild
Copy link
Contributor

cmsbuild commented Apr 4, 2023

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-40817/35042

  • This PR adds an extra 28KB to repository

@cmsbuild
Copy link
Contributor

cmsbuild commented Apr 4, 2023

Pull request #40817 was updated. @cmsbuild, @tvami, @saumyaphor4252, @francescobrivio can you please check and sign again.

@JanChyczynski
Copy link
Contributor Author

when the review will be considered done

what else is missing? I thought you addressed all comments

Nothing is missing, I addressed all the comments. I just didn't want to squash it as you might have wanted to look at the last commits in separate to see how I addressed the last issues. If you have no further comments I guess it's done and I'll go ahead and squash them

@tvami
Copy link
Contributor

tvami commented Apr 25, 2023

@cmsbuild , please test

@cmsbuild
Copy link
Contributor

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-40817/35268

  • This PR adds an extra 28KB to repository

@cmsbuild
Copy link
Contributor

Pull request #40817 was updated. @tvami, @saumyaphor4252, @francescobrivio can you please check and sign again.

@cmsbuild
Copy link
Contributor

+1

Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-1b1fdd/32132/summary.html
COMMIT: 6b35a12
CMSSW: CMSSW_13_1_X_2023-04-25-1100/el8_amd64_gcc11
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week0/cms-sw/cmssw/40817/32132/install.sh to create a dev area with all the needed externals and cmssw changes.

Comparison Summary

Summary:

  • You potentially added 7 lines to the logs
  • Reco comparison results: 3 differences found in the comparisons
  • DQMHistoTests: Total files compared: 48
  • DQMHistoTests: Total histograms compared: 3460685
  • DQMHistoTests: Total failures: 6
  • DQMHistoTests: Total nulls: 0
  • DQMHistoTests: Total successes: 3460657
  • DQMHistoTests: Total skipped: 22
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: 0.0 KiB( 47 files compared)
  • Checked 207 log files, 159 edm output root files, 48 DQM output files
  • TriggerResults: no differences found

@tvami
Copy link
Contributor

tvami commented Apr 26, 2023

+db

  • tests pass, we agreed to have a few follow-up PR

@cmsbuild
Copy link
Contributor

This pull request is fully signed and it will be integrated in one of the next master IBs (tests are also fine). This pull request will now be reviewed by the release team before it's merged. @perrotta, @dpiparo, @rappoccio (and backports should be raised in the release meeting by the corresponding L2)

@rappoccio
Copy link
Contributor

+1

@cmsbuild cmsbuild merged commit 7fefea9 into cms-sw:master Apr 27, 2023
11 checks passed
iarspider added a commit to iarspider-cmssw/cmssw that referenced this pull request Apr 28, 2023
The test was introduced in cms-sw#40817 and fails for non-amd64 architectures: it connects to Oracle databases, and proprietary libraries for that are only available for amd64.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet