|
Joshua
open source statistical hierarchical phrase-based machine translation system
|
Public Member Functions | |
| BilingualRule (int lhs, int[] sourceRhs, int[] targetRhs, float[] featureScores, int arity, int owner, float latticeCost, int ruleID) | |
| BilingualRule (int lhs, int[] sourceRhs, int[] targetRhs, float[] featureScores, int arity) | |
| final void | setEnglish (int[] eng) |
| final int[] | getEnglish () |
| String | toString (Map< Integer, String > ntVocab) |
| String | toString () |
| String | toStringWithoutFeatScores () |
| boolean | equals (Object o) |
| int | hashCode () |
Private Attributes | |
| int[] | english |
| transient String | cachedToString = null |
Normally, the feature score in the rule should be cost (i.e., -LogP), so that the feature weight should be positive
| joshua.decoder.ff.tm.BilingualRule.BilingualRule | ( | int | lhs, |
| int[] | sourceRhs, | ||
| int[] | targetRhs, | ||
| float[] | featureScores, | ||
| int | arity, | ||
| int | owner, | ||
| float | latticeCost, | ||
| int | ruleID | ||
| ) |
Constructs a new rule using the provided parameters. The owner and rule id for this rule are undefined.
| lhs | Left-hand side of the rule. |
| sourceRhs | Source language right-hand side of the rule. |
| targetRhs | Target language right-hand side of the rule. |
| featureScores | Feature value scores for the rule. |
| arity | Number of nonterminals in the source language right-hand side. |
| owner | |
| latticeCost | |
| ruleID |
| joshua.decoder.ff.tm.BilingualRule.BilingualRule | ( | int | lhs, |
| int[] | sourceRhs, | ||
| int[] | targetRhs, | ||
| float[] | featureScores, | ||
| int | arity | ||
| ) |
| boolean joshua.decoder.ff.tm.BilingualRule.equals | ( | Object | o | ) |
Two BilingualRules are equal of they have the same LHS, the same source RHS and the same target RHS.
| o | the object to check for equality |
| final int [] joshua.decoder.ff.tm.BilingualRule.getEnglish | ( | ) |
Reimplemented from joshua.decoder.ff.tm.MonolingualRule.
| final void joshua.decoder.ff.tm.BilingualRule.setEnglish | ( | int[] | eng | ) |
Reimplemented from joshua.decoder.ff.tm.MonolingualRule.
| String joshua.decoder.ff.tm.BilingualRule.toString | ( | Map< Integer, String > | ntVocab | ) |
| String joshua.decoder.ff.tm.BilingualRule.toString | ( | ) |
transient String joshua.decoder.ff.tm.BilingualRule.cachedToString = null [private] |
Reimplemented from joshua.decoder.ff.tm.MonolingualRule.
int [] joshua.decoder.ff.tm.BilingualRule.english [private] |