GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - inteintegrity/Offline-Warehouse-Box-Detection-Yolov8-RK3576-RK1820: Offline YOLOv8 warehouse box detection demo on RK3576 + RK1820 (RKNN3Lite).

BranchesTags
Open more actions menu

Latest commit

 

History

3 Commits
3 Commits

Folders and files

NameName
Last commit message
Last commit date
examples
examples
 
 
model
model
 
 
result
result
 
 
server
server
 
 
.gitignore
.gitignore
 
 
LICENSE
LICENSE
 
 
README.md
README.md
 
 
requirements.txt
requirements.txt
 
 

Repository files navigation

Offline Warehouse Box Detection with YOLOv8 on RK3576 + RK1820 AI Edge Platform

This repository demonstrates the full offline deployment workflow of YOLOv8 for warehouse box detection on an RK3576 + RK1820 edge AI platform, together with a runnable Web demo for image upload, RK1820 inference, and result visualization.

Note: the repository includes sample RKNN model artifacts and weight files in model/ for easier offline deployment and reproducibility.

Project structure

  • model/
    • best.rknn: RKNN model file
    • best.weight: weight file loaded by RKNN3Lite
  • server/: FastAPI backend for RK1820 inference and the Web UI
    • main.py: main entry point with home page, /detect API, and static file mounting
    • detector.py: RKNN3Lite inference wrapper with target="rk1820"
    • static/result/: output directory for visualized inference results
  • examples/: sample input images
  • result/: sample output images, including test_result.jpg

Environment and dependencies

Python dependencies

See requirements.txt:

pip install -r requirements.txt

RKNN3Lite / RK1820 runtime environment

server/detector.py attempts to add the site-packages directory under server/../rknn3_env into sys.path in order to load:

  • rknn3lite.api.rknn3_lite.RKNN3Lite

You can therefore prepare a Python runtime with a similar layout based on your device environment, for example by placing the Rockchip runtime packages under rknn3_env.

Model preparation and conversion

Below is a typical offline deployment path. The exact commands may vary depending on your training codebase and RKNN Toolkit version:

  1. Train or fine-tune YOLOv8 to obtain best.pt
  2. Export to ONNX: yolo export model=best.pt format=onnx imgsz=640
  3. Convert the ONNX model to RKNN using RKNN Toolkit / RKNN3 tools, and generate any required runtime weight or auxiliary files
  4. Place the generated artifacts under model/ and verify the paths in server/detector.py:
    • MODEL = "../model/best.rknn"
    • WEIGHT = "../model/best.weight"

Run the demo

After installing the required Python packages and RKNN3Lite runtime on the target device, run the following command from the repository root:

python -m uvicorn server.main:app --host 0.0.0.0 --port 8000

Then open the following URL in your browser:

  • http://<device-ip>:8000/

Upload an image on the page and click the detection button. The backend will run inference on RK1820 and return both the object count and the visualized result image.

Example result

Input example: examples/test.jpg
Output example: result/test_result.jpg

Inference preview

The image below shows the offline inference visualization bundled with this repository:

RK3576 + RK1820 offline inference result

License

MIT License. See LICENSE for details.

About

Offline YOLOv8 warehouse box detection demo on RK3576 + RK1820 (RKNN3Lite).

Resources

Readme
MIT license
Activity

Stars

2 stars

Watchers

0 watching

Forks

0 forks
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.