Skip to content
/ usls Public

A Rust library integrated with ONNXRuntime, providing a collection of Computer Vison and Vision-Language models.

License

Notifications You must be signed in to change notification settings

jamjamjon/usls

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

65 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

usls

Rust Continuous Integration Badge usls Version Rust MSRV ONNXRuntime MSRV CUDA MSRV TensorRT MSRV Crates.io Total Downloads

Examples usls documentation

usls is a Rust library integrated with ONNXRuntime, offering a suite of advanced models for Computer Vision and Vision-Language tasks, including:

👉 More Supported Models
Model Task / Description Example CoreML CUDA
FP32
CUDA
FP16
TensorRT
FP32
TensorRT
FP16
BEiT Image Classification demo
ConvNeXt Image Classification demo
FastViT Image Classification demo
MobileOne Image Classification demo
DeiT Image Classification demo
DINOv2 Vision Embedding demo
YOLOv5 Image Classification
Object Detection
Instance Segmentation
demo
YOLOv6 Object Detection demo
YOLOv7 Object Detection demo
YOLOv8
YOLO11
Object Detection
Instance Segmentation
Image Classification
Oriented Object Detection
Keypoint Detection
demo
YOLOv9 Object Detection demo
YOLOv10 Object Detection demo
RT-DETR Object Detection demo
PP-PicoDet Object Detection demo
DocLayout-YOLO Object Detection demo
D-FINE Object Detection demo
DEIM Object Detection demo
RTMO Keypoint Detection demo
SAM Segment Anything demo
SAM2 Segment Anything demo
MobileSAM Segment Anything demo
EdgeSAM Segment Anything demo
SAM-HQ Segment Anything demo
FastSAM Instance Segmentation demo
YOLO-World Open-Set Detection With Language demo
GroundingDINO Open-Set Detection With Language demo
CLIP Vision-Language Embedding demo
jina-clip-v1 Vision-Language Embedding demo
BLIP Image Captioning demo
DB(PaddleOCR-Det) Text Detection demo
FAST Text Detection demo
LinkNet Text Detection demo
SVTR(PaddleOCR-Rec) Text Recognition demo
SLANet Tabel Recognition demo
TrOCR Text Recognition demo
YOLOPv2 Panoptic Driving Perception demo
DepthAnything v1
DepthAnything v2
Monocular Depth Estimation demo
DepthPro Monocular Depth Estimation demo
MODNet Image Matting demo
Sapiens Foundation for Human Vision Models demo
Florence2 a Variety of Vision Tasks demo

⛳️ Cargo Features

By default, none of the following features are enabled. You can enable them as needed:

  • auto: Automatically downloads prebuilt ONNXRuntime binaries from Pyke’s CDN for supported platforms.

  • ffmpeg: Adds support for video streams, real-time frame visualization, and video export.

    • Powered by video-rs and minifb. For any issues related to ffmpeg features, please refer to the issues of these two crates.
  • cuda: Enables the NVIDIA TensorRT provider.

  • trt: Enables the NVIDIA TensorRT provider.

  • mps: Enables the Apple CoreML provider.

🎈 Example

  • Using CUDA

    cargo run -r -F cuda --example yolo -- --device cuda:0
    
  • Using Apple CoreML

    cargo run -r -F mps --example yolo -- --device mps
    
  • Using TensorRT

    cargo run -r -F trt --example yolo -- --device trt
    
  • Using CPU

    cargo run -r --example yolo
    

All examples are located in the examples directory.

🥂 Integrate Into Your Own Project

Add usls as a dependency to your project's Cargo.toml

cargo add usls -F cuda

Or use a specific commit:

[dependencies]
usls = { git = "https://github.com/jamjamjon/usls", rev = "commit-sha" }

🥳 If you find this helpful, please give it a star ⭐

📌 License

This project is licensed under LICENSE.