Skip to content
This repository was archived by the owner on Dec 13, 2021. It is now read-only.

JOSHUA-252 Make it possible to use Maven to build Joshua #12

Merged
merged 29 commits into from
Jun 1, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
8cdbc4b
JOSHUA-252 Make it possible to use Maven to build Joshua
lewismc May 14, 2016
89e2275
JOSHUA-252 Make it possible to use Maven to build Joshua
lewismc May 14, 2016
f401535
JOSHUA-252 Make it possible to use Maven to build Joshua
lewismc May 14, 2016
7f824b4
JOSHUA-252 Make it possible to use Maven to build Joshua
lewismc May 14, 2016
ab5bb42
JOSHUA-252 Make it possible to use Maven to build Joshua
lewismc May 16, 2016
7c8e856
JOSHUA-252 correctly specify test dependency in NodeTest.java
lewismc May 16, 2016
9848541
System.exit() removed and replaced with RuntimeException(...)
thammegowda May 16, 2016
f354c29
Merge branch 'JOSHUA-264' of https://github.com/thammegowda/incubator…
mjpost May 16, 2016
575ca46
Added Maven assembly plugin
thammegowda May 16, 2016
659e464
Merge branch 'jar-with-dependencies' of https://github.com/thammegowd…
mjpost May 17, 2016
ae47ca1
JOSHUA-252 Make it possible to use Maven to build Joshua
lewismc May 17, 2016
1fc0590
JOSHUA-252 Make it possible to use Maven to build Joshua
lewismc May 18, 2016
c21fa9e
Log4j - Slf4j bridge
thammegowda May 21, 2016
9114a00
Read me updated
thammegowda May 21, 2016
4d04cc2
LOG scope is privatized
thammegowda May 21, 2016
d6efccb
Clean LOGs, no redudant if(enabled) checks, no eager toString()s
thammegowda May 21, 2016
8652d19
Fix spaces
thammegowda May 21, 2016
d4ac451
Fix log issues such as redundant checks and spaces
thammegowda May 21, 2016
1586853
Replaced System.err.print* with logger api
thammegowda May 23, 2016
aead620
JOSHUA-252 Make it possible to use Maven to build Joshua
lewismc May 25, 2016
d8a68df
JOSHUA-252 Make it possible to use Maven to build Joshua
lewismc May 25, 2016
fdf20e2
JOSHUA-252 Make it possible to use Maven to build Joshua
lewismc May 25, 2016
a3a2522
JOSHUA-252 Make it possible to use Maven to build Joshua
lewismc May 25, 2016
9475d94
JOSHUA-252 Make it possible to use Maven to build Joshua
lewismc May 26, 2016
d026c71
JOSHUA-252 Make it possible to use Maven to build Joshua
lewismc May 26, 2016
ef91969
Pulled JOSHUA-252 changes and Resolved Merge Conflicts
thammegowda May 26, 2016
d51b15c
Merge branch 'jar-with-dependencies' of http://github.com/thammegowda…
lewismc May 26, 2016
02f3ef1
Resolve Merge Conflicts
thammegowda May 26, 2016
9d6f84d
Rebased with JOSHUA-252 and resolved merge conflicts
thammegowda May 26, 2016
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
10 changes: 0 additions & 10 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,10 +0,0 @@
[submodule "thrax"]
path = thrax
url = https://github.com/joshua-decoder/thrax.git
[submodule "berkeleylm"]
path = ext/berkeleylm
url = https://github.com/joshua-decoder/berkeleylm.git
[submodule "ext/kenlm"]
path = ext/kenlm
url = https://github.com/kpu/kenlm.git
branch = 56fdb5c44fca34d5a2e07d96139c28fb163983c5
18 changes: 0 additions & 18 deletions .project

This file was deleted.

3 changes: 0 additions & 3 deletions .settings/org.eclipse.core.resources.prefs

This file was deleted.

285 changes: 0 additions & 285 deletions .settings/org.eclipse.jdt.core.prefs

This file was deleted.

4 changes: 0 additions & 4 deletions .settings/org.eclipse.jdt.ui.prefs

This file was deleted.

12 changes: 12 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,18 @@ The basic method for invoking the decoder looks like this:

