From 076581999066860606cd37c18ff972898e75c67f Mon Sep 17 00:00:00 2001 From: Travis CI Date: Tue, 7 Mar 2017 21:05:24 +0000 Subject: [PATCH] Deploy to GitHub Pages: aaa2a1f8443bbc1ff06627dcf1ab4574d08e08ea --- develop/doc/_sources/api/v2/run_logic.rst.txt | 8 +++ develop/doc/api/v2/run_logic.html | 46 ++++++++++++++++++ develop/doc/genindex.html | 6 ++- develop/doc/objects.inv | Bin 3281 -> 3286 bytes develop/doc/searchindex.js | 2 +- .../doc_cn/_sources/api/v2/run_logic.rst.txt | 8 +++ develop/doc_cn/api/v2/run_logic.html | 46 ++++++++++++++++++ develop/doc_cn/genindex.html | 6 ++- develop/doc_cn/objects.inv | Bin 3782 -> 3788 bytes develop/doc_cn/searchindex.js | 2 +- 10 files changed, 118 insertions(+), 6 deletions(-) diff --git a/develop/doc/_sources/api/v2/run_logic.rst.txt b/develop/doc/_sources/api/v2/run_logic.rst.txt index 904d45966d..0f807873ff 100644 --- a/develop/doc/_sources/api/v2/run_logic.rst.txt +++ b/develop/doc/_sources/api/v2/run_logic.rst.txt @@ -2,6 +2,7 @@ Trainer API ########### + ========== Parameters ========== @@ -24,3 +25,10 @@ Event .. automodule:: paddle.v2.event :members: + + +========= +Inference +========= + +.. autofunction:: paddle.v2.infer \ No newline at end of file diff --git a/develop/doc/api/v2/run_logic.html b/develop/doc/api/v2/run_logic.html index 240266f1be..07784807d1 100644 --- a/develop/doc/api/v2/run_logic.html +++ b/develop/doc/api/v2/run_logic.html @@ -171,6 +171,7 @@
  • Parameters
  • Trainer
  • Event
  • +
  • Inference
  • @@ -496,6 +497,51 @@ index that reader returns.

    Event On One Batch Training Complete.

    + +
    +

    Inference

    +
    +
    +paddle.v2.infer(output, parameters, input=None, batch_size=None, reader=None, feeding=None, field='value')
    +

    Infer a neural network by given neural network output and parameters. The +user should pass either a batch of input data or reader method.

    +

    Example usages:

    +
    result = paddle.infer(prediction, parameters, input=SomeData,
    +                      batch_size=32)
    +print result
    +
    +
    + +++ + + + + + + + +
    Parameters:
      +
    • output (paddle.v2.config_base.Layer) – output of the neural network that would be inferred
    • +
    • parameters (paddle.v2.parameters.Parameters) – parameters of the neural network.
    • +
    • input (collections.Iterable) – input data batch. Should be a python iterable object, and each +element is the data batch.
    • +
    • batch_size (int) – the batch size when perform inference. Default is the +length of input.
    • +
    • reader (callable) – input data reader creator in batch. If this field is set, the +input and batch_size will be ignored.
    • +
    • feeding – Reader dictionary. Default could generate from input +value.
    • +
    • field (str) – The prediction field. It should in [value, ids]. value +means return the prediction probabilities, ids means return +the prediction labels. Default is value
    • +
    +
    Returns:

    a numpy array

    +
    Return type:

    numpy.ndarray

    +
    +
    +
    diff --git a/develop/doc/genindex.html b/develop/doc/genindex.html index 2c151ec5d7..13a54c2851 100644 --- a/develop/doc/genindex.html +++ b/develop/doc/genindex.html @@ -437,11 +437,13 @@
  • img_conv_bn_pool (class in paddle.v2.networks)
  • - - + @@ -503,6 +504,51 @@ index that reader returns.

    Event On One Batch Training Complete.

    + +
    +

    Inference

    +
    +
    +paddle.v2.infer(output, parameters, input=None, batch_size=None, reader=None, feeding=None, field='value')
    +

    Infer a neural network by given neural network output and parameters. The +user should pass either a batch of input data or reader method.

    +

    Example usages:

    +
    result = paddle.infer(prediction, parameters, input=SomeData,
    +                      batch_size=32)
    +print result
    +
    +
    + +++ + + + + + + + +
    参数:
      +
    • output (paddle.v2.config_base.Layer) – output of the neural network that would be inferred
    • +
    • parameters (paddle.v2.parameters.Parameters) – parameters of the neural network.
    • +
    • input (collections.Iterable) – input data batch. Should be a python iterable object, and each +element is the data batch.
    • +
    • batch_size (int) – the batch size when perform inference. Default is the +length of input.
    • +
    • reader (callable) – input data reader creator in batch. If this field is set, the +input and batch_size will be ignored.
    • +
    • feeding – Reader dictionary. Default could generate from input +value.
    • +
    • field (str) – The prediction field. It should in [value, ids]. value +means return the prediction probabilities, ids means return +the prediction labels. Default is value
    • +
    +
    返回:

    a numpy array

    +
    返回类型:

    numpy.ndarray

    +
    +
    +
    diff --git a/develop/doc_cn/genindex.html b/develop/doc_cn/genindex.html index 5583e80e4b..b4307250c1 100644 --- a/develop/doc_cn/genindex.html +++ b/develop/doc_cn/genindex.html @@ -444,11 +444,13 @@
  • img_conv_bn_pool (paddle.v2.networks 中的类)
  • - - +