Skip to content

Commit

Permalink
update deepsparse docs for 0.1.1 release (#12)
Browse files Browse the repository at this point in the history
  • Loading branch information
markurtz authored Feb 25, 2021
1 parent 7a2b32c commit 3074bb8
Show file tree
Hide file tree
Showing 22 changed files with 337 additions and 188 deletions.
3 changes: 2 additions & 1 deletion deepsparse/_modules/deepsparse/benchmark.html
Original file line number Diff line number Diff line change
Expand Up @@ -108,10 +108,11 @@
<ul>
<li class="toctree-l1"><a class="reference internal" href="../../api/deepsparse.html">deepsparse package</a></li>
</ul>
<p class="caption"><span class="caption-text">Help and Support</span></p>
<p class="caption"><span class="caption-text">Help</span></p>
<ul>
<li class="toctree-l1"><a class="reference external" href="https://github.com/neuralmagic/deepsparse/issues">Bugs, Feature Requests</a></li>
<li class="toctree-l1"><a class="reference external" href="https://github.com/neuralmagic/deepsparse/discussions">Support, General Q&amp;A</a></li>
<li class="toctree-l1"><a class="reference external" href="https://docs.neuralmagic.com">Neural Magic Docs</a></li>
</ul>


Expand Down
15 changes: 9 additions & 6 deletions deepsparse/_modules/deepsparse/cpu.html
Original file line number Diff line number Diff line change
Expand Up @@ -108,10 +108,11 @@
<ul>
<li class="toctree-l1"><a class="reference internal" href="../../api/deepsparse.html">deepsparse package</a></li>
</ul>
<p class="caption"><span class="caption-text">Help and Support</span></p>
<p class="caption"><span class="caption-text">Help</span></p>
<ul>
<li class="toctree-l1"><a class="reference external" href="https://github.com/neuralmagic/deepsparse/issues">Bugs, Feature Requests</a></li>
<li class="toctree-l1"><a class="reference external" href="https://github.com/neuralmagic/deepsparse/discussions">Support, General Q&amp;A</a></li>
<li class="toctree-l1"><a class="reference external" href="https://docs.neuralmagic.com">Neural Magic Docs</a></li>
</ul>


Expand Down Expand Up @@ -196,11 +197,12 @@ <h1>Source code for deepsparse.cpu</h1><div class="highlight"><pre>
<span class="sd">code related to detecting the details of the currently available cpu</span>
<span class="sd">&quot;&quot;&quot;</span>

<span class="kn">from</span> <span class="nn">typing</span> <span class="kn">import</span> <span class="n">Tuple</span>
<span class="kn">import</span> <span class="nn">json</span>
<span class="kn">import</span> <span class="nn">os</span>
<span class="kn">import</span> <span class="nn">sys</span>
<span class="kn">import</span> <span class="nn">subprocess</span>
<span class="kn">import</span> <span class="nn">json</span>
<span class="kn">import</span> <span class="nn">sys</span>
<span class="kn">from</span> <span class="nn">typing</span> <span class="kn">import</span> <span class="n">Tuple</span>


<span class="n">__all__</span> <span class="o">=</span> <span class="p">[</span><span class="s2">&quot;cpu_details&quot;</span><span class="p">,</span> <span class="s2">&quot;VALID_VECTOR_EXTENSIONS&quot;</span><span class="p">]</span>

Expand Down Expand Up @@ -312,8 +314,9 @@ <h1>Source code for deepsparse.cpu</h1><div class="highlight"><pre>
<span class="p">)</span>
<span class="k">if</span> <span class="n">avx_type_override</span> <span class="ow">not</span> <span class="ow">in</span> <span class="n">VALID_VECTOR_EXTENSIONS</span><span class="p">:</span>
<span class="k">raise</span> <span class="ne">OSError</span><span class="p">(</span>
<span class="s2">&quot;neuralmagic: invalid avx instruction set &#39;</span><span class="si">{}</span><span class="s2">&#39; must be one of </span><span class="si">{}</span><span class="s2">.&quot;</span>
<span class="o">.</span><span class="n">format</span><span class="p">(</span><span class="n">avx_type_override</span><span class="p">,</span> <span class="s2">&quot;,&quot;</span><span class="o">.</span><span class="n">join</span><span class="p">(</span><span class="n">VALID_VECTOR_EXTENSIONS</span><span class="p">))</span>
<span class="s2">&quot;neuralmagic: invalid avx instruction set &#39;</span><span class="si">{}</span><span class="s2">&#39; must be one of </span><span class="si">{}</span><span class="s2">.&quot;</span><span class="o">.</span><span class="n">format</span><span class="p">(</span>
<span class="n">avx_type_override</span><span class="p">,</span> <span class="s2">&quot;,&quot;</span><span class="o">.</span><span class="n">join</span><span class="p">(</span><span class="n">VALID_VECTOR_EXTENSIONS</span><span class="p">)</span>
<span class="p">)</span>
<span class="p">)</span>
<span class="n">arch</span><span class="o">.</span><span class="n">override_isa</span><span class="p">(</span><span class="n">avx_type_override</span><span class="p">)</span>

