Class MealyCaches


  • public final class MealyCaches
    extends Object
    A factory for creating caches for mealy-based MembershipOracles.
    • Method Detail

      • createDAGCache

        public static <I,​O> MealyCacheOracle<I,​O> createDAGCache​(Alphabet<I> alphabet,
                                                                             MembershipOracle<I,​Word<O>> mqOracle)
        Creates a cache oracle for a Mealy machine learning setup, using a DAG for internal cache organization.
        Parameters:
        alphabet - the input alphabet
        mqOracle - the membership oracle
        Returns:
        a Mealy learning cache with a DAG-based implementation
        See Also:
        IncrementalMealyDAGBuilder
      • createDAGCache

        public static <I,​O> MealyCacheOracle<I,​O> createDAGCache​(Alphabet<I> alphabet,
                                                                             Mapping<? super O,​? extends O> errorSyms,
                                                                             MembershipOracle<I,​Word<O>> mqOracle)
        Creates a cache oracle for a Mealy machine learning setup, using a DAG for internal cache organization.
        Parameters:
        alphabet - the input alphabet
        errorSyms - a mapping for the prefix-closure filter
        mqOracle - the membership oracle
        Returns:
        a Mealy learning cache with a DAG-based implementation
        See Also:
        IncrementalMealyDAGBuilder
      • createTreeCache

        public static <I,​O> MealyCacheOracle<I,​O> createTreeCache​(Alphabet<I> alphabet,
                                                                              MembershipOracle<I,​Word<O>> mqOracle)
        Creates a cache oracle for a Mealy machine learning setup, using a tree for internal cache organization.
        Parameters:
        alphabet - the input alphabet
        mqOracle - the membership oracle
        Returns:
        a Mealy learning cache with a tree-based implementation
        See Also:
        IncrementalMealyTreeBuilder
      • createTreeCache

        public static <I,​O> MealyCacheOracle<I,​O> createTreeCache​(Alphabet<I> alphabet,
                                                                              Mapping<? super O,​? extends O> errorSyms,
                                                                              MembershipOracle<I,​Word<O>> mqOracle)
        Creates a cache oracle for a Mealy machine learning setup, using a tree for internal cache organization.
        Parameters:
        alphabet - the input alphabet
        errorSyms - a mapping for the prefix-closure filter
        mqOracle - the membership oracle
        Returns:
        a Mealy learning cache with a tree-based implementation
        See Also:
        IncrementalMealyTreeBuilder
      • createDynamicTreeCache

        public static <I,​O> MealyCacheOracle<I,​O> createDynamicTreeCache​(MembershipOracle<I,​Word<O>> mqOracle)
        Creates a cache oracle for a Mealy machine learning setup with a dynamic alphabet storage, using a tree for internal cache organization.

        Note: Due to the dynamic alphabet storage, memory consumption of a dense tree may be higher than normal caches with a predefined alphabet. However, for sparse data, the memory consumption may be lower than only memory for the actual data of the tree is allocated.

        Parameters:
        mqOracle - the membership oracle
        Returns:
        a Mealy learning cache with a tree-based implementation
        See Also:
        DynamicIncrementalMealyTreeBuilder
      • createDynamicTreeCache

        public static <I,​O> MealyCacheOracle<I,​O> createDynamicTreeCache​(Mapping<? super O,​? extends O> errorSyms,
                                                                                     MembershipOracle<I,​Word<O>> mqOracle)
        Creates a cache oracle for a Mealy machine learning setup with a dynamic alphabet storage, using a tree for internal cache organization.

        Note: Due to the dynamic alphabet storage, memory consumption of a dense tree may be higher than normal caches with a predefined alphabet. However, for sparse data, the memory consumption may be lower than only memory for the actual data of the tree is allocated.

        Parameters:
        errorSyms - a mapping for the prefix-closure filter
        mqOracle - the membership oracle
        Returns:
        a Mealy learning cache with a tree-based implementation
        See Also:
        DynamicIncrementalMealyTreeBuilder
      • createSymbolQueryCache

        public static <I,​O> SymbolQueryCache<I,​O> createSymbolQueryCache​(Alphabet<I> alphabet,
                                                                                     SymbolQueryOracle<I,​O> mqOracle)
        Creates a cache oracle for a symbol-based Mealy machine learning setup, using a tree for internal cache organization.
        Parameters:
        alphabet - the input alphabet
        mqOracle - the membership oracle
        Returns:
        a symbol-based Mealy learning cache with a tree-based implementation