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/01 02:52:17 UTC
[82/94] [abbrv] incubator-joshua git commit: Fixed Jenkins compile
errors
Fixed Jenkins compile errors
Project: http://git-wip-us.apache.org/repos/asf/incubator-joshua/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-joshua/commit/9e702666
Tree: http://git-wip-us.apache.org/repos/asf/incubator-joshua/tree/9e702666
Diff: http://git-wip-us.apache.org/repos/asf/incubator-joshua/diff/9e702666
Branch: refs/heads/master
Commit: 9e7026665a92aa1d7298738a247f47c8ff3d326f
Parents: 7cadd04
Author: Matt Post <po...@cs.jhu.edu>
Authored: Tue May 31 14:30:04 2016 -0400
Committer: Matt Post <po...@cs.jhu.edu>
Committed: Tue May 31 14:30:04 2016 -0400
----------------------------------------------------------------------
.../apache/joshua/decoder/StructuredTranslationFactory.java | 8 ++++++--
src/main/java/org/apache/joshua/decoder/Translation.java | 6 +-----
.../org/apache/joshua/decoder/hypergraph/KBestExtractor.java | 5 ++++-
.../apache/joshua/decoder/hypergraph/WordAlignmentState.java | 5 +++++
src/main/java/org/apache/joshua/util/Constants.java | 2 +-
5 files changed, 17 insertions(+), 9 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-joshua/blob/9e702666/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 de5a90b..850fce4 100644
--- a/src/main/java/org/apache/joshua/decoder/StructuredTranslationFactory.java
+++ b/src/main/java/org/apache/joshua/decoder/StructuredTranslationFactory.java
@@ -43,6 +43,10 @@ public class StructuredTranslationFactory {
/**
* Returns a StructuredTranslation instance from the Viterbi derivation.
+ *
+ * @param sourceSentence
+ * @param hypergraph
+ * @param featureFunctions
* @return A StructuredTranslation object representing the Viterbi derivation.
*/
public static StructuredTranslation fromViterbiDerivation(
@@ -63,8 +67,8 @@ public class StructuredTranslationFactory {
/**
* Returns a StructuredTranslation from an empty decoder output
- * @param sourceSentence
- * @return
+ * @param sourceSentence the source sentence
+ * @return a StructuredTranslation object
*/
public static StructuredTranslation fromEmptyOutput(final Sentence sourceSentence) {
return new StructuredTranslation(
http://git-wip-us.apache.org/repos/asf/incubator-joshua/blob/9e702666/src/main/java/org/apache/joshua/decoder/Translation.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/joshua/decoder/Translation.java b/src/main/java/org/apache/joshua/decoder/Translation.java
index 6b8e5e4..7dbaf14 100644
--- a/src/main/java/org/apache/joshua/decoder/Translation.java
+++ b/src/main/java/org/apache/joshua/decoder/Translation.java
@@ -45,12 +45,8 @@ import org.slf4j.LoggerFactory;
* sentence and id and contains the decoded hypergraph. Translation objects are returned by
* DecoderThread instances to the InputHandler, where they are assembled in order for output.
*
-<<<<<<< HEAD:src/main/java/org/apache/joshua/decoder/Translation.java
* @author Matt Post post@cs.jhu.edu
-=======
- * @author Matt Post <po...@cs.jhu.edu>
- * @author Felix Hieber <fh...@amazon.com>
->>>>>>> origin/master:src/joshua/decoder/Translation.java
+ * @author Felix Hieber fhieber@amazon.com
*/
public class Translation {
http://git-wip-us.apache.org/repos/asf/incubator-joshua/blob/9e702666/src/main/java/org/apache/joshua/decoder/hypergraph/KBestExtractor.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/joshua/decoder/hypergraph/KBestExtractor.java b/src/main/java/org/apache/joshua/decoder/hypergraph/KBestExtractor.java
index 9782284..6b4a97c 100644
--- a/src/main/java/org/apache/joshua/decoder/hypergraph/KBestExtractor.java
+++ b/src/main/java/org/apache/joshua/decoder/hypergraph/KBestExtractor.java
@@ -162,6 +162,10 @@ public class KBestExtractor {
/**
* Returns the k-th Structured Translation.
+ *
+ * @param node The node to extract from
+ * @param k The (1-indexed) index of the item wanted
+ * @return a StructuredTranslation object
*/
public StructuredTranslation getKthStructuredTranslation(HGNode node, int k) {
StructuredTranslation result = null;
@@ -179,7 +183,6 @@ public class KBestExtractor {
*
* @param hg the hypergraph to extract from
* @param topN how many to extract
- * @param out object to write to
* @return list of StructuredTranslation objects, empty if there is no HyperGraph goal node.
*/
public List<StructuredTranslation> KbestExtractOnHG(HyperGraph hg, int topN) {
http://git-wip-us.apache.org/repos/asf/incubator-joshua/blob/9e702666/src/main/java/org/apache/joshua/decoder/hypergraph/WordAlignmentState.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/joshua/decoder/hypergraph/WordAlignmentState.java b/src/main/java/org/apache/joshua/decoder/hypergraph/WordAlignmentState.java
index 7a9ce7d..f057f23 100644
--- a/src/main/java/org/apache/joshua/decoder/hypergraph/WordAlignmentState.java
+++ b/src/main/java/org/apache/joshua/decoder/hypergraph/WordAlignmentState.java
@@ -52,6 +52,9 @@ public class WordAlignmentState {
/**
* construct AlignmentState object from a virgin Rule and its source span.
* Determines if state is complete (if no NT present)
+ *
+ * @param rule the input Rule
+ * @param start the start index
*/
public WordAlignmentState(final Rule rule, final int start) {
trgPoints = new LinkedList<AlignedSourceTokens>();
@@ -153,6 +156,8 @@ public class WordAlignmentState {
* nonterminal slot. Also shifts the indeces in this instance by the span/width of the
* child that is to be substituted.
* Substitution order is determined by the source-first traversal through the hypergraph.
+ *
+ * @param child The child
*/
public void substituteIn(WordAlignmentState child) {
// find the index of the NonTerminal where we substitute the child targetPoints into.
http://git-wip-us.apache.org/repos/asf/incubator-joshua/blob/9e702666/src/main/java/org/apache/joshua/util/Constants.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/joshua/util/Constants.java b/src/main/java/org/apache/joshua/util/Constants.java
index 45d2aef..3d4139d 100644
--- a/src/main/java/org/apache/joshua/util/Constants.java
+++ b/src/main/java/org/apache/joshua/util/Constants.java
@@ -21,7 +21,7 @@ package org.apache.joshua.util;
/***
* One day, all constants should be moved here (many are in Vocabulary).
*
- * @author Matt Post <po...@cs.jhu.edu>
+ * @author Matt Post post@cs.jhu.edu
*/
public final class Constants {