Some example usage scenarios and scripts can be found in the [examples/](https://github.com/apache/incubator-joshua/tree/master/examples) directory.

----
### Maven Build

### Create executable jar

mvn clean compile assembly:single

### Run the jar

java -jar target/joshua-6.0.6-SNAPSHOT-jar-with-dependencies.jar


## Working with "language packs"

Joshua includes a number of "language packs", which are pre-built models that
Expand Down
15 changes: 15 additions & 0 deletions bin/bleu
Original file line number Diff line number Diff line change
@@ -1,5 +1,20 @@
#!/usr/bin/env bash

# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

if [[ -z $2 ]]; then
echo "Usage: bleu output reference"
exit 1
Expand Down
15 changes: 15 additions & 0 deletions bin/extract-1best
Original file line number Diff line number Diff line change
@@ -1,3 +1,18 @@
#!/bin/bash

# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

java -Xmx500m -cp $JOSHUA/class -Dfile.encoding=utf8 joshua.util.ExtractTopCand $1 - $2
16 changes: 16 additions & 0 deletions bin/joshua-decoder
Original file line number Diff line number Diff line change
@@ -1,4 +1,20 @@
#!/bin/bash

# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

#
# Joshua decoder invocation script.
#
Expand Down
15 changes: 15 additions & 0 deletions bin/meteor
Original file line number Diff line number Diff line change
@@ -1,5 +1,20 @@
#!/usr/bin/env bash

# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

if [[ -z $3 ]]; then
echo "Usage: meteor output reference lang"
exit 1
Expand Down
File renamed without changes.
39 changes: 37 additions & 2 deletions examples/README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Examples
# Joshua Examples

The examples in this directory demonstrate how to exercise different
Joshua features. If you have any comments or questions please submit
Expand All @@ -10,4 +10,39 @@ Bugs or source code issues should be logged in our
The decoding examples and model training examples in the subdirectories of this
directory assume you have downloaded the Fisher Spanish--English dataset, which
contains speech-recognizer output paired with English translations. This data
can be downloaded by running the [download.sh](https://github.com/apache/incubator-joshua/blob/master/examples/download.sh) script.
can be downloaded by running the [download.sh](https://github.com/apache/incubator-joshua/blob/master/src/examples/resources/download.sh) script.

# Building a Spanish --> English Translation Model using the Fisher Spanish CALLHOME corpus

An example of how to build a model using the Fisher Spanish CALLHOME corpus

A) Download the corpus:
1) mkdir $HOME/git
2) cd $HOME/git
3) curl -o fisher-callhome-corpus.zip https://codeload.github.com/joshua-decoder/fisher-callhome-corpus/legacy.zip/master
4) unzip fisher-callhome-corpus.zip
5) # Set environment variable SPANISH=$HOME/git/fisher-callhome-corpus
5) mv joshua-decoder-*/ fisher-callhome-corpus

B) Download and install Joshua:
1) cd /directory/to/install/
2) git clone https://github.com/apache/incubator-joshua.git
3) cd incubator-joshua
4) # Set environment variable JAVA_HOME=/path/to/java # Try $(readlink -f /usr/bin/javac | sed "s:/bin/javac::")
5) # Set environment variable JOSHUA=/directory/to/install/joshua
6) mvn install

C) Train the model:
1) mkdir -p $HOME/expts/joshua && cd $HOME/expts/joshua
2) $JOSHUA/bin/pipeline.pl \
--rundir 1 \
--readme "Baseline Hiero run" \
--source es \
--target en \
--lm-gen srilm \
--witten-bell \
--corpus $SPANISH/corpus/asr/callhome_train \
--corpus $SPANISH/corpus/asr/fisher_train \
--tune $SPANISH/corpus/asr/fisher_dev \
--test $SPANISH/corpus/asr/callhome_devtest \
--lm-order 3
32 changes: 0 additions & 32 deletions examples/README.sp_to_en

This file was deleted.

1 change: 0 additions & 1 deletion ext/berkeleylm
Submodule berkeleylm deleted from c43105
119 changes: 0 additions & 119 deletions ext/giza-pp/GIZA++-v2/ATables.cpp

This file was deleted.

Loading