You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@joshua.apache.org by mj...@apache.org on 2016/06/23 17:17:28 UTC

incubator-joshua git commit: minor comments

Repository: incubator-joshua
Updated Branches:
  refs/heads/maven-multi-module [created] f178334de


minor comments


Project: http://git-wip-us.apache.org/repos/asf/incubator-joshua/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-joshua/commit/f178334d
Tree: http://git-wip-us.apache.org/repos/asf/incubator-joshua/tree/f178334d
Diff: http://git-wip-us.apache.org/repos/asf/incubator-joshua/diff/f178334d

Branch: refs/heads/maven-multi-module
Commit: f178334de55d551526eb39d1d405d0bd0c8adb9c
Parents: 6aef63d
Author: Matt Post <po...@cs.jhu.edu>
Authored: Thu Jun 23 13:17:24 2016 -0400
Committer: Matt Post <po...@cs.jhu.edu>
Committed: Thu Jun 23 13:17:24 2016 -0400

----------------------------------------------------------------------
 .../org/apache/joshua/decoder/StructuredTranslationFactory.java | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-joshua/blob/f178334d/src/main/java/org/apache/joshua/decoder/StructuredTranslationFactory.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/joshua/decoder/StructuredTranslationFactory.java b/src/main/java/org/apache/joshua/decoder/StructuredTranslationFactory.java
index 916a5a7..921771e 100644
--- a/src/main/java/org/apache/joshua/decoder/StructuredTranslationFactory.java
+++ b/src/main/java/org/apache/joshua/decoder/StructuredTranslationFactory.java
@@ -43,7 +43,9 @@ import org.apache.joshua.decoder.segment_file.Sentence;
 public class StructuredTranslationFactory {
   
   /**
-   * Returns a StructuredTranslation instance from the Viterbi derivation.
+   * Returns a StructuredTranslation instance from the Viterbi derivation. This is used to
+   * obtain the 1-best hypothesis, since traversing the Viterbi derivation directly on the 
+   * hypergraph is considerably faster than instantiating the k-best apparatus.
    * 
    * @param sourceSentence the source sentence
    * @param hypergraph the hypergraph object
@@ -78,6 +80,7 @@ public class StructuredTranslationFactory {
   
   /**
    * Returns a StructuredTranslation instance from a KBest DerivationState. 
+   * 
    * @param sourceSentence Sentence object representing the source.
    * @param derivationState the KBest DerivationState.
    * @return A StructuredTranslation object representing the derivation encoded by derivationState.