Belle II Software
release-06-01-15
Main Page
Modules
Namespaces
Namespace List
Namespace Members
All
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Functions
_
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
w
x
z
Variables
a
b
c
d
e
f
g
h
i
l
m
n
o
p
q
r
s
t
v
w
z
Typedefs
a
b
c
d
e
i
k
l
m
n
p
r
s
t
u
v
w
Enumerations
Enumerator
c
d
f
p
t
u
v
w
Classes
Class List
Class Hierarchy
Class Members
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
Enumerations
a
b
c
d
e
f
g
h
i
l
m
o
p
r
s
t
u
v
Enumerator
a
b
c
d
e
f
g
h
k
l
m
n
o
p
r
s
t
u
v
w
z
Related Functions
b
c
d
g
i
o
r
s
t
Files
File List
File Members
All
Functions
collApertOverride.py
1
#!/usr/bin/env python3
2
# -*- coding: utf-8 -*-
3
4
11
12
16
17
from
basf2
import
Path, process
18
from
sys
import
argv
19
20
# Create main path
21
main = Path()
22
# Add modules to main path
23
main.add_module(
"EventInfoSetter"
)
24
# Geometry parameter loader
25
gearbox = main.add_module(
"Gearbox"
)
26
# Geometry root file
27
gearbox.param(
'fileName'
,
'/geometry/Belle2.xml'
)
28
# Override collimator displacement
29
gearbox.param(
'override'
, [
30
(
"/DetectorComponent[@name='FarBeamLine']/Content/Collimator[@name='D01H5']/sec[@name='d1']"
,
'-15'
,
'mm'
),
31
(
"/DetectorComponent[@name='FarBeamLine']/Content/Collimator[@name='D01H5']/sec[@name='d2']"
,
'12'
,
'mm'
),
32
])
33
# Geometry builder
34
main.add_module(
"Geometry"
, useDB=
False
,
35
components=[
'FarBeamLine'
],
36
# components=['BeamPipe','Cryostat','VXDService','HeavyMetalShield','FarBeamLine'],
37
)
38
39
# Overlap checker
40
if
len(argv) > 1:
41
main.add_module(
"OverlapChecker"
, points=int(argv[1]))
42
else
:
43
main.add_module(
"OverlapChecker"
)
44
# Save overlaps to file to be able to view them with b2display
45
main.add_module(
"RootOutput"
, outputFileName=
"Overlaps.root"
)
46
# Process one event
47
process(main)
beast
examples
collApertOverride.py
Generated on Fri Dec 8 2023 04:14:22 for Belle II Software by
1.9.1