Expand Down
67 changes: 51 additions & 16 deletions deepsparse/_modules/deepsparse/engine.html

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion deepsparse/_modules/deepsparse/lib.html
Original file line number Diff line number Diff line change
Expand Up @@ -108,10 +108,11 @@
<ul>
<li class="toctree-l1"><a class="reference internal" href="../../api/deepsparse.html">deepsparse package</a></li>
</ul>
<p class="caption"><span class="caption-text">Help and Support</span></p>
<p class="caption"><span class="caption-text">Help</span></p>
<ul>
<li class="toctree-l1"><a class="reference external" href="https://github.com/neuralmagic/deepsparse/issues">Bugs, Feature Requests</a></li>
<li class="toctree-l1"><a class="reference external" href="https://github.com/neuralmagic/deepsparse/discussions">Support, General Q&amp;A</a></li>
<li class="toctree-l1"><a class="reference external" href="https://docs.neuralmagic.com">Neural Magic Docs</a></li>
</ul>


Expand Down
3 changes: 2 additions & 1 deletion deepsparse/_modules/deepsparse/utils/data.html
Original file line number Diff line number Diff line change
Expand Up @@ -108,10 +108,11 @@
<ul>
<li class="toctree-l1"><a class="reference internal" href="../../../api/deepsparse.html">deepsparse package</a></li>
</ul>
<p class="caption"><span class="caption-text">Help and Support</span></p>
<p class="caption"><span class="caption-text">Help</span></p>
<ul>
<li class="toctree-l1"><a class="reference external" href="https://github.com/neuralmagic/deepsparse/issues">Bugs, Feature Requests</a></li>
<li class="toctree-l1"><a class="reference external" href="https://github.com/neuralmagic/deepsparse/discussions">Support, General Q&amp;A</a></li>
<li class="toctree-l1"><a class="reference external" href="https://docs.neuralmagic.com">Neural Magic Docs</a></li>
</ul>


Expand Down
3 changes: 2 additions & 1 deletion deepsparse/_modules/deepsparse/utils/log.html
Original file line number Diff line number Diff line change
Expand Up @@ -108,10 +108,11 @@
<ul>
<li class="toctree-l1"><a class="reference internal" href="../../../api/deepsparse.html">deepsparse package</a></li>
</ul>
<p class="caption"><span class="caption-text">Help and Support</span></p>
<p class="caption"><span class="caption-text">Help</span></p>
<ul>
<li class="toctree-l1"><a class="reference external" href="https://github.com/neuralmagic/deepsparse/issues">Bugs, Feature Requests</a></li>
<li class="toctree-l1"><a class="reference external" href="https://github.com/neuralmagic/deepsparse/discussions">Support, General Q&amp;A</a></li>
<li class="toctree-l1"><a class="reference external" href="https://docs.neuralmagic.com">Neural Magic Docs</a></li>
</ul>


Expand Down
3 changes: 2 additions & 1 deletion deepsparse/_modules/deepsparse/utils/onnx.html
Original file line number Diff line number Diff line change
Expand Up @@ -108,10 +108,11 @@
<ul>
<li class="toctree-l1"><a class="reference internal" href="../../../api/deepsparse.html">deepsparse package</a></li>
</ul>
<p class="caption"><span class="caption-text">Help and Support</span></p>
<p class="caption"><span class="caption-text">Help</span></p>
<ul>
<li class="toctree-l1"><a class="reference external" href="https://github.com/neuralmagic/deepsparse/issues">Bugs, Feature Requests</a></li>
<li class="toctree-l1"><a class="reference external" href="https://github.com/neuralmagic/deepsparse/discussions">Support, General Q&amp;A</a></li>
<li class="toctree-l1"><a class="reference external" href="https://docs.neuralmagic.com">Neural Magic Docs</a></li>
</ul>


Expand Down
3 changes: 2 additions & 1 deletion deepsparse/_modules/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -108,10 +108,11 @@
<ul>
<li class="toctree-l1"><a class="reference internal" href="../api/deepsparse.html">deepsparse package</a></li>
</ul>
<p class="caption"><span class="caption-text">Help and Support</span></p>
<p class="caption"><span class="caption-text">Help</span></p>
<ul>
<li class="toctree-l1"><a class="reference external" href="https://github.com/neuralmagic/deepsparse/issues">Bugs, Feature Requests</a></li>
<li class="toctree-l1"><a class="reference external" href="https://github.com/neuralmagic/deepsparse/discussions">Support, General Q&amp;A</a></li>
<li class="toctree-l1"><a class="reference external" href="https://docs.neuralmagic.com">Neural Magic Docs</a></li>
</ul>


