jInfer

cz.cuni.mff.ksi.jinfer.twostep.processing.automatonmergingstate.simplifying.heuristicmdl
Class HeuristicMDL<T>

java.lang.Object
  extended by cz.cuni.mff.ksi.jinfer.twostep.processing.automatonmergingstate.simplifying.heuristicmdl.HeuristicMDL<T>
All Implemented Interfaces:
AutomatonSimplifier<T>

public class HeuristicMDL<T>
extends Object
implements AutomatonSimplifier<T>

HeuristicMDL simplifier, given MergeContitionTester, will merge all states that tester returns as equivalent. It will ask the tester for capability "parameters". When the tester is one from known, it will set parameters to it according to user preference. If it is not known, it is created with factory, so tester have to have some reasonable default parameter setting or own properties panel for user to enter defaults.


Constructor Summary
HeuristicMDL(MergeConditionTesterFactory mergeConditionTesterFactory, AutomatonEvaluatorFactory evaluatorFactory)
          Create with factory of MergeConditionTester selected.
HeuristicMDL(MergeConditionTesterFactory mergeConditionTesterFactory, AutomatonEvaluatorFactory evaluatorFactory, Properties properties)
          Create with factory of MergeConditionTester selected.
 
Method Summary
 Automaton<T> simplify(Automaton<T> inputAutomaton, SymbolToString<T> symbolToString)
          Simplify an automaton.
 Automaton<T> simplify(Automaton<T> inputAutomaton, SymbolToString<T> symbolToString, List<List<T>> inputStrings)
          Simplify by merging states greedily.
 Automaton<T> simplify(Automaton<T> inputAutomaton, SymbolToString<T> symbolToString, String elementName)
          Simplify an automaton.
 Automaton<T> simplify(Automaton<T> inputAutomaton, SymbolToString<T> symbolToString, String elementName, List<List<T>> inputStrings)
          Same as above.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HeuristicMDL

public HeuristicMDL(MergeConditionTesterFactory mergeConditionTesterFactory,
                    AutomatonEvaluatorFactory evaluatorFactory)
Create with factory of MergeConditionTester selected. Without parameters capability!

Parameters:
mergeConditionTesterFactory - factory for {link MergeConditionTester} to use in simplifying.

HeuristicMDL

public HeuristicMDL(MergeConditionTesterFactory mergeConditionTesterFactory,
                    AutomatonEvaluatorFactory evaluatorFactory,
                    Properties properties)
Create with factory of MergeConditionTester selected.

Parameters:
mergeConditionTesterFactory - factory for {link MergeConditionTester} to use in simplifying.
properties - project properties (from which it takes parameter values).
Method Detail

simplify

public Automaton<T> simplify(Automaton<T> inputAutomaton,
                             SymbolToString<T> symbolToString,
                             List<List<T>> inputStrings)
                      throws InterruptedException
Simplify by merging states greedily. Loops until there are no more states to merge by tester.

Specified by:
simplify in interface AutomatonSimplifier<T>
Parameters:
inputAutomaton - automaton to modify
symbolToString - edge label to string converter
Returns:
new automaton, which accepts more general language and is simple in design
Throws:
InterruptedException

simplify

public Automaton<T> simplify(Automaton<T> inputAutomaton,
                             SymbolToString<T> symbolToString,
                             String elementName,
                             List<List<T>> inputStrings)
                      throws InterruptedException
Same as above.

Specified by:
simplify in interface AutomatonSimplifier<T>
Parameters:
inputAutomaton - automaton to modify
symbolToString - edge label to string converter
elementName - name of element (cluster) we process right now, to be presented to user
Returns:
Throws:
InterruptedException

simplify

public Automaton<T> simplify(Automaton<T> inputAutomaton,
                             SymbolToString<T> symbolToString)
                      throws InterruptedException
Description copied from interface: AutomatonSimplifier
Simplify an automaton.

Specified by:
simplify in interface AutomatonSimplifier<T>
Parameters:
inputAutomaton - automaton to process
symbolToString - converter of symbols (of type T) to string - for rendering automaton to user
Returns:
new automaton, which accepts more general language and is simple in design
Throws:
InterruptedException

simplify

public Automaton<T> simplify(Automaton<T> inputAutomaton,
                             SymbolToString<T> symbolToString,
                             String elementName)
                      throws InterruptedException
Description copied from interface: AutomatonSimplifier
Simplify an automaton.

Specified by:
simplify in interface AutomatonSimplifier<T>
Parameters:
inputAutomaton - automaton to process
symbolToString - converter of symbols (of type T) to string - for rendering automaton to user
Returns:
new automaton, which accepts more general language and is simple in design
Throws:
InterruptedException

jInfer

Generated on Fri Dec 9 00:01:25 CET 2011