Skip to content

Commit

Permalink
nest recos/ under client/ - 3 (imports)
Browse files Browse the repository at this point in the history
  • Loading branch information
ric-evans committed Oct 28, 2024
1 parent a307a68 commit 248c2bc
Show file tree
Hide file tree
Showing 6 changed files with 19 additions and 20 deletions.
3 changes: 2 additions & 1 deletion skymap_scanner/client/reco_icetray.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@
from icecube.icetray import I3Tray # type: ignore[import-not-found]
from wipac_dev_tools import argparse_tools, logging_tools

from .. import config as cfg, recos
from .. import config as cfg
from . import recos
from ..utils import messages
from ..utils.data_handling import get_gcd_datastager
from ..utils.load_scan_state import get_baseline_gcd_frames
Expand Down
2 changes: 1 addition & 1 deletion skymap_scanner/client/recos/crash_dummy.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
from icecube import icetray # type: ignore[import] # noqa: F401

from . import RecoInterface, dummy
from ..config import ENV
from ...config import ENV


class CrashDummy(dummy.Dummy):
Expand Down
5 changes: 2 additions & 3 deletions skymap_scanner/client/recos/dummy.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
"""IceTray segment for a dummy reco."""


import datetime
import random
import time
Expand All @@ -21,8 +20,8 @@

from icecube.icetray import I3Frame # type: ignore[import]

from .. import config as cfg
from ..utils.pixel_classes import RecoPixelVariation
from ... import config as cfg
from ...utils.pixel_classes import RecoPixelVariation
from . import RecoInterface, VertexGenerator


Expand Down
17 changes: 8 additions & 9 deletions skymap_scanner/client/recos/millipede_original.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,15 +27,14 @@
)
from icecube.icetray import I3Frame

from .. import config as cfg
from ..utils.data_handling import DataStager
from ..utils.pixel_classes import RecoPixelVariation
from ... import config as cfg
from ...utils.pixel_classes import RecoPixelVariation
from . import RecoInterface, VertexGenerator
from .common.pulse_proc import late_pulse_cleaning

class MillipedeOriginal(RecoInterface):
"""Reco logic for millipede."""


@staticmethod
def get_vertex_variations() -> List[dataclasses.I3Position]:
Expand All @@ -45,9 +44,9 @@ def get_vertex_variations() -> List[dataclasses.I3Position]:

if cfg.ENV.SKYSCAN_MINI_TEST:
return VertexGenerator.mini_test(variation_distance=variation_distance)
else:
else:
return VertexGenerator.octahedron(radius=variation_distance)

pulsesName = cfg.INPUT_PULSES_NAME
pulsesName_cleaned = pulsesName+'LatePulseCleaned'

Expand Down Expand Up @@ -79,8 +78,8 @@ def extract_seed(frame):

tray.Add(extract_seed, "ExtractSeed",
If = lambda frame: frame.Has("HESE_VHESelfVeto"))
# Generates the vertex seed for the initial scan.

# Generates the vertex seed for the initial scan.
# Only run if HESE_VHESelfVeto is not present in the frame.
# VertexThreshold is 250 in the original HESE analysis (Tianlu)
# If HESE_VHESelfVeto is already in the frame, is likely using implicitly a VertexThreshold of 250 already. To be determined when this is not the case.
Expand All @@ -101,7 +100,7 @@ def setup_reco(self):
datastager = self.get_datastager()

datastager.stage_files(self.SPLINE_REQUIREMENTS)

abs_spline = datastager.get_filepath(self.MIE_ABS_SPLINE)
prob_spline = datastager.get_filepath(self.MIE_PROB_SPLINE)

Expand Down
8 changes: 4 additions & 4 deletions skymap_scanner/client/recos/millipede_wilks.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@
)
from icecube.icetray import I3Frame

from .. import config as cfg
from ..utils.pixel_classes import RecoPixelVariation
from ... import config as cfg
from ...utils.pixel_classes import RecoPixelVariation
from . import RecoInterface, VertexGenerator
from .common.pulse_proc import mask_deepcore, pulse_cleaning

Expand Down Expand Up @@ -84,7 +84,7 @@ def setup_reco(self):
@classmethod
@icetray.traysegment
def prepare_frames(cls, tray, name, logger):
# Generates the vertex seed for the initial scan.
# Generates the vertex seed for the initial scan.
# Only run if HESE_VHESelfVeto is not present in the frame.
# VertexThreshold is 250 in the original HESE analysis (Tianlu)
# If HESE_VHESelfVeto is already in the frame, is likely using implicitly a VertexThreshold of 250 already. To be determined when this is not the case.
Expand Down Expand Up @@ -112,7 +112,7 @@ def extract_seed(frame):
OutputVertexTime=cfg.INPUT_TIME_NAME,
OutputVertexPos=cfg.INPUT_POS_NAME,
If=lambda frame: not frame.Has("HESE_VHESelfVeto"))


tray.Add(mask_deepcore, origpulses=cfg.INPUT_PULSES_NAME, maskedpulses=cls.pulsesName)

Expand Down
4 changes: 2 additions & 2 deletions skymap_scanner/client/recos/splinempe.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@

from . import RecoInterface, VertexGenerator
from .common.pulse_proc import mask_deepcore
from .. import config as cfg
from ..utils.pixel_classes import RecoPixelVariation
from ... import config as cfg
from ...utils.pixel_classes import RecoPixelVariation


class SplineMPE(RecoInterface):
Expand Down

0 comments on commit 248c2bc

Please sign in to comment.