From 3ac3574481a75ddb69c3fd41d7b9a984cd5b7c53 Mon Sep 17 00:00:00 2001 From: WangLi <1286769394@qq.com> Date: Thu, 19 Nov 2015 09:43:06 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E7=BF=BB=E8=AF=91=E6=96=87?= =?UTF-8?q?=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- SOURCE/resources/glossary-zh.md | 41 ------- SOURCE/resources/glossary.md | 199 +++++++++----------------------- 2 files changed, 57 insertions(+), 183 deletions(-) delete mode 100644 SOURCE/resources/glossary-zh.md mode change 100755 => 100644 SOURCE/resources/glossary.md diff --git a/SOURCE/resources/glossary-zh.md b/SOURCE/resources/glossary-zh.md deleted file mode 100644 index e4a2c87..0000000 --- a/SOURCE/resources/glossary-zh.md +++ /dev/null @@ -1,41 +0,0 @@ - -#术语表 - -###广播系统(Broadcasting operation) -一种用颠簸式广播来兼容它的tensor参数形状的系统。 - -###Devices -一快可以用来运算并且有自己的地址空间的硬件,比如GPU和CPU。 -###eval -返回Tesor值的一个方法,触发任意一个图表计算都需要得出这个值。只能在一个已经开启了会话图表中的Tensor上里调用。 -###Feed -TensorFlow中的一个原理:把一个tensor直接连接到任意一个会话中图表的节点。feed不是在构建图表(graph)的时候创建,而是在触发图表的执行操作时去申请。feed临时替代带有tensor值的节点。把feed数据作为run()方法和eval()方法的参数叫做初始化运算。方法运行结束后,feed就会消失,而最初的节点定义会留下。可以通过tf.placeholder()把特定的节点指定为feed节点。点击这里查看更多信息[Basic Usage](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/get_started/basic_usage.md). -###Fetch -TensorFlow中的一个原理:从一个会话图表中取回tensor。取回fetches的申请发生在触发图表执行的操作,而不是发生在建立图表的时候。如果要取回node或多个node的tensor值,可以通过在Session对象上调用run方法并将传递待取回节点(node)的列表作为参数来执行图表(graph)。详见[Basic Usage](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/get_started/basic_usage.md)。 -###Graph -把运算描述成一个直接的无环图形(DAG),图表中的节点(node)代表必须实现的一个操作。图表中的边代表数据或者可控的依赖。GratheDef是一个把系统描述成一个图表的协议(api),一个GraphDef可以转化成一个更容易操作的图表对象。 -###IndexedSlices(索引化的切片) -在Python API中,TensorFlow仅仅在第一维上对tensor有所体现。如果tensor在一个k维空间里,一个IndexedSlices实例在逻辑上代表一个沿着这个tensor第一维的(k-1)维集合。切片的索引被连续储存在一个单独的一维向量中,而相关的切片被连接成一个单独的k维tensor。如果sparsity(稀疏、贫乏)不是受限于一维空间,就用SparseTensor。 - -###Node -图表中的一个元素。 -把怎样调用一个特定操作描述成一个特定的运算图表,包括任何需要用来配置这个操作的参数的值。对于那些多形性的操作,这些参数包括能完全决定这个节点(Node)的签名。详情见graph.proto。 -###操作(Op/operation) -在TensorFlow的运行时中:一种类似add或matmul或concat。可以用[how to add an op](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/how_tos/adding_an_op/index.md)这种方法来向运行时添加操作。 -在Python的Api中:图表中的一个节点。Ops在这个类[tf.Operation](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/api_docs/python/framework.md#Operation)中列举出来了。一个操作(Operation)的type属性代表这个节点(node)的操作,比如add和matmul。 -###Run -在运行的图表中执行ops的行为。要求这个图表运行在一个会话中。 -在Python的API中:是Session类的一个方法[tf.Session.run](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/api_docs/python/client.md#Session)。可以通过tensors去feed或fetch来调用run()操作。 -在C++API中:是一个用来开启一个图表并运行操作的类[tensorflow::Session](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/api_docs/cc/ClassSession.md) -###Shape -Tensor的维度和他们的长度。 -在运行的图表中,它表示存在于节点(node)之间Tensor的属性。一些操作强烈要求shape不能在运行时出现输入和输出错误的shape。 -在Python的API中,是图表结构API中Tensor的参数。在Tensor的Shape的构建中,只有部分可见,甚至全都不可见。详情见这里[tf.TensroShape](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/api_docs/python/framework.md#TensorShape) -在C++中,Shape类用来表现Tensor的Shape[tensorflow::TensorShape](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/api_docs/cc/ClassTensorShape.md)。 -###SparseTensor -在Python API中,TensorFlow对tensor的体现散落在任意位置。SparseTensor仅仅以字典值格式来储存切片(slices)中的非空值。换言之,m个非空值,就包含一个长度为m的值向量和一个由m列索引(indices)组成的矩阵。为了更高的效率,SparseTensor需要将indice(索引)按增量排序存储,比如行主序。如果排列不仅仅沿着第一维度,就用IndexedSlices。 -###Tensor -Tensor是一种特定的多维数组。比如,一个用浮点型数据组成的四维数组代表一小批由【batch,高,宽,channel】组成的数组。 -在一个运行的图表中,是一种连接在节点(node)之间的数据。 -在Python中,Tensor用来表示添加到图表的操作(op)中的输入和输出,这样的类不持有数据,见[tf.Tensor](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/api_docs/python/framework.md#Tensor)。 -在C++中,Tensor用来表示通过[Session::Run()](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/api_docs/cc/ClassSession.md)方法调用[tensorflow::Tensor](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/api_docs/cc/ClassTensor.md)的值,这样的Tensor持有数据。 \ No newline at end of file diff --git a/SOURCE/resources/glossary.md b/SOURCE/resources/glossary.md old mode 100755 new mode 100644 index 40683a1..4066297 --- a/SOURCE/resources/glossary.md +++ b/SOURCE/resources/glossary.md @@ -1,142 +1,57 @@ -# Glossary - -**Broadcasting operation** - -An operation that uses [numpy-style broadcasting](http://docs.scipy.org/doc/numpy/user/basics.broadcasting.html) -to make the shapes of its tensor arguments compatible. - -**Device** - -A piece of hardware that can run computation and has its own address space, -like a GPU or CPU. - -**eval** - -A method of `Tensor` that returns the value of the `Tensor`, triggering any -graph computation required to determine the value. You may only call `eval()` -on a `Tensor` in a graph that has been launched in a session. - -**Feed** - -TensorFlow's mechanism for patching a tensor directly into any node in a graph -launched in a session. You apply feeds when you trigger the execution of a -graph, not when you build the graph. A feed temporarily replaces a node with a -tensor value. You supply feed data as an argument to a `run()` or `eval()` call -that initiates computation. After the run the feed disappears and the original -node definition remains. You usually designate specific nodes to be "feed" -nodes by using `tf.placeholder()` to create them. See -[Basic Usage](../get_started/basic_usage.md) for more information. - -**Fetch** - -TensorFlow's mechanism for retrieving tensors from a graph launched in a -session. You retrieve fetches when you trigger the execution of a graph, not -when you build the graph. To fetch the tensor value of a node or nodes, -execute the graph with a `run()` call on the `Session` object and pass a list of -names of nodes to retrieve. See [Basic Usage](../get_started/basic_usage.md) -for more information. - -**Graph** - -Describes a computation as a directed acyclic -graph. Nodes in the graph represent operations that must be -performed. Edges in the graph represent either data or control -dependencies. `GraphDef` is the proto used to describe a graph to the -system (it is the API), and consists of a collection of `NodeDefs` (see -below). A `GraphDef` may be converted to a (C++) `Graph` object which is -easier to operate on. - -**IndexedSlices** - -In the Python API, TensorFlow's representation of a tensor that is sparse -along only its first dimension. If the tensor is `k`-dimensional, an -`IndexedSlices` instance logically represents a collection of -`(k-1)`-dimensional slices along the tensor's first dimension. The indices of -the slices are stored concatenated into a single 1-dimensional vector, and the -corresponding slices are concatenated to form a single `k`-dimensional tensor. Use -`SparseTensor` if the sparsity is not restricted to the first dimension. - -**Node** - -An element of a graph. - -Describes how to invoke a specific operation as one node in a specific -computation `Graph`, including the values for any `attrs` needed to configure -the operation. For operations that are polymorphic, the `attrs` include -sufficient information to completely determine the signature of the `Node`. -See `graph.proto` for details. - -**Op (operation)** - -In the TensorFlow runtime: A type of computation such as `add` or `matmul` or -`concat`. You can add new ops to the runtime as described [how to add an -op](../how_tos/adding_an_op/index.md). - -In the Python API: A node in the graph. Ops are represented by instances of -the class [`tf.Operation`](../api_docs/python/framework.md#Operation). The -`type` property of an `Operation` indicates the run operation for the node, -such as `add` or `matmul`. - -**Run** - -The action of executing ops in a launched graph. Requires that the graph be -launched in a `Session`. - -In the Python API: A method of the `Session` class: -[`tf.Session.run`](../api_docs/python/client.md#Session). You can pass tensors -to feed and fetch to the `run()` call. - -In the C++ API: A method of the [`tensorflow::Session`](../api_docs/cc/ClassSession.md). - -**Session** - -A runtime object representing a launched graph. Provides methods to execute -ops in the graph. - -In the Python API: [`tf.Session`](../api_docs/python/client.md#Session) - -In the C++ API: class used to launch a graph and run operations -[`tensorflow::Session`](../api_docs/cc/ClassSession.md). - -**Shape** - -The number of dimensions of a tensor and their sizes. - -In a launched graph: Property of the tensors that flow between nodes. Some ops -have strong requirements on the shape of their inputs and report errors at -runtime if these are not met. - -In the Python API: Attribute of a Python `Tensor` in the graph construction -API. During constructions the shape of tensors can be only partially known, or -even unknown. See -[`tf.TensorShape`](../api_docs/python/framework.md#TensorShape) - -In the C++ API: class used to represent the shape of tensors -[`tensorflow::TensorShape`](../api_docs/cc/ClassTensorShape.md). - -**SparseTensor** - -In the Python API, TensorFlow's representation of a tensor that is sparse in -arbitrary positions. A `SparseTensor` stores only the non-empty values along -with their indices, using a dictionary-of-keys format. In other words, if -there are `m` non-empty values, it maintains a length-`m` vector of values and -a matrix with m rows of indices. For efficiency, `SparseTensor` requires the -indices to be sorted along increasing dimension number, i.e. in row-major -order. Use `IndexedSlices` if the sparsity is only along the first dimension. - -**Tensor** - -A `Tensor` is a typed multi-dimensional array. For example, a 4-D -array of floating point numbers representing a mini-batch of images with -dimensions `[batch, height, width, channel]`. - -In a launched graph: Type of the data that flow between nodes. - -In the Python API: class used to represent the output and inputs of ops added -to the graph [`tf.Tensor`](../api_docs/python/framework.md#Tensor). Instances of -this class do not hold data. - -In the C++ API: class used to represent tensors returned from a -[`Session::Run()`](../api_docs/cc/ClassSession.md) call -[`tensorflow::Tensor`](../api_docs/cc/ClassTensor.md). -Instances of this class hold data. + +#术语表 + +###广播操作(Broadcasting operation) +一种用[numpy-style broadcasting](http://docs.scipy.org/doc/numpy/user/basics.broadcasting.html)来保证tensor参数的形态兼容的操作。 + +###Devices +一块可以用来运算并且拥有自己的地址空间的硬件,比如GPU和CPU。 +###eval +Tensor的一个方法,返回Tensor的值。触发任意一个图表计算都需要计算出这个值。只能在一个会话图表中的Tensor上调用。 +###Feed +TensorFlow的一个概念:把一个tensor直接连接到一个会话图表中的任意节点。feed不是在构建图表(graph)的时候创建,而是在触发图表的执行操作时去申请。一个feed临时替代一个带有tensor值的节点。把feed数据作为run()方法和eval()方法的参数来初始化运算。方法运行结束后,feed就会消失,而最初的节点定义仍然还在。可以通过tf.placeholder()把特定的节点指定为feed节点来创建它们。详见[Basic Usage](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/get_started/basic_usage.md). +###Fetch +TensorFlow中的一个概念:从一个会话图表中取回tensor。取回fetches的申请发生在触发执行图表操作的时候,而不是发生在建立图表的时候。如果要取回一个或多个节点(node)的tensor值,可以通过在Session对象上调用run()方法并将待取回节点(node)的列表作为参数来执行图表(graph)。详见[Basic Usage](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/get_started/basic_usage.md)。 +###Graph(图表) +把运算描述成一个直接的无环图形(DAG),图表中的节点(node)代表必须要实现的一些操作。图表中的边代表数据或者可控的依赖。GratheDef是系统中描述一个图表的协议(api),它由一个NodeDefs集合组成。一个GraphDef可以转化成一个更容易操作的图表对象。 +###IndexedSlices(索引化切片) +在Python API中,TensorFlow仅仅在第一维上对tensor有所体现。如果一个tensor有k维,那么一个IndexedSlices实例在逻辑上代表一个沿着这个tensor第一维的(k-1)维切片的集合。切片的索引被连续储存在一个单独的一维向量中,而对应的切片则被拼接成一个单独的k维tensor。如果sparsity不是受限于第一维空间,请用SparseTensor。 + +###Node(节点) +图表中的一个元素。 +把启动一个特定操作的方式称为特定运算图表中的一个节点,包括任何用来配置这个操作的属性的值。对于那些多形态的操作,这些属性包括能完全决定这个节点(Node)签名的充分信息。详见graph.proto。 +###操作(Op/operation) +在TensorFlow的运行时中,它是一种类似add或matmul或concat的运算。可以用[how to add an op](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/how_tos/adding_an_op/index.md)中的方法来向运行时添加新的操作。 + +在Python的API中,它是图表中的一个节点。在[tf.Operation](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/api_docs/python/framework.md#Operation)类中列举出了这些操作。一个操作(Operation)的type属性决定这个节点(node)的操作类型,比如add和matmul。 +###Run +在一个运行的图表中执行某种操作的行为。要求这个图表必须运行在一次会话中。 + +在Python的API中,它是Session类的一个方法[tf.Session.run](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/api_docs/python/client.md#Session)。可以通过tensors来订阅或获取run()操作。 + +在C++的API中,[tensorflow::Session](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/api_docs/python/client.md#Session)的一个方法。 +###Session(会话) +一个已经启动的图表(graph)的运行时对象。提供在图表中执行操作的一些方法。 + +在Python API中,[tf.Session](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/api_docs/python/client.md#Session)。 + +在C++API中,它是一个用来开启一个图表并运行操作的类:[tensorflow::Session](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/api_docs/cc/ClassSession.md) +###Shape +Tensor的维度和他们的大小。 + +在一个已经启动的图表中,它表示建立在节点(node)之间的Tensor的属性。一些操作强烈要求shape不能在运行时出现未知的输入和输出错误。 + +在Python API中,是图表构造API中Tensor的属性。在Tensor的Shape的构建中,要么只有部分已知,要么全部未知。见[tf.TensroShape](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/api_docs/python/framework.md#TensorShape) + +在C++中,Shape类用来表现Tensor的外形[tensorflow::TensorShape](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/api_docs/cc/ClassTensorShape.md)。 +###SparseTensor +在Python API中,TensorFlow对tensor的表现很散落在任意地方。SparseTensor以字典值格式来储存那些沿着索引的非空值。换言之,m个非空值,就包含一个长度为m的值向量和一个由m列索引(indices)组成的矩阵。为了提升效率,SparseTensor需要将indice(索引)按维度的增加来按序存储,比如行主序。如果稀疏值仅沿着第一维度,就用IndexedSlices。 +###Tensor +Tensor是一种特定的多维数组。比如,一个浮点型的四维数组表示一小批由[batch,height,width,channel]组成的图片。 + +在一个运行的图表(graph)中,它是一种连接在节点(node)之间的数据。 +在Python中,Tensor类表示添加到图表的操作中的输入和输出,见[tf.Tensor](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/api_docs/python/framework.md#Tensor),这样的类不持有数据。 + +在C++中,Tensor是方法[Session::Run()](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/api_docs/cc/ClassSession.md)的返回值,见[tensorflow::Tensor](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/api_docs/cc/ClassTensor.md),这样的Tensor持有数据。 + +原文:[Glossary](https://github.com/jikexueyuanwiki/tensorflow-zh/blob/master/SOURCE/resources/glossary.md) 翻译:[leege100](https://github.com/leege100) \ No newline at end of file