Skip to content

Commit 77274a4

Browse files
authored
Update syntax to use new build backend
See lhcb/starterkit-ci#4 * Fix building issues, PR #4 on starterkit-ci * Update htcondor links * Update pdg link
1 parent e5d9a88 commit 77274a4

36 files changed

Lines changed: 224 additions & 227 deletions

CONTRIBUTING.md

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -55,10 +55,9 @@ You can see your local version by using a web-browser to navigate to `http://loc
5555
[gh-fork-pull]: https://reflectoring.io/github-fork-and-pull/
5656

5757

58-
```eval_rst
59-
.. toctree::
60-
:hidden:
58+
```{toctree}
59+
:hidden:
6160
62-
CONDUCT.md
63-
LICENSE.md
61+
CONDUCT.md
62+
LICENSE.md
6463
```

README.md

Lines changed: 23 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,39 @@
11
# The LHCb Starterkit lessons ![Build Status](https://github.com/lhcb/starterkit-lessons/actions/workflows/build.yml/badge.svg)
22

3+
34
These are the lessons historically taught during the [LHCb Starterkit][starterkit].
45
These lessons focus on LHCb software from Runs 1 and 2. For Run 3, the software changed a lot and a [new set of Starterkit lessons][run3-starterkit] was written.
56
If you'd like to join the next workshop, visit [the website][starterkit] to find out when that will how and how to sign up.
67

8+
79
If you'd just like to learn about how to use the LHCb software, [read on](first-analysis-steps/README.md)!
810

11+
912
[starterkit]: https://lhcb.github.io/starterkit
1013
[run3-starterkit]: https://lhcb-starterkit-run3.docs.cern.ch/
1114
[first-analysis-steps]: https://lhcb.github.io/starterkit-lessons/first-analysis-steps/
1215

1316

14-
```eval_rst
15-
.. toctree::
16-
:maxdepth: 3
17-
:includehidden:
18-
:caption: Contents:
19-
20-
first-analysis-steps/README.md
21-
second-analysis-steps/README.md
22-
self-guided-lessons/README.md
23-
CONTRIBUTING.md
17+
```{toctree}
18+
:maxdepth: 3
19+
:includehidden:
20+
:caption: Contents:
2421
25-
.. toctree::
26-
:maxdepth: 2
27-
:includehidden:
28-
:caption: External links:
2922
30-
interesting-links/analysis-essentials.md
31-
LHCb Core documentation <https://cern.ch/lhcb-core-doc/>
32-
LHCb glossary <https://lhcb.github.io/glossary/>
23+
first-analysis-steps/README
24+
second-analysis-steps/README
25+
self-guided-lessons/README
26+
CONTRIBUTING
3327
```
28+
29+
30+
```{toctree}
31+
:maxdepth: 2
32+
:includehidden:
33+
:caption: External links:
34+
35+
36+
interesting-links/analysis-essentials
37+
LHCb Core documentation <https://cern.ch/lhcb-core-doc/>
38+
LHCb glossary <https://lhcb.github.io/glossary/>
39+
```

first-analysis-steps/README.md

Lines changed: 28 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -13,33 +13,32 @@ The [analysis essentials course](https://hsf-training.github.io/analysis-essenti
1313

1414
{% endprereq %}
1515

16-
```eval_rst
17-
.. toctree::
18-
:hidden:
19-
:caption: Contents:
20-
21-
prerequisites.md
22-
introduction-to-course.md
23-
physics-at-lhcb.md
24-
dataflow.md
25-
run-2-data-flow.md
26-
analysisflow.md
27-
davinci.md
28-
bookkeeping.md
29-
files-from-grid.md
30-
interactive-dst.md
31-
minimal-dv-job.md
32-
loki-functors.md
33-
add-tupletools.md
34-
decay-tree-fitter.md
35-
analysis-productions.md
36-
davinci-grid.md
37-
split-jobs.md
38-
ganga-data.md
39-
eos-storage.md
40-
lhcb-dev.md
41-
dataflow-run3.md
42-
asking-questions.md
43-
ecgd.md
44-
contributing-lesson.md
16+
```{toctree}
17+
:hidden:
18+
:caption: Contents:
19+
20+
prerequisites.md
21+
introduction-to-course.md
22+
physics-at-lhcb.md
23+
dataflow.md
24+
run-2-data-flow.md
25+
analysisflow.md
26+
davinci.md
27+
bookkeeping.md
28+
files-from-grid.md
29+
interactive-dst.md
30+
minimal-dv-job.md
31+
loki-functors.md
32+
add-tupletools.md
33+
decay-tree-fitter.md
34+
analysis-productions.md
35+
davinci-grid.md
36+
split-jobs.md
37+
ganga-data.md
38+
eos-storage.md
39+
lhcb-dev.md
40+
dataflow-run3.md
41+
asking-questions.md
42+
ecgd.md
43+
contributing-lesson.md
4544
```

