Skip to content

Releases: Ender-William/PackESAM

PackESAM Version 1.0.0

18 Feb 18:13
Compare
Choose a tag to compare

1. Introduce

PackESAM is a library encapsulated in the form of a wheel, known as the Efficient SAM library. This distinguished library affords the execution of models via onnxruntime as well as the torch jit approach, with the capability to run on NVIDIA GPU and CPU alike.

Should you wish to install and operate this library correctly, you are kindly advised to configure your environment in the manner described below, and to refer to the demonstration program for the development of your own applications. I wish you the utmost enjoyment in your development endeavours!

2. Environment Requirements

Install Pytorch and version >= 1.12.1

pip install torch==1.12.1+cu113 torchvision==0.13.1+cu113 torchaudio==0.12.1 --extra-index-url https://download.pytorch.org/whl/cu113

Install PackESAM

pip install ./PackESAM-1.0-py3-none-any.whl

It merits your attention that libraries such as onnxruntime and opencv-python, upon the installation of PackESAM, will automatically select the appropriate versions for installation. Furthermore, it is imperative to note that the default installation of onnxruntime is the GPU version. Should the GPU version of onnxruntime prove unfeasible to install upon your device, you are encouraged to clone this project, locally amend the configuration information concerning onnxruntime within the setup.py file, and package it anew. If it is within your means, you are also kindly requested to initiate an issue on this project, thereby enabling myself to swiftly rectify any errors that may arise within the program.

3. Performance

Upon rigorous testing, it has been ascertained that, when operating PackESAM in a single-threaded manner upon the machinery configured as below, utilising onnxruntime with the provider set to CUDAExecutionProvider, and employing the efficientsam_ti model, one can achieve an inference speed of 7 to 8 frames per second.

Processor:  Intel® Xeon(R) CPU E5-2680 v4 @ 2.40GHz × 28
Memory:     32 GiB @ 2666MHz
Graphics:   NVIDIA RTX 3060 12GB
OS:         Ubuntu 22.04 LTS 64 bit
Python:     Python 3.10
CUDA:       CUDA 11.5