Skip to content
Snippets Groups Projects
Commit 87ce0e39 authored by Stefan Reck's avatar Stefan Reck
Browse files

Moved attaching of core components to seperate method.

parent d9869a45
No related branches found
Tags v2.0.3
No related merge requests found
......@@ -208,6 +208,18 @@ class FileBinner:
pipe.attach(km.common.Keep, keys=['EventInfo', 'Header', 'RawHeader',
'McTracks', 'Hits', 'McHits'])
self.attach_components(pipe)
pipe.attach(kp.io.HDF5Sink,
filename=outfile,
complib=self.complib,
complevel=self.complevel,
chunksize=self.chunksize,
flush_frequency=self.flush_frequency)
return pipe
def attach_components(self, pipe):
""" Attach the core components of OrcaSong to a pipe. """
if self.det_file:
pipe.attach(modules.DetApplier, det_file=self.det_file)
......@@ -245,14 +257,6 @@ class FileBinner:
keys_keep.append('McTracks')
pipe.attach(km.common.Keep, keys=keys_keep)
pipe.attach(kp.io.HDF5Sink,
filename=outfile,
complib=self.complib,
complevel=self.complevel,
chunksize=self.chunksize,
flush_frequency=self.flush_frequency)
return pipe
def get_names_and_shape(self):
"""
Get names and shape of the resulting x data,
......
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