e18df168c65541107227e567de3a99cb21cfa426,theanolm/commands/decode.py,,decode,#Any#,91

Before Change


            args.output_file.write("{} ({})\n".format(" ".join(words), utterance_id))
        elif args.output == "n-best":
            ac_logprob = best_token.ac_logprob / log_scale
            lm_logprob = best_token.ac_logprob / log_scale
            args.output_file.write("{} {} {} {}\n".format(
                utterance_id, logprob, len(words), " ".join(words)))
        else:
            print("Invalid output format requested:", args.output)
            sys.exit(1)

After Change


                     args.job)
        tokens = decoder.decode(lattice)

        for index in range(min(args.n_best, len(tokens))):
            line = format_token(tokens[index],
                                utterance_id,
                                vocabulary,
                                log_scale,
                                args.output)
            args.output_file.write(line + "\n")

def format_token(token, utterance_id, vocabulary, log_scale, format):
    Formats an output line from a token and an utterance ID.
    
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: senarvi/theanolm
Commit Name: e18df168c65541107227e567de3a99cb21cfa426
Time: 2016-08-03
Author: seppo.git@marjaniemi.com
File Name: theanolm/commands/decode.py
Class Name:
Method Name: decode


Project Name: titu1994/MLSTM-FCN
Commit Name: 0bcbc6010cb581aec78aac51dbfda7d1e6a89621
Time: 2017-08-14
Author: titu1994@gmail.com
File Name: data/generate_character_dataset.py
Class Name:
Method Name:


Project Name: titu1994/MLSTM-FCN
Commit Name: 0bcbc6010cb581aec78aac51dbfda7d1e6a89621
Time: 2017-08-14
Author: titu1994@gmail.com
File Name: data/generate_ck_dataset.py
Class Name:
Method Name: