Skip to content

cython_bbox, but in Rust

Notifications You must be signed in to change notification settings

panchgonzalez/bboxrs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

bboxrs

A reimplementation of cython_bbox in Rust. It uses the pyo3 crate to interface with Python.

Installation

pip install bboxrs

Usage

from bboxrs import bbox_overlaps

import numpy as np

gt = np.random.random((5, 4)).astype(float)
dt = np.random.random((10, 4)).astype(float)

overlaps = bbox_overlaps(dt, gt)

Disclaimer

  • This is about an order of magnitude slower than the Cython implementation. Probably because I had to do a couple of unnecessary conversions. This is really just an exercise in learning Rust and interfacing with Python.