singa-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wang...@apache.org
Subject [35/51] [abbrv] incubator-singa git commit: Merge branch commits for doc layout change and commits for other doc and code changes
Date Wed, 17 Aug 2016 18:02:56 GMT
Merge branch commits for doc layout change and commits for other doc and code changes

Conflicts:
	doc/Makefile
	doc/docs.rst
	doc/docs/index.rst
	doc/docs/zh/index.md
	doc/en/conf.py
	examples/index.rst
	src/python/singa/device.py
	src/python/singa/tensor.py


Project: http://git-wip-us.apache.org/repos/asf/incubator-singa/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-singa/commit/72d736a6
Tree: http://git-wip-us.apache.org/repos/asf/incubator-singa/tree/72d736a6
Diff: http://git-wip-us.apache.org/repos/asf/incubator-singa/diff/72d736a6

Branch: refs/heads/master
Commit: 72d736a6ef665e6bea4e60f6d577ae3a38306e8c
Parents: c2173b3 31ae6bd
Author: Wei Wang <wangwei@comp.nus.edu.sg>
Authored: Mon Aug 15 21:10:29 2016 +0800
Committer: Wei Wang <wangwei@comp.nus.edu.sg>
Committed: Mon Aug 15 21:10:29 2016 +0800

----------------------------------------------------------------------
 doc/Makefile                          | 200 +----------------
 doc/_static/style.css                 |   3 +
 doc/_templates/layout.html            |  58 -----
 doc/build.sh                          |  33 ---
 doc/community/issue-tracking.md       |   9 -
 doc/community/mail-lists.rst          |  10 -
 doc/community/source-repository.md    |  22 --
 doc/community/team-list.rst           |  64 ------
 doc/conf.py                           | 340 -----------------------------
 doc/develop/contribute-code.md        |  60 -----
 doc/develop/contribute-docs.md        |  28 ---
 doc/develop/how-contribute.md         |  11 -
 doc/develop/schedule.rst              |  40 ----
 doc/docs.rst                          |   6 -
 doc/docs/cnn.md                       | 141 ------------
 doc/docs/device.rst                   |  36 ---
 doc/docs/index.rst                    |  15 --
 doc/docs/initializer.rst              |  12 -
 doc/docs/installation.md              | 226 -------------------
 doc/docs/layer.rst                    |  14 --
 doc/docs/loss.rst                     |   7 -
 doc/docs/metric.rst                   |   8 -
 doc/docs/neural-net.md                | 327 ---------------------------
 doc/docs/optimizer.rst                |  11 -
 doc/docs/overview.rst                 |  99 ---------
 doc/docs/software_stack.md            |  99 ---------
 doc/docs/tensor.rst                   |  30 ---
 doc/docs/utils.rst                    |   6 -
 doc/docs/zh/index.md                  |   9 -
 doc/downloads.md                      |  67 ------
 doc/en/_templates/layout.html         |  61 ++++++
 doc/en/community/issue-tracking.md    |   9 +
 doc/en/community/mail-lists.rst       |  10 +
 doc/en/community/source-repository.md |  22 ++
 doc/en/community/team-list.rst        |  64 ++++++
 doc/en/conf.py                        | 339 ++++++++++++++++++++++++++++
 doc/en/develop/contribute-code.md     |  60 +++++
 doc/en/develop/contribute-docs.md     |  28 +++
 doc/en/develop/how-contribute.md      |  11 +
 doc/en/develop/schedule.rst           |  40 ++++
 doc/en/docs.rst                       |   6 +
 doc/en/docs/cnn.md                    | 141 ++++++++++++
 doc/en/docs/device.rst                |  38 ++++
 doc/en/docs/index.rst                 |  10 +
 doc/en/docs/installation.md           | 226 +++++++++++++++++++
 doc/en/docs/neural-net.md             | 327 +++++++++++++++++++++++++++
 doc/en/docs/overview.rst              |  99 +++++++++
 doc/en/docs/software_stack.md         |  99 +++++++++
 doc/en/docs/tensor.rst                |  54 +++++
 doc/en/downloads.md                   |  67 ++++++
 doc/en/index.rst                      | 109 +++++++++
 doc/index.rst                         | 109 ---------
 doc/make.bat                          | 281 ------------------------
 doc/zh/_templates/layout.html         |  61 ++++++
 doc/zh/conf.py                        | 339 ++++++++++++++++++++++++++++
 doc/zh/index.md                       |   9 +
 src/python/singa/device.py            |   1 +
 57 files changed, 2240 insertions(+), 2371 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-singa/blob/72d736a6/doc/Makefile
----------------------------------------------------------------------
diff --cc doc/Makefile
index c6eddf1,436a661..b5282b7
--- a/doc/Makefile
+++ b/doc/Makefile
@@@ -50,8 -26,9 +26,14 @@@ clean
  
  .PHONY: html
  html:
