Skip to content

Commit 3f95dcd

Browse files
authored
01-dd4hep.md: set correct languages to code blocks
1 parent 8ea590b commit 3f95dcd

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

_episodes/01-dd4hep.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ This Geant4-based simualtion package propagates particles through magnetic field
3030

3131
Below is an example from epic/compact/tracking/vertex_barrel.xml:
3232

33-
```console
33+
```xml
3434
<readouts>
3535
<readout name="VertexBarrelHits">
3636
<segmentation type="CartesianGridXY" grid_size_x="0.020*mm" grid_size_y="0.020*mm" />
@@ -51,7 +51,7 @@ This Geant4-based simualtion package propagates particles through magnetic field
5151
>
5252
> -__Browse the directory__
5353
> For stand-alone `xrdfs` command, see the [previous tutorials](https://eic.github.io/tutorial-analysis/01-introduction/index.html). Here we will proceed with the python interface:
54-
```console
54+
```python
5555
from XRootD import client
5656
# Create XRootD client
5757
eic_server = 'root://dtn-eic.jlab.org/'
@@ -68,7 +68,7 @@ else:
6868
print(f"Error: {status.message}")
6969
```
7070
> -__Open a simulation campaign file__
71-
```console
71+
```python
7272
fname = eic_server+fpath+'e-_10GeV_130to177deg.0307.eicrecon.tree.edm4eic.root'
7373
tree_name = "events"
7474
# tree_name = "podio_metadata"
@@ -81,7 +81,7 @@ print(f"Read {fname}:{tree_name}. \n {tree.num_entries} events in total")
8181
> Exercise 1.2: inspect available branches in a rootfile
8282
> - use ```tree.keys(filter_name="*",recursive=False)``` to display all branches
8383
> - extract a given branch to dataframe
84-
```console
84+
```python
8585
bname = "MCParticles"
8686
df = tree[bname].array(library="ak")
8787
df = ak.to_dataframe(df)
@@ -91,7 +91,7 @@ print(df)
9191

9292

9393
> Exercise 1.3: extract momentum distribution of primary electrons
94-
```console
94+
```python
9595
# select electrons
9696
from particle import Particle
9797
part = Particle.from_name("e-")

0 commit comments

Comments
 (0)