From 11f24b09fc7d47f9a9cf6eb750ed7e9d28a62314 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Wed, 10 Jan 2018 13:35:29 +0000 Subject: [PATCH] Deploy to GitHub Pages: 861b84f5578f76ea75b6785d5ef73bd13e6503ba --- develop/doc/operators.json | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/develop/doc/operators.json b/develop/doc/operators.json index aa3b06cef0c..fa6428174d1 100644 --- a/develop/doc/operators.json +++ b/develop/doc/operators.json @@ -3305,6 +3305,35 @@ "intermediate" : 0 } ], "attrs" : [ ] +},{ + "type" : "edit_distance", + "comment" : "\n\nEditDistance operator computes the edit distances between a batch of hypothesis\nstrings and their references.\n\nEdit distance, also called Levenshtein distance, measures how dissimilar two strings \nare by counting the minimum number of operations to transform one string into anthor. \nHere the operations include insertion, deletion, and substitution. For example, \ngiven hypothesis string A = \"kitten\" and reference B = \"sitting\", the edit distance \nis 3 for A will be transformed into B at least after two substitutions and one \ninsertion:\n \n \"kitten\" -> \"sitten\" -> \"sittin\" -> \"sitting\"\n\nInput(Hyps) is a LoDTensor consisting of all the hypothesis strings with the total \nnumber denoted by `batch_size`, and the separation is specified by the LoD information. \nAnd the `batch_size` reference strings are arranged in order in the same way in the \nLoDTensor Input(Refs).\n\nOutput(Out) contains the `batch_size` results and each stands for the edit stance \nfor a pair of strings respectively. If Attr(normalized) is true, the edit distance \nwill be divided by the length of reference string.\n", + "inputs" : [ + { + "name" : "Hyps", + "comment" : "(2-D LoDTensor, 2nd dim. equal to 1) The indices for hypothesis strings.", + "duplicable" : 0, + "intermediate" : 0 + }, { + "name" : "Refs", + "comment" : "(2-D LoDTensor, 2nd dim. equal to 1) The indices for reference strings.", + "duplicable" : 0, + "intermediate" : 0 + } ], + "outputs" : [ + { + "name" : "Out", + "comment" : "(2-D Tensor with shape [`batch_size` x 1]) The output edit distances of EditDistance operator.", + "duplicable" : 0, + "intermediate" : 0 + } ], + "attrs" : [ + { + "name" : "normalized", + "type" : "bool", + "comment" : "(bool, default false) Indicated whether to normalize the edit distance by the length of reference string.", + "generated" : 0 + } ] },{ "type" : "l1_norm", "comment" : "\nL1 Norm Operator.\n\nComputes the L1 norm of a tensor.\n\n$$Out = \\sum{|X|}$$\n\n", -- GitLab