Added: websites/staging/singa/trunk/content/v0.3.0/zh/neural-net.html ============================================================================== --- websites/staging/singa/trunk/content/v0.3.0/zh/neural-net.html (added) +++ websites/staging/singa/trunk/content/v0.3.0/zh/neural-net.html Wed Apr 20 05:12:03 2016 @@ -0,0 +1,573 @@ +<!DOCTYPE html> +<!-- + | Generated by Apache Maven Doxia at 2016-04-20 + | Rendered using Apache Maven Fluido Skin 1.4 +--> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> + <head> + <meta charset="UTF-8" /> + <meta name="viewport" content="width=device-width, initial-scale=1.0" /> + <meta name="Date-Revision-yyyymmdd" content="20160420" /> + <meta http-equiv="Content-Language" content="en" /> + <title>Apache SINGA – Neural Net</title> + <link rel="stylesheet" href="../../css/apache-maven-fluido-1.4.min.css" /> + <link rel="stylesheet" href="../../css/site.css" /> + <link rel="stylesheet" href="../../css/print.css" media="print" /> + + + + + + <script type="text/javascript" src="../../js/apache-maven-fluido-1.4.min.js"></script> + + + +<script src="https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML" type="text/javascript"></script> + + +<script type="text/x-mathjax-config">MathJax.Hub.Config({tex2jax: {inlineMath: [['$','$'], ['\\(','\\)']]}});</script> + + +<meta content="Apache SINGA" name="author"/> + + +<meta content="SINGA, Deep Learning, Distributed training" name="keywords"/> + + </head> + <body class="topBarEnabled"> + + + + + + + <a href="https://github.com/apache/incubator-singa"> + <img style="position: absolute; top: 0; right: 0; border: 0; z-index: 10000;" + src="https://s3.amazonaws.com/github/ribbons/forkme_right_orange_ff7600.png" + alt="Fork me on GitHub"> + </a> + + + + + + <div id="topbar" class="navbar navbar-fixed-top navbar-inverse"> + <div class="navbar-inner"> + <div class="container-fluid"> + <a data-target=".nav-collapse" data-toggle="collapse" class="btn btn-navbar"> + <span class="icon-bar"></span> + <span class="icon-bar"></span> + <span class="icon-bar"></span> + </a> + + <ul class="nav"> + <li class="dropdown"> + <a href="#" class="dropdown-toggle" data-toggle="dropdown">Apache SINGA <b class="caret"></b></a> + <ul class="dropdown-menu"> + + <li> <a href="../../docs/overview.html" title="Introduction">Introduction</a> +</li> + + <li> <a href="../../docs/quick-start.html" title="Quick Start">Quick Start</a> +</li> + + <li> <a href="../../downloads.html" title="Downloads">Downloads</a> +</li> + </ul> + </li> + <li class="dropdown"> + <a href="#" class="dropdown-toggle" data-toggle="dropdown">Documentaion <b class="caret"></b></a> + <ul class="dropdown-menu"> + + <li class="dropdown-submenu"> + <a href="../../docs/index.html" title="v0.3.0">v0.3.0</a> + <ul class="dropdown-menu"> + <li> <a href="../../docs/index.html" title="English">English</a> +</li> + <li> <a href="../../docs/zh/index.html" title="䏿">䏿</a> +</li> + <li> <a href="../../docs/jp/index.html" title="æ¥æ¬èª">æ¥æ¬èª</a> +</li> + <li> <a href="../../docs/kr/index.html" title="íêµì´">íêµì´</a> +</li> + </ul> + </li> + + <li> <a href="../../v0.2.0/index.html" title="v0.2.0">v0.2.0</a> +</li> + + <li> <a href="../../v0.1.0/index.html" title="v0.1.0">v0.1.0</a> +</li> + </ul> + </li> + <li class="dropdown"> + <a href="#" class="dropdown-toggle" data-toggle="dropdown">Development <b class="caret"></b></a> + <ul class="dropdown-menu"> + + <li> <a href="../../develop/schedule.html" title="Schedule">Schedule</a> +</li> + + <li class="dropdown-submenu"> + <a href="../../develop/how-contribute.html" title="How to Contribute">How to Contribute</a> + <ul class="dropdown-menu"> + <li> <a href="../../develop/contribute-code.html" title="Code">Code</a> +</li> + <li> <a href="../../develop/contribute-docs.html" title="Documentation">Documentation</a> +</li> + </ul> + </li> + </ul> + </li> + <li class="dropdown"> + <a href="#" class="dropdown-toggle" data-toggle="dropdown">Community <b class="caret"></b></a> + <ul class="dropdown-menu"> + + <li> <a href="../../community/source-repository.html" title="Source Repository">Source Repository</a> +</li> + + <li> <a href="../../community/mail-lists.html" title="Mailing Lists">Mailing Lists</a> +</li> + + <li> <a href="../../community/issue-tracking.html" title="Issue Tracking">Issue Tracking</a> +</li> + + <li> <a href="../../community/team-list.html" title="SINGA Team">SINGA Team</a> +</li> + </ul> + </li> + <li class="dropdown"> + <a href="#" class="dropdown-toggle" data-toggle="dropdown">External Links <b class="caret"></b></a> + <ul class="dropdown-menu"> + + <li> <a href="http://www.apache.org/" title="Apache Software Foundation">Apache Software Foundation</a> +</li> + + <li> <a href="http://www.comp.nus.edu.sg/~dbsystem/singa/" title="NUS Site">NUS Site</a> +</li> + </ul> + </li> + </ul> + + + + + </div> + + </div> + </div> + </div> + + <div class="container-fluid"> + <div id="banner"> + <div class="pull-left"> + <a href="../../index.html" id="bannerLeft" title="Apache SINGA"> + <img src="../../images/singa-logo.png" alt="Apache SINGA"/> + </a> + </div> + <div class="pull-right"> <div id="bannerRight"> + <img src="../../images/singa-title.png" alt="Apache SINGA"/> + </div> + </div> + <div class="clear"><hr/></div> + </div> + + <div id="breadcrumbs"> + <ul class="breadcrumb"> + + + <li class=""> + <a href="../../index.html" title="Apache SINGA"> + Apache SINGA</a> + <span class="divider">/</span> + </li> + <li class="active ">Neural Net</li> + + + + + </ul> + </div> + + + <div class="row-fluid"> + <div id="leftColumn" class="span2"> + <div class="well sidebar-nav"> + + + <ul class="nav nav-list"> + <li class="nav-header">Apache SINGA</li> + + <li> + + <a href="../../docs/overview.html" title="Introduction"> + <span class="none"></span> + Introduction</a> + </li> + + <li> + + <a href="../../docs/quick-start.html" title="Quick Start"> + <span class="none"></span> + Quick Start</a> + </li> + + <li> + + <a href="../../downloads.html" title="Downloads"> + <span class="none"></span> + Downloads</a> + </li> + <li class="nav-header">Documentaion</li> + + <li> + + <a href="../../docs/index.html" title="v0.3.0"> + <span class="icon-chevron-right"></span> + v0.3.0</a> + </li> + + <li> + + <a href="../../v0.2.0/index.html" title="v0.2.0"> + <span class="none"></span> + v0.2.0</a> + </li> + + <li> + + <a href="../../v0.1.0/index.html" title="v0.1.0"> + <span class="none"></span> + v0.1.0</a> + </li> + <li class="nav-header">Development</li> + + <li> + + <a href="../../develop/schedule.html" title="Schedule"> + <span class="none"></span> + Schedule</a> + </li> + + <li> + + <a href="../../develop/how-contribute.html" title="How to Contribute"> + <span class="icon-chevron-right"></span> + How to Contribute</a> + </li> + <li class="nav-header">Community</li> + + <li> + + <a href="../../community/source-repository.html" title="Source Repository"> + <span class="none"></span> + Source Repository</a> + </li> + + <li> + + <a href="../../community/mail-lists.html" title="Mailing Lists"> + <span class="none"></span> + Mailing Lists</a> + </li> + + <li> + + <a href="../../community/issue-tracking.html" title="Issue Tracking"> + <span class="none"></span> + Issue Tracking</a> + </li> + + <li> + + <a href="../../community/team-list.html" title="SINGA Team"> + <span class="none"></span> + SINGA Team</a> + </li> + <li class="nav-header">External Links</li> + + <li> + + <a href="http://www.apache.org/" class="externalLink" title="Apache Software Foundation"> + <span class="none"></span> + Apache Software Foundation</a> + </li> + + <li> + + <a href="http://www.comp.nus.edu.sg/~dbsystem/singa/" class="externalLink" title="NUS Site"> + <span class="none"></span> + NUS Site</a> + </li> + </ul> + + + + <hr /> + + <div id="poweredBy"> + <div class="clear"></div> + <div class="clear"></div> + <div class="clear"></div> + <div class="clear"></div> + <a href="http://incubator.apache.org" title="apache-incubator" class="builtBy"> + <img class="builtBy" alt="Apache Incubator" src="http://incubator.apache.org/images/egg-logo.png" /> + </a> + </div> + </div> + </div> + + + <div id="bodyColumn" class="span10" > + + <h1>Neural Net</h1> +<hr /> +<p><tt>NeuralNet</tt> in SINGA represents an instance of user’s neural net model. As the neural net typically consists of a set of layers, <tt>NeuralNet</tt> comprises a set of unidirectionally connected <a href="layer.html">Layer</a>s. This page describes how to convert an user’s neural net into the configuration of <tt>NeuralNet</tt>.</p> +<p><img src="../images/model-category.png" align="center" width="200px" alt="" /> <span><b>Figure 1 - Categorization of popular deep learning models.</b></span></p> +<div class="section"> +<h2><a name="Net_structure_configuration"></a>Net structure configuration</h2> +<p>Users configure the <tt>NeuralNet</tt> by listing all layers of the neural net and specifying each layer’s source layer names. Popular deep learning models can be categorized as Figure 1. The subsequent sections give details for each category.</p> +<div class="section"> +<h3><a name="Feed-forward_models"></a>Feed-forward models</h3> + +<div align="left"> +<img src="../images/mlp-net.png" align="center" width="200px" alt="" /> +<span><b>Figure 2 - Net structure of a MLP model.</b></span> +</div> +<p>Feed-forward models, e.g., CNN and MLP, can easily get configured as their layer connections are undirected without circles. The configuration for the MLP model shown in Figure 1 is as follows,</p> + +<div class="source"> +<div class="source"><pre class="prettyprint">net { + layer { + name : 'data" + type : kData + } + layer { + name : 'image" + type : kImage + srclayer: 'data' + } + layer { + name : 'label" + type : kLabel + srclayer: 'data' + } + layer { + name : 'hidden" + type : kHidden + srclayer: 'image' + } + layer { + name : 'softmax" + type : kSoftmaxLoss + srclayer: 'hidden' + srclayer: 'label' + } +} +</pre></div></div></div> +<div class="section"> +<h3><a name="Energy_models"></a>Energy models</h3> +<p><img src="../images/rbm-rnn.png" align="center" width="500px" alt="" /> <span><b>Figure 3 - Convert connections in RBM and RNN.</b></span></p> +<p>For energy models including RBM, DBM, etc., their connections are undirected (i.e., Category B). To represent these models using <tt>NeuralNet</tt>, users can simply replace each connection with two directed connections, as shown in Figure 3a. In other words, for each pair of connected layers, their source layer field should include each other’s name. The full <a href="rbm.html">RBM example</a> has detailed neural net configuration for a RBM model, which looks like</p> + +<div class="source"> +<div class="source"><pre class="prettyprint">net { + layer { + name : "vis" + type : kVisLayer + param { + name : "w1" + } + srclayer: "hid" + } + layer { + name : "hid" + type : kHidLayer + param { + name : "w2" + share_from: "w1" + } + srclayer: "vis" + } +} +</pre></div></div></div> +<div class="section"> +<h3><a name="RNN_models"></a>RNN models</h3> +<p>For recurrent neural networks (RNN), users can remove the recurrent connections by unrolling the recurrent layer. For example, in Figure 3b, the original layer is unrolled into a new layer with 4 internal layers. In this way, the model is like a normal feed-forward model, thus can be configured similarly. The <a href="rnn.html">RNN example</a> has a full neural net configuration for a RNN model.</p></div></div> +<div class="section"> +<h2><a name="Configuration_for_multiple_nets"></a>Configuration for multiple nets</h2> +<p>Typically, a training job includes three neural nets for training, validation and test phase respectively. The three neural nets share most layers except the data layer, loss layer or output layer, etc.. To avoid redundant configurations for the shared layers, users can uses the <tt>exclude</tt> filed to filter a layer in the neural net, e.g., the following layer will be filtered when creating the testing <tt>NeuralNet</tt>.</p> + +<div class="source"> +<div class="source"><pre class="prettyprint">layer { + ... + exclude : kTest # filter this layer for creating test net +} +</pre></div></div></div> +<div class="section"> +<h2><a name="Neural_net_partitioning"></a>Neural net partitioning</h2> +<p>A neural net can be partitioned in different ways to distribute the training over multiple workers.</p> +<div class="section"> +<h3><a name="Batch_and_feature_dimension"></a>Batch and feature dimension</h3> +<p><img src="../images/partition_fc.png" align="center" width="400px" alt="" /> <span><b>Figure 4 - Partitioning of a fully connected layer.</b></span></p> +<p>Every layer’s feature blob is considered a matrix whose rows are feature vectors. Thus, one layer can be split on two dimensions. Partitioning on dimension 0 (also called batch dimension) slices the feature matrix by rows. For instance, if the mini-batch size is 256 and the layer is partitioned into 2 sub-layers, each sub-layer would have 128 feature vectors in its feature blob. Partitioning on this dimension has no effect on the parameters, as every <a href="param.html">Param</a> object is replicated in the sub-layers. Partitioning on dimension 1 (also called feature dimension) slices the feature matrix by columns. For example, suppose the original feature vector has 50 units, after partitioning into 2 sub-layers, each sub-layer would have 25 units. This partitioning may result in <a href="param.html">Param</a> object being split, as shown in Figure 4. Both the bias vector and weight matrix are partitioned into two sub-layers.</p></div> +<div class="section"> +<h3><a name="Partitioning_configuration"></a>Partitioning configuration</h3> +<p>There are 4 partitioning schemes, whose configurations are give below,</p> + +<ol style="list-style-type: decimal"> + +<li> +<p>Partitioning each singe layer into sub-layers on batch dimension (see below). It is enabled by configuring the partition dimension of the layer to 0, e.g.,</p> + +<div class="source"> +<div class="source"><pre class="prettyprint"> # with other fields omitted + layer { + partition_dim: 0 + } +</pre></div></div></li> + +<li> +<p>Partitioning each singe layer into sub-layers on feature dimension (see below). It is enabled by configuring the partition dimension of the layer to 1, e.g.,</p> + +<div class="source"> +<div class="source"><pre class="prettyprint"> # with other fields omitted + layer { + partition_dim: 1 + } +</pre></div></div></li> + +<li> +<p>Partitioning all layers into different subsets. It is enabled by configuring the location ID of a layer, e.g.,</p> + +<div class="source"> +<div class="source"><pre class="prettyprint"> # with other fields omitted + layer { + location: 1 + } + layer { + location: 0 + } +</pre></div></div></li> +</ol> + +<ol style="list-style-type: decimal"> + +<li> +<p>Hybrid partitioning of strategy 1, 2 and 3. The hybrid partitioning is useful for large models. An example application is to implement the <a class="externalLink" href="http://arxiv.org/abs/1404.5997">idea proposed by Alex</a>. Hybrid partitioning is configured like,</p> + +<div class="source"> +<div class="source"><pre class="prettyprint"> # with other fields omitted + layer { + location: 1 + } + layer { + location: 0 + } + layer { + partition_dim: 0 + location: 0 + } + layer { + partition_dim: 1 + location: 0 + } +</pre></div></div></li> +</ol> +<p>Currently SINGA supports strategy-2 well. Other partitioning strategies are are under test and will be released in later version.</p></div></div> +<div class="section"> +<h2><a name="Parameter_sharing"></a>Parameter sharing</h2> +<p>Parameters can be shared in two cases,</p> + +<ul> + +<li> +<p>sharing parameters among layers via user configuration. For example, the visible layer and hidden layer of a RBM shares the weight matrix, which is configured through the <tt>share_from</tt> field as shown in the above RBM configuration. The configurations must be the same (except name) for shared parameters.</p></li> + +<li> +<p>due to neural net partitioning, some <tt>Param</tt> objects are replicated into different workers, e.g., partitioning one layer on batch dimension. These workers share parameter values. SINGA controls this kind of parameter sharing automatically, users do not need to do any configuration.</p></li> + +<li> +<p>the <tt>NeuralNet</tt> for training and testing (and validation) share most layers , thus share <tt>Param</tt> values.</p></li> +</ul> +<p>If the shared <tt>Param</tt> instances resident in the same process (may in different threads), they use the same chunk of memory space for their values. But they would have different memory spaces for their gradients. In fact, their gradients will be averaged by the stub or server.</p></div> +<div class="section"> +<h2><a name="Advanced_user_guide"></a>Advanced user guide</h2> +<div class="section"> +<h3><a name="Creation"></a>Creation</h3> + +<div class="source"> +<div class="source"><pre class="prettyprint">static NeuralNet* NeuralNet::Create(const NetProto& np, Phase phase, int num); +</pre></div></div> +<p>The above function creates a <tt>NeuralNet</tt> for a given phase, and returns a pointer to the <tt>NeuralNet</tt> instance. The phase is in {kTrain, kValidation, kTest}. <tt>num</tt> is used for net partitioning which indicates the number of partitions. Typically, a training job includes three neural nets for training, validation and test phase respectively. The three neural nets share most layers except the data layer, loss layer or output layer, etc.. The <tt>Create</tt> function takes in the full net configuration including layers for training, validation and test. It removes layers for phases other than the specified phase based on the <tt>exclude</tt> field in <a href="layer.html">layer configuration</a>:</p> + +<div class="source"> +<div class="source"><pre class="prettyprint">layer { + ... + exclude : kTest # filter this layer for creating test net +} +</pre></div></div> +<p>The filtered net configuration is passed to the constructor of <tt>NeuralNet</tt>:</p> + +<div class="source"> +<div class="source"><pre class="prettyprint">NeuralNet::NeuralNet(NetProto netproto, int npartitions); +</pre></div></div> +<p>The constructor creates a graph representing the net structure firstly in</p> + +<div class="source"> +<div class="source"><pre class="prettyprint">Graph* NeuralNet::CreateGraph(const NetProto& netproto, int npartitions); +</pre></div></div> +<p>Next, it creates a layer for each node and connects layers if their nodes are connected.</p> + +<div class="source"> +<div class="source"><pre class="prettyprint">void NeuralNet::CreateNetFromGraph(Graph* graph, int npartitions); +</pre></div></div> +<p>Since the <tt>NeuralNet</tt> instance may be shared among multiple workers, the <tt>Create</tt> function returns a pointer to the <tt>NeuralNet</tt> instance .</p></div> +<div class="section"> +<h3><a name="Parameter_sharing"></a>Parameter sharing</h3> +<p><tt>Param</tt> sharing is enabled by first sharing the Param configuration (in <tt>NeuralNet::Create</tt>) to create two similar (e.g., the same shape) Param objects, and then calling (in <tt>NeuralNet::CreateNetFromGraph</tt>),</p> + +<div class="source"> +<div class="source"><pre class="prettyprint">void Param::ShareFrom(const Param& from); +</pre></div></div> +<p>It is also possible to share <tt>Param</tt>s of two nets, e.g., sharing parameters of the training net and the test net,</p> + +<div class="source"> +<div class="source"><pre class="prettyprint">void NeuralNet:ShareParamsFrom(NeuralNet* other); +</pre></div></div> +<p>It will call <tt>Param::ShareFrom</tt> for each Param object.</p></div> +<div class="section"> +<h3><a name="Access_functions"></a>Access functions</h3> +<p><tt>NeuralNet</tt> provides a couple of access function to get the layers and params of the net:</p> + +<div class="source"> +<div class="source"><pre class="prettyprint">const std::vector<Layer*>& layers() const; +const std::vector<Param*>& params() const ; +Layer* name2layer(string name) const; +Param* paramid2param(int id) const; +</pre></div></div></div> +<div class="section"> +<h3><a name="Partitioning"></a>Partitioning</h3> +<div class="section"> +<h4><a name="Implementation"></a>Implementation</h4> +<p>SINGA partitions the neural net in <tt>CreateGraph</tt> function, which creates one node for each (partitioned) layer. For example, if one layer’s partition dimension is 0 or 1, then it creates <tt>npartition</tt> nodes for it; if the partition dimension is -1, a single node is created, i.e., no partitioning. Each node is assigned a partition (or location) ID. If the original layer is configured with a location ID, then the ID is assigned to each newly created node. These nodes are connected according to the connections of the original layers. Some connection layers will be added automatically. For instance, if two connected sub-layers are located at two different workers, then a pair of bridge layers is inserted to transfer the feature (and gradient) blob between them. When two layers are partitioned on different dimensions, a concatenation layer which concatenates feature rows (or columns) and a slice layer which slices feature rows (or columns) would be inserted. These connection layers help making the network communication and synchronization transparent to the users.</p></div> +<div class="section"> +<h4><a name="Dispatching_partitions_to_workers"></a>Dispatching partitions to workers</h4> +<p>Each (partitioned) layer is assigned a location ID, based on which it is dispatched to one worker. Particularly, the pointer to the <tt>NeuralNet</tt> instance is passed to every worker within the same group, but each worker only computes over the layers that have the same partition (or location) ID as the worker’s ID. When every worker computes the gradients of the entire model parameters (strategy-2), we refer to this process as data parallelism. When different workers compute the gradients of different parameters (strategy-3 or strategy-1), we call this process model parallelism. The hybrid partitioning leads to hybrid parallelism where some workers compute the gradients of the same subset of model parameters while other workers compute on different model parameters. For example, to implement the hybrid parallelism in for the <a class="externalLink" href="http://arxiv.org/abs/1404.5997">DCNN model</a>, we set <tt>partition_dim = 0</tt> for lower layers and <tt>partition _dim = 1</tt> for higher layers.</p></div></div></div> + </div> + </div> + </div> + + <hr/> + + <footer> + <div class="container-fluid"> + <div class="row-fluid"> + +<p>Copyright © 2015 The Apache Software Foundation. All rights reserved. Apache Singa, Apache, the Apache feather logo, and the Apache Singa project logos are trademarks of The Apache Software Foundation. All other marks mentioned may be trademarks or registered trademarks of their respective owners.</p> + </div> + + + </div> + </footer> + </body> +</html>
Added: websites/staging/singa/trunk/content/v0.3.0/zh/overview.html ============================================================================== --- websites/staging/singa/trunk/content/v0.3.0/zh/overview.html (added) +++ websites/staging/singa/trunk/content/v0.3.0/zh/overview.html Wed Apr 20 05:12:03 2016 @@ -0,0 +1,371 @@ +<!DOCTYPE html> +<!-- + | Generated by Apache Maven Doxia at 2016-04-20 + | Rendered using Apache Maven Fluido Skin 1.4 +--> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> + <head> + <meta charset="UTF-8" /> + <meta name="viewport" content="width=device-width, initial-scale=1.0" /> + <meta name="Date-Revision-yyyymmdd" content="20160420" /> + <meta http-equiv="Content-Language" content="en" /> + <title>Apache SINGA – ç®ä»</title> + <link rel="stylesheet" href="../../css/apache-maven-fluido-1.4.min.css" /> + <link rel="stylesheet" href="../../css/site.css" /> + <link rel="stylesheet" href="../../css/print.css" media="print" /> + + + + + + <script type="text/javascript" src="../../js/apache-maven-fluido-1.4.min.js"></script> + + + +<script src="https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML" type="text/javascript"></script> + + +<script type="text/x-mathjax-config">MathJax.Hub.Config({tex2jax: {inlineMath: [['$','$'], ['\\(','\\)']]}});</script> + + +<meta content="Apache SINGA" name="author"/> + + +<meta content="SINGA, Deep Learning, Distributed training" name="keywords"/> + + </head> + <body class="topBarEnabled"> + + + + + + + <a href="https://github.com/apache/incubator-singa"> + <img style="position: absolute; top: 0; right: 0; border: 0; z-index: 10000;" + src="https://s3.amazonaws.com/github/ribbons/forkme_right_orange_ff7600.png" + alt="Fork me on GitHub"> + </a> + + + + + + <div id="topbar" class="navbar navbar-fixed-top navbar-inverse"> + <div class="navbar-inner"> + <div class="container-fluid"> + <a data-target=".nav-collapse" data-toggle="collapse" class="btn btn-navbar"> + <span class="icon-bar"></span> + <span class="icon-bar"></span> + <span class="icon-bar"></span> + </a> + + <ul class="nav"> + <li class="dropdown"> + <a href="#" class="dropdown-toggle" data-toggle="dropdown">Apache SINGA <b class="caret"></b></a> + <ul class="dropdown-menu"> + + <li> <a href="../../docs/overview.html" title="Introduction">Introduction</a> +</li> + + <li> <a href="../../docs/quick-start.html" title="Quick Start">Quick Start</a> +</li> + + <li> <a href="../../downloads.html" title="Downloads">Downloads</a> +</li> + </ul> + </li> + <li class="dropdown"> + <a href="#" class="dropdown-toggle" data-toggle="dropdown">Documentaion <b class="caret"></b></a> + <ul class="dropdown-menu"> + + <li class="dropdown-submenu"> + <a href="../../docs/index.html" title="v0.3.0">v0.3.0</a> + <ul class="dropdown-menu"> + <li> <a href="../../docs/index.html" title="English">English</a> +</li> + <li> <a href="../../docs/zh/index.html" title="䏿">䏿</a> +</li> + <li> <a href="../../docs/jp/index.html" title="æ¥æ¬èª">æ¥æ¬èª</a> +</li> + <li> <a href="../../docs/kr/index.html" title="íêµì´">íêµì´</a> +</li> + </ul> + </li> + + <li> <a href="../../v0.2.0/index.html" title="v0.2.0">v0.2.0</a> +</li> + + <li> <a href="../../v0.1.0/index.html" title="v0.1.0">v0.1.0</a> +</li> + </ul> + </li> + <li class="dropdown"> + <a href="#" class="dropdown-toggle" data-toggle="dropdown">Development <b class="caret"></b></a> + <ul class="dropdown-menu"> + + <li> <a href="../../develop/schedule.html" title="Schedule">Schedule</a> +</li> + + <li class="dropdown-submenu"> + <a href="../../develop/how-contribute.html" title="How to Contribute">How to Contribute</a> + <ul class="dropdown-menu"> + <li> <a href="../../develop/contribute-code.html" title="Code">Code</a> +</li> + <li> <a href="../../develop/contribute-docs.html" title="Documentation">Documentation</a> +</li> + </ul> + </li> + </ul> + </li> + <li class="dropdown"> + <a href="#" class="dropdown-toggle" data-toggle="dropdown">Community <b class="caret"></b></a> + <ul class="dropdown-menu"> + + <li> <a href="../../community/source-repository.html" title="Source Repository">Source Repository</a> +</li> + + <li> <a href="../../community/mail-lists.html" title="Mailing Lists">Mailing Lists</a> +</li> + + <li> <a href="../../community/issue-tracking.html" title="Issue Tracking">Issue Tracking</a> +</li> + + <li> <a href="../../community/team-list.html" title="SINGA Team">SINGA Team</a> +</li> + </ul> + </li> + <li class="dropdown"> + <a href="#" class="dropdown-toggle" data-toggle="dropdown">External Links <b class="caret"></b></a> + <ul class="dropdown-menu"> + + <li> <a href="http://www.apache.org/" title="Apache Software Foundation">Apache Software Foundation</a> +</li> + + <li> <a href="http://www.comp.nus.edu.sg/~dbsystem/singa/" title="NUS Site">NUS Site</a> +</li> + </ul> + </li> + </ul> + + + + + </div> + + </div> + </div> + </div> + + <div class="container-fluid"> + <div id="banner"> + <div class="pull-left"> + <a href="../../index.html" id="bannerLeft" title="Apache SINGA"> + <img src="../../images/singa-logo.png" alt="Apache SINGA"/> + </a> + </div> + <div class="pull-right"> <div id="bannerRight"> + <img src="../../images/singa-title.png" alt="Apache SINGA"/> + </div> + </div> + <div class="clear"><hr/></div> + </div> + + <div id="breadcrumbs"> + <ul class="breadcrumb"> + + + <li class=""> + <a href="../../index.html" title="Apache SINGA"> + Apache SINGA</a> + <span class="divider">/</span> + </li> + <li class="active ">ç®ä»</li> + + + + + </ul> + </div> + + + <div class="row-fluid"> + <div id="leftColumn" class="span2"> + <div class="well sidebar-nav"> + + + <ul class="nav nav-list"> + <li class="nav-header">Apache SINGA</li> + + <li> + + <a href="../../docs/overview.html" title="Introduction"> + <span class="none"></span> + Introduction</a> + </li> + + <li> + + <a href="../../docs/quick-start.html" title="Quick Start"> + <span class="none"></span> + Quick Start</a> + </li> + + <li> + + <a href="../../downloads.html" title="Downloads"> + <span class="none"></span> + Downloads</a> + </li> + <li class="nav-header">Documentaion</li> + + <li> + + <a href="../../docs/index.html" title="v0.3.0"> + <span class="icon-chevron-right"></span> + v0.3.0</a> + </li> + + <li> + + <a href="../../v0.2.0/index.html" title="v0.2.0"> + <span class="none"></span> + v0.2.0</a> + </li> + + <li> + + <a href="../../v0.1.0/index.html" title="v0.1.0"> + <span class="none"></span> + v0.1.0</a> + </li> + <li class="nav-header">Development</li> + + <li> + + <a href="../../develop/schedule.html" title="Schedule"> + <span class="none"></span> + Schedule</a> + </li> + + <li> + + <a href="../../develop/how-contribute.html" title="How to Contribute"> + <span class="icon-chevron-right"></span> + How to Contribute</a> + </li> + <li class="nav-header">Community</li> + + <li> + + <a href="../../community/source-repository.html" title="Source Repository"> + <span class="none"></span> + Source Repository</a> + </li> + + <li> + + <a href="../../community/mail-lists.html" title="Mailing Lists"> + <span class="none"></span> + Mailing Lists</a> + </li> + + <li> + + <a href="../../community/issue-tracking.html" title="Issue Tracking"> + <span class="none"></span> + Issue Tracking</a> + </li> + + <li> + + <a href="../../community/team-list.html" title="SINGA Team"> + <span class="none"></span> + SINGA Team</a> + </li> + <li class="nav-header">External Links</li> + + <li> + + <a href="http://www.apache.org/" class="externalLink" title="Apache Software Foundation"> + <span class="none"></span> + Apache Software Foundation</a> + </li> + + <li> + + <a href="http://www.comp.nus.edu.sg/~dbsystem/singa/" class="externalLink" title="NUS Site"> + <span class="none"></span> + NUS Site</a> + </li> + </ul> + + + + <hr /> + + <div id="poweredBy"> + <div class="clear"></div> + <div class="clear"></div> + <div class="clear"></div> + <div class="clear"></div> + <a href="http://incubator.apache.org" title="apache-incubator" class="builtBy"> + <img class="builtBy" alt="Apache Incubator" src="http://incubator.apache.org/images/egg-logo.png" /> + </a> + </div> + </div> + </div> + + + <div id="bodyColumn" class="span10" > + + <h1>简介</h1> +<hr /> +<p>SINGA是一个通用的分布式深度学习平台,面向训练大规模数据集上的大型深度学习模型。其设计基于一种直观的编程模型,即深度学习中层(layer)的抽象。SINGA支持大部分深度学习模型,包括卷积神经网络(CNN)、受限波尔兹曼模型(RBM)和循环神经网络(RNN)等,为用户提供许多可直接使用&# x7684;内建层。SINGA架构灵活,支持同步训练、异步训练和混合式训练。为了并行地训练深度学习模型,SINGA支持不同的神经网络划分机制,即批次维度划分(batch dimension partition),特征维度划分(feature dimension partition)和多维度混合划分(hybrid partition)。</p> +<div class="section"> +<h2><a name="a"></a>目标</h2> +<p>作为一个分布式系统,SINGA的首要目标就是具有良好的可扩展性。换言之,SINGA希望在准确度一定的情况下,通过利用更多的计算资源(即计算机)减少模型的训练时间。</p> +<p>SINGA的另一个目标是易用性。对程序员来说,开发和训练深层的复杂结构的深度学习模型十分困难。分布式训练又进一步增加了程序员的负担,比如:数据和模型划分,网络通信等。因此,提供一个易用的编程模型是十分重要的,可以让程序员在实现自己的深度学习模型和算法时不必€ 03;虑底层的分布式平台。</p></div> +<div class="section"> +<h2><a name="a"></a>原则</h2> +<p>扩展性是分布式深度学习的重要研究问题。SINGA提供了一个利用不同训练框架扩展性的通用平台。同步训练框架可提高每次训练迭代的效率,同时异步训练框架可加快模型收敛。在预算(比如:集群规模)一定的情况下,用户可以运行一个混合训练框架,在效率和收敛速度之间权衡,N e5;取得最大的扩展性。</p> +<p>SINGA的编程模型是基于层的抽象而设计,这对于深度学习模型而言是十分直观的。很多深度学习模型可以直接用这种编程模型来表达和训练。</p></div> +<div class="section"> +<h2><a name="a"></a>系统概览</h2> +<p><img src="../../images/sgd.png" align="center" width="400px" alt="" /> <span><b>图1 - 随机梯度下降流程图</b></span></p> +<p>对于特定的任务,训练一个深度学习模型就是找出能产生良好特征的转换函数中的最优参数。参数的合适程度由损失函数来度量,如交叉熵损失函数<a class="externalLink" href="https://en.wikipedia.org/wiki/Cross_entropy">(Cross-Entropy Loss)</a>。因为损失函数一般都是非线性和非凸的,难以得到一个封闭形式解。典型的解决方案是使用随机梯度& #x4e0b;降(SGD)算法,首先随机地初始化参数,然后迭代地更新参数值,减小损失函数值,如图1所示。</p> +<p><img src="../../images/overview.png" align="center" width="400px" alt="" /> <span><b>图2 - SINGA 概览</b></span></p> +<p>SINGA使用随机梯度下降来训练深度学习模型中的参数。训练的作业会被分配到作业者(worker)单元和服务器(server)单元,如图2所示。每次迭代中,作业者调用 <i>TrainOneBatch</i> 函数计算参数的梯度。 <i>TainOneBatch</i> 函数以一个神经网络对象 <i>NeuralNet</i> 作为输入,以一定的顺序遍历 <i>NeuralNet</i>。计算得到的梯度将发送给局部&# x7684;根节点(stub),该局部根节点聚合请求并转发给对应的服务器请求更新。服务器给作业者发回更新后的参数,进入下一轮迭代。</p></div> +<div class="section"> +<h2><a name="a"></a>作业提交</h2> +<p>在SINGA中提交一个作业(即训练一个深度学习模型),用户需要将任务配置传给<a href="programming-guide.html">主函数</a>中的SINGA driver。作业配置需要明确图2中的四个主要部分:</p> + +<ul> + +<li><a href="neural-net.html">NeuralNet</a> :描述神经网络结构,包括每层的具体设置和层与层的连接关系;</li> + +<li><a href="train-one-batch.html">TrainOneBatch</a> :该算法需要根据不同的模型类别而定制;</li> + +<li><a href="updater.html">Updater</a> :定义服务器端更新参数的协议;</li> + +<li><a href="distributed-training.html">Cluster Topology</a> :指定服务器和工作者的分布式拓扑架构。</li> +</ul> +<p>作业提交过程跟Hadoop的作业提交类似,用户在主函数中配置好自己的任务,设置mapper和reducer等。在Hadoop中,用户可用自己实现的或者内建的mapper和reducer来配置他们的作业;类似地,在SINGA中,用户也可以用自己实现的或者内建的layer,updater等来配置他们的作业。</p></div> + </div> + </div> + </div> + + <hr/> + + <footer> + <div class="container-fluid"> + <div class="row-fluid"> + +<p>Copyright © 2015 The Apache Software Foundation. All rights reserved. Apache Singa, Apache, the Apache feather logo, and the Apache Singa project logos are trademarks of The Apache Software Foundation. All other marks mentioned may be trademarks or registered trademarks of their respective owners.</p> + </div> + + + </div> + </footer> + </body> +</html> Added: websites/staging/singa/trunk/content/v0.3.0/zh/programming-guide.html ============================================================================== --- websites/staging/singa/trunk/content/v0.3.0/zh/programming-guide.html (added) +++ websites/staging/singa/trunk/content/v0.3.0/zh/programming-guide.html Wed Apr 20 05:12:03 2016 @@ -0,0 +1,407 @@ +<!DOCTYPE html> +<!-- + | Generated by Apache Maven Doxia at 2016-04-20 + | Rendered using Apache Maven Fluido Skin 1.4 +--> +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> + <head> + <meta charset="UTF-8" /> + <meta name="viewport" content="width=device-width, initial-scale=1.0" /> + <meta name="Date-Revision-yyyymmdd" content="20160420" /> + <meta http-equiv="Content-Language" content="en" /> + <title>Apache SINGA – ç¼ç¨æå</title> + <link rel="stylesheet" href="../../css/apache-maven-fluido-1.4.min.css" /> + <link rel="stylesheet" href="../../css/site.css" /> + <link rel="stylesheet" href="../../css/print.css" media="print" /> + + + + + + <script type="text/javascript" src="../../js/apache-maven-fluido-1.4.min.js"></script> + + + +<script src="https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML" type="text/javascript"></script> + + +<script type="text/x-mathjax-config">MathJax.Hub.Config({tex2jax: {inlineMath: [['$','$'], ['\\(','\\)']]}});</script> + + +<meta content="Apache SINGA" name="author"/> + + +<meta content="SINGA, Deep Learning, Distributed training" name="keywords"/> + + </head> + <body class="topBarEnabled"> + + + + + + + <a href="https://github.com/apache/incubator-singa"> + <img style="position: absolute; top: 0; right: 0; border: 0; z-index: 10000;" + src="https://s3.amazonaws.com/github/ribbons/forkme_right_orange_ff7600.png" + alt="Fork me on GitHub"> + </a> + + + + + + <div id="topbar" class="navbar navbar-fixed-top navbar-inverse"> + <div class="navbar-inner"> + <div class="container-fluid"> + <a data-target=".nav-collapse" data-toggle="collapse" class="btn btn-navbar"> + <span class="icon-bar"></span> + <span class="icon-bar"></span> + <span class="icon-bar"></span> + </a> + + <ul class="nav"> + <li class="dropdown"> + <a href="#" class="dropdown-toggle" data-toggle="dropdown">Apache SINGA <b class="caret"></b></a> + <ul class="dropdown-menu"> + + <li> <a href="../../docs/overview.html" title="Introduction">Introduction</a> +</li> + + <li> <a href="../../docs/quick-start.html" title="Quick Start">Quick Start</a> +</li> + + <li> <a href="../../downloads.html" title="Downloads">Downloads</a> +</li> + </ul> + </li> + <li class="dropdown"> + <a href="#" class="dropdown-toggle" data-toggle="dropdown">Documentaion <b class="caret"></b></a> + <ul class="dropdown-menu"> + + <li class="dropdown-submenu"> + <a href="../../docs/index.html" title="v0.3.0">v0.3.0</a> + <ul class="dropdown-menu"> + <li> <a href="../../docs/index.html" title="English">English</a> +</li> + <li> <a href="../../docs/zh/index.html" title="䏿">䏿</a> +</li> + <li> <a href="../../docs/jp/index.html" title="æ¥æ¬èª">æ¥æ¬èª</a> +</li> + <li> <a href="../../docs/kr/index.html" title="íêµì´">íêµì´</a> +</li> + </ul> + </li> + + <li> <a href="../../v0.2.0/index.html" title="v0.2.0">v0.2.0</a> +</li> + + <li> <a href="../../v0.1.0/index.html" title="v0.1.0">v0.1.0</a> +</li> + </ul> + </li> + <li class="dropdown"> + <a href="#" class="dropdown-toggle" data-toggle="dropdown">Development <b class="caret"></b></a> + <ul class="dropdown-menu"> + + <li> <a href="../../develop/schedule.html" title="Schedule">Schedule</a> +</li> + + <li class="dropdown-submenu"> + <a href="../../develop/how-contribute.html" title="How to Contribute">How to Contribute</a> + <ul class="dropdown-menu"> + <li> <a href="../../develop/contribute-code.html" title="Code">Code</a> +</li> + <li> <a href="../../develop/contribute-docs.html" title="Documentation">Documentation</a> +</li> + </ul> + </li> + </ul> + </li> + <li class="dropdown"> + <a href="#" class="dropdown-toggle" data-toggle="dropdown">Community <b class="caret"></b></a> + <ul class="dropdown-menu"> + + <li> <a href="../../community/source-repository.html" title="Source Repository">Source Repository</a> +</li> + + <li> <a href="../../community/mail-lists.html" title="Mailing Lists">Mailing Lists</a> +</li> + + <li> <a href="../../community/issue-tracking.html" title="Issue Tracking">Issue Tracking</a> +</li> + + <li> <a href="../../community/team-list.html" title="SINGA Team">SINGA Team</a> +</li> + </ul> + </li> + <li class="dropdown"> + <a href="#" class="dropdown-toggle" data-toggle="dropdown">External Links <b class="caret"></b></a> + <ul class="dropdown-menu"> + + <li> <a href="http://www.apache.org/" title="Apache Software Foundation">Apache Software Foundation</a> +</li> + + <li> <a href="http://www.comp.nus.edu.sg/~dbsystem/singa/" title="NUS Site">NUS Site</a> +</li> + </ul> + </li> + </ul> + + + + + </div> + + </div> + </div> + </div> + + <div class="container-fluid"> + <div id="banner"> + <div class="pull-left"> + <a href="../../index.html" id="bannerLeft" title="Apache SINGA"> + <img src="../../images/singa-logo.png" alt="Apache SINGA"/> + </a> + </div> + <div class="pull-right"> <div id="bannerRight"> + <img src="../../images/singa-title.png" alt="Apache SINGA"/> + </div> + </div> + <div class="clear"><hr/></div> + </div> + + <div id="breadcrumbs"> + <ul class="breadcrumb"> + + + <li class=""> + <a href="../../index.html" title="Apache SINGA"> + Apache SINGA</a> + <span class="divider">/</span> + </li> + <li class="active ">ç¼ç¨æå</li> + + + + + </ul> + </div> + + + <div class="row-fluid"> + <div id="leftColumn" class="span2"> + <div class="well sidebar-nav"> + + + <ul class="nav nav-list"> + <li class="nav-header">Apache SINGA</li> + + <li> + + <a href="../../docs/overview.html" title="Introduction"> + <span class="none"></span> + Introduction</a> + </li> + + <li> + + <a href="../../docs/quick-start.html" title="Quick Start"> + <span class="none"></span> + Quick Start</a> + </li> + + <li> + + <a href="../../downloads.html" title="Downloads"> + <span class="none"></span> + Downloads</a> + </li> + <li class="nav-header">Documentaion</li> + + <li> + + <a href="../../docs/index.html" title="v0.3.0"> + <span class="icon-chevron-right"></span> + v0.3.0</a> + </li> + + <li> + + <a href="../../v0.2.0/index.html" title="v0.2.0"> + <span class="none"></span> + v0.2.0</a> + </li> + + <li> + + <a href="../../v0.1.0/index.html" title="v0.1.0"> + <span class="none"></span> + v0.1.0</a> + </li> + <li class="nav-header">Development</li> + + <li> + + <a href="../../develop/schedule.html" title="Schedule"> + <span class="none"></span> + Schedule</a> + </li> + + <li> + + <a href="../../develop/how-contribute.html" title="How to Contribute"> + <span class="icon-chevron-right"></span> + How to Contribute</a> + </li> + <li class="nav-header">Community</li> + + <li> + + <a href="../../community/source-repository.html" title="Source Repository"> + <span class="none"></span> + Source Repository</a> + </li> + + <li> + + <a href="../../community/mail-lists.html" title="Mailing Lists"> + <span class="none"></span> + Mailing Lists</a> + </li> + + <li> + + <a href="../../community/issue-tracking.html" title="Issue Tracking"> + <span class="none"></span> + Issue Tracking</a> + </li> + + <li> + + <a href="../../community/team-list.html" title="SINGA Team"> + <span class="none"></span> + SINGA Team</a> + </li> + <li class="nav-header">External Links</li> + + <li> + + <a href="http://www.apache.org/" class="externalLink" title="Apache Software Foundation"> + <span class="none"></span> + Apache Software Foundation</a> + </li> + + <li> + + <a href="http://www.comp.nus.edu.sg/~dbsystem/singa/" class="externalLink" title="NUS Site"> + <span class="none"></span> + NUS Site</a> + </li> + </ul> + + + + <hr /> + + <div id="poweredBy"> + <div class="clear"></div> + <div class="clear"></div> + <div class="clear"></div> + <div class="clear"></div> + <a href="http://incubator.apache.org" title="apache-incubator" class="builtBy"> + <img class="builtBy" alt="Apache Incubator" src="http://incubator.apache.org/images/egg-logo.png" /> + </a> + </div> + </div> + </div> + + + <div id="bodyColumn" class="span10" > + + <h1>编程指南</h1> +<hr /> +<p>要提交一个训练作业,用户需要提供图1中的四个部分的配置:</p> + +<ul> + +<li><a href="neural-net.html">NeuralNet</a> :描述神经网络结构,包括每层的具体设置和层与层的连接关系;</li> + +<li><a href="train-one-batch.html">TrainOneBatch</a> :该算法需要根据不同的模型类别而定制;</li> + +<li><a href="updater.html">Updater</a> :定义服务器端更新参数的协议;</li> + +<li><a href="distributed-training.html">Cluster Topology</a> :指定服务器和工作者的分布式拓扑架构。</li> +</ul> +<p><i>初级用户指南</i> 将介绍如何利用内建层提交一个训练作业,而 <i>高级用户指南</i> 将详细介绍如何编写用户自己的主函数并注册自己实现的组件。此外,高级用户和初级用户对训练数据集的<a href="data.html">处理</a>方式是相同的。</p> +<p><img src="../../images/overview.png" align="center" width="400px" alt="" /> <span><b>图 1 - SINGA 概览</b></span></p> +<div class="section"> +<h2><a name="a"></a>初级用户指南</h2> +<p>用户可以使用SINGA提供的主函数提交训练作业。对于这种情况,用户必须在命令行中提供根据 <a href="../api/classsinga_1_1JobProto.html">JobProto</a> 设置的作业配置文件,</p> + +<div class="source"> +<div class="source"><pre class="prettyprint">./bin/singa-run.sh -conf <path to job conf> [-resume] +</pre></div></div> +<p><tt>-resume</tt> 表示从上次的<a href="checkpoint.html">检查点(checkpoint)</a>继续训练。 <a href="mlp.html">MLP</a> 模型和 <a href="cnn.html">CNN</a> 模型使用内建层提交训练作业。请阅读相关页面,查看它们的作业配置文件,这些页面会介绍每个组件配置的细节。</p></div> +<div class="section"> +<h2><a name="a"></a>高级用户指南</h2> +<p>如果用户的模型中包含一些自己定义的组件,比如<a href="updater.html">Updater</a>,用户必须自己编写主函数注册这些组件,跟Hadoop的主函数类似。一般地,主函数应该</p> + +<ul> + +<li>初始化SINGA,如:设置日志;</li> + +<li>注册用户自定义组件;</li> + +<li>创建作业配置并传递给SINGA driver。</li> +</ul> +<p>主函数示例</p> + +<div class="source"> +<div class="source"><pre class="prettyprint">#include "singa.h" +#include "user.h" // header for user code + +int main(int argc, char** argv) { + singa::Driver driver; + driver.Init(argc, argv); + bool resume; + // parse resume option from argv. + + // register user defined layers + driver.RegisterLayer<FooLayer>(kFooLayer); + // register user defined updater + driver.RegisterUpdater<FooUpdater>(kFooUpdater); + ... + auto jobConf = driver.job_conf(); + // update jobConf + + driver.Train(resume, jobConf); + return 0; +} +</pre></div></div> +<p>driver 类’ <tt>Init</tt> 方法加载用户在命令行参数中 (<tt>-conf <job conf></tt>)提供的作业配置文件(至少包含集群拓扑结构),并返回<tt>jobConf</tt>给用户,用户可更新和添加神经网络或者Updater的配置。如果定义了Layer、Updater、Worker或者Param的子类,用户需要通过driver为它们注册。最后,作业配置会被提交到driver,由driver启动训练。</p> +<p>将来我们会提供类似<a class="externalLink" href="https://github.com/fchollet/keras">keras</a> 的帮助工具,使作业配置更加简单。</p> +<p>用户需要使用SINGA库(<i>.libs/libsinga.so</i>)编译和链接自己的代码(如:layer的实现和主函数),得到可执行文件,如名为<i>mysinga</i> 的文件。执行以下命令启动该程序,用户需要将<i>mysinga</i> 和作业配置文件的路径传给 <i>./bin/singa-run.sh</i> 。</p> + +<div class="source"> +<div class="source"><pre class="prettyprint">./bin/singa-run.sh -conf <path to job conf> -exec <path to mysinga> [other arguments] +</pre></div></div> +<p><a href="rnn.html">RNN application</a> 提供了一个完整的实现主函数训练特定RNN模型的例子。</p></div> + </div> + </div> + </div> + + <hr/> + + <footer> + <div class="container-fluid"> + <div class="row-fluid"> + +<p>Copyright © 2015 The Apache Software Foundation. All rights reserved. Apache Singa, Apache, the Apache feather logo, and the Apache Singa project logos are trademarks of The Apache Software Foundation. All other marks mentioned may be trademarks or registered trademarks of their respective owners.</p> + </div> + + + </div> + </footer> + </body> +</html>
