def main():

    global MAX_SENT_LEN

    d_dir = sys.argv[1]
    out_dir = sys.argv[2]
    file_prefix = sys.argv[3]
    src = sys.argv[4]
    tgt = sys.argv[5]
    if len(sys.argv) == 7:
        try:
            MAX_SENT_LEN = int(sys.argv[6])
        except __HOLE__:
            print "\nERROR: Last argument should be the maximum sentence length (default 80)\n"
            sys.exit(1)

    if not d_dir.endswith("/"): d_dir += "/"
    if not out_dir.endswith("/"): out_dir += "/"
    src_file = d_dir + file_prefix + "." + src
    tgt_file = d_dir + file_prefix + "." + tgt
    src_cleaned = out_dir + file_prefix + ".cln." + src
    tgt_cleaned = out_dir + file_prefix + ".cln." + tgt

    cleanCorpus(src_file, tgt_file, src_cleaned, tgt_cleaned)
dataset/ETHPy150Open sfu-natlang/Kriya/src/Kriya-Grammar-Xtrctr/pre-process/clean_corpus.py/main