first-analysis-steps/add-tupletools.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,7 @@ To add LoKi-based leaves to the tree, we need to use the `LoKi::Hybrid::TupleToo
164164
1. Its *name*, specified in the `addTupleTool` call after a `/`. This is
165165
very useful (and recommended) if we want to have different
166166
`LoKi::Hybrid::TupleTool` for each of our branches. For instance, we may
167-
want to add different information for the D*, the D0 and the soft `$ \pi $`:
167+
want to add different information for the D*, the D0 and the soft $\pi$:
168168

169169
```python
170170
dstar_hybrid = dtt.Dstar.addTupleTool('LoKi::Hybrid::TupleTool/LoKi_Dstar')

first-analysis-steps/analysis-productions.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ Before making any edits, you should create a branch for your changes, and switch
5959
git checkout -b ${USER}/starterkit-practice
6060
```
6161

62-
Now we need to create a folder to store all the things we're going to add for our new production. For this practice production, we'll continue with the `$ B^+ \to (J/\psi \to \mu^+ \mu^-) K^+ $` decays used in the previous few lessons, so we should name the folder appropriately:
62+
Now we need to create a folder to store all the things we're going to add for our new production. For this practice production, we'll continue with the $B^+ \to (J/\psi \to \mu^+ \mu^-) K^+$ decays used in the previous few lessons, so we should name the folder appropriately:
6363

6464
```bash
6565
mkdir starterkit
@@ -99,7 +99,7 @@ Bu2JpsiK_24c4_MagDown:
9999
Here, the unindented lines are the names of jobs (although `defaults` has a special function), and the indented lines are the options we're applying to those jobs. Using this file will create one job called `Bu2JpsiK_24c4_MagDown`, that will read in data from the provided bookkeeping path. All the options applied under `defaults` are automatically applied to all other jobs - very useful for avoiding repetition. The options we're using here are copied from the Run 3 DaVinci lesson:
100100

