https://github.com/hominsu/moses-docker
Docker build for mosesdecoder
https://github.com/hominsu/moses-docker
docker docker-container docker-image dockerfile moses moses-installer moses-machine-translation mosesdecoder
Last synced: 2 months ago
JSON representation
Docker build for mosesdecoder
- Host: GitHub
- URL: https://github.com/hominsu/moses-docker
- Owner: hominsu
- License: mit
- Created: 2023-10-11T08:37:38.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2023-10-31T12:50:27.000Z (over 2 years ago)
- Last Synced: 2023-11-01T09:25:31.774Z (over 2 years ago)
- Topics: docker, docker-container, docker-image, dockerfile, moses, moses-installer, moses-machine-translation, mosesdecoder
- Language: Dockerfile
- Homepage:
- Size: 12.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
moses-docker
This project prepares a minimalist Docker image with mosesdecoder.
Examples
·
Building
·
License
## Examples
All the scripts and binaries are placed in `/moses/script/` and `/moses/bin/`.
```bash
mkdir -p workspace
docker pull hominsu/moses:latest
docker run -v ./workspace:/workspace -it --rm hominsu/moses:latest /bin/bash
```
For examples.
- Use `multi-bleu.perl` to evaluate bleu.
```bash
/moses/scripts/generic/multi-bleu.perl -lc ../corpus/tst.clean.en < tst.translated.en
```
- Use `moses` to translate the test set.
```bash
/moses/bin/moses -f ./filtered-corpus/moses.ini < ../corpus/tst.clean.zh > tst.translated.en 2> tst.out
```
### Notice!!!
Use `Multi-threaded GIZA++` as the word alignment tool here, so while you are training, you need to specify the word
alignment tool as MGIZA.
```bash
/moses/scripts/training/train-model.perl -root-dir train -corpus ../corpus/train.clean -f zh -e en -alignment grow-diag-final-and -reordering msd-bidirectional-fe -lm 0:3:$(pwd)/../lm/train.blm.en:8 -mgiza -mgiza-cpus 64 -cores 64 -external-bin-dir /usr/local/bin >& training.out
```
## Building
This project requires Docker.
With the `platform` option, build any platform you want.
```shell
docker buildx bake --file ./docker-bake.hcl --load --set "*.platform=linux/amd64"
```
## License
Distributed under the MIT license. See `LICENSE` for more information.