Expand Down
15 changes: 15 additions & 0 deletions deepsparse/_sources/api/deepsparse.rst.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,18 @@
..
Copyright (c) 2021 - present / Neuralmagic, Inc. All Rights Reserved.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
deepsparse package
==================

Expand Down
15 changes: 15 additions & 0 deletions deepsparse/_sources/api/deepsparse.utils.rst.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,18 @@
..
Copyright (c) 2021 - present / Neuralmagic, Inc. All Rights Reserved.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
deepsparse.utils package
========================

Expand Down
15 changes: 15 additions & 0 deletions deepsparse/_sources/api/modules.rst.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,18 @@
..
Copyright (c) 2021 - present / Neuralmagic, Inc. All Rights Reserved.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
deepsparse
==========

Expand Down
85 changes: 46 additions & 39 deletions deepsparse/_sources/index.rst.txt
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,17 @@
DeepSparse |version|
====================

CPU inference engine that delivers unprecedented performance for sparse models.
Neural network inference engine that delivers GPU-class performance for sparsified models on CPUs

.. raw:: html

<div style="margin-bottom:16px;">
<a href="https://github.com/neuralmagic/deepsparse/blob/main/LICENSE-NEURALMAGIC"><img alt="GitHub" src="https://img.shields.io/static/v1.svg?label=LICENSE&message=neural%20magic%20engine&color=purple&style=for-the-badge" height=25>
</a>
<a href="https://github.com/neuralmagic/deepsparse/blob/main/LICENSE">
<img alt="GitHub" src="https://img.shields.io/github/license/neuralmagic/sparseml.svg?color=purple&style=for-the-badge" height=25>
</a>
<a href="https://github.com/neuralmagic/deepsparse/blob/main/LICENSE-NEURALMAGIC">
<img alt="GitHub" src="https://img.shields.io/static/v1.svg?label=LICENSE&message=neural%20magic%20engine&color=purple&style=for-the-badge" height=25 style="margin-bottom:4px;">
</a>
<a href="https://github.com/neuralmagic/deepsparse/blob/main/LICENSE">
<img alt="GitHub" src="https://img.shields.io/static/v1.svg?label=LICENSE&message=apache-2.0&color=purple&style=for-the-badge" height=25 style="margin-bottom:4px;">
</a>
<a href="https://docs.neuralmagic.com/deepsparse/index.html">
<img alt="Documentation" src="https://img.shields.io/website/http/docs.neuralmagic.com/deepsparse/index.html.svg?down_color=red&down_message=offline&up_message=online&style=for-the-badge" height=25 style="margin-bottom:4px;">
</a>
Expand All @@ -50,54 +51,59 @@ CPU inference engine that delivers unprecedented performance for sparse models.
Overview
========

The DeepSparse Engine is a CPU runtime that delivers unprecedented performance by taking advantage of
natural sparsity within neural networks to reduce compute required as well as accelerate memory bound workloads.
It is focused on model deployment and scaling machine learning pipelines,
fitting seamlessly into your existing deployments as an inference backend.
The DeepSparse Engine is a CPU runtime that delivers GPU-class performance by taking advantage of sparsity within neural networks to reduce compute required as well as accelerate memory bound workloads.
It is focused on model deployment and scaling machine learning pipelines, fitting seamlessly into your existing deployments as an inference backend.

`This repository <https://github.com/neuralmagic/deepsparse />`_ includes package APIs along with examples to quickly get started benchmarking and inferencing sparse models.

Sparsification
==============

Sparsification is the process of taking a trained deep learning model and removing redundant information from the overprecise and over-parameterized network resulting in a faster and smaller model.
Techniques for sparsification are all encompassing including everything from inducing sparsity using `pruning <https://neuralmagic.com/blog/pruning-overview/>`_ and `quantization <https://arxiv.org/abs/1609.07061>`_ to enabling naturally occurring sparsity using `activation sparsity <http://proceedings.mlr.press/v119/kurtz20a.html>`_ or `winograd/FFT <https://arxiv.org/abs/1509.09308>`_.
When implemented correctly, these techniques result in significantly more performant and smaller models with limited to no effect on the baseline metrics.
For example, pruning plus quantization can give over `7x improvements in performance <https://neuralmagic.com/blog/benchmark-resnet50-with-deepsparse>`_ while recovering to nearly the same baseline accuracy.