101101
* **application**: the version of DaVinci to use. Here we choose v64r12, see [here](http://lhcbdoc.web.cern.ch/lhcbdoc/davinci/) to check what versions are available.
102-
* **wg**: the working group this production is a part of. Since this is a `$ B^+ \to (J/\psi \to \mu^+ \mu^-) K^+ $` decay, we'll set this to `B2CC`.
102+
* **wg**: the working group this production is a part of. Since this is a $B^+ \to (J/\psi \to \mu^+ \mu^-) K^+$ decay, we'll set this to `B2CC`.
103103
* **inform**: optionally, you can enter your email address to receive updates on the status of your jobs.
104104
* **options**: the settings to use when running DaVinci. These are copied from the Run 3 DaVinci lesson.
105105
* **output**: the name of the output `.root` ntuples. These will get registered in bookkeeping as well.

first-analysis-steps/analysisflow.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ This is done using the software package called DaVinci.
2020

2121
{% endcallout %}
2222

23-
### Getting data files
23+
## Getting data files
2424

2525
After preselecting data either in the Stripping, Sprucing or triggering step, users can produce ROOT files containing _ntuples_, running the DaVinci application.
2626
An ntuple is a (often complex) data structure typically stored within a (ROOT) file, which contains information about events or candidates in the data sample, such as the candidate mass or trigger decision flags.
@@ -39,7 +39,7 @@ We will discuss the concept of analysis preservation a bit later in this lesson.
3939
In first analysis steps we cover both running DaVinci on [Ganga](https://lhcb.github.io/starterkit-lessons/first-analysis-steps/davinci-grid.html) and via [Analysis Productions](https://lhcb.github.io/starterkit-lessons/first-analysis-steps/analysis-productions.html).
4040

4141

42-
### Useful high energy physics analysis tools
42+
## Useful high energy physics analysis tools
4343

4444
After getting the ntuples a user usually develops new analysis code or expands an existing code, that their collaborators use.
4545
Analysis code is usually based on the popular high-energy physics software tools or on the more general data analysis tools, like [numpy](https://numpy.org/) or [pandas](https://pandas.pydata.org/).
@@ -66,7 +66,7 @@ This list is by no means exhaustive, so if there are any other tools you use oft
6666

6767
Discussions on the new analysis tools that might be useful for the LHCb community are held in the [Work Package 4](https://lhcb-dpa.web.cern.ch/lhcb-dpa/wp4/index.html) of the Data Processing & Analysis project (DPA).
6868

69-
### Analysis Preservation
69+
## Analysis Preservation
7070

7171
When the samples are ready one can proceed with developing the necessary macros and scripts to perform the analysis steps, such as applying additional selections, fitting distributions, computing efficiencies and acceptances, etc.
7272
Starting from the ntuples a typical analysis will consist of the following steps:

first-analysis-steps/bookkeeping.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ After this, a tree of various application and processing versions will
1010
eventually lead to the data you need.
1111

1212
So, before we can run our first DaVinci job we need to locate some events. In
13-
this tutorial we will use the decay `$ D^{* +} \to D^{0}\pi^{+} $` as an example,
14-
where the `$ D^{0} $` decays to `$ K^{-} K^{+} $`.
13+
this tutorial we will use the decay $ D^{* +} \to D^{0}\pi^{+} $ as an example,
14+
where the $D^{0}$ decays to $K^{-} K^{+}$.
1515

1616
{% objectives "Learning Objectives" %}
1717

@@ -40,8 +40,8 @@ representation of the [event
4040
type](https://cds.cern.ch/record/855452?ln=en). The text is the human
4141
readable version of that.
4242

43-
This sample of simulated events will only contain events where a `$ D^{* +} \to
44-
D^{0}(\to K^{-}K^{+})\pi^{+} $` was generated within the LHCb acceptance,
43+
This sample of simulated events will only contain events where a $D^{* +} \to
44+
D^{0}(\to K^{-}K^{+})\pi^{+}$ was generated within the LHCb acceptance,
4545
although the decay might not have been fully reconstructed. (Not all simulated
4646
samples have the same requirements made on the signal decay.)
4747

@@ -109,9 +109,9 @@ by typing this path and pressing the `Go` button.
109109

110110
Think of a decay and try to find a Monte Carlo sample for it. You could use
111111
the decay that your analysis is about, or if you don't have any ideas you
112-
could look for the semileptonic decay `$ \Lambda_{b}^{0} \to
113-
\Lambda_{c}^{+}\mu^{-}\bar{\nu}_{\mu} $`, where the `$ \Lambda_{c}^{+} $` decays
114-
to `$ pK^{-}\pi^{+} $`.
112+
could look for the semileptonic decay $\Lambda_{b}^{0} \to
113+
\Lambda_{c}^{+}\mu^{-}\bar{\nu}_{\mu}$, where the $\Lambda_{c}^{+}$ decays
114+
to $pK^{-}\pi^{+}$.
115115

116116
{% endchallenge %}
117117

first-analysis-steps/dataflow-run3.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,22 +11,22 @@
1111

1212
In Run 1 & 2 LHCb proved itself not only to be a high-precision
1313
heavy flavour physics experiment, but also extended the core physics programme to many different areas such as electroweak physics and fixed-target experiments. This incredible precision led to
14-
over 500 papers including breakthroughs such as the first discovery of `$ C\!P $`-violation in charm and the first observation of the decay `$ B_s^0\to \mu^+\mu^- $` among many others.
14+
over 500 papers including breakthroughs such as the first discovery of $C\!P$-violation in charm and the first observation of the decay $B_s^0\to \mu^+\mu^-$ among many others.
1515

16-
In order to reach even higher precision the experiment aims to take `$ 50\,\mathrm{fb}^{-1} $` of
16+
In order to reach even higher precision the experiment aims to take $50\,\mathrm{fb}^{-1}$ of
1717
data in Run 3 by increasing the instantaneous luminosity by a factor of five.
1818
To be capable of dealing with the higher detector occupancy the experiment will be equipped with an entire new set of tracking detectors with higher granularity and improved radiation tolerance.
1919

2020
One of the most important upgrades in Run 3 will be the removal of the LHCb L0 hardware triggers. As described in the following, this will bring significant changes in the data flow of the experiment both for online and offline processing. It also means that the front-end and readout electronics of all sub-detectors will be replaced, to be able
21-
to operate at the bunch crossing rate of `$ 40\,\mathrm{MHz} $`, as well as the photodetectors of the RICH1 detector.
21+
to operate at the bunch crossing rate of $40\,\mathrm{MHz}$, as well as the photodetectors of the RICH1 detector.
2222

2323
## Upgrade of the LHCb trigger system
2424

2525
The trigger layout for Run 3 will look like this:
2626

2727
!["Data processing chain for Run 3"](img/hidef_RTA_dataflow_widescreen.png)
2828

29-
The LHCb trigger system will be fully redesigned by removing the L0 hardware trigger and moving to a fully-software based trigger. The hardware trigger has a rate limit of 1 MHz, which would be a limitation with the increase in luminosity. Such a low rate could be only achieved by having tight hardware trigger thresholds on `$ p_\mathrm{T} $` and `$ E_\mathrm{T} $` which is inefficient especially for fully hadronic decay modes. The removal of this bottleneck means that the full detector readout as well as running the HLT1 needs to be enabled at the average non-empty bunch crossing rate in LHCb of `$ 30\,\mathrm{MHz} $`, a not so trivial computing challenge!
29+
The LHCb trigger system will be fully redesigned by removing the L0 hardware trigger and moving to a fully-software based trigger. The hardware trigger has a rate limit of 1 MHz, which would be a limitation with the increase in luminosity. Such a low rate could be only achieved by having tight hardware trigger thresholds on $p_\mathrm{T}$ and $E_\mathrm{T}$ which is inefficient especially for fully hadronic decay modes. The removal of this bottleneck means that the full detector readout as well as running the HLT1 needs to be enabled at the average non-empty bunch crossing rate in LHCb of $30\,\mathrm{MHz}$, a not so trivial computing challenge!
3030

3131
As we saw already at the [Run 1 and Run 2 dataflow lecture](https://lhcb.github.io/starterkit-lessons/first-analysis-steps/dataflow.html), the software trigger is implemented in two steps: the HLT1 which performs partial event reconstruction and simple trigger decisions to reduce the data rate, and HLT2, which performs the more computationally expensive full reconstruction and complete trigger selection. One of the most important tasks of building the events is track reconstruction, which is an inherently parallelizable process. For this purpose, HLT1 in Run 3 is implemented as part of the ```Allen project``` and run on GPUs.
3232

@@ -38,7 +38,7 @@ Having the HLT1 run on GPUs imposes some different requirements on the code deve
3838
The raw data of events selected by HLT1 is passed on to the buffer system and stored there. The buffering of events enables to run the real-time alignment and calibration before events are entering HLT2. This is crucial because in this way calibration and alignment constants obtained can be used in the full event reconstruction performed in HLT2. For the determination of these constants, HLT1 selects dedicated calibration samples.
3939
More information about the real-time alignment and calibration can be found in the [Upgrade Alignment TWIKI page](https://twiki.cern.ch/twiki/bin/view/LHCb/AlignmentInUpgrade).
4040

41-
The total bandwidth that can be saved from HLT2 to tape is limited to `$ 10\,\mathrm{GB}/s $`. An important change in the HLT2 selections with respect to the Run 2 will be the increased use of the Turbo model. Wherever possible, the Turbo will be the baseline, so that in total for approximately 2/3 of data only the data of the signal candidate (raw and reconstructed) will be saved and no further offline reconstruction will be possible. This results in significantly smaller event sizes so that more events can be saved.
41+
The total bandwidth that can be saved from HLT2 to tape is limited to $10\,\mathrm{GB}/s$. An important change in the HLT2 selections with respect to the Run 2 will be the increased use of the Turbo model. Wherever possible, the Turbo will be the baseline, so that in total for approximately 2/3 of data only the data of the signal candidate (raw and reconstructed) will be saved and no further offline reconstruction will be possible. This results in significantly smaller event sizes so that more events can be saved.
4242

4343
For details and tutorials on how to develop HLT2 line selections as well as how to check their efficiencies and data rates follow the [Moore documentation](https://lhcbdoc.web.cern.ch/lhcbdoc/moore/master/index.html).
4444

first-analysis-steps/decay-tree-fitter.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ a vertex fit acts like a vertex constraint, improving the opening-angle resoluti
111111
{% endcallout %}
112112

113113

114-
Now let us look at the refitted mass of the `$ D^{*+} $`, with the `$ D^0 $` constrained to its nominal mass.
114+
Now let us look at the refitted mass of the $D^{*+}$, with the $D^0$ constrained to its nominal mass.
115115
It is stored in the variable `Dstar_ConsD_M`.
116116
If you plot this you will note that some values are unphysical.
117117
So, let's restrict the range we look at to something that makes sense.

first-analysis-steps/interactive-dst.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -176,9 +176,9 @@ one with:
176176
>>> print(candidates[0])
177177
```
178178

179-
Which will print out some information about the [Particle](https://lhcb-doxygen.web.cern.ch/lhcb-doxygen/davinci/latest/d0/d13/class_l_h_cb_1_1_particle.html). In our case a `$ D^{* +} $` ([particle ID number](http://pdg.lbl.gov/2019/reviews/rpp2018-rev-monte-carlo-numbering.pdf) 413). You can access its decay products with
179+
Which will print out some information about the [Particle](https://lhcb-doxygen.web.cern.ch/lhcb-doxygen/davinci/latest/d0/d13/class_l_h_cb_1_1_particle.html). In our case a $D^{* +}$ ([particle ID number](http://pdg.lbl.gov/2019/reviews/rpp2018-rev-monte-carlo-numbering.pdf) 413). You can access its decay products with
180180
`candidates[0].daughtersVector()[0]` and `candidates[0].daughtersVector()[1]`,
181-
which will be a `$ D^{0} $` and a `$ \pi^{+} $`.
181+
which will be a $D^{0}$ and a $\pi^{+}$.
182182

183183
There is a useful tool for printing out decay trees, which you can
184184
pass the top level particle to and it will print out the full decay tree etc:

0 commit comments

Comments
 (0)