Hi,

        Has nothing do to with kenlm.  The error message says
./trained_models/en-hi-translit.gz contains the non-numerical string
"(0)" on line 0 where features are supposed to be.

Kenneth

On 07/22/13 20:44, Pratik Jain wrote:
> Hi
> 
> Thanks a lot for your help. Running moses, I get the mentioned error.
> Could you point out what could be wrong. The code that I am using was
> using SRILM. I changed it to KenLM. Could that be a possible reason for
> this behaviour?
> 
> Output is appended below :
> 
> 
> Defined parameters (per moses.ini or switch):
>     config: ./trained_models/en-hi-baseline.ini
>     distortion-limit: 0
>     input-factors: 0
>     input-file: ./intermediate_results/en-clean-input.txt
>     lmodel-file: 8 0 5 ./trained_models/en-hi-baseline.lm
>     mapping: 0 T 0
>     n-best-list: ./intermediate_results/en-hi-baseline-results.txt 10
> distinct
>     ttable-file: 0 0 0 5 ./trained_models/en-hi-baseline.gz
>     ttable-limit: 20 0
>     weight-d: 10
>     weight-l: 0.7000
>     weight-t: 0.35 0.25 0.2 0.1 0.1
>     weight-w: -1
> /home/irlab/mosesdecoder/bin
> line=KENLM factor=0 order=5 num-features=1 lazyken=0
> path=./trained_models/en-hi-baseline.lm
> FeatureFunction: KENLM0 start: 0 end: 1
> Loading the LM will be faster if you build a binary file.
> Reading ./trained_models/en-hi-baseline.lm
> ----5---10---15---20---25---30---35---40---45---50---55---60---65---70---75---80---85---90---95--100
> The ARPA file is missing <unk>.  Substituting log10 probability -100.000.
> ****************************************************************************************************
> WEIGHT KENLM0=0.700,
> line=Distortion
> FeatureFunction: Distortion0 start: 1 end: 2
> WEIGHT Distortion0=10.000,
> line=WordPenalty
> FeatureFunction: WordPenalty0 start: 2 end: 3
> WEIGHT WordPenalty0=-1.000,
> line=UnknownWordPenalty
> FeatureFunction: UnknownWordPenalty0 start: 3 end: 4
> WEIGHT UnknownWordPenalty0=
> line=PhraseDictionaryMemory input-factor=0 output-factor=0
> path=./trained_models/en-hi-baseline.gz num-features=5
> num-input-features=0 table-limit=20
> FeatureFunction: PhraseDictionaryMemory0 start: 4 end: 9
> WEIGHT PhraseDictionaryMemory0=0.350,0.250,0.200,0.100,0.100,
> Start loading text SCFG phrase table. Moses  format : [0.000] seconds
> Reading ./trained_models/en-hi-baseline.gz
> ----5---10---15---20---25---30---35---40---45---50---55---60---65---70---75---80---85---90---95--100
> ****************************************************************************************************
> Exception: moses/TranslationModel/RuleTable/LoaderStandard.cpp:206 in
> bool Moses::RuleTableLoaderStandard::Load(Moses::FormatType, const
> std::vector<long unsigned int>&, const std::vector<long unsigned int>&,
> const string&, size_t, Moses::RuleTableTrie&) threw util::Exception
> because `isnan(score)'.
> Bad score (0) on line 0
> Defined parameters (per moses.ini or switch):
>     config: ./trained_models/en-sy.ini
>     distortion-limit: 0
>     input-factors: 0
>     input-file: ./intermediate_results/en-clean-input.txt
>     lmodel-file: 8 0 4 ./trained_models/en-sy.lm
>     mapping: 0 T 0
>     n-best-list: ./intermediate_results/en-sy-results.txt 1 distinct
>     ttable-file: 0 0 0 5 ./trained_models/en-sy.gz
>     ttable-limit: 20 0
>     weight-d: 0.6
>     weight-l: 0.6000
>     weight-t: 0.4 0.3 0.2 0.1 0
>     weight-w: -1
> /home/irlab/mosesdecoder/bin
> line=KENLM factor=0 order=4 num-features=1 lazyken=0
> path=./trained_models/en-sy.lm
> FeatureFunction: KENLM0 start: 0 end: 1
> Loading the LM will be faster if you build a binary file.
> Reading ./trained_models/en-sy.lm
> ----5---10---15---20---25---30---35---40---45---50---55---60---65---70---75---80---85---90---95--100
> The ARPA file is missing <unk>.  Substituting log10 probability -100.000.
> ****************************************************************************************************
> WEIGHT KENLM0=0.600,
> line=Distortion
> FeatureFunction: Distortion0 start: 1 end: 2
> WEIGHT Distortion0=0.600,
> line=WordPenalty
> FeatureFunction: WordPenalty0 start: 2 end: 3
> WEIGHT WordPenalty0=-1.000,
> line=UnknownWordPenalty
> FeatureFunction: UnknownWordPenalty0 start: 3 end: 4
> WEIGHT UnknownWordPenalty0=
> line=PhraseDictionaryMemory input-factor=0 output-factor=0
> path=./trained_models/en-sy.gz num-features=5 num-input-features=0
> table-limit=20
> FeatureFunction: PhraseDictionaryMemory0 start: 4 end: 9
> WEIGHT PhraseDictionaryMemory0=0.400,0.300,0.200,0.100,0.000,
> Start loading text SCFG phrase table. Moses  format : [0.000] seconds
> Reading ./trained_models/en-sy.gz
> ----5---10---15---20---25---30---35---40---45---50---55---60---65---70---75---80---85---90---95--100
> ****************************************************************************************************
> Exception: moses/TranslationModel/RuleTable/LoaderStandard.cpp:206 in
> bool Moses::RuleTableLoaderStandard::Load(Moses::FormatType, const
> std::vector<long unsigned int>&, const std::vector<long unsigned int>&,
> const string&, size_t, Moses::RuleTableTrie&) threw util::Exception
> because `isnan(score)'.
> Bad score (0) on line 0
> Defined parameters (per moses.ini or switch):
>     config: ./trained_models/en-hi-translit.ini
>     distortion-limit: 0
>     input-factors: 0
>     input-file: ./intermediate_results/en-sy-bestresult.txt
>     lmodel-file: 8 0 5 ./trained_models/en-hi-translit.lm
>     mapping: 0 T 0
>     n-best-list: ./intermediate_results/en-hi-translit-results.txt 10
> distinct
>     ttable-file: 0 0 0 5 ./trained_models/en-hi-translit.gz
>     ttable-limit: 20 0
>     weight-d: 0.6
>     weight-l: 0.5000
>     weight-t: 0.4 0.3 0.15 0.15 0.0
>     weight-w: -1
> /home/irlab/mosesdecoder/bin
> line=KENLM factor=0 order=5 num-features=1 lazyken=0
> path=./trained_models/en-hi-translit.lm
> FeatureFunction: KENLM0 start: 0 end: 1
> Loading the LM will be faster if you build a binary file.
> Reading ./trained_models/en-hi-translit.lm
> ----5---10---15---20---25---30---35---40---45---50---55---60---65---70---75---80---85---90---95--100
> The ARPA file is missing <unk>.  Substituting log10 probability -100.000.
> ****************************************************************************************************
> WEIGHT KENLM0=0.500,
> line=Distortion
> FeatureFunction: Distortion0 start: 1 end: 2
> WEIGHT Distortion0=0.600,
> line=WordPenalty
> FeatureFunction: WordPenalty0 start: 2 end: 3
> WEIGHT WordPenalty0=-1.000,
> line=UnknownWordPenalty
> FeatureFunction: UnknownWordPenalty0 start: 3 end: 4
> WEIGHT UnknownWordPenalty0=
> line=PhraseDictionaryMemory input-factor=0 output-factor=0
> path=./trained_models/en-hi-translit.gz num-features=5
> num-input-features=0 table-limit=20
> FeatureFunction: PhraseDictionaryMemory0 start: 4 end: 9
> WEIGHT PhraseDictionaryMemory0=0.400,0.300,0.150,0.150,0.000,
> Start loading text SCFG phrase table. Moses  format : [0.000] seconds
> Reading ./trained_models/en-hi-translit.gz
> ----5---10---15---20---25---30---35---40---45---50---55---60---65---70---75---80---85---90---95--100
> ****************************************************************************************************
> Exception: moses/TranslationModel/RuleTable/LoaderStandard.cpp:206 in
> bool Moses::RuleTableLoaderStandard::Load(Moses::FormatType, const
> std::vector<long unsigned int>&, const std::vector<long unsigned int>&,
> const string&, size_t, Moses::RuleTableTrie&) threw util::Exception
> because `isnan(score)'.
> Bad score (0) on line 0
> 
> 
> Thanks
> Pratik
> 
> 
> _______________________________________________
> Moses-support mailing list
> [email protected]
> http://mailman.mit.edu/mailman/listinfo/moses-support
> 
_______________________________________________
Moses-support mailing list
[email protected]
http://mailman.mit.edu/mailman/listinfo/moses-support

Reply via email to