realign
Sentence align a given file anew.
convert_and_copy(corpus_path1, corpus_path2)
Reconvert and copy files to prestable/converted.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
corpus_path1
|
make_corpus_path
|
A CorpusPath representing the lang1 file that should be reconverted. |
required |
corpus_path2
|
make_corpus_path
|
A CorpusPath representing the lang2 file that should be reconverted. |
required |
Source code in corpustools/realign.py
64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 | |
main()
Sentence align a given file anew.
Source code in corpustools/realign.py
118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 | |
parse_options()
Parse the commandline options.
Returns:
| Type | Description |
|---|---|
Namespace
|
the parsed commandline arguments |
Source code in corpustools/realign.py
84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 | |
print_filename(corpus_path)
Print interesting filenames for doing sentence alignment.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
corpus_path
|
make_corpus_path
|
filenames |
required |
Source code in corpustools/realign.py
38 39 40 41 42 43 44 45 46 47 48 | |
print_filenames(corpus_path1, corpus_path2)
Print interesting filenames for doing sentence alignment.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
corpus_path1
|
make_corpus_path
|
filenames for the lang1 file. |
required |
corpus_path2
|
make_corpus_path
|
filenames for the lang2 file. |
required |
Source code in corpustools/realign.py
51 52 53 54 55 56 57 58 59 60 61 | |