提交 3991a9b9 编写于 作者: T Travis CI

Deploy to GitHub Pages: b8e782c9

上级 b54435a8
...@@ -239,10 +239,9 @@ ...@@ -239,10 +239,9 @@
<li><strong>size</strong> (<em>int</em>) &#8211; The layer dimension.</li> <li><strong>size</strong> (<em>int</em>) &#8211; The layer dimension.</li>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation Type. paddle.v2.activation.Tanh is the default.</li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation Type. paddle.v2.activation.Tanh is the default.</li>
<li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The Parameter Attribute|list.</li> <li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The Parameter Attribute|list.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra Layer config.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra Layer config.</li>
</ul> </ul>
</td> </td>
...@@ -284,10 +283,9 @@ If is None, acts exactly like fc.</li> ...@@ -284,10 +283,9 @@ If is None, acts exactly like fc.</li>
<li><strong>size</strong> (<em>int</em>) &#8211; The layer dimension.</li> <li><strong>size</strong> (<em>int</em>) &#8211; The layer dimension.</li>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Tanh is the default.</li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Tanh is the default.</li>
<li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The Parameter Attribute.</li> <li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The Parameter Attribute.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra Layer config.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra Layer config.</li>
</ul> </ul>
</td> </td>
...@@ -510,10 +508,9 @@ image dimension</li> ...@@ -510,10 +508,9 @@ image dimension</li>
<li><strong>dilation</strong> (<em>int | tuple | list</em>) &#8211; The x dimension of the dilation. Or input a tuple for two <li><strong>dilation</strong> (<em>int | tuple | list</em>) &#8211; The x dimension of the dilation. Or input a tuple for two
image dimension</li> image dimension</li>
<li><strong>dilation_y</strong> (<em>int</em>) &#8211; The y dimension of the dilation.</li> <li><strong>dilation_y</strong> (<em>int</em>) &#8211; The y dimension of the dilation.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>num_channels</strong> (<em>int</em>) &#8211; number of input channels. If None will be set <li><strong>num_channels</strong> (<em>int</em>) &#8211; number of input channels. If None will be set
automatically from previous output.</li> automatically from previous output.</li>
<li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; Convolution param attribute. None means default attribute</li> <li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; Convolution param attribute. None means default attribute</li>
...@@ -617,9 +614,10 @@ number plus one equals context_len.</p> ...@@ -617,9 +614,10 @@ number plus one equals context_len.</p>
<li><strong>context_len</strong> (<em>int</em>) &#8211; The context length equals the lookahead step number <li><strong>context_len</strong> (<em>int</em>) &#8211; The context length equals the lookahead step number
plus one.</li> plus one.</li>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation Type. paddle.v2.activation.Linear is the default.</li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation Type. paddle.v2.activation.Linear is the default.</li>
<li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The Parameter Attribute. If None, the parameter will be <li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The parameter attribute. See paddle.v2.attr.ParameterAttribute for
initialized smartly. It&#8217;s better to set it by yourself.</li> details.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra Layer config.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; The extra layer attribute. See paddle.v2.attr.ExtraAttribute for
details.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
...@@ -1056,10 +1054,9 @@ out_{i} = act(in_{i} + out_{i+1} * W) \ \ \text{for} \ start &lt;= i &lt; end\en ...@@ -1056,10 +1054,9 @@ out_{i} = act(in_{i} + out_{i+1} * W) \ \ \text{for} \ start &lt;= i &lt; end\en
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple"> <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
<li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input of this layer.</li> <li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input of this layer.</li>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Tanh is the default.</li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Tanh is the default.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; parameter attribute.</li> <li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; parameter attribute.</li>
<li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Layer Attribute.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Layer Attribute.</li>
...@@ -1109,10 +1106,9 @@ more details about LSTM.</p> ...@@ -1109,10 +1106,9 @@ more details about LSTM.</p>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Tanh is the default. <span class="math">\(h_t\)</span></li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Tanh is the default. <span class="math">\(h_t\)</span></li>
<li><strong>gate_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; gate activation type, paddle.v2.activation.Sigmoid by default.</li> <li><strong>gate_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; gate activation type, paddle.v2.activation.Sigmoid by default.</li>
<li><strong>state_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; state activation type, paddle.v2.activation.Tanh by default.</li> <li><strong>state_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; state activation type, paddle.v2.activation.Tanh by default.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | False</em>) &#8211; Parameter Attribute.</li> <li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | False</em>) &#8211; Parameter Attribute.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra Layer attribute</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra Layer attribute</li>
</ul> </ul>
...@@ -1179,10 +1175,9 @@ affects the <span class="math">\({\tilde{h_t}}\)</span>.</li> ...@@ -1179,10 +1175,9 @@ affects the <span class="math">\({\tilde{h_t}}\)</span>.</li>
<li><strong>gate_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; gate activation type, paddle.v2.activation.Sigmoid by default. <li><strong>gate_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; gate activation type, paddle.v2.activation.Sigmoid by default.
This activation affects the <span class="math">\(z_t\)</span> and <span class="math">\(r_t\)</span>. It is the This activation affects the <span class="math">\(z_t\)</span> and <span class="math">\(r_t\)</span>. It is the
<span class="math">\(\sigma\)</span> in the above formula.</li> <span class="math">\(\sigma\)</span> in the above formula.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | False</em>) &#8211; Parameter Attribute.</li> <li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | False</em>) &#8211; Parameter Attribute.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra Layer attribute</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra Layer attribute</li>
</ul> </ul>
...@@ -1363,10 +1358,9 @@ output is <span class="math">\(o_t\)</span>, whose name is &#8216;state&#8217; a ...@@ -1363,10 +1358,9 @@ output is <span class="math">\(o_t\)</span>, whose name is &#8216;state&#8217; a
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Tanh is the default.</li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Tanh is the default.</li>
<li><strong>gate_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Gate Activation Type. paddle.v2.activation.Sigmoid is the default.</li> <li><strong>gate_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Gate Activation Type. paddle.v2.activation.Sigmoid is the default.</li>
<li><strong>state_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; State Activation Type. paddle.v2.activation.Tanh is the default.</li> <li><strong>state_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; State Activation Type. paddle.v2.activation.Tanh is the default.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; layer&#8217;s extra attribute.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; layer&#8217;s extra attribute.</li>
</ul> </ul>
</td> </td>
...@@ -1398,10 +1392,9 @@ True, the bias is initialized to zero.</li> ...@@ -1398,10 +1392,9 @@ True, the bias is initialized to zero.</li>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; </li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; </li>
<li><strong>name</strong> &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> &#8211; The name of this layer. It is optional.</li>
<li><strong>gate_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type of this layer&#8217;s two gates. Default is Sigmoid.</li> <li><strong>gate_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type of this layer&#8217;s two gates. Default is Sigmoid.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>param_attr</strong> &#8211; the parameter_attribute for transforming the output_mem <li><strong>param_attr</strong> &#8211; the parameter_attribute for transforming the output_mem
from previous step.</li> from previous step.</li>
<li><strong>layer_attr</strong> &#8211; </li> <li><strong>layer_attr</strong> &#8211; </li>
...@@ -1571,10 +1564,9 @@ Each inputs is a projection or operator.</p> ...@@ -1571,10 +1564,9 @@ Each inputs is a projection or operator.</p>
<li><strong>input</strong> &#8211; The input of this layer. It is an optional parameter. If set, <li><strong>input</strong> &#8211; The input of this layer. It is an optional parameter. If set,
then this function will just return layer&#8217;s name.</li> then this function will just return layer&#8217;s name.</li>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation Type. paddle.v2.activation.Linear is the default.</li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation Type. paddle.v2.activation.Linear is the default.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; The extra layer config. Default is None.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; The extra layer config. Default is None.</li>
</ul> </ul>
</td> </td>
...@@ -2002,10 +1994,9 @@ AggregateLevel.TO_SEQUENCE</li> ...@@ -2002,10 +1994,9 @@ AggregateLevel.TO_SEQUENCE</li>
<li><strong>pooling_type</strong> (<em>BasePoolingType | None</em>) &#8211; Type of pooling, MaxPooling(default), AvgPooling, <li><strong>pooling_type</strong> (<em>BasePoolingType | None</em>) &#8211; Type of pooling, MaxPooling(default), AvgPooling,
SumPooling, SquareRootNPooling.</li> SumPooling, SquareRootNPooling.</li>
<li><strong>stride</strong> (<em>Int</em>) &#8211; The step size between successive pooling regions.</li> <li><strong>stride</strong> (<em>Int</em>) &#8211; The step size between successive pooling regions.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; The Extra Attributes for layer, such as dropout.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; The Extra Attributes for layer, such as dropout.</li>
</ul> </ul>
</td> </td>
...@@ -2162,10 +2153,9 @@ processed in one batch.</p> ...@@ -2162,10 +2153,9 @@ processed in one batch.</p>
<li><strong>b</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; input sequence layer</li> <li><strong>b</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; input sequence layer</li>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Identity is the default.</li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Identity is the default.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer Attribute.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer Attribute.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
...@@ -2367,10 +2357,9 @@ sequence is one) to sequence data.&#8221;</p> ...@@ -2367,10 +2357,9 @@ sequence is one) to sequence data.&#8221;</p>
<li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input of this layer.</li> <li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input of this layer.</li>
<li><strong>expand_as</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; Expand as this layer&#8217;s sequence info.</li> <li><strong>expand_as</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; Expand as this layer&#8217;s sequence info.</li>
<li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>expand_level</strong> (<em>ExpandLevel</em>) &#8211; whether input layer is timestep(default) or sequence.</li> <li><strong>expand_level</strong> (<em>ExpandLevel</em>) &#8211; whether input layer is timestep(default) or sequence.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; extra layer attributes.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; extra layer attributes.</li>
</ul> </ul>
...@@ -2498,10 +2487,9 @@ output sequence has T*M/N instances, the dimension of each instance is N.</p> ...@@ -2498,10 +2487,9 @@ output sequence has T*M/N instances, the dimension of each instance is N.</p>
<li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Identity is the default.</li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Identity is the default.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; extra layer attributes.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; extra layer attributes.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
...@@ -2554,10 +2542,9 @@ Please refer to dropout for details.</p> ...@@ -2554,10 +2542,9 @@ Please refer to dropout for details.</p>
<li><strong>input</strong> (<em>paddle.v2.config_base.Layer | list | tuple</em>) &#8211; Input layers. It could be a paddle.v2.config_base.Layer or list/tuple of <li><strong>input</strong> (<em>paddle.v2.config_base.Layer | list | tuple</em>) &#8211; Input layers. It could be a paddle.v2.config_base.Layer or list/tuple of
paddle.v2.config_base.Layer.</li> paddle.v2.config_base.Layer.</li>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation Type. paddle.v2.activation.Linear is the default.</li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation Type. paddle.v2.activation.Linear is the default.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer attribute.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer attribute.</li>
</ul> </ul>
</td> </td>
...@@ -2817,11 +2804,11 @@ ight)</p> ...@@ -2817,11 +2804,11 @@ ight)</p>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">param min:</th><td class="field-body">The lower threshold for clipping.</td> <tr class="field-odd field"><th class="field-name">param min:</th><td class="field-body">The lower threshold for clipping.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">type min:</th><td class="field-body">double</td> <tr class="field-even field"><th class="field-name">type min:</th><td class="field-body">float</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">param max:</th><td class="field-body">The upper threshold for clipping.</td> <tr class="field-odd field"><th class="field-name">param max:</th><td class="field-body">The upper threshold for clipping.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">type max:</th><td class="field-body">double</td> <tr class="field-even field"><th class="field-name">type max:</th><td class="field-body">float</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">return:</th><td class="field-body">paddle.v2.config_base.Layer object.</td> <tr class="field-odd field"><th class="field-name">return:</th><td class="field-body">paddle.v2.config_base.Layer object.</td>
</tr> </tr>
...@@ -2935,10 +2922,9 @@ For example, each sample:</p> ...@@ -2935,10 +2922,9 @@ For example, each sample:</p>
<li><strong>size</strong> (<em>int.</em>) &#8211; the layer dimension.</li> <li><strong>size</strong> (<em>int.</em>) &#8211; the layer dimension.</li>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Linear is the default.</li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Linear is the default.</li>
<li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The Parameter Attribute.</li> <li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The Parameter Attribute.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra Layer config.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra Layer config.</li>
</ul> </ul>
</td> </td>
...@@ -3054,11 +3040,11 @@ bias are trainable.</p> ...@@ -3054,11 +3040,11 @@ bias are trainable.</p>
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple"> <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
<li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input of this layer.</li> <li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input of this layer.</li>
<li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The parameter attribute of scaling.</li> <li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The parameter attribute of scaling. See paddle.v2.attr.ParameterAttribute for
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to details.</li>
False or something not type of paddle.v2.attr.ParameterAttribute, <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
no bias is defined. If the parameter is set to whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
True, the bias is initialized to zero.</li> parameter is set to True, the bias is initialized to zero.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
...@@ -3147,12 +3133,12 @@ Sampling one id for one sample.</p> ...@@ -3147,12 +3133,12 @@ Sampling one id for one sample.</p>
<dl class="class"> <dl class="class">
<dt> <dt>
<em class="property">class </em><code class="descclassname">paddle.v2.layer.</code><code class="descname">multiplex</code></dt> <em class="property">class </em><code class="descclassname">paddle.v2.layer.</code><code class="descname">multiplex</code></dt>
<dd><p>This layer multiplex multiple layers according to the index, <dd><p>This layer multiplex multiple layers according to the indexes,
which is provided by the first input layer. which are provided by the first input layer.
inputs[0]: the index of the layer to output of size batchSize. inputs[0]: the indexes of the layers to form the output of size batchSize.
inputs[1:N]; the candidate output data. inputs[1:N]; the candidate output data.
For each index i from 0 to batchSize -1, the output is the i-th row of the For each index i from 0 to batchSize - 1, the i-th row of the output is the
(index[i] + 1)-th layer.</p> the same to the i-th row of the (index[i] + 1)-th layer.</p>
<p>For each i-th row of output: <p>For each i-th row of output:
.. math:</p> .. math:</p>
<div class="highlight-default"><div class="highlight"><pre><span></span><span class="n">y</span><span class="p">[</span><span class="n">i</span><span class="p">][</span><span class="n">j</span><span class="p">]</span> <span class="o">=</span> <span class="n">x_</span><span class="p">{</span><span class="n">x_</span><span class="p">{</span><span class="mi">0</span><span class="p">}[</span><span class="n">i</span><span class="p">]</span> <span class="o">+</span> <span class="mi">1</span><span class="p">}[</span><span class="n">i</span><span class="p">][</span><span class="n">j</span><span class="p">],</span> <span class="n">j</span> <span class="o">=</span> <span class="mi">0</span><span class="p">,</span><span class="mi">1</span><span class="p">,</span> <span class="o">...</span> <span class="p">,</span> <span class="p">(</span><span class="n">x_</span><span class="p">{</span><span class="mi">1</span><span class="p">}</span><span class="o">.</span><span class="n">width</span> <span class="o">-</span> <span class="mi">1</span><span class="p">)</span> <div class="highlight-default"><div class="highlight"><pre><span></span><span class="n">y</span><span class="p">[</span><span class="n">i</span><span class="p">][</span><span class="n">j</span><span class="p">]</span> <span class="o">=</span> <span class="n">x_</span><span class="p">{</span><span class="n">x_</span><span class="p">{</span><span class="mi">0</span><span class="p">}[</span><span class="n">i</span><span class="p">]</span> <span class="o">+</span> <span class="mi">1</span><span class="p">}[</span><span class="n">i</span><span class="p">][</span><span class="n">j</span><span class="p">],</span> <span class="n">j</span> <span class="o">=</span> <span class="mi">0</span><span class="p">,</span><span class="mi">1</span><span class="p">,</span> <span class="o">...</span> <span class="p">,</span> <span class="p">(</span><span class="n">x_</span><span class="p">{</span><span class="mi">1</span><span class="p">}</span><span class="o">.</span><span class="n">width</span> <span class="o">-</span> <span class="mi">1</span><span class="p">)</span>
...@@ -3171,7 +3157,8 @@ For each index i from 0 to batchSize -1, the output is the i-th row of the ...@@ -3171,7 +3157,8 @@ For each index i from 0 to batchSize -1, the output is the i-th row of the
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple"> <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
<li><strong>input</strong> (<em>list of paddle.v2.config_base.Layer</em>) &#8211; Input layers.</li> <li><strong>input</strong> (<em>list of paddle.v2.config_base.Layer</em>) &#8211; Input layers.</li>
<li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; extra layer attributes.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; The extra layer attribute. See paddle.v2.attr.ExtraAttribute for
details.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
...@@ -3274,22 +3261,23 @@ in width dimension.</p> ...@@ -3274,22 +3261,23 @@ in width dimension.</p>
<col class="field-body" /> <col class="field-body" />
<tbody valign="top"> <tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple"> <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
<li><strong>input</strong> (<em>paddle.v2.config_base.Layer.</em>) &#8211; The first input layer.</li> <li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The first input layer.</li>
<li><strong>label</strong> &#8211; The input label.</li> <li><strong>label</strong> &#8211; The input label.</li>
<li><strong>name</strong> (<em>None | basestring.</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>coeff</strong> (<em>float.</em>) &#8211; The cost is multiplied with coeff. <li><strong>coeff</strong> (<em>float</em>) &#8211; The weight of the gradient in the back propagation.
The coefficient affects the gradient in the backward.</li> 1.0 is the default.</li>
<li><strong>weight</strong> (<em>LayerOutout</em>) &#8211; The cost of each sample is multiplied with each weight. <li><strong>weight</strong> (<em>LayerOutout</em>) &#8211; The cost of each sample is multiplied with each weight.
The weight should be a layer with size=1. Note that gradient The weight should be a layer with size=1. Note that gradient
will not be calculated for weight.</li> will not be calculated for weight.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer Attribute.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; The extra layer attribute. See paddle.v2.attr.ExtraAttribute for
details.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first">paddle.v2.config_base.Layer object.</p> <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first">paddle.v2.config_base.Layer object.</p>
</td> </td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body"><p class="first last">paddle.v2.config_base.Layer.</p> <tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body"><p class="first last">paddle.v2.config_base.Layer</p>
</td> </td>
</tr> </tr>
</tbody> </tbody>
...@@ -3314,19 +3302,21 @@ Input should be a vector of positive numbers, without normalization.</p> ...@@ -3314,19 +3302,21 @@ Input should be a vector of positive numbers, without normalization.</p>
<col class="field-body" /> <col class="field-body" />
<tbody valign="top"> <tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple"> <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
<li><strong>input</strong> (<em>paddle.v2.config_base.Layer.</em>) &#8211; The first input layer.</li> <li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The first input layer.</li>
<li><strong>label</strong> &#8211; The input label.</li> <li><strong>label</strong> &#8211; The input label.</li>
<li><strong>name</strong> (<em>None | basestring.</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>coeff</strong> (<em>float.</em>) &#8211; The coefficient affects the gradient in the backward.</li> <li><strong>coeff</strong> (<em>float</em>) &#8211; The weight of the gradient in the back propagation.
<li><strong>softmax_selfnorm_alpha</strong> (<em>float.</em>) &#8211; The scale factor affects the cost.</li> 1.0 is the default.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer Attribute.</li> <li><strong>softmax_selfnorm_alpha</strong> (<em>float</em>) &#8211; The scale factor affects the cost.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; The extra layer attribute. See paddle.v2.attr.ExtraAttribute for
details.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first">paddle.v2.config_base.Layer object.</p> <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first">paddle.v2.config_base.Layer object.</p>
</td> </td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body"><p class="first last">paddle.v2.config_base.Layer.</p> <tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body"><p class="first last">paddle.v2.config_base.Layer</p>
</td> </td>
</tr> </tr>
</tbody> </tbody>
...@@ -3352,9 +3342,11 @@ Input should be a vector of positive numbers, without normalization.</p> ...@@ -3352,9 +3342,11 @@ Input should be a vector of positive numbers, without normalization.</p>
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple"> <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
<li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The first input layer.</li> <li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The first input layer.</li>
<li><strong>label</strong> &#8211; The input label.</li> <li><strong>label</strong> &#8211; The input label.</li>
<li><strong>name</strong> (<em>None | basestring</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>coeff</strong> (<em>float</em>) &#8211; The coefficient affects the gradient in the backward.</li> <li><strong>coeff</strong> (<em>float</em>) &#8211; The weight of the gradient in the back propagation.
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer Attribute.</li> 1.0 is the default.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; The extra layer attribute. See paddle.v2.attr.ExtraAttribute for
details.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
...@@ -3395,26 +3387,28 @@ ight <a href="#id2"><span class="problematic" id="id3">|</span></a>leq delta</p> ...@@ -3395,26 +3387,28 @@ ight <a href="#id2"><span class="problematic" id="id3">|</span></a>leq delta</p>
<tbody valign="top"> <tbody valign="top">
<tr class="field-odd field"><th class="field-name">param input:</th><td class="field-body">The first input layer.</td> <tr class="field-odd field"><th class="field-name">param input:</th><td class="field-body">The first input layer.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">type input:</th><td class="field-body">paddle.v2.config_base.Layer.</td> <tr class="field-even field"><th class="field-name">type input:</th><td class="field-body">paddle.v2.config_base.Layer</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">param label:</th><td class="field-body">The input label.</td> <tr class="field-odd field"><th class="field-name">param label:</th><td class="field-body">The input label.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">type input:</th><td class="field-body">paddle.v2.config_base.Layer.</td> <tr class="field-even field"><th class="field-name">type input:</th><td class="field-body">paddle.v2.config_base.Layer</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">param name:</th><td class="field-body">The name of this layer. It is optional.</td> <tr class="field-odd field"><th class="field-name">param name:</th><td class="field-body">The name of this layer. It is optional.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">type name:</th><td class="field-body">None | basestring.</td> <tr class="field-even field"><th class="field-name">type name:</th><td class="field-body">basestring</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">param delta:</th><td class="field-body">The difference between the observed and predicted values.</td> <tr class="field-odd field"><th class="field-name">param delta:</th><td class="field-body">The difference between the observed and predicted values.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">type delta:</th><td class="field-body">float.</td> <tr class="field-even field"><th class="field-name">type delta:</th><td class="field-body">float</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">param coeff:</th><td class="field-body">The coefficient affects the gradient in the backward.</td> <tr class="field-odd field"><th class="field-name">param coeff:</th><td class="field-body">The weight of the gradient in the back propagation.
1.0 is the default.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">type coeff:</th><td class="field-body">float.</td> <tr class="field-even field"><th class="field-name">type coeff:</th><td class="field-body">float</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name" colspan="2">param layer_attr:</th></tr> <tr class="field-odd field"><th class="field-name" colspan="2">param layer_attr:</th></tr>
<tr class="field-odd field"><td>&#160;</td><td class="field-body">Extra Layer Attribute.</td> <tr class="field-odd field"><td>&#160;</td><td class="field-body">The extra layer attribute. See paddle.v2.attr.ExtraAttribute for
details.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name" colspan="2">type layer_attr:</th></tr> <tr class="field-even field"><th class="field-name" colspan="2">type layer_attr:</th></tr>
<tr class="field-even field"><td>&#160;</td><td class="field-body">paddle.v2.attr.ExtraAttribute</td> <tr class="field-even field"><td>&#160;</td><td class="field-body">paddle.v2.attr.ExtraAttribute</td>
...@@ -3454,29 +3448,31 @@ a true binary class label :math:<a href="#id6"><span class="problematic" id="id7 ...@@ -3454,29 +3448,31 @@ a true binary class label :math:<a href="#id6"><span class="problematic" id="id7
<tbody valign="top"> <tbody valign="top">
<tr class="field-odd field"><th class="field-name">param input:</th><td class="field-body">The first input layer.</td> <tr class="field-odd field"><th class="field-name">param input:</th><td class="field-body">The first input layer.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">type input:</th><td class="field-body">paddle.v2.config_base.Layer.</td> <tr class="field-even field"><th class="field-name">type input:</th><td class="field-body">paddle.v2.config_base.Layer</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">param label:</th><td class="field-body">The input label.</td> <tr class="field-odd field"><th class="field-name">param label:</th><td class="field-body">The input label.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">type input:</th><td class="field-body">paddle.v2.config_base.Layer.</td> <tr class="field-even field"><th class="field-name">type input:</th><td class="field-body">paddle.v2.config_base.Layer</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">param name:</th><td class="field-body">The name of this layer. It is optional.</td> <tr class="field-odd field"><th class="field-name">param name:</th><td class="field-body">The name of this layer. It is optional.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">type name:</th><td class="field-body">None | basestring.</td> <tr class="field-even field"><th class="field-name">type name:</th><td class="field-body">basestring</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">param coeff:</th><td class="field-body">The coefficient affects the gradient in the backward.</td> <tr class="field-odd field"><th class="field-name">param coeff:</th><td class="field-body">The weight of the gradient in the back propagation.
1.0 is the default.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">type coeff:</th><td class="field-body">float.</td> <tr class="field-even field"><th class="field-name">type coeff:</th><td class="field-body">float</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name" colspan="2">param layer_attr:</th></tr> <tr class="field-odd field"><th class="field-name" colspan="2">param layer_attr:</th></tr>
<tr class="field-odd field"><td>&#160;</td><td class="field-body">Extra Layer Attribute.</td> <tr class="field-odd field"><td>&#160;</td><td class="field-body">The extra layer attribute. See paddle.v2.attr.ExtraAttribute for
details.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name" colspan="2">type layer_attr:</th></tr> <tr class="field-even field"><th class="field-name" colspan="2">type layer_attr:</th></tr>
<tr class="field-even field"><td>&#160;</td><td class="field-body">paddle.v2.attr.ExtraAttribute</td> <tr class="field-even field"><td>&#160;</td><td class="field-body">paddle.v2.attr.ExtraAttribute</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">return:</th><td class="field-body">paddle.v2.config_base.Layer object.</td> <tr class="field-odd field"><th class="field-name">return:</th><td class="field-body">paddle.v2.config_base.Layer object.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">rtype:</th><td class="field-body">paddle.v2.config_base.Layer.</td> <tr class="field-even field"><th class="field-name">rtype:</th><td class="field-body">paddle.v2.config_base.Layer</td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
...@@ -3625,7 +3621,7 @@ It is an optional argument.</li> ...@@ -3625,7 +3621,7 @@ It is an optional argument.</li>
<dl class="class"> <dl class="class">
<dt> <dt>
<em class="property">class </em><code class="descclassname">paddle.v2.layer.</code><code class="descname">sum_cost</code></dt> <em class="property">class </em><code class="descclassname">paddle.v2.layer.</code><code class="descname">sum_cost</code></dt>
<dd><p>A loss layer which calculate the sum of the input as loss</p> <dd><p>A loss layer which calculates the sum of the input as loss.</p>
<p>The example usage is:</p> <p>The example usage is:</p>
<div class="highlight-python"><div class="highlight"><pre><span></span><span class="n">cost</span> <span class="o">=</span> <span class="n">sum_cost</span><span class="p">(</span><span class="nb">input</span><span class="o">=</span><span class="nb">input</span><span class="p">)</span> <div class="highlight-python"><div class="highlight"><pre><span></span><span class="n">cost</span> <span class="o">=</span> <span class="n">sum_cost</span><span class="p">(</span><span class="nb">input</span><span class="o">=</span><span class="nb">input</span><span class="p">)</span>
</pre></div> </pre></div>
...@@ -3635,9 +3631,10 @@ It is an optional argument.</li> ...@@ -3635,9 +3631,10 @@ It is an optional argument.</li>
<col class="field-body" /> <col class="field-body" />
<tbody valign="top"> <tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple"> <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
<li><strong>input</strong> (<em>paddle.v2.config_base.Layer.</em>) &#8211; The input of this layer.</li> <li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input of this layer.</li>
<li><strong>name</strong> (<em>None | basestring.</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer Attribute.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; The extra layer attribute. See paddle.v2.attr.ExtraAttribute for
details.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
...@@ -3875,10 +3872,9 @@ A fast and simple algorithm for training neural probabilistic language models.</ ...@@ -3875,10 +3872,9 @@ A fast and simple algorithm for training neural probabilistic language models.</
<li><strong>neg_distribution</strong> (<em>list | tuple | collections.Sequence | None</em>) &#8211; The distribution for generating the random negative labels. <li><strong>neg_distribution</strong> (<em>list | tuple | collections.Sequence | None</em>) &#8211; The distribution for generating the random negative labels.
A uniform distribution will be used if not provided. A uniform distribution will be used if not provided.
If not None, its length must be equal to num_classes.</li> If not None, its length must be equal to num_classes.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer Attribute.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer Attribute.</li>
</ul> </ul>
</td> </td>
...@@ -3917,10 +3913,9 @@ Hierarchical Probabilistic Neural Network Language Model.&#8221;</p> ...@@ -3917,10 +3913,9 @@ Hierarchical Probabilistic Neural Network Language Model.&#8221;</p>
<li><strong>label</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; Label layer.</li> <li><strong>label</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; Label layer.</li>
<li><strong>num_classes</strong> (<em>int | None</em>) &#8211; number of classes.</li> <li><strong>num_classes</strong> (<em>int | None</em>) &#8211; number of classes.</li>
<li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None</em>) &#8211; Parameter Attribute. None means default parameter.</li> <li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None</em>) &#8211; Parameter Attribute. None means default parameter.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer Attribute.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer Attribute.</li>
</ul> </ul>
...@@ -3943,13 +3938,17 @@ True, the bias is initialized to zero.</li> ...@@ -3943,13 +3938,17 @@ True, the bias is initialized to zero.</li>
<dt> <dt>
<em class="property">class </em><code class="descclassname">paddle.v2.layer.</code><code class="descname">smooth_l1_cost</code></dt> <em class="property">class </em><code class="descclassname">paddle.v2.layer.</code><code class="descname">smooth_l1_cost</code></dt>
<dd><p>This is a L1 loss but more smooth. It requires that the <dd><p>This is a L1 loss but more smooth. It requires that the
size of input and label are equal. The formula is as follows,</p> sizes of input and label are equal. The formula is as follows,</p>
<div class="math"> <div class="math">
\[L = \sum_{i} smooth_{L1}(input_i - label_i)\]</div> \[L = \sum_{i} smooth_{L1}(input_i - label_i)\]</div>
<p>in which</p> <p>in which</p>
<div class="math"> <div class="math">
\[\begin{split}smooth_{L1}(x) = \begin{cases} 0.5x^2&amp; \text{if} \ |x| &lt; 1 \\ |x|-0.5&amp; \text{otherwise} \end{cases}\end{split}\]</div> \[\begin{split}smooth_{L1}(x) = \begin{cases} 0.5x^2&amp; \text{if} \ |x| &lt; 1 \\ |x|-0.5&amp; \text{otherwise} \end{cases}\end{split}\]</div>
<p>More details can be found by referring to <a class="reference external" href="https://arxiv.org/pdf/1504.08083v2.pdf">Fast R-CNN</a></p> <dl class="docutils">
<dt>Reference:</dt>
<dd>Fast R-CNN
<a class="reference external" href="https://arxiv.org/pdf/1504.08083v2.pdf">https://arxiv.org/pdf/1504.08083v2.pdf</a></dd>
</dl>
<p>The example usage is:</p> <p>The example usage is:</p>
<div class="highlight-python"><div class="highlight"><pre><span></span><span class="n">cost</span> <span class="o">=</span> <span class="n">smooth_l1_cost</span><span class="p">(</span><span class="nb">input</span><span class="o">=</span><span class="nb">input</span><span class="p">,</span> <div class="highlight-python"><div class="highlight"><pre><span></span><span class="n">cost</span> <span class="o">=</span> <span class="n">smooth_l1_cost</span><span class="p">(</span><span class="nb">input</span><span class="o">=</span><span class="nb">input</span><span class="p">,</span>
<span class="n">label</span><span class="o">=</span><span class="n">label</span><span class="p">)</span> <span class="n">label</span><span class="o">=</span><span class="n">label</span><span class="p">)</span>
...@@ -3962,9 +3961,11 @@ size of input and label are equal. The formula is as follows,</p> ...@@ -3962,9 +3961,11 @@ size of input and label are equal. The formula is as follows,</p>
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple"> <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
<li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input layer.</li> <li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input layer.</li>
<li><strong>label</strong> &#8211; The input label.</li> <li><strong>label</strong> &#8211; The input label.</li>
<li><strong>name</strong> (<em>None | basestring</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>coeff</strong> (<em>float</em>) &#8211; The coefficient affects the gradient in the backward.</li> <li><strong>coeff</strong> (<em>float</em>) &#8211; The weight of the gradient in the back propagation.
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer Attribute.</li> 1.0 is the default.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; The extra layer attribute. See paddle.v2.attr.ExtraAttribute for
details.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
...@@ -4092,7 +4093,7 @@ It is used by recurrent layer group.</p> ...@@ -4092,7 +4093,7 @@ It is used by recurrent layer group.</p>
<dl class="class"> <dl class="class">
<dt> <dt>
<em class="property">class </em><code class="descclassname">paddle.v2.layer.</code><code class="descname">prelu</code></dt> <em class="property">class </em><code class="descclassname">paddle.v2.layer.</code><code class="descname">prelu</code></dt>
<dd><p>The Parameter Relu activation that actives outputs with a learnable weight.</p> <dd><p>The Parametric Relu activation that actives outputs with a learnable weight.</p>
<dl class="docutils"> <dl class="docutils">
<dt>Reference:</dt> <dt>Reference:</dt>
<dd>Delving Deep into Rectifiers: Surpassing Human-Level Performance on <dd>Delving Deep into Rectifiers: Surpassing Human-Level Performance on
...@@ -4112,15 +4113,16 @@ a_i * z_i &amp;\quad \mathrm{otherwise}\end{split}\]</div> ...@@ -4112,15 +4113,16 @@ a_i * z_i &amp;\quad \mathrm{otherwise}\end{split}\]</div>
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple"> <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
<li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input of this layer.</li> <li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input of this layer.</li>
<li><strong>partial_sum</strong> (<em>int</em>) &#8211; <p>this parameter makes a group of inputs share a same weight.</p> <li><strong>partial_sum</strong> (<em>int</em>) &#8211; <p>this parameter makes a group of inputs share the same weight.</p>
<ul> <ul>
<li>partial_sum = 1, indicates the element-wise activation: each element has a weight.</li> <li>partial_sum = 1, indicates the element-wise activation: each element has a weight.</li>
<li>partial_sum = number of elements in one channel, indicates the channel-wise activation, elements in a channel share a same weight.</li> <li>partial_sum = number of elements in one channel, indicates the channel-wise activation, elements in a channel share the same weight.</li>
<li>partial_sum = number of outputs, indicates all elements share a same weight.</li> <li>partial_sum = number of outputs, indicates all elements share the same weight.</li>
</ul> </ul>
</li> </li>
<li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None</em>) &#8211; The parameter attribute. See paddle.v2.attr.ParameterAttribute for details.</li> <li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The parameter attribute. See paddle.v2.attr.ParameterAttribute for details.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra layer configurations. Default is None.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; The extra layer attribute. See paddle.v2.attr.ExtraAttribute for
details.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
...@@ -4158,25 +4160,25 @@ product between <a href="#id11"><span class="problematic" id="id12">:match:`X&#8 ...@@ -4158,25 +4160,25 @@ product between <a href="#id11"><span class="problematic" id="id12">:match:`X&#8
<tbody valign="top"> <tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple"> <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
<li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input of this layer.</li> <li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input of this layer.</li>
<li><strong>size</strong> (<em>int</em>) &#8211; output size of the gated unit.</li> <li><strong>size</strong> (<em>int</em>) &#8211; The dimension of this layer&#8217;s output.</li>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type of the projected input. paddle.v2.activation.Linear is the default.</li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type of the projection. paddle.v2.activation.Linear is the default.</li>
<li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>gate_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Attributes to tune the gate output, for example, error <li><strong>gate_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; The extra layer attribute of the gate. See paddle.v2.attr.ExtraAttribute for
clipping threshold, dropout and so on. See paddle.v2.attr.ExtraAttribute for details.</li>
more details.</li> <li><strong>gate_param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The parameter attribute of the gate. See paddle.v2.attr.ParameterAttribute
<li><strong>gate_param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None</em>) &#8211; Attributes to tune the learnable projected matrix for details.</li>
parameter of the gate.</li> <li><strong>gate_bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | bool | None | Any</em>) &#8211; The bias attribute of the gate. If the parameter is set to False or
<li><strong>gate_bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None</em>) &#8211; Attributes to tune the learnable bias of the gate.</li> an object whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined.
<li><strong>inproj_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Attributes to the tune the projected input, for If the parameter is set to True, the bias is initialized to zero.</li>
example, error clipping threshold, dropout and so on. See <li><strong>inproj_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra layer attributes of the projection. See paddle.v2.attr.ExtraAttribute for
paddle.v2.attr.ExtraAttribute for more details.</li> details.</li>
<li><strong>inproj_param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None</em>) &#8211; Attributes to tune the learnable parameter of <li><strong>inproj_param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The parameter attribute of the projection. See paddle.v2.attr.ParameterAttribute
the projection of input.</li> for details.</li>
<li><strong>inproj_bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None</em>) &#8211; Attributes to tune the learnable bias of <li><strong>inproj_bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | bool | None | Any</em>) &#8211; The bias attribute of the projection. If the parameter is set to False
projection of the input.</li> or an object whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined.
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Attributes to tune the final output of the gated unit, If the parameter is set to True, the bias is initialized to zero.</li>
for example, error clipping threshold, dropout and so on. See <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra layer attribute of the product. See paddle.v2.attr.ExtraAttribute for
paddle.v2.attr.ExtraAttribute for more details.</li> details.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
......
因为 它太大了无法显示 source diff 。你可以改为 查看blob
...@@ -253,10 +253,9 @@ ...@@ -253,10 +253,9 @@
<li><strong>size</strong> (<em>int</em>) &#8211; The layer dimension.</li> <li><strong>size</strong> (<em>int</em>) &#8211; The layer dimension.</li>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation Type. paddle.v2.activation.Tanh is the default.</li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation Type. paddle.v2.activation.Tanh is the default.</li>
<li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The Parameter Attribute|list.</li> <li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The Parameter Attribute|list.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra Layer config.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra Layer config.</li>
</ul> </ul>
</td> </td>
...@@ -298,10 +297,9 @@ If is None, acts exactly like fc.</li> ...@@ -298,10 +297,9 @@ If is None, acts exactly like fc.</li>
<li><strong>size</strong> (<em>int</em>) &#8211; The layer dimension.</li> <li><strong>size</strong> (<em>int</em>) &#8211; The layer dimension.</li>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Tanh is the default.</li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Tanh is the default.</li>
<li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The Parameter Attribute.</li> <li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The Parameter Attribute.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra Layer config.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra Layer config.</li>
</ul> </ul>
</td> </td>
...@@ -524,10 +522,9 @@ image dimension</li> ...@@ -524,10 +522,9 @@ image dimension</li>
<li><strong>dilation</strong> (<em>int | tuple | list</em>) &#8211; The x dimension of the dilation. Or input a tuple for two <li><strong>dilation</strong> (<em>int | tuple | list</em>) &#8211; The x dimension of the dilation. Or input a tuple for two
image dimension</li> image dimension</li>
<li><strong>dilation_y</strong> (<em>int</em>) &#8211; The y dimension of the dilation.</li> <li><strong>dilation_y</strong> (<em>int</em>) &#8211; The y dimension of the dilation.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>num_channels</strong> (<em>int</em>) &#8211; number of input channels. If None will be set <li><strong>num_channels</strong> (<em>int</em>) &#8211; number of input channels. If None will be set
automatically from previous output.</li> automatically from previous output.</li>
<li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; Convolution param attribute. None means default attribute</li> <li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; Convolution param attribute. None means default attribute</li>
...@@ -631,9 +628,10 @@ number plus one equals context_len.</p> ...@@ -631,9 +628,10 @@ number plus one equals context_len.</p>
<li><strong>context_len</strong> (<em>int</em>) &#8211; The context length equals the lookahead step number <li><strong>context_len</strong> (<em>int</em>) &#8211; The context length equals the lookahead step number
plus one.</li> plus one.</li>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation Type. paddle.v2.activation.Linear is the default.</li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation Type. paddle.v2.activation.Linear is the default.</li>
<li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The Parameter Attribute. If None, the parameter will be <li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The parameter attribute. See paddle.v2.attr.ParameterAttribute for
initialized smartly. It&#8217;s better to set it by yourself.</li> details.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra Layer config.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; The extra layer attribute. See paddle.v2.attr.ExtraAttribute for
details.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
...@@ -1070,10 +1068,9 @@ out_{i} = act(in_{i} + out_{i+1} * W) \ \ \text{for} \ start &lt;= i &lt; end\en ...@@ -1070,10 +1068,9 @@ out_{i} = act(in_{i} + out_{i+1} * W) \ \ \text{for} \ start &lt;= i &lt; end\en
<tr class="field-odd field"><th class="field-name">参数:</th><td class="field-body"><ul class="first simple"> <tr class="field-odd field"><th class="field-name">参数:</th><td class="field-body"><ul class="first simple">
<li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input of this layer.</li> <li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input of this layer.</li>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Tanh is the default.</li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Tanh is the default.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; parameter attribute.</li> <li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; parameter attribute.</li>
<li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Layer Attribute.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Layer Attribute.</li>
...@@ -1123,10 +1120,9 @@ more details about LSTM.</p> ...@@ -1123,10 +1120,9 @@ more details about LSTM.</p>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Tanh is the default. <span class="math">\(h_t\)</span></li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Tanh is the default. <span class="math">\(h_t\)</span></li>
<li><strong>gate_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; gate activation type, paddle.v2.activation.Sigmoid by default.</li> <li><strong>gate_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; gate activation type, paddle.v2.activation.Sigmoid by default.</li>
<li><strong>state_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; state activation type, paddle.v2.activation.Tanh by default.</li> <li><strong>state_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; state activation type, paddle.v2.activation.Tanh by default.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | False</em>) &#8211; Parameter Attribute.</li> <li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | False</em>) &#8211; Parameter Attribute.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra Layer attribute</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra Layer attribute</li>
</ul> </ul>
...@@ -1193,10 +1189,9 @@ affects the <span class="math">\({\tilde{h_t}}\)</span>.</li> ...@@ -1193,10 +1189,9 @@ affects the <span class="math">\({\tilde{h_t}}\)</span>.</li>
<li><strong>gate_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; gate activation type, paddle.v2.activation.Sigmoid by default. <li><strong>gate_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; gate activation type, paddle.v2.activation.Sigmoid by default.
This activation affects the <span class="math">\(z_t\)</span> and <span class="math">\(r_t\)</span>. It is the This activation affects the <span class="math">\(z_t\)</span> and <span class="math">\(r_t\)</span>. It is the
<span class="math">\(\sigma\)</span> in the above formula.</li> <span class="math">\(\sigma\)</span> in the above formula.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | False</em>) &#8211; Parameter Attribute.</li> <li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | False</em>) &#8211; Parameter Attribute.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra Layer attribute</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra Layer attribute</li>
</ul> </ul>
...@@ -1377,10 +1372,9 @@ output is <span class="math">\(o_t\)</span>, whose name is &#8216;state&#8217; a ...@@ -1377,10 +1372,9 @@ output is <span class="math">\(o_t\)</span>, whose name is &#8216;state&#8217; a
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Tanh is the default.</li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Tanh is the default.</li>
<li><strong>gate_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Gate Activation Type. paddle.v2.activation.Sigmoid is the default.</li> <li><strong>gate_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Gate Activation Type. paddle.v2.activation.Sigmoid is the default.</li>
<li><strong>state_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; State Activation Type. paddle.v2.activation.Tanh is the default.</li> <li><strong>state_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; State Activation Type. paddle.v2.activation.Tanh is the default.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; layer&#8217;s extra attribute.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; layer&#8217;s extra attribute.</li>
</ul> </ul>
</td> </td>
...@@ -1412,10 +1406,9 @@ True, the bias is initialized to zero.</li> ...@@ -1412,10 +1406,9 @@ True, the bias is initialized to zero.</li>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; </li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; </li>
<li><strong>name</strong> &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> &#8211; The name of this layer. It is optional.</li>
<li><strong>gate_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type of this layer&#8217;s two gates. Default is Sigmoid.</li> <li><strong>gate_act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type of this layer&#8217;s two gates. Default is Sigmoid.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>param_attr</strong> &#8211; the parameter_attribute for transforming the output_mem <li><strong>param_attr</strong> &#8211; the parameter_attribute for transforming the output_mem
from previous step.</li> from previous step.</li>
<li><strong>layer_attr</strong> &#8211; </li> <li><strong>layer_attr</strong> &#8211; </li>
...@@ -1585,10 +1578,9 @@ Each inputs is a projection or operator.</p> ...@@ -1585,10 +1578,9 @@ Each inputs is a projection or operator.</p>
<li><strong>input</strong> &#8211; The input of this layer. It is an optional parameter. If set, <li><strong>input</strong> &#8211; The input of this layer. It is an optional parameter. If set,
then this function will just return layer&#8217;s name.</li> then this function will just return layer&#8217;s name.</li>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation Type. paddle.v2.activation.Linear is the default.</li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation Type. paddle.v2.activation.Linear is the default.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; The extra layer config. Default is None.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; The extra layer config. Default is None.</li>
</ul> </ul>
</td> </td>
...@@ -2016,10 +2008,9 @@ AggregateLevel.TO_SEQUENCE</li> ...@@ -2016,10 +2008,9 @@ AggregateLevel.TO_SEQUENCE</li>
<li><strong>pooling_type</strong> (<em>BasePoolingType | None</em>) &#8211; Type of pooling, MaxPooling(default), AvgPooling, <li><strong>pooling_type</strong> (<em>BasePoolingType | None</em>) &#8211; Type of pooling, MaxPooling(default), AvgPooling,
SumPooling, SquareRootNPooling.</li> SumPooling, SquareRootNPooling.</li>
<li><strong>stride</strong> (<em>Int</em>) &#8211; The step size between successive pooling regions.</li> <li><strong>stride</strong> (<em>Int</em>) &#8211; The step size between successive pooling regions.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; The Extra Attributes for layer, such as dropout.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; The Extra Attributes for layer, such as dropout.</li>
</ul> </ul>
</td> </td>
...@@ -2176,10 +2167,9 @@ processed in one batch.</p> ...@@ -2176,10 +2167,9 @@ processed in one batch.</p>
<li><strong>b</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; input sequence layer</li> <li><strong>b</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; input sequence layer</li>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Identity is the default.</li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Identity is the default.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer Attribute.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer Attribute.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
...@@ -2381,10 +2371,9 @@ sequence is one) to sequence data.&#8221;</p> ...@@ -2381,10 +2371,9 @@ sequence is one) to sequence data.&#8221;</p>
<li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input of this layer.</li> <li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input of this layer.</li>
<li><strong>expand_as</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; Expand as this layer&#8217;s sequence info.</li> <li><strong>expand_as</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; Expand as this layer&#8217;s sequence info.</li>
<li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>expand_level</strong> (<em>ExpandLevel</em>) &#8211; whether input layer is timestep(default) or sequence.</li> <li><strong>expand_level</strong> (<em>ExpandLevel</em>) &#8211; whether input layer is timestep(default) or sequence.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; extra layer attributes.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; extra layer attributes.</li>
</ul> </ul>
...@@ -2512,10 +2501,9 @@ output sequence has T*M/N instances, the dimension of each instance is N.</p> ...@@ -2512,10 +2501,9 @@ output sequence has T*M/N instances, the dimension of each instance is N.</p>
<li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Identity is the default.</li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Identity is the default.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; extra layer attributes.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; extra layer attributes.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
...@@ -2568,10 +2556,9 @@ Please refer to dropout for details.</p> ...@@ -2568,10 +2556,9 @@ Please refer to dropout for details.</p>
<li><strong>input</strong> (<em>paddle.v2.config_base.Layer | list | tuple</em>) &#8211; Input layers. It could be a paddle.v2.config_base.Layer or list/tuple of <li><strong>input</strong> (<em>paddle.v2.config_base.Layer | list | tuple</em>) &#8211; Input layers. It could be a paddle.v2.config_base.Layer or list/tuple of
paddle.v2.config_base.Layer.</li> paddle.v2.config_base.Layer.</li>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation Type. paddle.v2.activation.Linear is the default.</li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation Type. paddle.v2.activation.Linear is the default.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer attribute.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer attribute.</li>
</ul> </ul>
</td> </td>
...@@ -2831,11 +2818,11 @@ ight)</p> ...@@ -2831,11 +2818,11 @@ ight)</p>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">param min:</th><td class="field-body">The lower threshold for clipping.</td> <tr class="field-odd field"><th class="field-name">param min:</th><td class="field-body">The lower threshold for clipping.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">type min:</th><td class="field-body">double</td> <tr class="field-even field"><th class="field-name">type min:</th><td class="field-body">float</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">param max:</th><td class="field-body">The upper threshold for clipping.</td> <tr class="field-odd field"><th class="field-name">param max:</th><td class="field-body">The upper threshold for clipping.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">type max:</th><td class="field-body">double</td> <tr class="field-even field"><th class="field-name">type max:</th><td class="field-body">float</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">return:</th><td class="field-body">paddle.v2.config_base.Layer object.</td> <tr class="field-odd field"><th class="field-name">return:</th><td class="field-body">paddle.v2.config_base.Layer object.</td>
</tr> </tr>
...@@ -2949,10 +2936,9 @@ For example, each sample:</p> ...@@ -2949,10 +2936,9 @@ For example, each sample:</p>
<li><strong>size</strong> (<em>int.</em>) &#8211; the layer dimension.</li> <li><strong>size</strong> (<em>int.</em>) &#8211; the layer dimension.</li>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Linear is the default.</li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type. paddle.v2.activation.Linear is the default.</li>
<li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The Parameter Attribute.</li> <li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The Parameter Attribute.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra Layer config.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra Layer config.</li>
</ul> </ul>
</td> </td>
...@@ -3068,11 +3054,11 @@ bias are trainable.</p> ...@@ -3068,11 +3054,11 @@ bias are trainable.</p>
<tr class="field-odd field"><th class="field-name">参数:</th><td class="field-body"><ul class="first simple"> <tr class="field-odd field"><th class="field-name">参数:</th><td class="field-body"><ul class="first simple">
<li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input of this layer.</li> <li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input of this layer.</li>
<li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The parameter attribute of scaling.</li> <li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The parameter attribute of scaling. See paddle.v2.attr.ParameterAttribute for
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to details.</li>
False or something not type of paddle.v2.attr.ParameterAttribute, <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
no bias is defined. If the parameter is set to whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
True, the bias is initialized to zero.</li> parameter is set to True, the bias is initialized to zero.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
...@@ -3161,12 +3147,12 @@ Sampling one id for one sample.</p> ...@@ -3161,12 +3147,12 @@ Sampling one id for one sample.</p>
<dl class="class"> <dl class="class">
<dt> <dt>
<em class="property">class </em><code class="descclassname">paddle.v2.layer.</code><code class="descname">multiplex</code></dt> <em class="property">class </em><code class="descclassname">paddle.v2.layer.</code><code class="descname">multiplex</code></dt>
<dd><p>This layer multiplex multiple layers according to the index, <dd><p>This layer multiplex multiple layers according to the indexes,
which is provided by the first input layer. which are provided by the first input layer.
inputs[0]: the index of the layer to output of size batchSize. inputs[0]: the indexes of the layers to form the output of size batchSize.
inputs[1:N]; the candidate output data. inputs[1:N]; the candidate output data.
For each index i from 0 to batchSize -1, the output is the i-th row of the For each index i from 0 to batchSize - 1, the i-th row of the output is the
(index[i] + 1)-th layer.</p> the same to the i-th row of the (index[i] + 1)-th layer.</p>
<p>For each i-th row of output: <p>For each i-th row of output:
.. math:</p> .. math:</p>
<div class="highlight-default"><div class="highlight"><pre><span></span><span class="n">y</span><span class="p">[</span><span class="n">i</span><span class="p">][</span><span class="n">j</span><span class="p">]</span> <span class="o">=</span> <span class="n">x_</span><span class="p">{</span><span class="n">x_</span><span class="p">{</span><span class="mi">0</span><span class="p">}[</span><span class="n">i</span><span class="p">]</span> <span class="o">+</span> <span class="mi">1</span><span class="p">}[</span><span class="n">i</span><span class="p">][</span><span class="n">j</span><span class="p">],</span> <span class="n">j</span> <span class="o">=</span> <span class="mi">0</span><span class="p">,</span><span class="mi">1</span><span class="p">,</span> <span class="o">...</span> <span class="p">,</span> <span class="p">(</span><span class="n">x_</span><span class="p">{</span><span class="mi">1</span><span class="p">}</span><span class="o">.</span><span class="n">width</span> <span class="o">-</span> <span class="mi">1</span><span class="p">)</span> <div class="highlight-default"><div class="highlight"><pre><span></span><span class="n">y</span><span class="p">[</span><span class="n">i</span><span class="p">][</span><span class="n">j</span><span class="p">]</span> <span class="o">=</span> <span class="n">x_</span><span class="p">{</span><span class="n">x_</span><span class="p">{</span><span class="mi">0</span><span class="p">}[</span><span class="n">i</span><span class="p">]</span> <span class="o">+</span> <span class="mi">1</span><span class="p">}[</span><span class="n">i</span><span class="p">][</span><span class="n">j</span><span class="p">],</span> <span class="n">j</span> <span class="o">=</span> <span class="mi">0</span><span class="p">,</span><span class="mi">1</span><span class="p">,</span> <span class="o">...</span> <span class="p">,</span> <span class="p">(</span><span class="n">x_</span><span class="p">{</span><span class="mi">1</span><span class="p">}</span><span class="o">.</span><span class="n">width</span> <span class="o">-</span> <span class="mi">1</span><span class="p">)</span>
...@@ -3185,7 +3171,8 @@ For each index i from 0 to batchSize -1, the output is the i-th row of the ...@@ -3185,7 +3171,8 @@ For each index i from 0 to batchSize -1, the output is the i-th row of the
<tr class="field-odd field"><th class="field-name">参数:</th><td class="field-body"><ul class="first simple"> <tr class="field-odd field"><th class="field-name">参数:</th><td class="field-body"><ul class="first simple">
<li><strong>input</strong> (<em>list of paddle.v2.config_base.Layer</em>) &#8211; Input layers.</li> <li><strong>input</strong> (<em>list of paddle.v2.config_base.Layer</em>) &#8211; Input layers.</li>
<li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; extra layer attributes.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; The extra layer attribute. See paddle.v2.attr.ExtraAttribute for
details.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
...@@ -3288,22 +3275,23 @@ in width dimension.</p> ...@@ -3288,22 +3275,23 @@ in width dimension.</p>
<col class="field-body" /> <col class="field-body" />
<tbody valign="top"> <tbody valign="top">
<tr class="field-odd field"><th class="field-name">参数:</th><td class="field-body"><ul class="first simple"> <tr class="field-odd field"><th class="field-name">参数:</th><td class="field-body"><ul class="first simple">
<li><strong>input</strong> (<em>paddle.v2.config_base.Layer.</em>) &#8211; The first input layer.</li> <li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The first input layer.</li>
<li><strong>label</strong> &#8211; The input label.</li> <li><strong>label</strong> &#8211; The input label.</li>
<li><strong>name</strong> (<em>None | basestring.</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>coeff</strong> (<em>float.</em>) &#8211; The cost is multiplied with coeff. <li><strong>coeff</strong> (<em>float</em>) &#8211; The weight of the gradient in the back propagation.
The coefficient affects the gradient in the backward.</li> 1.0 is the default.</li>
<li><strong>weight</strong> (<em>LayerOutout</em>) &#8211; The cost of each sample is multiplied with each weight. <li><strong>weight</strong> (<em>LayerOutout</em>) &#8211; The cost of each sample is multiplied with each weight.
The weight should be a layer with size=1. Note that gradient The weight should be a layer with size=1. Note that gradient
will not be calculated for weight.</li> will not be calculated for weight.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer Attribute.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; The extra layer attribute. See paddle.v2.attr.ExtraAttribute for
details.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">返回:</th><td class="field-body"><p class="first">paddle.v2.config_base.Layer object.</p> <tr class="field-even field"><th class="field-name">返回:</th><td class="field-body"><p class="first">paddle.v2.config_base.Layer object.</p>
</td> </td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">返回类型:</th><td class="field-body"><p class="first last">paddle.v2.config_base.Layer.</p> <tr class="field-odd field"><th class="field-name">返回类型:</th><td class="field-body"><p class="first last">paddle.v2.config_base.Layer</p>
</td> </td>
</tr> </tr>
</tbody> </tbody>
...@@ -3328,19 +3316,21 @@ Input should be a vector of positive numbers, without normalization.</p> ...@@ -3328,19 +3316,21 @@ Input should be a vector of positive numbers, without normalization.</p>
<col class="field-body" /> <col class="field-body" />
<tbody valign="top"> <tbody valign="top">
<tr class="field-odd field"><th class="field-name">参数:</th><td class="field-body"><ul class="first simple"> <tr class="field-odd field"><th class="field-name">参数:</th><td class="field-body"><ul class="first simple">
<li><strong>input</strong> (<em>paddle.v2.config_base.Layer.</em>) &#8211; The first input layer.</li> <li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The first input layer.</li>
<li><strong>label</strong> &#8211; The input label.</li> <li><strong>label</strong> &#8211; The input label.</li>
<li><strong>name</strong> (<em>None | basestring.</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>coeff</strong> (<em>float.</em>) &#8211; The coefficient affects the gradient in the backward.</li> <li><strong>coeff</strong> (<em>float</em>) &#8211; The weight of the gradient in the back propagation.
<li><strong>softmax_selfnorm_alpha</strong> (<em>float.</em>) &#8211; The scale factor affects the cost.</li> 1.0 is the default.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer Attribute.</li> <li><strong>softmax_selfnorm_alpha</strong> (<em>float</em>) &#8211; The scale factor affects the cost.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; The extra layer attribute. See paddle.v2.attr.ExtraAttribute for
details.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">返回:</th><td class="field-body"><p class="first">paddle.v2.config_base.Layer object.</p> <tr class="field-even field"><th class="field-name">返回:</th><td class="field-body"><p class="first">paddle.v2.config_base.Layer object.</p>
</td> </td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">返回类型:</th><td class="field-body"><p class="first last">paddle.v2.config_base.Layer.</p> <tr class="field-odd field"><th class="field-name">返回类型:</th><td class="field-body"><p class="first last">paddle.v2.config_base.Layer</p>
</td> </td>
</tr> </tr>
</tbody> </tbody>
...@@ -3366,9 +3356,11 @@ Input should be a vector of positive numbers, without normalization.</p> ...@@ -3366,9 +3356,11 @@ Input should be a vector of positive numbers, without normalization.</p>
<tr class="field-odd field"><th class="field-name">参数:</th><td class="field-body"><ul class="first simple"> <tr class="field-odd field"><th class="field-name">参数:</th><td class="field-body"><ul class="first simple">
<li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The first input layer.</li> <li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The first input layer.</li>
<li><strong>label</strong> &#8211; The input label.</li> <li><strong>label</strong> &#8211; The input label.</li>
<li><strong>name</strong> (<em>None | basestring</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>coeff</strong> (<em>float</em>) &#8211; The coefficient affects the gradient in the backward.</li> <li><strong>coeff</strong> (<em>float</em>) &#8211; The weight of the gradient in the back propagation.
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer Attribute.</li> 1.0 is the default.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; The extra layer attribute. See paddle.v2.attr.ExtraAttribute for
details.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
...@@ -3409,26 +3401,28 @@ ight <a href="#id2"><span class="problematic" id="id3">|</span></a>leq delta</p> ...@@ -3409,26 +3401,28 @@ ight <a href="#id2"><span class="problematic" id="id3">|</span></a>leq delta</p>
<tbody valign="top"> <tbody valign="top">
<tr class="field-odd field"><th class="field-name">param input:</th><td class="field-body">The first input layer.</td> <tr class="field-odd field"><th class="field-name">param input:</th><td class="field-body">The first input layer.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">type input:</th><td class="field-body">paddle.v2.config_base.Layer.</td> <tr class="field-even field"><th class="field-name">type input:</th><td class="field-body">paddle.v2.config_base.Layer</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">param label:</th><td class="field-body">The input label.</td> <tr class="field-odd field"><th class="field-name">param label:</th><td class="field-body">The input label.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">type input:</th><td class="field-body">paddle.v2.config_base.Layer.</td> <tr class="field-even field"><th class="field-name">type input:</th><td class="field-body">paddle.v2.config_base.Layer</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">param name:</th><td class="field-body">The name of this layer. It is optional.</td> <tr class="field-odd field"><th class="field-name">param name:</th><td class="field-body">The name of this layer. It is optional.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">type name:</th><td class="field-body">None | basestring.</td> <tr class="field-even field"><th class="field-name">type name:</th><td class="field-body">basestring</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">param delta:</th><td class="field-body">The difference between the observed and predicted values.</td> <tr class="field-odd field"><th class="field-name">param delta:</th><td class="field-body">The difference between the observed and predicted values.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">type delta:</th><td class="field-body">float.</td> <tr class="field-even field"><th class="field-name">type delta:</th><td class="field-body">float</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">param coeff:</th><td class="field-body">The coefficient affects the gradient in the backward.</td> <tr class="field-odd field"><th class="field-name">param coeff:</th><td class="field-body">The weight of the gradient in the back propagation.
1.0 is the default.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">type coeff:</th><td class="field-body">float.</td> <tr class="field-even field"><th class="field-name">type coeff:</th><td class="field-body">float</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name" colspan="2">param layer_attr:</th></tr> <tr class="field-odd field"><th class="field-name" colspan="2">param layer_attr:</th></tr>
<tr class="field-odd field"><td>&#160;</td><td class="field-body">Extra Layer Attribute.</td> <tr class="field-odd field"><td>&#160;</td><td class="field-body">The extra layer attribute. See paddle.v2.attr.ExtraAttribute for
details.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name" colspan="2">type layer_attr:</th></tr> <tr class="field-even field"><th class="field-name" colspan="2">type layer_attr:</th></tr>
<tr class="field-even field"><td>&#160;</td><td class="field-body">paddle.v2.attr.ExtraAttribute</td> <tr class="field-even field"><td>&#160;</td><td class="field-body">paddle.v2.attr.ExtraAttribute</td>
...@@ -3468,29 +3462,31 @@ a true binary class label :math:<a href="#id6"><span class="problematic" id="id7 ...@@ -3468,29 +3462,31 @@ a true binary class label :math:<a href="#id6"><span class="problematic" id="id7
<tbody valign="top"> <tbody valign="top">
<tr class="field-odd field"><th class="field-name">param input:</th><td class="field-body">The first input layer.</td> <tr class="field-odd field"><th class="field-name">param input:</th><td class="field-body">The first input layer.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">type input:</th><td class="field-body">paddle.v2.config_base.Layer.</td> <tr class="field-even field"><th class="field-name">type input:</th><td class="field-body">paddle.v2.config_base.Layer</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">param label:</th><td class="field-body">The input label.</td> <tr class="field-odd field"><th class="field-name">param label:</th><td class="field-body">The input label.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">type input:</th><td class="field-body">paddle.v2.config_base.Layer.</td> <tr class="field-even field"><th class="field-name">type input:</th><td class="field-body">paddle.v2.config_base.Layer</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">param name:</th><td class="field-body">The name of this layer. It is optional.</td> <tr class="field-odd field"><th class="field-name">param name:</th><td class="field-body">The name of this layer. It is optional.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">type name:</th><td class="field-body">None | basestring.</td> <tr class="field-even field"><th class="field-name">type name:</th><td class="field-body">basestring</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">param coeff:</th><td class="field-body">The coefficient affects the gradient in the backward.</td> <tr class="field-odd field"><th class="field-name">param coeff:</th><td class="field-body">The weight of the gradient in the back propagation.
1.0 is the default.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">type coeff:</th><td class="field-body">float.</td> <tr class="field-even field"><th class="field-name">type coeff:</th><td class="field-body">float</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name" colspan="2">param layer_attr:</th></tr> <tr class="field-odd field"><th class="field-name" colspan="2">param layer_attr:</th></tr>
<tr class="field-odd field"><td>&#160;</td><td class="field-body">Extra Layer Attribute.</td> <tr class="field-odd field"><td>&#160;</td><td class="field-body">The extra layer attribute. See paddle.v2.attr.ExtraAttribute for
details.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name" colspan="2">type layer_attr:</th></tr> <tr class="field-even field"><th class="field-name" colspan="2">type layer_attr:</th></tr>
<tr class="field-even field"><td>&#160;</td><td class="field-body">paddle.v2.attr.ExtraAttribute</td> <tr class="field-even field"><td>&#160;</td><td class="field-body">paddle.v2.attr.ExtraAttribute</td>
</tr> </tr>
<tr class="field-odd field"><th class="field-name">return:</th><td class="field-body">paddle.v2.config_base.Layer object.</td> <tr class="field-odd field"><th class="field-name">return:</th><td class="field-body">paddle.v2.config_base.Layer object.</td>
</tr> </tr>
<tr class="field-even field"><th class="field-name">rtype:</th><td class="field-body">paddle.v2.config_base.Layer.</td> <tr class="field-even field"><th class="field-name">rtype:</th><td class="field-body">paddle.v2.config_base.Layer</td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
...@@ -3639,7 +3635,7 @@ It is an optional argument.</li> ...@@ -3639,7 +3635,7 @@ It is an optional argument.</li>
<dl class="class"> <dl class="class">
<dt> <dt>
<em class="property">class </em><code class="descclassname">paddle.v2.layer.</code><code class="descname">sum_cost</code></dt> <em class="property">class </em><code class="descclassname">paddle.v2.layer.</code><code class="descname">sum_cost</code></dt>
<dd><p>A loss layer which calculate the sum of the input as loss</p> <dd><p>A loss layer which calculates the sum of the input as loss.</p>
<p>The example usage is:</p> <p>The example usage is:</p>
<div class="highlight-python"><div class="highlight"><pre><span></span><span class="n">cost</span> <span class="o">=</span> <span class="n">sum_cost</span><span class="p">(</span><span class="nb">input</span><span class="o">=</span><span class="nb">input</span><span class="p">)</span> <div class="highlight-python"><div class="highlight"><pre><span></span><span class="n">cost</span> <span class="o">=</span> <span class="n">sum_cost</span><span class="p">(</span><span class="nb">input</span><span class="o">=</span><span class="nb">input</span><span class="p">)</span>
</pre></div> </pre></div>
...@@ -3649,9 +3645,10 @@ It is an optional argument.</li> ...@@ -3649,9 +3645,10 @@ It is an optional argument.</li>
<col class="field-body" /> <col class="field-body" />
<tbody valign="top"> <tbody valign="top">
<tr class="field-odd field"><th class="field-name">参数:</th><td class="field-body"><ul class="first simple"> <tr class="field-odd field"><th class="field-name">参数:</th><td class="field-body"><ul class="first simple">
<li><strong>input</strong> (<em>paddle.v2.config_base.Layer.</em>) &#8211; The input of this layer.</li> <li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input of this layer.</li>
<li><strong>name</strong> (<em>None | basestring.</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer Attribute.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; The extra layer attribute. See paddle.v2.attr.ExtraAttribute for
details.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
...@@ -3889,10 +3886,9 @@ A fast and simple algorithm for training neural probabilistic language models.</ ...@@ -3889,10 +3886,9 @@ A fast and simple algorithm for training neural probabilistic language models.</
<li><strong>neg_distribution</strong> (<em>list | tuple | collections.Sequence | None</em>) &#8211; The distribution for generating the random negative labels. <li><strong>neg_distribution</strong> (<em>list | tuple | collections.Sequence | None</em>) &#8211; The distribution for generating the random negative labels.
A uniform distribution will be used if not provided. A uniform distribution will be used if not provided.
If not None, its length must be equal to num_classes.</li> If not None, its length must be equal to num_classes.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer Attribute.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer Attribute.</li>
</ul> </ul>
</td> </td>
...@@ -3931,10 +3927,9 @@ Hierarchical Probabilistic Neural Network Language Model.&#8221;</p> ...@@ -3931,10 +3927,9 @@ Hierarchical Probabilistic Neural Network Language Model.&#8221;</p>
<li><strong>label</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; Label layer.</li> <li><strong>label</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; Label layer.</li>
<li><strong>num_classes</strong> (<em>int | None</em>) &#8211; number of classes.</li> <li><strong>num_classes</strong> (<em>int | None</em>) &#8211; number of classes.</li>
<li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The Bias Attribute. If the parameter is set to <li><strong>bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None | bool | Any</em>) &#8211; The bias attribute. If the parameter is set to False or an object
False or something not type of paddle.v2.attr.ParameterAttribute, whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined. If the
no bias is defined. If the parameter is set to parameter is set to True, the bias is initialized to zero.</li>
True, the bias is initialized to zero.</li>
<li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None</em>) &#8211; Parameter Attribute. None means default parameter.</li> <li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None</em>) &#8211; Parameter Attribute. None means default parameter.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer Attribute.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer Attribute.</li>
</ul> </ul>
...@@ -3957,13 +3952,17 @@ True, the bias is initialized to zero.</li> ...@@ -3957,13 +3952,17 @@ True, the bias is initialized to zero.</li>
<dt> <dt>
<em class="property">class </em><code class="descclassname">paddle.v2.layer.</code><code class="descname">smooth_l1_cost</code></dt> <em class="property">class </em><code class="descclassname">paddle.v2.layer.</code><code class="descname">smooth_l1_cost</code></dt>
<dd><p>This is a L1 loss but more smooth. It requires that the <dd><p>This is a L1 loss but more smooth. It requires that the
size of input and label are equal. The formula is as follows,</p> sizes of input and label are equal. The formula is as follows,</p>
<div class="math"> <div class="math">
\[L = \sum_{i} smooth_{L1}(input_i - label_i)\]</div> \[L = \sum_{i} smooth_{L1}(input_i - label_i)\]</div>
<p>in which</p> <p>in which</p>
<div class="math"> <div class="math">
\[\begin{split}smooth_{L1}(x) = \begin{cases} 0.5x^2&amp; \text{if} \ |x| &lt; 1 \\ |x|-0.5&amp; \text{otherwise} \end{cases}\end{split}\]</div> \[\begin{split}smooth_{L1}(x) = \begin{cases} 0.5x^2&amp; \text{if} \ |x| &lt; 1 \\ |x|-0.5&amp; \text{otherwise} \end{cases}\end{split}\]</div>
<p>More details can be found by referring to <a class="reference external" href="https://arxiv.org/pdf/1504.08083v2.pdf">Fast R-CNN</a></p> <dl class="docutils">
<dt>Reference:</dt>
<dd>Fast R-CNN
<a class="reference external" href="https://arxiv.org/pdf/1504.08083v2.pdf">https://arxiv.org/pdf/1504.08083v2.pdf</a></dd>
</dl>
<p>The example usage is:</p> <p>The example usage is:</p>
<div class="highlight-python"><div class="highlight"><pre><span></span><span class="n">cost</span> <span class="o">=</span> <span class="n">smooth_l1_cost</span><span class="p">(</span><span class="nb">input</span><span class="o">=</span><span class="nb">input</span><span class="p">,</span> <div class="highlight-python"><div class="highlight"><pre><span></span><span class="n">cost</span> <span class="o">=</span> <span class="n">smooth_l1_cost</span><span class="p">(</span><span class="nb">input</span><span class="o">=</span><span class="nb">input</span><span class="p">,</span>
<span class="n">label</span><span class="o">=</span><span class="n">label</span><span class="p">)</span> <span class="n">label</span><span class="o">=</span><span class="n">label</span><span class="p">)</span>
...@@ -3976,9 +3975,11 @@ size of input and label are equal. The formula is as follows,</p> ...@@ -3976,9 +3975,11 @@ size of input and label are equal. The formula is as follows,</p>
<tr class="field-odd field"><th class="field-name">参数:</th><td class="field-body"><ul class="first simple"> <tr class="field-odd field"><th class="field-name">参数:</th><td class="field-body"><ul class="first simple">
<li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input layer.</li> <li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input layer.</li>
<li><strong>label</strong> &#8211; The input label.</li> <li><strong>label</strong> &#8211; The input label.</li>
<li><strong>name</strong> (<em>None | basestring</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>coeff</strong> (<em>float</em>) &#8211; The coefficient affects the gradient in the backward.</li> <li><strong>coeff</strong> (<em>float</em>) &#8211; The weight of the gradient in the back propagation.
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; Extra Layer Attribute.</li> 1.0 is the default.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute</em>) &#8211; The extra layer attribute. See paddle.v2.attr.ExtraAttribute for
details.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
...@@ -4106,7 +4107,7 @@ It is used by recurrent layer group.</p> ...@@ -4106,7 +4107,7 @@ It is used by recurrent layer group.</p>
<dl class="class"> <dl class="class">
<dt> <dt>
<em class="property">class </em><code class="descclassname">paddle.v2.layer.</code><code class="descname">prelu</code></dt> <em class="property">class </em><code class="descclassname">paddle.v2.layer.</code><code class="descname">prelu</code></dt>
<dd><p>The Parameter Relu activation that actives outputs with a learnable weight.</p> <dd><p>The Parametric Relu activation that actives outputs with a learnable weight.</p>
<dl class="docutils"> <dl class="docutils">
<dt>Reference:</dt> <dt>Reference:</dt>
<dd>Delving Deep into Rectifiers: Surpassing Human-Level Performance on <dd>Delving Deep into Rectifiers: Surpassing Human-Level Performance on
...@@ -4126,15 +4127,16 @@ a_i * z_i &amp;\quad \mathrm{otherwise}\end{split}\]</div> ...@@ -4126,15 +4127,16 @@ a_i * z_i &amp;\quad \mathrm{otherwise}\end{split}\]</div>
<tr class="field-odd field"><th class="field-name">参数:</th><td class="field-body"><ul class="first simple"> <tr class="field-odd field"><th class="field-name">参数:</th><td class="field-body"><ul class="first simple">
<li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input of this layer.</li> <li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input of this layer.</li>
<li><strong>partial_sum</strong> (<em>int</em>) &#8211; <p>this parameter makes a group of inputs share a same weight.</p> <li><strong>partial_sum</strong> (<em>int</em>) &#8211; <p>this parameter makes a group of inputs share the same weight.</p>
<ul> <ul>
<li>partial_sum = 1, indicates the element-wise activation: each element has a weight.</li> <li>partial_sum = 1, indicates the element-wise activation: each element has a weight.</li>
<li>partial_sum = number of elements in one channel, indicates the channel-wise activation, elements in a channel share a same weight.</li> <li>partial_sum = number of elements in one channel, indicates the channel-wise activation, elements in a channel share the same weight.</li>
<li>partial_sum = number of outputs, indicates all elements share a same weight.</li> <li>partial_sum = number of outputs, indicates all elements share the same weight.</li>
</ul> </ul>
</li> </li>
<li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None</em>) &#8211; The parameter attribute. See paddle.v2.attr.ParameterAttribute for details.</li> <li><strong>param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The parameter attribute. See paddle.v2.attr.ParameterAttribute for details.</li>
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra layer configurations. Default is None.</li> <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; The extra layer attribute. See paddle.v2.attr.ExtraAttribute for
details.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
...@@ -4172,25 +4174,25 @@ product between <a href="#id11"><span class="problematic" id="id12">:match:`X&#8 ...@@ -4172,25 +4174,25 @@ product between <a href="#id11"><span class="problematic" id="id12">:match:`X&#8
<tbody valign="top"> <tbody valign="top">
<tr class="field-odd field"><th class="field-name">参数:</th><td class="field-body"><ul class="first simple"> <tr class="field-odd field"><th class="field-name">参数:</th><td class="field-body"><ul class="first simple">
<li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input of this layer.</li> <li><strong>input</strong> (<em>paddle.v2.config_base.Layer</em>) &#8211; The input of this layer.</li>
<li><strong>size</strong> (<em>int</em>) &#8211; output size of the gated unit.</li> <li><strong>size</strong> (<em>int</em>) &#8211; The dimension of this layer&#8217;s output.</li>
<li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type of the projected input. paddle.v2.activation.Linear is the default.</li> <li><strong>act</strong> (<em>paddle.v2.activation.Base</em>) &#8211; Activation type of the projection. paddle.v2.activation.Linear is the default.</li>
<li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li> <li><strong>name</strong> (<em>basestring</em>) &#8211; The name of this layer. It is optional.</li>
<li><strong>gate_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Attributes to tune the gate output, for example, error <li><strong>gate_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; The extra layer attribute of the gate. See paddle.v2.attr.ExtraAttribute for
clipping threshold, dropout and so on. See paddle.v2.attr.ExtraAttribute for details.</li>
more details.</li> <li><strong>gate_param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The parameter attribute of the gate. See paddle.v2.attr.ParameterAttribute
<li><strong>gate_param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None</em>) &#8211; Attributes to tune the learnable projected matrix for details.</li>
parameter of the gate.</li> <li><strong>gate_bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | bool | None | Any</em>) &#8211; The bias attribute of the gate. If the parameter is set to False or
<li><strong>gate_bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None</em>) &#8211; Attributes to tune the learnable bias of the gate.</li> an object whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined.
<li><strong>inproj_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Attributes to the tune the projected input, for If the parameter is set to True, the bias is initialized to zero.</li>
example, error clipping threshold, dropout and so on. See <li><strong>inproj_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra layer attributes of the projection. See paddle.v2.attr.ExtraAttribute for
paddle.v2.attr.ExtraAttribute for more details.</li> details.</li>
<li><strong>inproj_param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None</em>) &#8211; Attributes to tune the learnable parameter of <li><strong>inproj_param_attr</strong> (<em>paddle.v2.attr.ParameterAttribute</em>) &#8211; The parameter attribute of the projection. See paddle.v2.attr.ParameterAttribute
the projection of input.</li> for details.</li>
<li><strong>inproj_bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | None</em>) &#8211; Attributes to tune the learnable bias of <li><strong>inproj_bias_attr</strong> (<em>paddle.v2.attr.ParameterAttribute | bool | None | Any</em>) &#8211; The bias attribute of the projection. If the parameter is set to False
projection of the input.</li> or an object whose type is not paddle.v2.attr.ParameterAttribute, no bias is defined.
<li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Attributes to tune the final output of the gated unit, If the parameter is set to True, the bias is initialized to zero.</li>
for example, error clipping threshold, dropout and so on. See <li><strong>layer_attr</strong> (<em>paddle.v2.attr.ExtraAttribute | None</em>) &#8211; Extra layer attribute of the product. See paddle.v2.attr.ExtraAttribute for
paddle.v2.attr.ExtraAttribute for more details.</li> details.</li>
</ul> </ul>
</td> </td>
</tr> </tr>
......
因为 它太大了无法显示 source diff 。你可以改为 查看blob
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册