++<<<<<<< HEAD
 +	cp -rf ../examples docs/
 +	$(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html
++=======
+ 	cp -rf ../examples en/docs/
+ 	$(SPHINXBUILD) -b html  -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) en $(BUILDDIR)/html
+ 	$(SPHINXBUILD) -b html  -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) zh $(BUILDDIR)/html/zh
++>>>>>>> v1doc
  	@echo
  	@echo "Build finished. The HTML pages are in $(BUILDDIR)/html."
  

http://git-wip-us.apache.org/repos/asf/incubator-singa/blob/72d736a6/doc/en/conf.py
----------------------------------------------------------------------
diff --cc doc/en/conf.py
index 0000000,332a0d1..36080d9
mode 000000,100755..100755
--- a/doc/en/conf.py
+++ b/doc/en/conf.py
@@@ -1,0 -1,339 +1,339 @@@
 -# -*- coding: utf-8 -*-
 -#
 -# incubator-singa documentation build configuration file, created by
 -# sphinx-quickstart on Sat Jul  9 20:36:57 2016.
 -#
 -# This file is execfile()d with the current directory set to its
 -# containing dir.
 -#
 -# Note that not all possible configuration values are present in this
 -# autogenerated file.
 -#
 -# All configuration values have a default; values that are commented out
 -# serve to show the default.
 -
 -# If extensions (or modules to document with autodoc) are in another directory,
 -# add these directories to sys.path here. If the directory is relative to the
 -# documentation root, use os.path.abspath to make it absolute, like shown here.
 -#
 -import os
 -import sys
 -sys.path.insert(0, os.path.abspath('.'))
 -sys.path.insert(1, os.path.abspath('../build/python'))
 -
 -# -- General configuration ------------------------------------------------
 -from recommonmark.parser import CommonMarkParser
 -
 -source_parsers = {
 -    '.md': CommonMarkParser,
 -}
 -
 -# If your documentation needs a minimal Sphinx version, state it here.
 -#
 -# needs_sphinx = '1.0'
 -
 -# Add any Sphinx extension module names here, as strings. They can be
 -# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
 -# ones.
 -extensions = ['sphinx.ext.autodoc', 'sphinx.ext.napoleon']
 -napoleon_google_docstring = True
 -
 -# Add any paths that contain templates here, relative to this directory.
 -templates_path = ['_templates']
 -
 -# The suffix(es) of source filenames.
 -# You can specify multiple suffix as a list of string:
 -#
 -# source_suffix = ['.rst', '.md']
 -source_suffix = ['.rst', '.md']
 -
 -# The encoding of source files.
 -#
 -source_encoding = 'utf-8-sig'
 -
 -# The master toctree document.
 -master_doc = 'index'
 -
 -# General information about the project.
 -project = u'incubator-singa'
 -copyright = u'2016 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.'
 -author = u'moaz'
 -
 -# The version info for the project you're documenting, acts as replacement for
 -# |version| and |release|, also used in various other places throughout the
 -# built documents.
 -#
 -# The short X.Y version.
 -version = u'1.0.0'
 -# The full version, including alpha/beta/rc tags.
 -release = u'1.0.0'
 -
 -# The language for content autogenerated by Sphinx. Refer to documentation
 -# for a list of supported languages.
 -#
 -# This is also used if you do content translation via gettext catalogs.
 -# Usually you set "language" from the command line for these cases.
 -language = None
 -
 -# There are two options for replacing |today|: either, you set today to some
 -# non-false value, then it is used:
 -#
 -# today = ''
 -#
 -# Else, today_fmt is used as the format for a strftime call.
 -#
 -# today_fmt = '%B %d, %Y'
 -
 -# List of patterns, relative to source directory, that match files and
 -# directories to ignore when looking for source files.
 -# This patterns also effect to html_static_path and html_extra_path
 -exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store']
 -
 -# The reST default role (used for this markup: `text`) to use for all
 -# documents.
 -#
 -# default_role = None
 -
 -# If true, '()' will be appended to :func: etc. cross-reference text.
 -#
 -# add_function_parentheses = True
 -
 -# If true, the current module name will be prepended to all description
 -# unit titles (such as .. function::).
 -#
 -# add_module_names = True
 -
 -# If true, sectionauthor and moduleauthor directives will be shown in the
 -# output. They are ignored by default.
 -#
 -# show_authors = False
 -
 -# The name of the Pygments (syntax highlighting) style to use.
 -pygments_style = 'sphinx'
 -
 -# A list of ignored prefixes for module index sorting.
 -# modindex_common_prefix = []
 -
 -# If true, keep warnings as "system message" paragraphs in the built documents.
 -# keep_warnings = False
 -
 -# If true, `todo` and `todoList` produce output, else they produce nothing.
 -todo_include_todos = False
 -
 -
 -# -- Options for HTML output ----------------------------------------------
 -
 -# The theme to use for HTML and HTML Help pages.  See the documentation for
 -# a list of builtin themes.
 -#
 -html_theme = 'sphinx_rtd_theme'
 -
 -# Theme options are theme-specific and customize the look and feel of a theme
 -# further.  For a list of options available for each theme, see the
 -# documentation.
 -#
 -# html_theme_options = {}
 -
 -# Add any paths that contain custom themes here, relative to this directory.
 -# html_theme_path = []
 -
 -# The name for this set of Sphinx documents.
 -# "<project> v<release> documentation" by default.
 -#
 -# html_title = u'Singa v1.0.0'
 -
 -# A shorter title for the navigation bar.  Default is the same as html_title.
 -#
 -# html_short_title = None
 -
 -# The name of an image file (relative to this directory) to place at the top
 -# of the sidebar.
 -#
 -html_logo = 'image/singa.png'
 -
 -# The name of an image file (relative to this directory) to use as a favicon of
 -# the docs.  This file should be a Windows icon file (.ico) being 16x16 or 32x32
 -# pixels large.
 -#
 -# html_favicon = None
 -
 -# Add any paths that contain custom static files (such as style sheets) here,
 -# relative to this directory. They are copied after the builtin static files,
 -# so a file named "default.css" will overwrite the builtin "default.css".
 -html_static_path = ['../_static']
 -
 -# Add any extra paths that contain custom files (such as robots.txt or
 -# .htaccess) here, relative to this directory. These files are copied
 -# directly to the root of the documentation.
 -#
 -# html_extra_path = []
 -
 -# If not None, a 'Last updated on:' timestamp is inserted at every page
 -# bottom, using the given strftime format.
 -# The empty string is equivalent to '%b %d, %Y'.
 -#
 -# html_last_updated_fmt = None
 -
 -# If true, SmartyPants will be used to convert quotes and dashes to
 -# typographically correct entities.
 -#
 -# html_use_smartypants = True
 -
 -# Custom sidebar templates, maps document names to template names.
 -#
 -# html_sidebars = {}
 -
 -# Additional templates that should be rendered to pages, maps page names to
 -# template names.
 -#
 -# html_additional_pages = {}
 -
 -# If false, no module index is generated.
 -#
 -# html_domain_indices = True
 -
 -# If false, no index is generated.
 -#
 -# html_use_index = True
 -
 -# If true, the index is split into individual pages for each letter.
 -#
 -# html_split_index = False
 -
 -# If true, links to the reST sources are added to the pages.
 -#
 -html_show_sourcelink = False
 -
 -# If true, "Created using Sphinx" is shown in the HTML footer. Default is True.
 -#
 -# html_show_sphinx = True
 -
 -# If true, "(C) Copyright ..." is shown in the HTML footer. Default is True.
 -#
 -# html_show_copyright = True
 -
 -# If true, an OpenSearch description file will be output, and all pages will
 -# contain a <link> tag referring to it.  The value of this option must be the
 -# base URL from which the finished HTML is served.
 -#
 -# html_use_opensearch = ''
 -
 -# This is the file name suffix for HTML files (e.g. ".xhtml").
 -# html_file_suffix = None
 -
 -# Language to be used for generating the HTML full-text search index.
 -# Sphinx supports the following languages:
 -#   'da', 'de', 'en', 'es', 'fi', 'fr', 'hu', 'it', 'ja'
 -#   'nl', 'no', 'pt', 'ro', 'ru', 'sv', 'tr', 'zh'
 -#
 -# html_search_language = 'en'
 -
 -# A dictionary with options for the search language support, empty by default.
 -# 'ja' uses this config value.
 -# 'zh' user can custom change `jieba` dictionary path.
 -#
 -# html_search_options = {'type': 'default'}
 -
 -# The name of a javascript file (relative to the configuration directory) that
 -# implements a search results scorer. If empty, the default will be used.
 -#
 -# html_search_scorer = 'scorer.js'
 -
 -# Output file base name for HTML help builder.
 -htmlhelp_basename = 'Singadoc'
 -
 -# -- Options for LaTeX output ---------------------------------------------
 -
 -latex_elements = {
 -     # The paper size ('letterpaper' or 'a4paper').
 -     #
 -     # 'papersize': 'letterpaper',
 -
 -     # The font size ('10pt', '11pt' or '12pt').
 -     #
 -     # 'pointsize': '10pt',
 -
 -     # Additional stuff for the LaTeX preamble.
 -     #
 -     # 'preamble': '',
 -
 -     # Latex figure (float) alignment
 -     #
 -     # 'figure_align': 'htbp',
 -}
 -
 -# Grouping the document tree into LaTeX files. List of tuples
 -# (source start file, target name, title,
 -#  author, documentclass [howto, manual, or own class]).
 -latex_documents = [
 -    (master_doc, 'incubator-singa.tex', u'incubator-singa Documentation',
 -     u'moaz', 'manual'),
 -]
 -
 -# The name of an image file (relative to this directory) to place at the top of
 -# the title page.
 -#
 -# latex_logo = None
 -
 -# For "manual" documents, if this is true, then toplevel headings are parts,
 -# not chapters.
 -#
 -# latex_use_parts = False
 -
 -# If true, show page references after internal links.
 -#
 -# latex_show_pagerefs = False
 -
 -# If true, show URL addresses after external links.
 -#
 -# latex_show_urls = False
 -
 -# Documents to append as an appendix to all manuals.
 -#
 -# latex_appendices = []
 -
 -# If false, no module index is generated.
 -#
 -# latex_domain_indices = True
 -
 -
 -# -- Options for manual page output ---------------------------------------
 -
 -# One entry per manual page. List of tuples
 -# (source start file, name, description, authors, manual section).
 -man_pages = [
 -    (master_doc, 'incubator-singa', u'incubator-singa Documentation',
 -     [author], 1)
 -]
 -
 -# If true, show URL addresses after external links.
 -#
 -# man_show_urls = False
 -
 -
 -# -- Options for Texinfo output -------------------------------------------
 -
 -# Grouping the document tree into Texinfo files. List of tuples
 -# (source start file, target name, title, author,
 -#  dir menu entry, description, category)
 -texinfo_documents = [
 -    (master_doc, 'incubator-singa', u'incubator-singa Documentation',
 -     author, 'incubator-singa', 'One line description of project.',
 -     'Miscellaneous'),
 -]
 -
 -# Documents to append as an appendix to all manuals.
 -#
 -# texinfo_appendices = []
 -
 -# If false, no module index is generated.
 -#
 -# texinfo_domain_indices = True
 -
 -# How to display URL addresses: 'footnote', 'no', or 'inline'.
 -#
 -# texinfo_show_urls = 'footnote'
 -
 -# If true, do not generate a @detailmenu in the "Top" node's menu.
 -#
 -# texinfo_no_detailmenu = False
