Welcome to mirror list, hosted at ThFree Co, Russian Federation.

test_context_partial.sh « _self-adaptive « tests - github.com/marian-nmt/marian-regression-tests.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: a062b5188cd545fbe1c37ed74d7103da08f87ef6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/bin/bash

# Exit on error
set -e

# Test code goes here
rm -f contextpart.log

# Run Marian
$MRT_MARIAN/marian-adaptive \
  -m $MRT_MODELS/wmt16_systems/en-de/model.npz \
  -v $MRT_MODELS/wmt16_systems/en-de/vocab.en.json -v $MRT_MODELS/wmt16_systems/en-de/vocab.de.json \
  --dim-vocabs 85000 85000 --dim-emb 500 --after-epochs 1 \
  -t ubuntu.contextpart.src ubuntu.contextpart.ref --log contextpart.log < ubuntu.src > contextpart.out

# Check outputs
$MRT_TOOLS/diff.sh contextpart.out contextpart.expected > contextpart.diff

# Check costs
cat contextpart.log | $MRT_TOOLS/extract-costs.sh > contextpart.costs.out
$MRT_TOOLS/diff-nums.py -p 0.01 contextpart.costs.out contextpart.costs.expected -o contextpart.costs.diff

# Exit with success code
exit 0