Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
KM3BUU
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
simulation
KM3BUU
Merge requests
!47
Resolve "Muon Propagation"
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
Resolve "Muon Propagation"
8-muon-propagation
into
master
Overview
0
Commits
35
Pipelines
10
Changes
1
Merged
Johannes Schumann
requested to merge
8-muon-propagation
into
master
1 year ago
Overview
0
Commits
35
Pipelines
10
Changes
1
Expand
Closes
#8 (closed)
0
0
Merge request reports
Viewing commit
8d3fa039
Prev
Next
Show latest version
1 file
+
53
−
0
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
8d3fa039
Add script for doing initialisations
· 8d3fa039
Johannes Schumann
authored
1 year ago
km3buu/utils/initials.py
0 → 100755
+
53
−
0
Options
#!/usr/bin/env python
# coding=utf-8
# Filename: initials.py
# Author: Johannes Schumann <jschumann@km3net.de>
"""
Initialisation script for different KM3BUU parts
Usage:
initials.py (--proposal)
initials.py (-h | --help)
PROPOSAL setup crosssection tables of proposal based on the standard settings used in KM3BUU
Options:
-h --help Show this screen.
"""
import
logging
FORMAT
=
'
%(asctime)s %(levelname)s %(filename)s -- %(message)s
'
logging
.
basicConfig
(
format
=
FORMAT
)
logging
.
getLogger
().
setLevel
(
logging
.
INFO
)
def
main
():
from
docopt
import
docopt
args
=
docopt
(
__doc__
)
if
args
[
'
--proposal
'
]:
from
km3buu.config
import
Config
tablepath
=
Config
().
proposal_itp_tables
logging
.
info
(
f
"
Writing PROPOSAL tables to:
{
tablepath
}
"
)
from
km3buu.propagation
import
_setup_utility
,
PROPOSAL_LEPTON_DEFINITIONS
,
PROPOSAL_TARGET_WATER
import
proposal
as
pp
pp
.
InterpolationSettings
.
tables_path
=
'
.
'
_setup_utility
(
PROPOSAL_LEPTON_DEFINITIONS
[
13
](),
PROPOSAL_TARGET_WATER
)
_setup_utility
(
PROPOSAL_LEPTON_DEFINITIONS
[
15
](),
PROPOSAL_TARGET_WATER
)
_setup_utility
(
PROPOSAL_LEPTON_DEFINITIONS
[
-
13
](),
PROPOSAL_TARGET_WATER
)
_setup_utility
(
PROPOSAL_LEPTON_DEFINITIONS
[
-
15
](),
PROPOSAL_TARGET_WATER
)
_setup_utility
(
PROPOSAL_LEPTON_DEFINITIONS
[
13
](),
PROPOSAL_TARGET_ROCK
)
_setup_utility
(
PROPOSAL_LEPTON_DEFINITIONS
[
15
](),
PROPOSAL_TARGET_ROCK
)
_setup_utility
(
PROPOSAL_LEPTON_DEFINITIONS
[
-
13
](),
PROPOSAL_TARGET_ROCK
)
_setup_utility
(
PROPOSAL_LEPTON_DEFINITIONS
[
-
15
](),
PROPOSAL_TARGET_ROCK
)
if
__name__
==
'
__main__
'
:
main
()
Loading