++# -*- coding: utf-8 -*-
++#
++# incubator-singa documentation build configuration file, created by
++# sphinx-quickstart on Sat Jul  9 20:36:57 2016.
++#
++# This file is execfile()d with the current directory set to its
++# containing dir.
++#
++# Note that not all possible configuration values are present in this
++# autogenerated file.
++#
++# All configuration values have a default; values that are commented out
++# serve to show the default.
++
++# If extensions (or modules to document with autodoc) are in another directory,
++# add these directories to sys.path here. If the directory is relative to the
++# documentation root, use os.path.abspath to make it absolute, like shown here.
++#
++import os
++import sys
++sys.path.insert(0, os.path.abspath('.'))
++sys.path.insert(1, os.path.abspath('../build/python'))
++
++# -- General configuration ------------------------------------------------
++from recommonmark.parser import CommonMarkParser
++
++source_parsers = {
++    '.md': CommonMarkParser,
++}
++
++# If your documentation needs a minimal Sphinx version, state it here.
++#
++# needs_sphinx = '1.0'
++
++# Add any Sphinx extension module names here, as strings. They can be
++# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
++# ones.
++extensions = ['sphinx.ext.autodoc', 'sphinx.ext.napoleon']
++napoleon_google_docstring = True
++
++# Add any paths that contain templates here, relative to this directory.
++templates_path = ['_templates']
++
++# The suffix(es) of source filenames.
++# You can specify multiple suffix as a list of string:
++#
++# source_suffix = ['.rst', '.md']
++source_suffix = ['.rst', '.md']
++
++# The encoding of source files.
++#
++source_encoding = 'utf-8-sig'
++
++# The master toctree document.
++master_doc = 'index'
++
++# General information about the project.
++project = u'incubator-singa'
++copyright = u'2016 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.'
++author = u'moaz'
++
++# The version info for the project you're documenting, acts as replacement for
++# |version| and |release|, also used in various other places throughout the
++# built documents.
++#
++# The short X.Y version.
++version = u'1.0.0'
++# The full version, including alpha/beta/rc tags.
++release = u'1.0.0'
++
++# The language for content autogenerated by Sphinx. Refer to documentation
++# for a list of supported languages.
++#
++# This is also used if you do content translation via gettext catalogs.
++# Usually you set "language" from the command line for these cases.
++language = None
++
++# There are two options for replacing |today|: either, you set today to some
++# non-false value, then it is used:
++#
++# today = ''
++#
++# Else, today_fmt is used as the format for a strftime call.
++#
++# today_fmt = '%B %d, %Y'
++
++# List of patterns, relative to source directory, that match files and
++# directories to ignore when looking for source files.
++# This patterns also effect to html_static_path and html_extra_path
++exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store']
++
++# The reST default role (used for this markup: `text`) to use for all
++# documents.
++#
++# default_role = None
++
++# If true, '()' will be appended to :func: etc. cross-reference text.
++#
++# add_function_parentheses = True
++
++# If true, the current module name will be prepended to all description
++# unit titles (such as .. function::).
++#
++# add_module_names = True
++
++# If true, sectionauthor and moduleauthor directives will be shown in the
++# output. They are ignored by default.
++#
++# show_authors = False
++
++# The name of the Pygments (syntax highlighting) style to use.
++pygments_style = 'sphinx'
++
++# A list of ignored prefixes for module index sorting.
++# modindex_common_prefix = []
++
++# If true, keep warnings as "system message" paragraphs in the built documents.
++# keep_warnings = False
++
++# If true, `todo` and `todoList` produce output, else they produce nothing.
++todo_include_todos = False
++
++
++# -- Options for HTML output ----------------------------------------------
++
++# The theme to use for HTML and HTML Help pages.  See the documentation for
++# a list of builtin themes.
++#
++html_theme = 'sphinx_rtd_theme'
++
++# Theme options are theme-specific and customize the look and feel of a theme
++# further.  For a list of options available for each theme, see the
++# documentation.
++#
++# html_theme_options = {}
++
++# Add any paths that contain custom themes here, relative to this directory.
++# html_theme_path = []
++
++# The name for this set of Sphinx documents.
++# "<project> v<release> documentation" by default.
++#
++# html_title = u'Singa v1.0.0'
++
++# A shorter title for the navigation bar.  Default is the same as html_title.
++#
++# html_short_title = None
++
++# The name of an image file (relative to this directory) to place at the top
++# of the sidebar.
++#
++html_logo = 'image/singa.png'
++
++# The name of an image file (relative to this directory) to use as a favicon of
++# the docs.  This file should be a Windows icon file (.ico) being 16x16 or 32x32
++# pixels large.
++#
++# html_favicon = None
++
++# Add any paths that contain custom static files (such as style sheets) here,
++# relative to this directory. They are copied after the builtin static files,
++# so a file named "default.css" will overwrite the builtin "default.css".
++html_static_path = ['../_static']
++
++# Add any extra paths that contain custom files (such as robots.txt or
++# .htaccess) here, relative to this directory. These files are copied
++# directly to the root of the documentation.
++#
++# html_extra_path = []
++
++# If not None, a 'Last updated on:' timestamp is inserted at every page
++# bottom, using the given strftime format.
++# The empty string is equivalent to '%b %d, %Y'.
++#
++# html_last_updated_fmt = None
++
++# If true, SmartyPants will be used to convert quotes and dashes to
++# typographically correct entities.
++#
++# html_use_smartypants = True
++
++# Custom sidebar templates, maps document names to template names.
++#
++# html_sidebars = {}
++
++# Additional templates that should be rendered to pages, maps page names to
++# template names.
++#
++# html_additional_pages = {}
++
++# If false, no module index is generated.
++#
++# html_domain_indices = True
++
++# If false, no index is generated.
++#
++# html_use_index = True
++
++# If true, the index is split into individual pages for each letter.
++#
++# html_split_index = False
++
++# If true, links to the reST sources are added to the pages.
++#
++html_show_sourcelink = False
++
++# If true, "Created using Sphinx" is shown in the HTML footer. Default is True.
++#
++# html_show_sphinx = True
++
++# If true, "(C) Copyright ..." is shown in the HTML footer. Default is True.
++#
++# html_show_copyright = True
++
++# If true, an OpenSearch description file will be output, and all pages will
++# contain a <link> tag referring to it.  The value of this option must be the
++# base URL from which the finished HTML is served.
++#
++# html_use_opensearch = ''
++
++# This is the file name suffix for HTML files (e.g. ".xhtml").
++# html_file_suffix = None
++
++# Language to be used for generating the HTML full-text search index.
++# Sphinx supports the following languages:
++#   'da', 'de', 'en', 'es', 'fi', 'fr', 'hu', 'it', 'ja'
++#   'nl', 'no', 'pt', 'ro', 'ru', 'sv', 'tr', 'zh'
++#
++# html_search_language = 'en'
++
++# A dictionary with options for the search language support, empty by default.
++# 'ja' uses this config value.
++# 'zh' user can custom change `jieba` dictionary path.
++#
++# html_search_options = {'type': 'default'}
++
++# The name of a javascript file (relative to the configuration directory) that
++# implements a search results scorer. If empty, the default will be used.
++#
++# html_search_scorer = 'scorer.js'
++
++# Output file base name for HTML help builder.
++htmlhelp_basename = 'Singadoc'
++
++# -- Options for LaTeX output ---------------------------------------------
++
++latex_elements = {
++     # The paper size ('letterpaper' or 'a4paper').
++     #
++     # 'papersize': 'letterpaper',
++
++     # The font size ('10pt', '11pt' or '12pt').
++     #
++     # 'pointsize': '10pt',
++
++     # Additional stuff for the LaTeX preamble.
++     #
++     # 'preamble': '',
++
++     # Latex figure (float) alignment
++     #
++     # 'figure_align': 'htbp',
++}
++
++# Grouping the document tree into LaTeX files. List of tuples
++# (source start file, target name, title,
++#  author, documentclass [howto, manual, or own class]).
++latex_documents = [
++    (master_doc, 'incubator-singa.tex', u'incubator-singa Documentation',
++     u'moaz', 'manual'),
++]
++
++# The name of an image file (relative to this directory) to place at the top of
++# the title page.
++#
++# latex_logo = None
++
++# For "manual" documents, if this is true, then toplevel headings are parts,
++# not chapters.
++#
++# latex_use_parts = False
++
++# If true, show page references after internal links.
++#
++# latex_show_pagerefs = False
++
++# If true, show URL addresses after external links.
++#
++# latex_show_urls = False
++
++# Documents to append as an appendix to all manuals.
++#
++# latex_appendices = []
++
++# If false, no module index is generated.
++#
++# latex_domain_indices = True
++
++
++# -- Options for manual page output ---------------------------------------
++
++# One entry per manual page. List of tuples
++# (source start file, name, description, authors, manual section).
++man_pages = [
++    (master_doc, 'incubator-singa', u'incubator-singa Documentation',
++     [author], 1)
++]
++
++# If true, show URL addresses after external links.
++#
++# man_show_urls = False
++
++
++# -- Options for Texinfo output -------------------------------------------
++
++# Grouping the document tree into Texinfo files. List of tuples
++# (source start file, target name, title, author,
++#  dir menu entry, description, category)
++texinfo_documents = [
++    (master_doc, 'incubator-singa', u'incubator-singa Documentation',
++     author, 'incubator-singa', 'One line description of project.',
++     'Miscellaneous'),
++]
++
++# Documents to append as an appendix to all manuals.
++#
++# texinfo_appendices = []
++
++# If false, no module index is generated.
++#
++# texinfo_domain_indices = True
++
++# How to display URL addresses: 'footnote', 'no', or 'inline'.
++#
++# texinfo_show_urls = 'footnote'
++
++# If true, do not generate a @detailmenu in the "Top" node's menu.
++#
++# texinfo_no_detailmenu = False

