PyLamarr
Pythonizations for the ultra-fast simulation option for the LHCb experiment
Loading...
Searching...
No Matches
PVReconstruction.py
1
from
typing
import
Union, Optional
2
from
pydantic
import
validate_arguments, Field
3
from
dataclasses
import
dataclass, InitVar
4
from
PyLamarr
import
RemoteResource
as
RemoteRes
5
from
PyLamarr
import
Wrapper
6
7
PV_LIB = (
"https://github.com/LamarrSim/SQLamarr/raw/master/temporary_data/"
8
"PrimaryVertex/PrimaryVertexSmearing.db"
)
9
10
11
@validate_arguments
12
@dataclass(frozen=True)
13
class
PVReconstruction
(
Wrapper
):
14
"""
15
Parametrize the reconstruction of a Primary Vertex.
16
17
18
@param condition: Data-taking condition, e.g. `2016_pp_MagUp`;
19
@param library: RemoteResource (or simply an URL) to the SQLite DB with
20
parametrizations;
21
@param table: name of the SQLite table to read the parametrization from
22
23
```python
24
db = SQLamarr.SQLite3DB(parsed_fmt)
25
pv_reco = PVReconstruction('2016_pp_MagUp')
26
pv_reco (db)
27
```
28
29
@see SQLamarr.PVReconstruction: C++ implementation of the algorithm
30
31
"""
32
33
condition: str
34
library: Optional[RemoteRes] = Field(default_factory=
lambda
: RemoteRes(PV_LIB))
35
table: Optional[str] =
"PVSmearing"
36
37
implements: str =
"PVReconstruction"
38
39
@property
40
def
config(self):
41
"""@private Call method"""
42
return
dict(
43
file_name=self.
library
.file,
44
table_name=self.
table
,
45
condition=self.
condition
46
)
PyLamarr.LHCb.PVReconstruction.PVReconstruction
Parametrize the reconstruction of a Primary Vertex.
Definition
PVReconstruction.py:13
PyLamarr.LHCb.PVReconstruction.PVReconstruction.library
Optional library
Definition
PVReconstruction.py:34
PyLamarr.LHCb.PVReconstruction.PVReconstruction.condition
str condition
Definition
PVReconstruction.py:33
PyLamarr.LHCb.PVReconstruction.PVReconstruction.table
Optional table
Definition
PVReconstruction.py:35
PyLamarr.Wrapper.Wrapper
Definition
Wrapper.py:14
PyLamarr
LHCb
PVReconstruction.py
Generated by
1.9.8