# ADI MAX78000/MAX78002 Model Training and Synthesis
June 14, 2022
ADI’s MAX78000/MAX78002 project is comprised of five repositories:
1. **Start here**:
**[Top Level Documentation](https://github.com/MaximIntegratedAI/MaximAI_Documentation)**
2. The software development kit (SDK), which contains drivers and example programs ready to run on the evaluation kits (EVkit and Feather):
[MAX78000_SDK](https://github.com/MaximIntegratedAI/MAX78000_SDK) *also includes MAX78002 support*
3. The training repository, which is used for deep learning *model development and training*:
[ai8x-training](https://github.com/MaximIntegratedAI/ai8x-training) **(described in this document)**
4. The synthesis repository, which is used to *convert a trained model into C code* using the “izer” tool:
[ai8x-synthesis](https://github.com/MaximIntegratedAI/ai8x-synthesis) **(described in this document)**
5. The reference design repository, which contains host applications and sample applications for reference designs:
[refdes](https://github.com/MaximIntegratedAI/refdes)
_Open the `.md` version of this file in a markdown enabled viewer, for example Typora (<http://typora.io>).
See <https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet> for a description of Markdown. A [PDF copy of this file](README.pdf) is available in this repository. The GitHub rendering of this document does not show the mathematical formulas. Use the ≡ button to access the table of contents on GitHub._
---
[TOC]
## Part Numbers
This document covers several of ADI’s ultra-low power machine learning accelerator systems. They are sometimes referred to by their die types. The following shows the die types and their corresponding part numbers:
| Die Type | Part Number(s) |
| -------- | ------------------------------ |
| *AI84* | *Unreleased test chip* |
| **AI85** | **MAX78000** (full production) |
| AI87 | MAX78002 (engineering samples) |
## Overview
The following graphic shows an overview of the development flow:
![Development Flow](docs/DevelopmentFlow.png)
## Installation
### File System Layout
Including the SDK, the expected/resulting file system layout will be:
..../ai8x-training/
..../ai8x-synthesis/
..../ai8x-synthesis/sdk/
where “....” is the project root, for example `~/Documents/Source/AI`.
### Prerequisites
This software requires PyTorch. *For TensorFlow / Keras, please use the `develop-tf` branch.*
PyTorch operating system and hardware support are constantly evolving. This document does not cover all possible combinations of operating system and hardware. Instead, this document describes how to install PyTorch on one officially supported platform.
#### Platform Recommendation and Full Support
Full support and documentation are provided for the following platform:
* CPU: 64-bit amd64/x86_64 “PC” with [Ubuntu Linux 20.04 LTS](https://ubuntu.com/download/server)
* GPU for hardware acceleration (optional but highly recommended): Nvidia with [CUDA 11](https://developer.nvidia.com/cuda-toolkit-archive)
* [PyTorch 1.8.1 (LTS)](https://pytorch.org/get-started/locally/) on Python 3.8.x
Limited support and advice for using other hardware and software combinations is available as follows.
#### Operating System Support
##### Linux
**The only officially supported platform for model training** is Ubuntu Linux 20.04 LTS on amd64/x86_64, either the desktop or the [server version](https://ubuntu.com/download/server).
*Note that hardware acceleration/CUDA is <u>not available</u> in PyTorch for Raspberry Pi 4 and other <u>aarch64/arm64</u> devices, even those running Ubuntu Linux 20.04. See also [Development on Raspberry Pi 4 and 400](https://github.com/MaximIntegratedAI/ai8x-synthesis/blob/develop/docs/RaspberryPi.md) (unsupported).*
This document also provides instructions for installing on RedHat Enterprise Linux / CentOS 8 with limited support.
##### Windows
On Windows 10 version 21H2 or newer, and Windows 11, after installing the Windows Subsystem for Linux (WSL2), Ubuntu Linux 20.04 can be used inside Windows with full CUDA acceleration, please see *[Windows Subsystem for Linux](https://github.com/MaximIntegratedAI/ai8x-synthesis/blob/develop/docs/WSL2.md).* For the remainder of this document, follow the steps for Ubuntu Linux.
If WSL2 is not available, it is also possible (but not recommended due to inherent compatibility issues and slightly degraded performance) to run this software natively on Windows. Please see *[Native Windows Installation](https://github.com/MaximIntegratedAI/ai8x-synthesis/blob/develop/docs/Windows.md)*.
##### macOS
The software works on macOS, but model training suffers from the lack of hardware acceleration.
##### Virtual Machines (Unsupported)
This software works inside a virtual machine running Ubuntu Linux 20.04. However, GPU passthrough is potentially difficult to set up and <u>not always available</u> for Linux VMs, so there may be no CUDA hardware acceleration. Certain Nvidia cards support [vGPU software](https://www.nvidia.com/en-us/data-center/graphics-cards-for-virtualization/); see also [vGPUs and CUDA](https://docs.nvidia.com/cuda/vGPU/), but vGPU features may come at substantial additional cost and vGPU software is not covered by this document.
##### Docker Containers (Unsupported)
This software also works inside Docker containers. However, CUDA support inside containers requires Nvidia Docker ([see blog entry](https://developer.nvidia.com/blog/nvidia-docker-gpu-server-application-deployment-made-easy/)) and is not covered by this document.
#### PyTorch and Python
The officially supported version of [PyTorch is 1.8.1 (LTS)](https://pytorch.org/get-started/locally/) running on Python 3.8.x. Newer versions will typically work, but are not covered by support, documentation, and installation scripts.
#### Hardware Acceleration
When going beyond simple models, model training does not work well without CUDA hardware acceleration. The network loader (“izer”) does <u>not</u> require CUDA, and very simple models can also be trained on systems without CUDA.
* CUDA requires Nvidia GPUs.
* There is a PyTorch pre-release with ROCm acceleration for certain AMD GPUs on Linux ([see blog entry](https://pytorch.org/blog/pytorch-for-amd-rocm-platform-now-available-as-python-package/)), but this is not currently covered by the installation instructions in this document, and it is not supported.
* At this time, there is neither CUDA nor ROCm nor Neural Engine support on macOS, and therefore no hardware acceleration (there is a pre-release version of PyTorch with M1 acceleration on macOS 12.3 or later, and M1 acceleration will be supported in a future release of these tools).
* PyTorch does not include CUDA support for aarch64/arm64 systems. *Rebuilding PyTorch from source is not covered by this document.*
##### Using Multiple GPUs
When using multiple GPUs (graphics cards), the software will automatically use all available GPUs and distribute the workload. To prevent this (for example, when the GPUs are not balanced), set the `CUDA_VISIBLE_DEVICES` environment variable. Use the `--gpus` command line argument to set the default GPU.
#### Shared (Multi-User) and Remote Systems
On a shared (multi-user) system that has previously been set up, only local installation is needed. CUDA and any `apt-get` or `brew` tasks are not necessary, with the exception of the CUDA [Environment Setup](https://docs.nvidia.com/cuda/cuda-installation-guide-linux/index.html#environment-setup).
The `screen` command (or alternatively, the more powerful `tmux`) can be used inside a remote terminal to disconnect a session from the controlling terminal, so that a long running training session doesn’t abort due to network issues, or local power saving. In addition, screen can log all console output to a text file.
Example:
```shell
$ ssh targethost
targethost$ screen -L # or screen
没有合适的资源?快使用搜索试试~ 我知道了~
ADI MAX78000 和 MAX78002 AI器件 的模型训练_python_代码_下载
共237个文件
py:69个
sh:61个
yaml:36个
1.该资源内容由用户上传,如若侵权请联系客服进行举报
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
版权申诉
5星 · 超过95%的资源 1 下载量 13 浏览量
2022-06-25
03:21:06
上传
评论
收藏 27.22MB ZIP 举报
温馨提示
ADI MAX78000/MAX78002 模型训练和综 本文档涵盖了 ADI 的多个超低功耗机器学习加速器系统。它们有时被称为它们的模具类型。下面显示了模具类型及其对应的零件编号: 概述 下图显示了开发流程的概览: 更多详情、使用方法,请下载后阅读README.md文件
资源推荐
资源详情
资源评论
收起资源包目录
ADI MAX78000 和 MAX78002 AI器件 的模型训练_python_代码_下载
(237个子文件)
.isort.cfg 210B
.isort.cfg 194B
ai8x-training.code-workspace 287B
logging.conf 1KB
logging.conf 452B
.flake8 84B
.flake8 13B
.gitignore 279B
.gitmodules 274B
mypy.ini 82B
TinySSDModelVisualization_svhn.ipynb 56KB
putty-forward.jpg 39KB
.keep 0B
AHBAddresses.md 18KB
README.md 2KB
LICENSE.md 2KB
README.md 193KB
README.pdf 6.4MB
Conv2Dk1x1.png 596KB
MLP.png 558KB
CNNOverview.png 393KB
Streaming-NextPixel.png 186KB
Streaming.png 185KB
shap.png 182KB
DevelopmentFlow.png 181KB
Streaming-Rows.png 180KB
fireexample.png 156KB
residual.png 144KB
fractionallystrided.png 143KB
CNNInFlight.png 125KB
model.png 122KB
projector.png 118KB
histogram.png 117KB
DataMemory.png 97KB
top1.png 85KB
KernelMemory.png 85KB
objectiveloss.png 78KB
Overview.png 73KB
KernelMemoryGaps.png 73KB
noactivation.png 53KB
residual-basic.png 48KB
lr.png 47KB
NAS_Sequential_Model.png 45KB
softmax.png 44KB
abs.png 43KB
KernelMemoryLayers.png 40KB
relu.png 35KB
confusionmatrix.png 22KB
Numbers.png 20KB
CHW.png 18KB
HWC.png 15KB
train.py 80KB
range_linear_ai84.py 66KB
ai8x.py 50KB
kws20.py 26KB
ai85nasnet-sequential.py 23KB
ai8x_nas.py 22KB
aisegment.py 19KB
ai85net-tinierssd.py 19KB
mixedkws.py 19KB
speechcom.py 18KB
svhn.py 18KB
test_nas.py 18KB
msnoise.py 17KB
parsecmd.py 16KB
object_detection_utils.py 14KB
camvid.py 13KB
ai85net-test.py 12KB
ai85net-unet.py 12KB
run_nas_network_search.py 11KB
ai8x_blocks.py 10KB
ai84net.py 9KB
gen_youtubefaces_embeddings.py 9KB
multiboxloss.py 8KB
nas_auto_generator.py 8KB
cats_vs_dogs.py 8KB
ai87net-mobilenet-v2.py 7KB
evo_search.py 7KB
gen_loss_plots.py 6KB
gen_vggface2_embeddings.py 6KB
mnist.py 5KB
ai85net.py 5KB
test_qat.py 5KB
ai87net-imagenet-effnetv2.py 5KB
cifar100.py 4KB
imagenet.py 4KB
ai85net-res-simplenet.py 4KB
afsk.py 4KB
ai87net-effnetv2.py 4KB
ai85net-audio.py 4KB
ai85net-simplenet-wide2x.py 4KB
ai85net-simplenet.py 4KB
batchnormfuser.py 4KB
merge_youtubefaces_dataset.py 4KB
inspect_ckpt.py 3KB
merge_vggface2_dataset.py 3KB
cifar.py 3KB
ai85net-nas-cifar.py 3KB
ai85net-kws20.py 3KB
ai85net-kws20-v2-batchnorm.py 3KB
共 237 条
- 1
- 2
- 3
资源评论
- Serei6232022-10-14这个资源值得下载,资源内容详细全面,与描述一致,受益匪浅。
快撑死的鱼
- 粉丝: 1w+
- 资源: 9154
下载权益
C知道特权
VIP文章
课程特权
开通VIP
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功