The Deep Sparse product suite builds on top of sparsification enabling you to easily apply the techniques to your datasets and models using recipe-driven approaches.
Recipes encode the directions for how to sparsify a model into a simple, easily editable format.
- Download a sparsification recipe and sparsified model from the `SparseZoo <https://github.com/neuralmagic/sparsezoo>`_.
- Alternatively, create a recipe for your model using `Sparsify <https://github.com/neuralmagic/sparsify>`_.
- Apply your recipe with only a few lines of code using `SparseML <https://github.com/neuralmagic/sparseml>`_.
- Finally, for GPU-level performance on CPUs, deploy your sparse-quantized model with the `DeepSparse Engine <https://github.com/neuralmagic/deepsparse>`_.

`This GitHub repository <https://github.com/neuralmagic/deepsparse />`_ includes package APIs along with examples to quickly get started learning about and
actually running sparse models.

**Full Deep Sparse product flow:**

<img src="https://docs.neuralmagic.com/docs/source/sparsification/flow-overview.svg" width="960px">

Compatibility
=============

The DeepSparse Engine ingests models in the `ONNX <https://onnx.ai/ />`_ format,
allowing for compatibility with `PyTorch <https://pytorch.org/docs/stable/onnx.html />`_,
`TensorFlow <https://github.com/onnx/tensorflow-onnx />`_, `Keras <https://github.com/onnx/keras-onnx />`_,
and `many other frameworks <https://github.com/onnx/onnxmltools />`_ that support it.
The DeepSparse Engine ingests models in the `ONNX <https://onnx.ai>`_ format,
allowing for compatibility with `PyTorch <https://pytorch.org/docs/stable/onnx.html>`_,
`TensorFlow <https://github.com/onnx/tensorflow-onnx>`_, `Keras <https://github.com/onnx/keras-onnx>`_,
and `many other frameworks <https://github.com/onnx/onnxmltools>`_ that support it.
This reduces the extra work of preparing your trained model for inference to just one step of exporting.

Related Products
================

- `SparseZoo <https://github.com/neuralmagic/sparsezoo />`_:
Neural network model repository for highly sparse models and optimization recipes
- `SparseML <https://github.com/neuralmagic/sparseml />`_:
Libraries for state-of-the-art deep neural network optimization algorithms,
enabling simple pipelines integration with a few lines of code
- `Sparsify <https://github.com/neuralmagic/sparsify />`_:
Easy-to-use autoML interface to optimize deep neural networks for
better inference performance and a smaller footprint

Resources and Learning More
===========================

- `SparseZoo Documentation <https://docs.neuralmagic.com/sparsezoo/ />`_
- `SparseML Documentation <https://docs.neuralmagic.com/sparseml/ />`_
- `Sparsify Documentation <https://docs.neuralmagic.com/sparsify/ />`_
- `Neural Magic Blog <https://www.neuralmagic.com/blog/ />`_,
`Resources <https://www.neuralmagic.com/resources/ />`_,
`Website <https://www.neuralmagic.com/ />`_
- `SparseZoo Documentation <https://docs.neuralmagic.com/sparsezoo>`_
- `SparseML Documentation <https://docs.neuralmagic.com/sparseml>`_
- `Sparsify Documentation <https://docs.neuralmagic.com/sparsify>`_
- `Neural Magic Blog <https://www.neuralmagic.com/blog>`_,
`Resources <https://www.neuralmagic.com/resources>`_,
`Website <https://www.neuralmagic.com>`_

Release History
===============

Official builds are hosted on PyPi
- stable: `deepsparse <https://pypi.org/project/deepsparse/ />`_
- nightly (dev): `deepsparse-nightly <https://pypi.org/project/deepsparse-nightly/ />`_
- stable: `deepsparse <https://pypi.org/project/deepsparse>`_
- nightly (dev): `deepsparse-nightly <https://pypi.org/project/deepsparse-nightly>`_

Additionally, more information can be found via
`GitHub Releases <https://github.com/neuralmagic/deepsparse/releases />`_.
`GitHub Releases <https://github.com/neuralmagic/deepsparse/releases>`_.

.. toctree::
:maxdepth: 3
Expand All @@ -120,8 +126,9 @@ Additionally, more information can be found via
api/deepsparse

.. toctree::
:maxdepth: 2
:caption: Help and Support
:maxdepth: 3
:caption: Help

Bugs, Feature Requests <https://github.com/neuralmagic/deepsparse/issues>
Support, General Q&A <https://github.com/neuralmagic/deepsparse/discussions>
Neural Magic Docs <https://docs.neuralmagic.com>
Loading

0 comments on commit 3074bb8

Please sign in to comment.