I
- input symbol typeO
- output symbol typepublic class KearnsVaziraniMealy<I,O> extends Object implements LearningAlgorithm.MealyLearner<I,O>, SupportsGrowingAlphabet<I>, ResumableLearner<de.learnlib.algorithms.kv.mealy.KearnsVaziraniMealyState<I,O>>
Modifier and Type | Class and Description |
---|---|
protected class |
KearnsVaziraniMealy.KVAbstractCounterexample |
LearningAlgorithm.DFALearner<I>, LearningAlgorithm.MealyLearner<I,O>
Modifier and Type | Field and Description |
---|---|
protected AbstractWordBasedDiscriminationTree<I,net.automatalib.words.Word<O>,StateInfo<I,net.automatalib.words.Word<O>>> |
discriminationTree |
protected List<StateInfo<I,net.automatalib.words.Word<O>>> |
stateInfos |
Constructor and Description |
---|
KearnsVaziraniMealy(net.automatalib.words.Alphabet<I> alphabet,
MembershipOracle<I,net.automatalib.words.Word<O>> oracle,
boolean repeatedCounterexampleEvaluation,
AcexAnalyzer counterexampleAnalyzer) |
Modifier and Type | Method and Description |
---|---|
void |
addAlphabetSymbol(I symbol) |
net.automatalib.automata.transout.MealyMachine<?,I,?,O> |
getHypothesisModel()
Returns the current hypothesis model.
|
boolean |
refineHypothesis(DefaultQuery<I,net.automatalib.words.Word<O>> ceQuery)
Triggers a refinement of the model by providing a counterexample.
|
void |
resume(de.learnlib.algorithms.kv.mealy.KearnsVaziraniMealyState<I,O> state)
Does not get the learner to continue learning.
|
void |
startLearning()
Starts the model inference process, creating an initial hypothesis in the provided model object.
|
de.learnlib.algorithms.kv.mealy.KearnsVaziraniMealyState<I,O> |
suspend()
Expose the serializable learner state object.
|
protected AbstractWordBasedDiscriminationTree<I,net.automatalib.words.Word<O>,StateInfo<I,net.automatalib.words.Word<O>>> discriminationTree
public KearnsVaziraniMealy(net.automatalib.words.Alphabet<I> alphabet, MembershipOracle<I,net.automatalib.words.Word<O>> oracle, boolean repeatedCounterexampleEvaluation, AcexAnalyzer counterexampleAnalyzer)
public void startLearning()
LearningAlgorithm
startLearning
in interface LearningAlgorithm<net.automatalib.automata.transout.MealyMachine<?,I,?,O>,I,net.automatalib.words.Word<O>>
public boolean refineHypothesis(DefaultQuery<I,net.automatalib.words.Word<O>> ceQuery)
LearningAlgorithm
LearningAlgorithm.startLearning()
should be illegal.refineHypothesis
in interface LearningAlgorithm<net.automatalib.automata.transout.MealyMachine<?,I,?,O>,I,net.automatalib.words.Word<O>>
ceQuery
- the query which exposes diverging behavior, as posed to the real SUL (i.e. with the SULs output).public net.automatalib.automata.transout.MealyMachine<?,I,?,O> getHypothesisModel()
LearningAlgorithm
N.B.: By the contract of this interface, the model returned by this method may not be modified (i.e., M generally
should refer to an immutable interface), and its validity is retained only until the next invocation of LearningAlgorithm.refineHypothesis(DefaultQuery)
. If older hypotheses have to be maintained, a copy of the returned model must be
made.
Please note that it should be illegal to invoke this method before an initial invocation of LearningAlgorithm.startLearning()
.
getHypothesisModel
in interface LearningAlgorithm<net.automatalib.automata.transout.MealyMachine<?,I,?,O>,I,net.automatalib.words.Word<O>>
public void addAlphabetSymbol(I symbol)
addAlphabetSymbol
in interface SupportsGrowingAlphabet<I>
public de.learnlib.algorithms.kv.mealy.KearnsVaziraniMealyState<I,O> suspend()
ResumableLearner
Does not stop a running learning process. Since most data structures that are used during learning are mutable, use this method inside of a learning loop with care.
suspend
in interface ResumableLearner<de.learnlib.algorithms.kv.mealy.KearnsVaziraniMealyState<I,O>>
public void resume(de.learnlib.algorithms.kv.mealy.KearnsVaziraniMealyState<I,O> state)
ResumableLearner
resume
in interface ResumableLearner<de.learnlib.algorithms.kv.mealy.KearnsVaziraniMealyState<I,O>>
state
- The learner state.Copyright © 2018. All rights reserved.