Skip to content
Snippets Groups Projects
Commit 22817df5 authored by Johannes Schumann's avatar Johannes Schumann
Browse files

Add cylindrical volume as option to runner

parent e91b9f18
No related branches found
No related tags found
1 merge request!47Resolve "Muon Propagation"
...@@ -11,7 +11,7 @@ from os.path import join ...@@ -11,7 +11,7 @@ from os.path import join
from km3buu.jobcard import generate_neutrino_jobcard from km3buu.jobcard import generate_neutrino_jobcard
from km3buu.ctrl import run_jobcard from km3buu.ctrl import run_jobcard
from km3buu.geometry import CANVolume, SphericalVolume, NoVolume from km3buu.geometry import *
from km3buu.output import GiBUUOutput, write_detector_file from km3buu.output import GiBUUOutput, write_detector_file
ARGPARSE_DESC = { ARGPARSE_DESC = {
...@@ -64,7 +64,7 @@ ARGPARSE_GENERAL_PARAMS = [{ ...@@ -64,7 +64,7 @@ ARGPARSE_GENERAL_PARAMS = [{
"option_strings": ["--geometry", "-g"], "option_strings": ["--geometry", "-g"],
"dest": "dest":
"geometry", "geometry",
"choices": ["no", "can", "sphere"], "choices": ["no", "can", "sphere", "cylindrical"],
"default": "default":
"no", "no",
"help": "help":
...@@ -90,7 +90,7 @@ ARGPARSE_GENERAL_PARAMS = [{ ...@@ -90,7 +90,7 @@ ARGPARSE_GENERAL_PARAMS = [{
"nargs": "nargs":
"*", "*",
"help": "help":
"Dimensions of the geometry; sphere -> -d <radius> / can -> -d <radius> <zmin> <zmax>" "Dimensions of the geometry; sphere -> -d <radius> / can -> -d <radius> <zmin> <zmax> / cylindrical -> -d <seawaterheight> <rockheight> <radius> <canradius> <canzmin> <canzmax>"
}, { }, {
"option_strings": ["--output-dir", "-o"], "option_strings": ["--output-dir", "-o"],
"dest": "output", "dest": "output",
...@@ -231,6 +231,15 @@ def main(): ...@@ -231,6 +231,15 @@ def main():
kwargs["zmax"] = args.dimensions[1] kwargs["zmax"] = args.dimensions[1]
kwargs["radius"] = args.dimensions[2] kwargs["radius"] = args.dimensions[2]
volume = CANVolume(**kwargs) volume = CANVolume(**kwargs)
elif args.geometry == 'cylindrical':
kwargs = {"detector_center": tuple(args.center), "zenith": args.zenith}
kwargs["sw_height"] = args.dimensions[0]
kwargs["sr_height"] = args.dimensions[1]
kwargs["radius"] = args.dimensions[2]
kwargs["can_radius"] = args.dimensions[3]
kwargs["can_zmin"] = args.dimensions[4]
kwargs["can_zmax"] = args.dimensions[5]
volume = CylindricalVolume(**kwargs)
run_descriptor = "" run_descriptor = ""
if args.runnumber: if args.runnumber:
run_descriptor = "run{:08d}_".format(args.runnumber) run_descriptor = "run{:08d}_".format(args.runnumber)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment