日韩av黄I国产麻豆传媒I国产91av视频在线观看I日韩一区二区三区在线看I美女国产在线I麻豆视频国产在线观看I成人黄色短片

歡迎訪問(wèn) 生活随笔!

生活随笔

當(dāng)前位置: 首頁(yè) >

TVM部署和集成Deploy and Integration

發(fā)布時(shí)間:2023/11/28 84 豆豆
生活随笔 收集整理的這篇文章主要介紹了 TVM部署和集成Deploy and Integration 小編覺(jué)得挺不錯(cuò)的,現(xiàn)在分享給大家,幫大家做個(gè)參考.

TVM部署和集成Deploy and Integration

本文包含如何將TVM部署到各種平臺(tái)以及如何將其與項(xiàng)目集成。

與傳統(tǒng)的深度學(xué)習(xí)框架不同。TVM堆棧分為兩個(gè)主要組件:

TVM編譯器,完成所有編譯和優(yōu)化

TVM runtime運(yùn)行時(shí),在目標(biāo)設(shè)備上運(yùn)行。

為了集成編譯后的模塊,不需要在目標(biāo)設(shè)備上構(gòu)建整個(gè)TVM。只需要在桌面上構(gòu)建TVM編譯器堆棧,用它來(lái)交叉編譯部署在目標(biāo)設(shè)備上的模塊。只需要使用一個(gè)輕量級(jí)的runtime運(yùn)行時(shí)API,它可以集成到各種平臺(tái)中。

例如,可以運(yùn)行以下命令,基于Linux的嵌入式系統(tǒng)(如Raspberry Pi)上構(gòu)建runtime運(yùn)行時(shí)API:

git clone --recursive
https://github.com/apache/tvm tvm

cd tvm

mkdir build

cp cmake/config.cmake build

cd build

cmake …

make runtime

注意,鍵入make runtime只構(gòu)建runtime運(yùn)行時(shí)庫(kù)。如果要包含其他runtime運(yùn)行時(shí)(如OpenCL),可以修改config.cmake啟用這些選項(xiàng)。獲得TVM運(yùn)行庫(kù)之后,可以鏈接已編譯的庫(kù)。

在嵌入式設(shè)備上測(cè)試、調(diào)整和基準(zhǔn)測(cè)試TVM內(nèi)核的最簡(jiǎn)單和推薦的方法是通過(guò)TVM’s RPC
API。以下是相關(guān)的模塊。

· Cross Compilation and RPC

· Deploy the Pretrained Model on Raspberry Pi

在完成優(yōu)化和基準(zhǔn)測(cè)試之后,可能需要在不依賴RPC的情況下將模型部署到目標(biāo)設(shè)備上。請(qǐng)參閱下面的參考資料以了解如何這樣做。

· Deploy TVM Module using C++ API

o Get TVM Runtime Library

o Dynamic Library vs. System Module

· Deploy to Android

o Build model for Android Target

o TVM Runtime for Android Target

· Integrate TVM into Your Project

o DLPack Support

o Integrate User Defined C++ Array

o Integrate User Defined Python Array

· HLS Backend Example

o Setup

o Emulation

o Synthesis

o Run

· Relay Arm ? Compute Library Integration

o Introduction

o Installing Arm Compute Library

o Building with ACL support

o Usage

o More examples

o Operator support

o Adding a new operator

· Relay TensorRT Integration

o Introduction

o Installing TensorRT

o Building TVM with TensorRT support

o Build and Deploy ResNet-18 with TensorRT

o Partitioning and Compilation Settings

o Runtime Settings

o Operator support

o Adding a new operator

· Vitis-AI Integration

o DPU naming information

o Build instructions

o Getting started

總結(jié)

以上是生活随笔為你收集整理的TVM部署和集成Deploy and Integration的全部?jī)?nèi)容,希望文章能夠幫你解決所遇到的問(wèn)題。

如果覺(jué)得生活随笔網(wǎng)站內(nèi)容還不錯(cuò),歡迎將生活随笔推薦給好友。