NNIE Python Interface
Project description
NNIE Python Interface
Python remote interface for Huawei HiSilicon's NNIE NPUs.
Introduction
This repo provides interface for using NNIE's wk models
remotely with the nnie_transfer_server authored by me
running on the Hi3516/Hi3519 platforms.
Usage
- Build the nnie_transfer_server following the instructions and run it on the remote board.
- Install the NNIE python interface by executing
pip3 install nnie - Make sure your device can reach your HiSilicon board through network.
- Sample codes are provided below:
import cv2
from nnie.nnie import NNIE
net = NNIE(file='path/to/your/model.wk',ipaddr='192.168.31.20',port=7777)
image = cv2.imread("path/to/your/image.jpg")
network_input_width = 320
network_input_height = 240
image = cv2.resize(image, (network_input_width, network_input_height))
result = net(data=image) # You may change 'data' into other names according
result = net(image=image) # to the name of your model's input layer
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
nnie-0.1.tar.gz
(3.4 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
nnie-0.1-py3-none-any.whl
(4.7 kB
view details)
File details
Details for the file nnie-0.1.tar.gz.
File metadata
- Download URL: nnie-0.1.tar.gz
- Upload date:
- Size: 3.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/39.0.1 requests-toolbelt/0.9.1 tqdm/4.28.1 CPython/3.6.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c31b66ecd414bc0c8db447de9e86a9243f542c862f3a6193d7289efabc9ffd26
|
|
| MD5 |
0e7fcf364227285ca6556f41a93e0056
|
|
| BLAKE2b-256 |
292e6bac6aaf888761b810fe1c695161e2effeceadaf9be42e3c84df59d333bb
|
File details
Details for the file nnie-0.1-py3-none-any.whl.
File metadata
- Download URL: nnie-0.1-py3-none-any.whl
- Upload date:
- Size: 4.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/39.0.1 requests-toolbelt/0.9.1 tqdm/4.28.1 CPython/3.6.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
cb1b275bc5ff47033e83c8cc82ca7d96fed2d17370cfa5aebcc4ae00b3284a8d
|
|
| MD5 |
d81f5561feebe466a8fc873b21502ad8
|
|
| BLAKE2b-256 |
3c84bad8dda9c1bd66e7a2b68307edd2e264f66c08fac5cc3663a1835154a3bf
|