:py:mod:`km3pipe.io.daq` ======================== .. py:module:: km3pipe.io.daq .. autoapi-nested-parse:: Pumps for the DAQ data formats. .. !! processed by numpydoc !! Module Contents --------------- Classes ~~~~~~~ .. autoapisummary:: km3pipe.io.daq.TimesliceParser km3pipe.io.daq.RePump km3pipe.io.daq.DAQPump km3pipe.io.daq.DAQProcessor km3pipe.io.daq.DAQPreamble km3pipe.io.daq.DAQHeader km3pipe.io.daq.DAQSummaryslice km3pipe.io.daq.DAQEvent km3pipe.io.daq.TMCHData km3pipe.io.daq.TMCHRepump km3pipe.io.daq.DMMonitor Attributes ~~~~~~~~~~ .. autoapisummary:: km3pipe.io.daq.log km3pipe.io.daq.DATA_TYPES km3pipe.io.daq.MINIMAL_RATE_HZ km3pipe.io.daq.MAXIMAL_RATE_HZ km3pipe.io.daq.RecoTrack km3pipe.io.daq.RecoShower .. py:data:: log .. py:data:: DATA_TYPES .. py:data:: MINIMAL_RATE_HZ :value: 2000.0 .. py:data:: MAXIMAL_RATE_HZ :value: 2000000.0 .. py:class:: TimesliceParser(name=None, **parameters) Preliminary parser for DAQTimeslice .. !! processed by numpydoc !! .. py:method:: configure() Configure module, like instance variables etc. .. !! processed by numpydoc !! .. py:method:: process(blob) Knead the blob and return it .. !! processed by numpydoc !! .. py:class:: RePump(name=None, **parameters) A pump for binary DAQ files. This pump can be used to replay raw dumps e.g. created with the ``daqsample`` tool. It creates the same structures as the ``kp.io.ch.CHPump`` and thus suited to test online processing pipelines with offline files. .. !! processed by numpydoc !! .. py:method:: configure() Configure module, like instance variables etc. .. !! processed by numpydoc !! .. py:method:: process(blob) Knead the blob and return it .. !! processed by numpydoc !! .. py:method:: finish() Clean everything up. .. !! processed by numpydoc !! .. py:class:: DAQPump(name=None, **parameters) A pump for binary DAQ files. Deprecated! .. !! processed by numpydoc !! .. py:method:: configure() Configure module, like instance variables etc. .. !! processed by numpydoc !! .. py:method:: next_blob() Get the next frame from file .. !! processed by numpydoc !! .. py:method:: seek_to_frame(index) Move file pointer to the frame with given index. .. !! processed by numpydoc !! .. py:method:: get_blob(index) Return blob at given index. .. !! processed by numpydoc !! .. py:method:: determine_frame_positions() Record the file pointer position of each frame .. !! processed by numpydoc !! .. py:method:: process(blob) Pump the next blob to the modules .. !! processed by numpydoc !! .. py:method:: finish() Clean everything up .. !! processed by numpydoc !! .. py:class:: DAQProcessor(name=None, **parameters) The module which can be attached to the pipeline .. !! processed by numpydoc !! .. py:method:: configure() Configure module, like instance variables etc. .. !! processed by numpydoc !! .. py:method:: process(blob) Knead the blob and return it .. !! processed by numpydoc !! .. py:method:: process_event(data, blob) .. py:method:: process_summaryslice(data, blob) .. py:method:: process_online_reco(data, blob) .. py:data:: RecoTrack .. py:data:: RecoShower .. py:class:: DAQPreamble(byte_data=None, file_obj=None) Wrapper for the JDAQPreamble binary format. :Parameters: **byte_data** : bytes (optional) The binary file, where the file pointer is at the beginning of the header. **file_obj** : file (optional) The binary file, where the file pointer is at the beginning of the header. :Attributes: **size** : int The size of the original DAQ byte representation. **data_type** : int The data type of the following frame. The coding is stored in the ``DATA_TYPES``. .. !! processed by numpydoc !! .. py:attribute:: size :value: 8 .. py:class:: DAQHeader(byte_data=None, file_obj=None) Wrapper for the JDAQHeader binary format. :Parameters: **byte_data** : bytes (optional) The binary file, where the file pointer is at the beginning of the header. **file_obj** : file (optional) The binary file, where the file pointer is at the beginning of the header. :Attributes: **size** : int The size of the original DAQ byte representation. .. !! processed by numpydoc !! .. py:attribute:: size :value: 20 .. py:class:: DAQSummaryslice(file_obj, legacy=False) Wrapper for the JDAQSummarySlice binary format. :Parameters: **file_obj** : file (optional) The binary file, where the file pointer is at the beginning of the header. :Attributes: **n_summary_frames** : int The number of summary frames. **summary_frames** : dict The PMT rates for each DOM. The key is the DOM identifier and the corresponding value is a sorted list of PMT rates in [Hz]. **dom_rates** : dict The overall DOM rate for each DOM. .. !! processed by numpydoc !! .. py:class:: DAQEvent(file_obj, legacy=False) Wrapper for the JDAQEvent binary format. :Parameters: **file_obj** : file The binary file, where the file pointer is at the beginning of the header. :Attributes: **trigger_counter** : int Incremental identifier of the occurred trigger. **trigger_mask** : int The trigger type(s) satisfied. **overlays** : int Number of merged events. **n_triggered_hits** : int Number of hits satisfying the trigger conditions. **n_snapshot_hits** : int Number of snapshot hits. **triggered_hits** : np.recarray Array of triggered hits (fields: dom_id, pmt_id, tdc_time, tot, trigger_mask) **snapshot_hits** : np.recarray A list of snapshot hits (fields: dom_id, pmt_id, tdc_time, tot) .. !! processed by numpydoc !! .. py:attribute:: triggered_hits_dt .. py:attribute:: triggered_hits_dt_final .. py:attribute:: snapshot_hits_dt .. py:attribute:: snapshot_hits_dt_final .. py:class:: TMCHData(file_obj, version=None) Monitoring Channel data. .. !! processed by numpydoc !! .. py:class:: TMCHRepump(name=None, **parameters) Takes a IO_MONIT raw dump and replays it. .. !! processed by numpydoc !! .. py:method:: configure() Configure module, like instance variables etc. .. !! processed by numpydoc !! .. py:method:: process(blob) Knead the blob and return it .. !! processed by numpydoc !! .. py:method:: blob_generator() .. py:method:: finish() Clean everything up. .. !! processed by numpydoc !! .. py:class:: DMMonitor(host, port=1302, base='') A class which provides access to the Detector Manager parameters. .. rubric:: Examples >>> import km3pipe as kp >>> dmm = kp.io.daq.DMMonitor('192.168.0.120', base='clb/outparams') >>> session = dmm.start_session('test', ['wr_mu/1/0','wr_mu/1/1']) >>> for values in session: print(values) .. !! processed by numpydoc !! .. py:property:: available_parameters .. py:method:: get(path) .. py:method:: start_session(name, paths, interval=10)