ATLAS Offline Software
Public Member Functions | Private Attributes | List of all members
lwtDev::SequenceNode Class Reference

#include <Graph.h>

Inheritance diagram for lwtDev::SequenceNode:
Collaboration diagram for lwtDev::SequenceNode:

Public Member Functions

 SequenceNode (const RecurrentStack *, const ISequenceNode *source)
 
virtual MatrixXd scan (const ISource &) const override
 
virtual VectorXd compute (const ISource &) const override
 
virtual size_t n_outputs () const override
 

Private Attributes

const RecurrentStackm_stack
 
const ISequenceNodem_source
 

Detailed Description

Definition at line 86 of file Graph.h.

Constructor & Destructor Documentation

◆ SequenceNode()

lwtDev::SequenceNode::SequenceNode ( const RecurrentStack stack,
const ISequenceNode source 
)

Definition at line 152 of file Graph.cxx.

153  :
154  m_stack(stack),
156  {
157  }

Member Function Documentation

◆ compute()

VectorXd lwtDev::SequenceNode::compute ( const ISource src) const
overridevirtual

Implements lwtDev::INode.

Definition at line 161 of file Graph.cxx.

161  {
162  MatrixXd mat = scan(src);
163  size_t n_cols = mat.cols();
164  // special handling for empty sequence
165  if (n_cols == 0) {
166  return MatrixXd::Zero(mat.rows(), 1);
167  }
168  return mat.col(n_cols - 1);
169  }

◆ n_outputs()

size_t lwtDev::SequenceNode::n_outputs ( ) const
overridevirtual

Implements lwtDev::INode.

Definition at line 170 of file Graph.cxx.

170  {
171  return m_stack->n_outputs();
172  }

◆ scan()

MatrixXd lwtDev::SequenceNode::scan ( const ISource source) const
overridevirtual

Implements lwtDev::ISequenceNode.

Definition at line 158 of file Graph.cxx.

158  {
159  return m_stack->scan(m_source->scan(source));
160  }

Member Data Documentation

◆ m_source

const ISequenceNode* lwtDev::SequenceNode::m_source
private

Definition at line 95 of file Graph.h.

◆ m_stack

const RecurrentStack* lwtDev::SequenceNode::m_stack
private

Definition at line 94 of file Graph.h.


The documentation for this class was generated from the following files:
lwtDev::RecurrentStack::scan
MatrixXd scan(MatrixXd inputs) const
Definition: Stack.cxx:300
lwtDev::SequenceNode::m_source
const ISequenceNode * m_source
Definition: Graph.h:95
WriteCellNoiseToCool.src
src
Definition: WriteCellNoiseToCool.py:513
mat
GeoMaterial * mat
Definition: LArDetectorConstructionTBEC.cxx:55
lwtDev::RecurrentStack::n_outputs
size_t n_outputs() const
Definition: Stack.cxx:306
lwtDev::ISequenceNode::scan
virtual MatrixXd scan(const ISource &) const =0
lwtDev::SequenceNode::scan
virtual MatrixXd scan(const ISource &) const override
Definition: Graph.cxx:158
lwtDev::SequenceNode::m_stack
const RecurrentStack * m_stack
Definition: Graph.h:94
copySelective.source
string source
Definition: copySelective.py:32
generate::Zero
void Zero(TH1D *hin)
Definition: generate.cxx:32