Main Page
Related Pages
Modules
Namespaces
Classes
Files
Examples
File List
File Members
wire-cell-build
img
inc
WireCellImg
SumSlice.h
Go to the documentation of this file.
1
/* Note, this file should not be #include'd into WCT components
2
* directly but may be included into tests.
3
4
Uniformly slice a frame by charge summation
5
6
This file provides two variants.
7
8
- SumSlicer :: a function node which produces an IFrameSlice
9
10
- SumSlices :: a queuedout node which produces an ISlice
11
12
The two have trace-offs.
13
14
r: keeps context, makes DFP graph simpler, forces monolithic downstream/more memory/node
15
16
s: the opposite
17
18
Notes:
19
20
- Any sample must be different than 0.0 to be considered for
21
addition to a slice but no other thresholding is done here (do it
22
in some other component).
23
24
*/
25
26
#ifndef WIRECELLIMG_SUMSLICE
27
#define WIRECELLIMG_SUMSLICE
28
29
#include "
WireCellIface/IConfigurable.h
"
30
#include "
WireCellIface/IFrameSlicer.h
"
31
#include "
WireCellIface/IFrameSlices.h
"
32
#include "
WireCellIface/IAnodePlane.h
"
33
34
#include <string>
35
36
namespace
WireCell
{
37
namespace
Img {
38
39
namespace
Data
{
40
// ISlice class is held temporarily as concrete.
41
class
Slice
;
42
}
43
44
class
SumSliceBase
:
public
IConfigurable
{
45
public
:
46
SumSliceBase
();
47
virtual
~
SumSliceBase
();
48
49
// IConfigurable
50
virtual
void
configure
(
const
WireCell::Configuration
&
cfg
);
51
virtual
WireCell::Configuration
default_configuration()
const
;
52
53
protected
:
54
55
typedef
std::map<size_t, Data::Slice*>
slice_map_t
;
56
void
slice(
const
IFrame::pointer
& in, slice_map_t& sm);
57
58
private
:
59
60
IAnodePlane::pointer
m_anode
;
61
int
m_tick_span
;
62
std::string
m_tag
;
63
};
64
65
class
SumSlicer
:
public
SumSliceBase
,
public
IFrameSlicer
{
66
public
:
67
virtual
~
SumSlicer
();
68
69
// IFrameSlicer
70
bool
operator()(
const
input_pointer
& in,
output_pointer
& out);
71
};
72
73
class
SumSlices
:
public
SumSliceBase
,
public
IFrameSlices
{
74
public
:
75
virtual
~
SumSlices
();
76
77
// IFrameSlices
78
virtual
bool
operator()(
const
input_pointer
& depo,
output_queue
&
slices
);
79
80
};
81
82
}
83
}
84
#endif
WireCell::IData< IFrame >::pointer
std::shared_ptr< const IFrame > pointer
Definition:
IData.h:19
WireCell::IConfigurable
Definition:
IConfigurable.h:13
lar_content::Slice
SlicingAlgorithm::Slice Slice
Definition:
CheatingEventSlicingTool.cc:22
WireCell::Img::SumSlices
Definition:
SumSlice.h:73
Data
Definition:
RangeForWrapper_test.cc:81
string
std::string string
Definition:
nybbler.cc:12
WireCell::Img::SumSliceBase::slice_map_t
std::map< size_t, Data::Slice * > slice_map_t
Definition:
SumSlice.h:55
IConfigurable.h
dbjson.cfg
cfg
Definition:
dbjson.py:29
WireCell::IQueuedoutNode< IFrame, ISlice >::output_queue
std::deque< output_pointer > output_queue
Definition:
IQueuedoutNode.h:46
IFrameSlicer.h
WireCell::IFunctionNode< IFrame, ISliceFrame >::input_pointer
std::shared_ptr< const IFrame > input_pointer
Definition:
IFunctionNode.h:39
cuda.configure
def configure(cfg)
Definition:
cuda.py:34
WireCell::Interface::pointer
std::shared_ptr< Interface > pointer
Definition:
Interface.h:16
WireCell::IFunctionNode< IFrame, ISliceFrame >::output_pointer
std::shared_ptr< const ISliceFrame > output_pointer
Definition:
IFunctionNode.h:40
tca::slices
std::vector< TCSlice > slices
Definition:
DataStructs.cxx:12
WireCell::Img::SumSliceBase
Definition:
SumSlice.h:44
WireCell
Definition:
Main.h:22
IAnodePlane.h
IFrameSlices.h
WireCell::Img::SumSliceBase::m_tag
std::string m_tag
Definition:
SumSlice.h:62
WireCell::Configuration
Json::Value Configuration
Definition:
Configuration.h:50
WireCell::IFrameSlices
Definition:
IFrameSlices.h:19
WireCell::IQueuedoutNode< IFrame, ISlice >::input_pointer
std::shared_ptr< const IFrame > input_pointer
Definition:
IQueuedoutNode.h:44
WireCell::IFrameSlicer
Definition:
IFrameSlicer.h:23
WireCell::Img::SumSlicer
Definition:
SumSlice.h:65
WireCell::Img::SumSliceBase::m_tick_span
int m_tick_span
Definition:
SumSlice.h:61
WireCell::Img::SumSliceBase::m_anode
IAnodePlane::pointer m_anode
Definition:
SumSlice.h:60
Generated by
1.8.11