Skip to content

Commit

Permalink
deploy: 2198162
Browse files Browse the repository at this point in the history
  • Loading branch information
guizili0 committed Sep 5, 2023
1 parent e80c603 commit 337116e
Show file tree
Hide file tree
Showing 64 changed files with 126 additions and 332 deletions.
4 changes: 2 additions & 2 deletions latest/CODE_OF_CONDUCT.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<meta charset="utf-8" /><meta name="generator" content="Docutils 0.18.1: http://docutils.sourceforge.net/" />

<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Contributor Covenant Code of Conduct &mdash; Intel® Extension for TensorFlow* 0.1.dev1+g864d43e documentation</title>
<title>Contributor Covenant Code of Conduct &mdash; Intel® Extension for TensorFlow* 0.1.dev1+g2198162 documentation</title>
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
<link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="_static/custom.css" type="text/css" />
Expand Down Expand Up @@ -222,7 +222,7 @@ <h2>Attribution<a class="headerlink" href="#attribution" title="Permalink to thi
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
<jinja2.runtime.BlockReference object at 0x7fbd35fbe140>
<jinja2.runtime.BlockReference object at 0x7fa90d439330>
<p></p><div><a href='https://www.intel.com/content/www/us/en/privacy/intel-cookie-notice.html' data-cookie-notice='true'>Cookies</a> <a href='https://www.intel.com/content/www/us/en/privacy/intel-privacy-notice.html'>| Privacy</a></div>


Expand Down
4 changes: 2 additions & 2 deletions latest/SECURITY.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<meta charset="utf-8" /><meta name="generator" content="Docutils 0.18.1: http://docutils.sourceforge.net/" />

<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Security Policy &mdash; Intel® Extension for TensorFlow* 0.1.dev1+g864d43e documentation</title>
<title>Security Policy &mdash; Intel® Extension for TensorFlow* 0.1.dev1+g2198162 documentation</title>
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
<link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="_static/custom.css" type="text/css" />
Expand Down Expand Up @@ -117,7 +117,7 @@ <h2>Report a Vulnerability<a class="headerlink" href="#report-a-vulnerability" t
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
<jinja2.runtime.BlockReference object at 0x7fbd364cb7c0>
<jinja2.runtime.BlockReference object at 0x7fa90d6d1ed0>
<p></p><div><a href='https://www.intel.com/content/www/us/en/privacy/intel-cookie-notice.html' data-cookie-notice='true'>Cookies</a> <a href='https://www.intel.com/content/www/us/en/privacy/intel-privacy-notice.html'>| Privacy</a></div>


Expand Down
93 changes: 1 addition & 92 deletions latest/_sources/examples/train_horovod/resnet50/README.md.txt
Original file line number Diff line number Diff line change
@@ -1,92 +1 @@
# Distributed Training Example with Intel® Optimization for Horovod*

## Model Information

