Skip to content

Commit d9d9be1

Browse files
committed
Fix white space in comments.
1 parent 8143a42 commit d9d9be1

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

python/paddle/v2/fluid/evaluator.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -212,7 +212,7 @@ class EditDistance(Evaluator):
212212
compute the average edit_distance of all batches.
213213
214214
Args:
215-
input: the sequences predicted by network
215+
input: the sequences predicted by network.
216216
label: the target sequences which must has same sequence count
217217
with input.
218218
ignored_tokens(list of int): Tokens that should be removed before

python/paddle/v2/fluid/layers/nn.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1870,7 +1870,7 @@ def edit_distance(input,
18701870
ignored_tokens=None,
18711871
name=None):
18721872
"""
1873-
EditDistance operator computes the edit distances between a batch of hypothesis strings and their references.Edit distance, also called Levenshtein distance, measures how dissimilar two strings are by counting the minimum number of operations to transform one string into anthor. Here the operations include insertion, deletion, and substitution. For example, given hypothesis string A = "kitten" and reference B = "sitting", the edit distance is 3 for A will be transformed into B at least after two substitutions and one insertion:
1873+
EditDistance operator computes the edit distances between a batch of hypothesis strings and their references. Edit distance, also called Levenshtein distance, measures how dissimilar two strings are by counting the minimum number of operations to transform one string into anthor. Here the operations include insertion, deletion, and substitution. For example, given hypothesis string A = "kitten" and reference B = "sitting", the edit distance is 3 for A will be transformed into B at least after two substitutions and one insertion:
18741874
18751875
"kitten" -> "sitten" -> "sittin" -> "sitting"
18761876
@@ -2028,7 +2028,7 @@ def warpctc(input, label, blank=0, norm_by_times=False, **kwargs):
20282028
Temporal Classification (CTC) loss, which is in the
20292029
half-opened interval [0, num_classes + 1).
20302030
norm_by_times: (bool, default: false), whether to normalize
2031-
the gradients by the number of time-step,which is also the
2031+
the gradients by the number of time-step, which is also the
20322032
sequence's length. There is no need to normalize the gradients
20332033
if warpctc layer was follewed by a mean_op.
20342034

0 commit comments

Comments
 (0)