internal GrammarState(DynamicFlatLinguist dynamicFlatLinguist, GrammarNode grammarNode, float num, int num2, int num3) : base(dynamicFlatLinguist) { this.lc = num2; this.nextBaseID = num3; this.node = grammarNode; this.languageProbability = num; }
public override SearchStateArc[] getSuccessors() { SearchStateArc[] array = this.getCachedSuccessors(); if (array != null) { return(array); } if (this.isFinal()) { array = DynamicFlatLinguist.access_100(this.this_0); } else if (this.node.isEmpty()) { array = this.getNextGrammarStates(this.lc, this.nextBaseID); } else { Word word = this.node.getWord(); Pronunciation[] pronunciations = word.getPronunciations(); SearchStateArc[] array2 = new SearchStateArc[pronunciations.Length]; for (int i = 0; i < pronunciations.Length; i++) { array2[i] = new DynamicFlatLinguist.PronunciationState(this.this_0, this, pronunciations[i]); } array = array2; } this.cacheSuccessors(array); return(array); }
public override float getInsertionProbability() { if (this.pronunciation.getWord().isFiller()) { return(0f); } return(DynamicFlatLinguist.access_500(this.this_0)); }
public SearchState getInitialState() { DynamicFlatLinguist.InitialState initialState = new DynamicFlatLinguist.InitialState(this.this_0); initialState.addArc(new DynamicFlatLinguist.GrammarState(this.this_0, DynamicFlatLinguist.access_900(this.this_0).getInitialNode())); if (DynamicFlatLinguist.access_1000(this.this_0)) { OutOfGrammarGraph outOfGrammarGraph = new OutOfGrammarGraph(DynamicFlatLinguist.access_1100(this.this_0), DynamicFlatLinguist.access_1200(this.this_0), DynamicFlatLinguist.access_1300(this.this_0)); initialState.addArc(outOfGrammarGraph.getOutOfGrammarGraph()); } return(initialState); }
internal FullHMMSearchState(DynamicFlatLinguist dynamicFlatLinguist, DynamicFlatLinguist.PronunciationState pronunciationState, int num, int leftID, int rightID) : base(dynamicFlatLinguist) { this.pState = pronunciationState; this.index = num; this.lc = leftID; this.rc = rightID; int baseID = pronunciationState.getPronunciation().getUnits()[num].getBaseID(); int unitID = DynamicFlatLinguist.access_200(dynamicFlatLinguist).buildID(baseID, leftID, rightID); this.hmm = DynamicFlatLinguist.access_200(dynamicFlatLinguist).getHMM(unitID, this.getPosition()); this._isLastUnitOfWord = (num == pronunciationState.getPronunciation().getUnits().Length - 1); }
public override float getInsertionProbability() { Unit baseUnit = this.hmm.getBaseUnit(); if (baseUnit.isSilence()) { return(DynamicFlatLinguist.access_600(this.this_0)); } if (baseUnit.isFiller()) { return(DynamicFlatLinguist.access_700(this.this_0)); } return(DynamicFlatLinguist.access_800(this.this_0)); }
internal GrammarState(DynamicFlatLinguist dynamicFlatLinguist, GrammarNode grammarNode, float num, int num2) : this(dynamicFlatLinguist, grammarNode, num, num2, 0) { }
internal GrammarState(DynamicFlatLinguist dynamicFlatLinguist, GrammarNode grammarNode) : this(dynamicFlatLinguist, grammarNode, 0f, UnitManager.__SILENCE.getBaseID()) { }
internal static AcousticModel access_1100(DynamicFlatLinguist dynamicFlatLinguist) { return(dynamicFlatLinguist.phoneLoopAcousticModel); }
internal HMMStateSearchState(DynamicFlatLinguist dynamicFlatLinguist, DynamicFlatLinguist.FullHMMSearchState fullHMMSearchState, HMMState hmmstate, float num) : base(dynamicFlatLinguist) { this.probability = num; this.fullHMMSearchState = fullHMMSearchState; this.hmmState = hmmstate; }
public override string toString() { return(new StringBuilder().append(this.node).append("[").append(DynamicFlatLinguist.access_200(this.this_0).getUnit(this.lc)).append(',').append(DynamicFlatLinguist.access_200(this.this_0).getUnit(this.nextBaseID)).append(']').toString()); }
public override string getSignature() { return(new StringBuilder().append("GS ").append(this.node).append("-lc-").append(DynamicFlatLinguist.access_200(this.this_0).getUnit(this.lc)).append("-rc-").append(DynamicFlatLinguist.access_200(this.this_0).getUnit(this.nextBaseID)).toString()); }
public override float getLanguageProbability() { return(this.languageProbability * DynamicFlatLinguist.access_000(this.this_0)); }
internal DynamicFlatSearchGraph(DynamicFlatLinguist dynamicFlatLinguist) { this.this_0 = dynamicFlatLinguist; }
internal static float access_1300(DynamicFlatLinguist dynamicFlatLinguist) { return(dynamicFlatLinguist.logPhoneInsertionProbability); }
internal static float access_1200(DynamicFlatLinguist dynamicFlatLinguist) { return(dynamicFlatLinguist.logOutOfGrammarBranchProbability); }
internal static float access_700(DynamicFlatLinguist dynamicFlatLinguist) { return(dynamicFlatLinguist.logFillerInsertionProbability); }
internal static Map access_400(DynamicFlatLinguist dynamicFlatLinguist) { return(dynamicFlatLinguist.nodeToNextUnitArrayMap); }
internal static Map access_300(DynamicFlatLinguist dynamicFlatLinguist) { return(dynamicFlatLinguist.nodeToUnitSetMap); }
internal static float access_000(DynamicFlatLinguist dynamicFlatLinguist) { return(dynamicFlatLinguist.languageWeight); }
private bool hasEntryContext(GrammarNode grammarNode, int unitID) { Set set = (Set)DynamicFlatLinguist.access_300(this.this_0).get(grammarNode); return(set.contains(DynamicFlatLinguist.access_200(this.this_0).getUnit(unitID))); }
internal static SearchStateArc[] access_100(DynamicFlatLinguist dynamicFlatLinguist) { return(dynamicFlatLinguist.EMPTY_ARCS); }
internal static bool access_1000(DynamicFlatLinguist dynamicFlatLinguist) { return(dynamicFlatLinguist.addOutOfGrammarBranch); }
internal FlatSearchState(DynamicFlatLinguist dynamicFlatLinguist) { this.this_0 = dynamicFlatLinguist; }
internal int[] getNextUnits() { return((int[])DynamicFlatLinguist.access_400(this.this_0).get(this.node)); }
internal static Grammar access_900(DynamicFlatLinguist dynamicFlatLinguist) { return(dynamicFlatLinguist.grammar); }
internal HMMStateSearchState(DynamicFlatLinguist dynamicFlatLinguist, DynamicFlatLinguist.FullHMMSearchState fullHMMSearchState, HMMState hmmstate) : this(dynamicFlatLinguist, fullHMMSearchState, hmmstate, 0f) { }
internal FullHMMSearchState(DynamicFlatLinguist dynamicFlatLinguist, DynamicFlatLinguist.PronunciationState pronunciationState, int num, int num2) : this(dynamicFlatLinguist, pronunciationState, num, num2, pronunciationState.getPronunciation().getUnits()[num + 1].getBaseID()) { }
internal InitialState(DynamicFlatLinguist dynamicFlatLinguist) : base(dynamicFlatLinguist) { this.nextArcs = new ArrayList(); }
internal static HMMPool access_200(DynamicFlatLinguist dynamicFlatLinguist) { return(dynamicFlatLinguist.hmmPool); }