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

Support SMOG2 in LHCb bookkeping queries #2313

Open
chrisburr opened this issue Mar 23, 2024 · 2 comments
Open

Support SMOG2 in LHCb bookkeping queries #2313

chrisburr opened this issue Mar 23, 2024 · 2 comments
Assignees

Comments

@chrisburr
Copy link
Contributor

We have a new option for Run 3 in bokkeeping queries to specify the state of SMOG2 see here for details.

Ganga should support this too, I think it's just a matter of extended ganga's BKQuery object to support a SMOG2 field.

In [1]: import DIRAC; DIRAC.initialize()
   ...: from LHCbDIRAC.BookkeepingSystem.Client.BKQuery import BKQuery
   ...: bkq = BKQuery(bkQuery="/LHCb/Lead23/Beam6800GeV-VeloClosed-MagDown-Excl-UT/Real Data/SprucingPbPb23/90800000/IFT.DST")
   ...: bkq.setDQFlag(["OK","UNCHECKED"])
   ...: bkq.setOption("SMOG2", ["Argon"])
   ...: print(len(bkq.getLFNs()))
   ...: print(bkq.getQueryDict())
   ...:
2024-03-23 15:34:46 UTC Framework NOTICE:
136 files (1.3 TB) in directories:
2024-03-23 15:34:46 UTC Framework NOTICE: /lhcb/LHCb/Lead23/IFT.DST/00208343/0002/ 136 files
136
{'ConfigName': 'LHCb', 'ConfigVersion': 'Lead23', 'ConditionDescription': 'Beam6800GeV-VeloClosed-MagDown-Excl-UT', 'ProcessingPass': '/Real Data/SprucingPbPb23', 'EventType': '90800000', 'FileType': 'IFT.DST', 'Visible': 'Yes', 'DataTakingConditions': 'Beam6800GeV-VeloClosed-MagDown-Excl-UT', 'DataQuality': ['OK', 'UNCHECKED'], 'SMOG2': ['Argon']}

In [2]: bkq.setOption("SMOG2", ["Argon", "ArgonUnstable"])
   ...: print(len(bkq.getLFNs()))
   ...: print(bkq.getQueryDict())
2024-03-23 15:34:57 UTC Framework NOTICE:
157 files (1.5 TB) in directories:
2024-03-23 15:34:57 UTC Framework NOTICE: /lhcb/LHCb/Lead23/IFT.DST/00208343/0002/ 157 files
157
{'ConfigName': 'LHCb', 'ConfigVersion': 'Lead23', 'ConditionDescription': 'Beam6800GeV-VeloClosed-MagDown-Excl-UT', 'ProcessingPass': '/Real Data/SprucingPbPb23', 'EventType': '90800000', 'FileType': 'IFT.DST', 'Visible': 'Yes', 'DataTakingConditions': 'Beam6800GeV-VeloClosed-MagDown-Excl-UT', 'DataQuality': ['OK', 'UNCHECKED'], 'SMOG2': ['Argon', 'ArgonUnstable']}
@mesmith75 mesmith75 self-assigned this Mar 23, 2024
@mesmith75
Copy link
Contributor

mesmith75 commented Mar 23, 2024

This should be straightforward to do but I think the LHCbDirac API would benefit from being updated for the new option (e.g. here and the rest: https://gitlab.cern.ch/lhcb-dirac/LHCbDIRAC/-/blob/master/src/LHCbDIRAC/Interfaces/API/DiracLHCb.py?ref_type=heads#L394).

If you would prefer to leave it as is, I'll rejig what ganga uses.

@chrisburr
Copy link
Contributor Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants