Class mata::applications::strings::seg_nfa::Segmentation¶
-
class Segmentation
Class executing segmentation operations for a given segment automaton.
Works only with segment automata.
Public Types
-
using EpsilonDepth = size_t
Depth of ε-transitions. Dictionary of lists of ε-transitions grouped by their depth. For each depth ‘i’ we have ‘depths[i]’ which contains a list of ε-transitions of depth ‘i’.
Public Functions
-
inline explicit Segmentation(const SegNfa &aut, const std::set<Symbol> &epsilons)
Prepare automaton
autfor segmentation.- Parameters:
aut – [in] Segment automaton to make segments for.
epsilon – [in] Symbol to execute segmentation for.
-
inline const EpsilonDepthTransitions &get_epsilon_depths() const
Get segmentation depths for ε-transitions.
- Returns:
Map of depths to lists of ε-transitions.
-
inline const EpsilonDepthTransitionMap &get_epsilon_depth_trans_map() const
Get the epsilon depth trans map object (mapping of depths and states to eps-successors)
- Returns:
Map of depths to a map of states to transitions
-
const std::vector<Nfa> &get_segments()
Get segment automata.
- Returns:
A vector of segments for the segment automaton in the order from the left (initial state in segment automaton) to the right (final states of segment automaton).
-
const std::vector<Nfa> &get_untrimmed_segments()
Get raw segment automata.
- Returns:
A vector of segments for the segment automaton in the order from the left (initial state in segment automaton) to the right (final states of segment automaton) without trimming (the states are same as in the original automaton).
-
using EpsilonDepth = size_t