Belle II Software development
|
Implements to pick up of the highest value path in neighborhood Following high value paths can be done two ways. More...
#include <CellularPathFollower.h>
Public Member Functions | |
std::vector< Path< ACellHolder > > | followAll (const std::vector< ACellHolder * > &cellHolders, const std::vector< WeightedRelation< ACellHolder > > &cellHolderRelations, Weight minStateToFollow=-INFINITY) const |
Follow paths from all start cells marked with the start flag. | |
Path< ACellHolder > | followSingle (ACellHolder *startCellHolder, const std::vector< WeightedRelation< ACellHolder > > &cellHolderRelations, Weight minStateToFollow=-INFINITY) const |
Follows a single maximal path starting with the given start cell. | |
Private Member Functions | |
void | growAllPaths (Path< ACellHolder > &path, const std::vector< WeightedRelation< ACellHolder > > &cellHolderRelations, std::vector< Path< ACellHolder > > &paths) const |
Helper function for recursively growing paths. | |
Static Private Member Functions | |
static bool | validStartCell (const AutomatonCell &automatonCell, Weight minStateToFollow) |
Helper function to determine, if the cell has all flags indicating to be a start cell and that its state exceeds the minimal requirement. | |
static bool | isHighestContinuation (const WeightedRelation< ACellHolder > &relation) |
Helper function determining if the given neighbor is one of the best to be followed. | |
static bool | isHighestContinuation (ACellHolder &cellHolder, Weight relationWeight, ACellHolder &neighborCellHolder) |
Helper function determining if the given neighbor is one of the best to be followed. | |
Implements to pick up of the highest value path in neighborhood Following high value paths can be done two ways.
First construct a single path that has the highest value of all. This carried out by follow single which uses the highest cell returned by the cellular automaton. Second construct all paths which are maximal. A maximal path means that there is no longer path including this path. If there are many disjoint paths this is the way to get them. However you most certainly pick up a lot of elements twice if there are many start culminating into a common long path. This is carried out recursively by followAll over the start cells marked with start flag.
Definition at line 38 of file CellularPathFollower.h.
|
inline |
Follow paths from all start cells marked with the start flag.
Definition at line 42 of file CellularPathFollower.h.
|
inline |
Follows a single maximal path starting with the given start cell.
If the start cell is nullptr or has a state lower than the minimum state to follow an empty vector is returned.
Definition at line 81 of file CellularPathFollower.h.
|
inlineprivate |
Helper function for recursively growing paths.
[in] | path | Current path to be extended |
[in] | cellHolderRelations | Considered relations to follow to extend the path |
[out] | paths | Longest paths generated |
Definition at line 126 of file CellularPathFollower.h.
|
inlinestaticprivate |
Helper function determining if the given neighbor is one of the best to be followed.
Since this is an algebraic property no comparison to the other alternatives is necessary.
Definition at line 190 of file CellularPathFollower.h.
|
inlinestaticprivate |
Helper function determining if the given neighbor is one of the best to be followed.
Since this is an algebraic property on comparison to the other alternatives is necessary.
Definition at line 172 of file CellularPathFollower.h.
|
inlinestaticprivate |
Helper function to determine, if the cell has all flags indicating to be a start cell and that its state exceeds the minimal requirement.
Definition at line 158 of file CellularPathFollower.h.