未验证 提交 dbf20500 编写于 作者: K kexinzhao 提交者: GitHub

fix read and write tensor array op (#6312)

上级 a5167ce0
......@@ -60,12 +60,16 @@ class WriteToArrayOpProtoMaker : public framework::OpProtoAndCheckerMaker {
"(Tensor) the subscript index in tensor array. The number of element "
"should be 1");
AddOutput("Out", "(TensorArray) the tensor array will be written");
AddComment(R"DOC(Write a LoDTensor to a LoDTensor array.
AddComment(R"DOC(
WriteToArray Operator.
Assume T is LoDTensor, i is the subscript of the array, and A is the array. The
This operator writes a LoDTensor to a LoDTensor array.
Assume $T$ is LoDTensor, $i$ is the subscript of the array, and $A$ is the array. The
equation is
A[i] = T
$$A[i] = T$$
)DOC");
}
};
......@@ -144,12 +148,16 @@ class ReadFromArrayProtoMaker : public framework::OpProtoAndCheckerMaker {
"(Tensor) the subscript index in tensor array. The number of "
"element should be 1");
AddOutput("Out", "(LoDTensor) the tensor will be read from.");
AddComment(R"DOC(Read a LoDTensor from a LoDTensor Array
AddComment(R"DOC(
ReadFromArray Operator.
Assume T is LoDTensor, i is th e subscript of the array, and A is the array. The
Read a LoDTensor from a LoDTensor Array.
Assume $T$ is LoDTensor, $i$ is the subscript of the array, and $A$ is the array. The
equation is
T = A[i]
$$T = A[i]$$
)DOC");
}
};
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册