| Use Case |Framework | Model Repo | Branch Commit Tag | Optional Patch
| :---: | :---: | :---: | :---: | :---: |
| Training | TensorFlow | [Tensorflow-Models](https://github.com/tensorflow/models) | v2.8.0 | itex.yaml <br> itex_dummy.yaml <br> hvd_support_light.patch <br> or hvd_support.patch |

<br>

## Dependency
- [Tensorflow](https://pypi.org/project/tensorflow/)
- [Intel® Extension for TensorFlow*](https://pypi.org/project/intel-extension-for-tensorflow/)
- [Intel® Optimization for Horovod*](https://pypi.org/project/intel-optimization-for-Horovod/)
- others show as below
```
pip install gin gin-config tensorflow-addons tensorflow-model-optimization tensorflow-datasets
```

## Model examples preparation

### Model Repo
```
WORKSPACE=xxxx # set your workspace folder
cd $WORKSPACE
git clone -b v2.8.0 https://github.com/tensorflow/models.git tensorflow-models
cd tensorflow-models
git apply path/to/hvd_support_light.patch # or path/to/hvd_support.patch
```
**hvd_support_light.patch** is the minimum change.
- hvd.init() is Horovod initialization, including resource allocation.
- tf.config.experimental.set_memory_growth(): If memory growth is enabled, the runtime initialization will not allocate all memory on the device.
- tf.config.experimental.set_visible_devices(): Set the list of visible devices.
- strategy_scope: Remove native distributed.
- hvd.DistributedOptimizer(): use Horovod distributed optimizer.
- dataset.shard(): Multiple workers run the same code but with different data. Dataset is split equally between different index workers.

**hvd_support.patch** adds LARS optimizer [paper](https://arxiv.org/abs/1708.03888)

### Download Dataset
Download imagenet dataset from https://image-net.org/download-images.php


**Note** Only for non-commercial research and/or educational purposes

<br>

## Execution
### Set Model Parameters
Export those parameters to script or environment.
```
export PYTHONPATH=${WORKSPACE}/tensorflow-models
MODEL_DIR=${WORKSPACE}/output
DATA_DIR=${WORKSPACE}/imagenet_data/imagenet

CONFIG_FILE=path/to/itex.yaml
NUMBER_OF_PROCESS=2
PROCESS_PER_NODE=2
```
- Download `itex.yaml` or `itex_dummy.yaml` and set one of them as CONFIG_FILE, then model would correspondingly run with `real data` or `dummy data`. Default value is itex.yaml.
- Set `NUMBER_OF_PROCESS` and `PROCESS_PER_NODE` according to hvd rank number you need. Default value is a 2 rank task.
### HVD command

```
if [ ! -d "$MODEL_DIR" ]; then
mkdir -p $MODEL_DIR
else
rm -rf $MODEL_DIR && mkdir -p $MODEL_DIR
fi

mpirun -np $NUMBER_OF_PROCESS -ppn $PROCESS_PER_NODE --prepend-rank \
python ${PYTHONPATH}/official/vision/image_classification/classifier_trainer.py \
--mode=train_and_eval \
--model_type=resnet \
--dataset=imagenet \
--model_dir=$MODEL_DIR \
--data_dir=$DATA_DIR \
--config_file=$CONFIG_FILE
```

<br>

## OUTPUT
### Performance Data
```
[1] I0909 03:33:23.323099 140645511436096 keras_utils.py:145] TimeHistory: xxxx seconds, xxxx examples/second between steps 0 and 100
[0] I0909 03:33:23.324534 140611700504384 keras_utils.py:145] TimeHistory: xxxx seconds, xxxx examples/second between steps 0 and 100
[0] I0909 03:33:43.037004 140611700504384 keras_utils.py:145] TimeHistory: xxxx seconds, xxxx examples/second between steps 100 and 200
[1] I0909 03:33:43.037142 140645511436096 keras_utils.py:145] TimeHistory: xxxx seconds, xxxx examples/second between steps 100 and 200
[1] I0909 03:34:03.213994 140645511436096 keras_utils.py:145] TimeHistory: xxxx seconds, xxxx examples/second between steps 200 and 300
[0] I0909 03:34:03.214127 140611700504384 keras_utils.py:145] TimeHistory: xxxx seconds, xxxx examples/second between steps 200 and 300
```
## Refer to [train_resnet50](../../train_resnet50)
2 changes: 1 addition & 1 deletion latest/_static/documentation_options.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
var DOCUMENTATION_OPTIONS = {
URL_ROOT: document.getElementById("documentation_options").getAttribute('data-url_root'),
VERSION: '0.1.dev1+g864d43e',
VERSION: '0.1.dev1+g2198162',
LANGUAGE: 'en',
COLLAPSE_INDEX: false,
BUILDER: 'html',
Expand Down
4 changes: 2 additions & 2 deletions latest/docker/README.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<meta charset="utf-8" /><meta name="generator" content="Docutils 0.18.1: http://docutils.sourceforge.net/" />

<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Intel® Extension for TensorFlow* Docker Container Guide &mdash; Intel® Extension for TensorFlow* 0.1.dev1+g864d43e documentation</title>
<title>Intel® Extension for TensorFlow* Docker Container Guide &mdash; Intel® Extension for TensorFlow* 0.1.dev1+g2198162 documentation</title>
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
<link rel="stylesheet" href="../_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="../_static/custom.css" type="text/css" />
Expand Down Expand Up @@ -204,7 +204,7 @@ <h2>Verify That Intel GPU is Accessible From TensorFlow<a class="headerlink" hre
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
<jinja2.runtime.BlockReference object at 0x7fbd364cb7f0>
<jinja2.runtime.BlockReference object at 0x7fa90d679e10>
<p></p><div><a href='https://www.intel.com/content/www/us/en/privacy/intel-cookie-notice.html' data-cookie-notice='true'>Cookies</a> <a href='https://www.intel.com/content/www/us/en/privacy/intel-privacy-notice.html'>| Privacy</a></div>


Expand Down
4 changes: 2 additions & 2 deletions latest/docker/tensorflow-serving/README.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<meta charset="utf-8" /><meta name="generator" content="Docutils 0.18.1: http://docutils.sourceforge.net/" />

<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Intel® Extension for TensorFlow* Serving - Docker Container Guide &mdash; Intel® Extension for TensorFlow* 0.1.dev1+g864d43e documentation</title>
<title>Intel® Extension for TensorFlow* Serving - Docker Container Guide &mdash; Intel® Extension for TensorFlow* 0.1.dev1+g2198162 documentation</title>
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
<link rel="stylesheet" href="../../_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="../../_static/custom.css" type="text/css" />
Expand Down Expand Up @@ -163,7 +163,7 @@ <h2>Running the Container<a class="headerlink" href="#running-the-container" tit
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
<jinja2.runtime.BlockReference object at 0x7fbd35f0bc70>
<jinja2.runtime.BlockReference object at 0x7fa90d446260>
<p></p><div><a href='https://www.intel.com/content/www/us/en/privacy/intel-cookie-notice.html' data-cookie-notice='true'>Cookies</a> <a href='https://www.intel.com/content/www/us/en/privacy/intel-privacy-notice.html'>| Privacy</a></div>


Expand Down
4 changes: 2 additions & 2 deletions latest/docs/README.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<meta charset="utf-8" /><meta name="generator" content="Docutils 0.18.1: http://docutils.sourceforge.net/" />

<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Welcome to Intel® Extension for TensorFlow* documentation &mdash; Intel® Extension for TensorFlow* 0.1.dev1+g864d43e documentation</title>
<title>Welcome to Intel® Extension for TensorFlow* documentation &mdash; Intel® Extension for TensorFlow* 0.1.dev1+g2198162 documentation</title>
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
<link rel="stylesheet" href="../_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="../_static/custom.css" type="text/css" />
Expand Down Expand Up @@ -216,7 +216,7 @@ <h2>Highlights<a class="headerlink" href="#highlights" title="Permalink to this
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
<jinja2.runtime.BlockReference object at 0x7fbd363017e0>
<jinja2.runtime.BlockReference object at 0x7fa90d4478b0>
<p></p><div><a href='https://www.intel.com/content/www/us/en/privacy/intel-cookie-notice.html' data-cookie-notice='true'>Cookies</a> <a href='https://www.intel.com/content/www/us/en/privacy/intel-privacy-notice.html'>| Privacy</a></div>


Expand Down
4 changes: 2 additions & 2 deletions latest/docs/build_docs/docs_build_tips.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<meta charset="utf-8" /><meta name="generator" content="Docutils 0.18.1: http://docutils.sourceforge.net/" />

<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Online Documentation Build Guide &mdash; Intel® Extension for TensorFlow* 0.1.dev1+g864d43e documentation</title>
<title>Online Documentation Build Guide &mdash; Intel® Extension for TensorFlow* 0.1.dev1+g2198162 documentation</title>
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
<link rel="stylesheet" href="../../_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="../../_static/custom.css" type="text/css" />
Expand Down Expand Up @@ -158,7 +158,7 @@ <h2>Build to Local Test<a class="headerlink" href="#build-to-local-test" title="
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
<jinja2.runtime.BlockReference object at 0x7fbd35d229b0>
<jinja2.runtime.BlockReference object at 0x7fa90d27af80>
<p></p><div><a href='https://www.intel.com/content/www/us/en/privacy/intel-cookie-notice.html' data-cookie-notice='true'>Cookies</a> <a href='https://www.intel.com/content/www/us/en/privacy/intel-privacy-notice.html'>| Privacy</a></div>


Expand Down
4 changes: 2 additions & 2 deletions latest/docs/build_docs/source/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<meta charset="utf-8" /><meta name="generator" content="Docutils 0.18.1: http://docutils.sourceforge.net/" />

<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Welcome to Intel ® Extension for TensorFlow* documentation! &mdash; Intel® Extension for TensorFlow* 0.1.dev1+g864d43e documentation</title>
<title>Welcome to Intel ® Extension for TensorFlow* documentation! &mdash; Intel® Extension for TensorFlow* 0.1.dev1+g2198162 documentation</title>
<link rel="stylesheet" href="../../../_static/pygments.css" type="text/css" />
<link rel="stylesheet" href="../../../_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="../../../_static/custom.css" type="text/css" />
Expand Down Expand Up @@ -107,7 +107,7 @@ <h1>Welcome to Intel ® Extension for TensorFlow* documentation!<a class="header
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
<jinja2.runtime.BlockReference object at 0x7fbd360727a0>
<jinja2.runtime.BlockReference object at 0x7fa90d278c70>
<p></p><div><a href='https://www.intel.com/content/www/us/en/privacy/intel-cookie-notice.html' data-cookie-notice='true'>Cookies</a> <a href='https://www.intel.com/content/www/us/en/privacy/intel-privacy-notice.html'>| Privacy</a></div>


Expand Down
4 changes: 2 additions & 2 deletions latest/docs/community/contributing.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<meta charset="utf-8" /><meta name="generator" content="Docutils 0.18.1: http://docutils.sourceforge.net/" />

<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Contributing guidelines &mdash; Intel® Extension for TensorFlow* 0.1.dev1+g864d43e documentation</title>
<title>Contributing guidelines &mdash; Intel® Extension for TensorFlow* 0.1.dev1+g2198162 documentation</title>
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
<link rel="stylesheet" href="../../_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="../../_static/custom.css" type="text/css" />
Expand Down Expand Up @@ -257,7 +257,7 @@ <h3>Documentation style guide<a class="headerlink" href="#documentation-style-gu
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
<jinja2.runtime.BlockReference object at 0x7fbd35d22e30>
<jinja2.runtime.BlockReference object at 0x7fa90d447640>
<p></p><div><a href='https://www.intel.com/content/www/us/en/privacy/intel-cookie-notice.html' data-cookie-notice='true'>Cookies</a> <a href='https://www.intel.com/content/www/us/en/privacy/intel-privacy-notice.html'>| Privacy</a></div>


Expand Down
4 changes: 2 additions & 2 deletions latest/docs/community/releases.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<meta charset="utf-8" /><meta name="generator" content="Docutils 0.18.1: http://docutils.sourceforge.net/" />

<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Releases &mdash; Intel® Extension for TensorFlow* 0.1.dev1+g864d43e documentation</title>
<title>Releases &mdash; Intel® Extension for TensorFlow* 0.1.dev1+g2198162 documentation</title>
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
<link rel="stylesheet" href="../../_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="../../_static/custom.css" type="text/css" />
Expand Down Expand Up @@ -127,7 +127,7 @@ <h2>Incompatible Changes<a class="headerlink" href="#incompatible-changes" title
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
<jinja2.runtime.BlockReference object at 0x7fbd363002e0>
<jinja2.runtime.BlockReference object at 0x7fa90d279a50>
<p></p><div><a href='https://www.intel.com/content/www/us/en/privacy/intel-cookie-notice.html' data-cookie-notice='true'>Cookies</a> <a href='https://www.intel.com/content/www/us/en/privacy/intel-privacy-notice.html'>| Privacy</a></div>


Expand Down
4 changes: 2 additions & 2 deletions latest/docs/design/directory_structure.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<meta charset="utf-8" /><meta name="generator" content="Docutils 0.18.1: http://docutils.sourceforge.net/" />

<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Directory Tree Structure &mdash; Intel® Extension for TensorFlow* 0.1.dev1+g864d43e documentation</title>
<title>Directory Tree Structure &mdash; Intel® Extension for TensorFlow* 0.1.dev1+g2198162 documentation</title>
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
<link rel="stylesheet" href="../../_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="../../_static/custom.css" type="text/css" />
Expand Down Expand Up @@ -183,7 +183,7 @@ <h1>Directory Tree Structure<a class="headerlink" href="#directory-tree-structur
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
<jinja2.runtime.BlockReference object at 0x7fbd35f0ba60>
<jinja2.runtime.BlockReference object at 0x7fa90d279de0>
<p></p><div><a href='https://www.intel.com/content/www/us/en/privacy/intel-cookie-notice.html' data-cookie-notice='true'>Cookies</a> <a href='https://www.intel.com/content/www/us/en/privacy/intel-privacy-notice.html'>| Privacy</a></div>


Expand Down
4 changes: 2 additions & 2 deletions latest/docs/design/extension_design.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<meta charset="utf-8" /><meta name="generator" content="Docutils 0.18.1: http://docutils.sourceforge.net/" />

<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Extension Design &mdash; Intel® Extension for TensorFlow* 0.1.dev1+g864d43e documentation</title>
<title>Extension Design &mdash; Intel® Extension for TensorFlow* 0.1.dev1+g2198162 documentation</title>
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
<link rel="stylesheet" href="../../_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="../../_static/custom.css" type="text/css" />
Expand Down Expand Up @@ -121,7 +121,7 @@ <h2>Resources<a class="headerlink" href="#resources" title="Permalink to this he
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
<jinja2.runtime.BlockReference object at 0x7fbd364cb7f0>
<jinja2.runtime.BlockReference object at 0x7fa90d278550>
<p></p><div><a href='https://www.intel.com/content/www/us/en/privacy/intel-cookie-notice.html' data-cookie-notice='true'>Cookies</a> <a href='https://www.intel.com/content/www/us/en/privacy/intel-privacy-notice.html'>| Privacy</a></div>


Expand Down
Loading

0 comments on commit 337116e

Please sign in to comment.