http://git-wip-us.apache.org/repos/asf/incubator-singa/blob/72d736a6/doc/en/docs/installation.md
----------------------------------------------------------------------
diff --cc doc/en/docs/installation.md
index 0000000,8ab617f..5d3c8a2
mode 000000,100755..100755
--- a/doc/en/docs/installation.md
+++ b/doc/en/docs/installation.md
@@@ -1,0 -1,69 +1,226 @@@
 -# Building SINGA from source
 -
 -## Dependencies
 -
 -### Required
 -* Google Protobuf (>=2.5)
 -* BLAS (tested with OpenBLAS >=0.2.10)
 -* CUDA (tested with 6.5, 7.0 and 7.5)
 -* CUDNN (v4 and v5)
 -* cmake (>=2.6)
 -
 -Users must install the above mandatory libraries.
 -Currently CUDA and CUDNN are also mandatory, but it would become optional later.
 -
 -### Optional
 -* Glog
 -* OpenCV (tested with 2.4.8)
 -* LMDB (tested with 0.9)
 -
 -
 -## Instructions
 -
 -Please clone the newest code from [Github](https://github.com/apache/incubator-singa) and
execute the following commands,
 -
 -
 -    $ git clone https://github.com/apache/incubator-singa.git
 -    $ cd incubator-singa/
 -    # switch to dev branch
 -    $ git checkout dev
 -
 -
 -If you use CUDA, then [CNMeM](https://github.com/NVIDIA/cnmem) is necessary,
 -which could be downloaded as
 -
 -    $ git submodule init
 -    $ git submodule update
 -
 -
 -### Linux OS
 -
 -GCC (>=4.8.1) is required to compile SINGA on Linux OS.
 -In SINGA_ROOT, execute the following commands for compiling SINGA,
 -
 -    $ mkdir build && cd build
 -    # generate Makefile for compilation
 -    $ cmake ..
 -    # compile SINGA
 -    $ make
 -
 -Note that if you are using CUDNN, you need to let cmake know the paths to CUDNN,
 -
 -    $ export CMAKE_INCLUDE_PATH=<path to cudnn>/include:$CMAKE_INCLUDE_PATH
 -    $ export CMAKE_LIBRARY_PATH=<path to cudnn>/lib64:$CMAKE_LIBRARY_PATH
 -
 -You can use `ccmake ..` to configure the compilation options including using
 -LMDB, GLOG, etc.
 -
 -After compiling SINGA, you can run the unit tests by
 -
 -    $ ./bin/test_singa
 -
 -You can see all the testing cases with testing results. If SINGA passes all
 -tests, then you have successfully installed SINGA. Please proceed to try the examples!
 -
 -
 -### MacOS
 -
 -
 -### Windows
++# Installation
++
++## Dependencies
++
++### Required
++* google protobuf (>=2.5,<3)
++* blas (tested with openblas >=0.2.10)
++* cmake (>=2.6)
++
++
++### Optional
++* glog
++* opencv (tested with 2.4.8)
++* lmdb (tested with 0.9)
++* cuda (tested with 6.5, 7.0 and 7.5)
++* cudnn (v4 and v5)
++
++PySINGA has additional dependencies
++
++* python(==2.7)
++* pip(>=1.5)
++* swig(>=3.0)
++* numpy(>=1.11.0)
++* openblas (>=0.2.10)
++
++Users are encouraged to install the cuda and [cudnn](https://developer.nvidia.com/cudnn)
for running SINGA on GPUs to
++get better performance.
++Most of the dependent libraries could be installed via package mangers like
++apt-get or homebrew.
++
++    # for ubuntu users, tested on 14.04
++    sudo apt-get install libprotobuf-dev libopencv-dev protobuf-compiler libgoogle-glog-dev
liblmdb-dev, python2.7-dev, python-pip, python-numpy
++
++    # for Mac OS users
++    brew install -vd glog lmdb
++    brew tap homebrew/science
++    brew install opencv
++    brew install openblas
++    brew tap homebrew/python
++    brew install python
++    brew install numpy  --with-openblas
++
++
++## Install PySINGA
++
++### From wheel
++
++After installing the dependencies for SINGA and PySINGA, please download the correct binary:
++
++    # Ubuntu/Linux 64-bit, CPU only, Python 2.7, Protobuf 2.5
++    $ export SINGA_WHEEL_URL=http://comp.nus.edu.sg/~dbsystem/singa/assets/file/pb2.5/singa-1.0.0-cp27-none-linux_x86_64.whl
++
++    # Ubuntu/Linux 64-bit, CPU only, Python 2.7, Protobuf 2.6
++    $ export SINGA_WHEEL_URL=http://comp.nus.edu.sg/~dbsystem/singa/assets/file/pb2.6/singa-1.0.0-cp27-none-linux_x86_64.whl
++
++    # Ubuntu/Linux 64-bit, GPU enabled, Python 2.7, Protobuf 2.5, CUDA toolkit 7.5 and CuDNN
v5
++    $ export SINGA_WHEEL_URL=http://comp.nus.edu.sg/~dbsystem/singa/assets/file/pb2.5-cuda7.5-cudnn5/singa-1.0.0-cp27-none-linux_x86_64.whl
++
++    # Ubuntu/Linux 64-bit, GPU enabled, Python 2.7, Protobuf 2.6, CUDA toolkit 7.5 and CuDNN
v5
++    $ export SINGA_WHEEL_URL=http://comp.nus.edu.sg/~dbsystem/singa/assets/file/pb2.6-cuda7.5-cudnn5/singa-1.0.0-cp27-none-linux_x86_64.whl
++
++Then, run the following command
++
++    $ sudo pip install --upgrade $SINGA_WHEEL_URL
++
++If you do not have sudo right, you can run `pip install` in a python virtual environment.
++
++
++### From source
++
++Please compile SINGA from source (see the next section) with the 'USE_PYTHON' option on,
++and then run the following commands,
++
++    # under the build directory
++    $ cd python
++    $ sudo pip install .
++
++If you are using a virtual environment, you can ignore the `sudo` keyword.
++
++Developers can build the wheel file via
++
++    # under the build directory
++    $ cd python
++    $ python setup.py bdist_wheel
++
++
++The generated wheel file is under "dist" directory
++
++
++## Build SINGA from source
++
++Please clone the newest code from [Github](https://github.com/apache/incubator-singa) and
execute the following commands,
++
++    $ git clone https://github.com/apache/incubator-singa.git
++    $ cd incubator-singa/
++
++If you use CUDA, then [CNMeM](https://github.com/NVIDIA/cnmem) is necessary,
++which could be downloaded as
++
++    $ git submodule init
++    $ git submodule update
++
++
++### Linux & MacOS
++
++GCC (>=4.8.1) is required to compile SINGA on Linux.
++For Mac OS users, you can use either GCC or Clang.
++
++In SINGA_ROOT, execute the following commands for compiling SINGA,
++
++    $ mkdir build && cd build
++    $ cmake ..
++    $ make
++    $ make install
++
++Note that if you are using CUDNN and it is not installed under system default
++folder, you need to let cmake know the paths to CUDNN,
++
++    $ export CMAKE_INCLUDE_PATH=<path to cudnn>/include:$CMAKE_INCLUDE_PATH
++    $ export CMAKE_LIBRARY_PATH=<path to cudnn>/lib64:$CMAKE_LIBRARY_PATH
++
++You can use `ccmake ..` to configure the compilation options including using
++generating python binding and changing the installation folder.
++If the dependent libraries are not in the system default paths, you need to export
++the following environment variables
++
++    export CMAKE_INCLUDE_PATH=<path to your header file folder>
++    export CMAKE_LIBRARY_PATH=<path to your lib file folder>
++
++After compiling SINGA, you can run the unit tests by
++
++    $ ./bin/test_singa
++
++You can see all the testing cases with testing results. If SINGA passes all
++tests, then you have successfully installed SINGA. Please proceed to try the examples!
++
++
++### Windows
++To be added.
++
++
++## FAQ
++
++* Q: Error from running `cmake ..`, which cannot find the dependent libraries.
++
++    A: If you haven't installed the libraries, please install them. If you installed
++    the libraries in a folder that is outside of the system folder, e.g. /usr/local,
++    please export the following variables
++
++        export CMAKE_INCLUDE_PATH=<path to your header file folder>
++        export CMAKE_LIBRARY_PATH=<path to your lib file folder>
++
++
++* Q: Error from `make`, e.g. the linking phase
++
++    A: If your libraries are in other folders than system default paths, you need
++    to export the following varaibles
++
++    $ export LIBRARY_PATH=<path to your lib file folder>
++    $ export LD_LIBRARY_PATH=<path to your lib file folder>
++
++
++* Q: Error from header files, e.g. 'cblas.h no such file or directory exists'
++
++    A: You need to include the folder of the cblas.h into CPLUS_INCLUDE_PATH,
++    e.g.,
++
++        $ export CPLUS_INCLUDE_PATH=/opt/OpenBLAS/include:$CPLUS_INCLUDE_PATH
++
++* Q:While compiling SINGA, I get error `SSE2 instruction set not enabled`
++
++    A:You can try following command:
++
++        $ make CFLAGS='-msse2' CXXFLAGS='-msse2'
++
++* Q:I get `ImportError: cannot import name enum_type_wrapper` from google.protobuf.internal
when I try to import .py files.
++
++    A: You need to install the python binding of protobuf, which could be installed via
++
++        $ sudo apt-get install protobuf
++
++    or from source
++
++        $ cd /PROTOBUF/SOURCE/FOLDER
++        $ cd python
++        $ python setup.py build
++        $ python setup.py install
++
++* Q: When I build OpenBLAS from source, I am told that I need a Fortran compiler.
++
++    A: You can compile OpenBLAS by
++
++        $ make ONLY_CBLAS=1
++
++    or install it using
++
++        $ sudo apt-get install libopenblas-dev
++
++* Q: When I build protocol buffer, it reports that GLIBC++_3.4.20 not found in /usr/lib64/libstdc++.so.6.
++
++    A9: This means the linker found libstdc++.so.6 but that library
++    belongs to an older version of GCC than was used to compile and link the
++    program. The program depends on code defined in
++    the newer libstdc++ that belongs to the newer version of GCC, so the linker
++    must be told how to find the newer libstdc++ shared library.
++    The simplest way to fix this is to find the correct libstdc++ and export it to
++    LD_LIBRARY_PATH. For example, if GLIBC++_3.4.20 is listed in the output of the
++    following command,
++
++        $ strings /usr/local/lib64/libstdc++.so.6|grep GLIBC++
++
++    then you just set your environment variable as
++
++        $ export LD_LIBRARY_PATH=/usr/local/lib64:$LD_LIBRARY_PATH
++
++* Q: When I build glog, it reports that "src/logging_unittest.cc:83:20: error: ‘gflags’
is not a namespace-name"
++
++    A: It maybe that you have installed gflags with a different namespace such as "google".
so glog can't find 'gflags' namespace.
++    Because it is not necessary to have gflags to build glog. So you can change the configure.ac
file to ignore gflags.
++
++        1. cd to glog src directory
++        2. change line 125 of configure.ac  to "AC_CHECK_LIB(gflags, main, ac_cv_have_libgflags=0,
ac_cv_have_libgflags=0)"
++        3. autoreconf
++
++    After this, you can build glog again.
++

http://git-wip-us.apache.org/repos/asf/incubator-singa/blob/72d736a6/src/python/singa/device.py
----------------------------------------------------------------------
diff --cc src/python/singa/device.py
index 65824c2,eff6783..2d93823
--- a/src/python/singa/device.py
+++ b/src/python/singa/device.py
@@@ -114,9 -114,6 +114,10 @@@ def create_cuda_gpu_on(device_id)
      return devices[0]
  
  
 +default_device = singa.Platform.GetDefaultDevice()
 +
 +
  def get_default_device():
      '''Get the default host device which is a CppCPU device'''
 -    return singa.Platform.GetDefaultDevice()
 +    return default_device
++



Mime
View raw message