Skip to content

Commit 9ac58fc

Browse files
author
Robert Muchsel
authored
Remove distiller from synthesis project; update onnx package; update README (#128)
* README: Add Centos/RHEL 8 instructions
1 parent d701938 commit 9ac58fc

File tree

6 files changed

+49
-20
lines changed

6 files changed

+49
-20
lines changed

.gitmodules

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,3 @@
11
[submodule "sdk"]
22
path = sdk
33
url = https://github.com/MaximIntegratedAI/MAX78000_SDK.git
4-
[submodule "distiller"]
5-
path = distiller
6-
url = https://github.com/MaximIntegratedAI/distiller.git
7-
branch = pytorch-1.5

README.md

Lines changed: 48 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# MAX78000 Model Training and Synthesis
22

3-
_April 20, 2021_
3+
_April 22, 2021_
44

55
The Maxim Integrated AI project is comprised of four repositories:
66

@@ -90,23 +90,63 @@ The following software is optional, and can be replaced with other similar softw
9090

9191
### Project Installation
9292

93-
*The software in this project uses Python 3.8.9 or a later 3.8.x version.*
93+
#### System Packages
9494

95-
It is not necessary to install Python 3.8.9 system-wide, or to rely on the system-provided Python. To manage Python versions, use `pyenv` (https://github.com/pyenv/pyenv).
95+
Some additional system packages are required, and installation of these additional packages requires administrator privileges. Note that this is the only time administrator privileges are required unless the optional Manifold is installed locally.
9696

97-
On macOS (no CUDA support available):
97+
##### macOS
98+
99+
On macOS (no CUDA support available) use:
98100

99101
```shell
100-
$ brew install pyenv pyenv-virtualenv libomp libsndfile tcl-tk
102+
$ brew install libomp libsndfile tcl-tk
101103
```
102104

103-
On Linux:
105+
##### Linux (Ubuntu)
104106

105107
```shell
106108
$ sudo apt-get install -y make build-essential libssl-dev zlib1g-dev \
107109
libbz2-dev libreadline-dev libsqlite3-dev wget curl llvm \
108110
libncurses5-dev libncursesw5-dev xz-utils tk-dev libffi-dev liblzma-dev \
109111
libsndfile-dev portaudio19-dev
112+
```
113+
114+
###### RedHat Enterprise Linux / CentOS 8
115+
116+
While Ubuntu 20.04 LTS is the supported distribution, the MAX78000 software packages run fine on all modern Linux distributions that also support CUDA. The *apt-get install* commands above must be replaced with distribution specific commands and package names. Unfortunately, there is no obvious 1:1 mapping between package names from one distribution to the next. The following example shows the commands needed for RHEL/CentOS 8.
117+
118+
*Two of the required packages are not in the base repositories. Enable the EPEL and PowerTools repositories:*
119+
120+
```shell
121+
$ sudo dnf install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm
122+
$ sudo dnf config-manager --set-enabled powertools
123+
```
124+
125+
*Proceed to install the required packages:*
126+
127+
```shell
128+
$ sudo dnf group install "Development Tools"
129+
$ sudo dnf install openssl-devel zlib-devel \
130+
bzip2-devel readline-devel sqlite-devel wget llvm \
131+
xz-devel tk tk-devel libffi-devel \
132+
libsndfile libsndfile-devel portaudio-devel
133+
```
134+
135+
#### Python 3.8
136+
137+
*The software in this project uses Python 3.8.9 or a later 3.8.x version.*
138+
139+
It is not necessary to install Python 3.8.9 system-wide, or to rely on the system-provided Python. To manage Python versions, use `pyenv` (https://github.com/pyenv/pyenv).
140+
141+
On macOS (no CUDA support available):
142+
143+
```shell
144+
$ brew install pyenv pyenv-virtualenv
145+
```
146+
147+
On Linux:
148+
149+
```shell
110150
$ curl -L https://github.com/pyenv/pyenv-installer/raw/master/bin/pyenv-installer | bash # NOTE: Verify contents of the script before running it!!
111151
```
112152

@@ -161,9 +201,9 @@ Add this line to `~/.profile` (and on macOS, to `~/.zprofile`).
161201

162202
#### Nervana Distiller
163203

164-
Nirvana Distiller is package for neural network compression and quantization. Network compression can reduce the memory footprint of a neural network, increase its inference speed and save energy. Distiller is automatically installed with the other packages.
204+
Nirvana Distiller is package for neural network compression and quantization. Network compression can reduce the memory footprint of a neural network, increase its inference speed and save energy. Distiller is automatically installed as a git sub-module with the other packages.
165205

166-
#### Uber Manifold
206+
#### Uber Manifold (Optional)
167207

168208
Manifold is a model-agnostic visual debugging tool for machine learning. Manifold can compare models, detects which subset of data a model is inaccurately predicting, and explains the potential cause of poor model performance by surfacing the feature distribution difference between better and worse-performing subsets of data.
169209

README.pdf

10.3 KB
Binary file not shown.

distiller

Lines changed: 0 additions & 1 deletion
This file was deleted.

izer/quantize.py

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,6 @@
1212

1313
import torch
1414

15-
from distiller.apputils.checkpoint import get_contents_table # pylint: disable=no-name-in-module
16-
1715
from . import tornadocnn as tc
1816
from . import yamlcfg
1917
from .devices import device
@@ -46,9 +44,6 @@ def convert_checkpoint(input_file, output_file, arguments):
4644
print("Converting checkpoint file", input_file, "to", output_file)
4745
checkpoint = torch.load(input_file, map_location='cpu')
4846

49-
if arguments.verbose:
50-
print(get_contents_table(checkpoint))
51-
5247
if 'state_dict' not in checkpoint:
5348
eprint("No `state_dict` in checkpoint file.")
5449

requirements.txt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ six>=1.12.0
66
scipy>=1.3.0
77
torch==1.8.1
88
pytest~=4.6.4
9-
onnx>=1.7.0
9+
onnx>=1.9.0
1010
tensorboard==2.4.1
1111
colorama>=0.4.4
12-
-e file:distiller

0 commit comments

Comments
 (0)