RAPID is a patterned animal re-identification (reID) tool. It is easy-to-use, fast and accurate. Furthermore, suitable for edge deployment (e.g. drones) and integration into larger pipelines (e.g. autonomous monitoring).
The tool has two main features: 1) RAPID predicts IDs (with confidence scores) for query animals based on a set of database images, and 2) FalseTagFinder supports researchers to identify potentially wrong ID labels within ground truth databases.
As images should strictly follow the naming convention: animalID_viewpoint_frameID.filetype (e.g. jaguar7_left_23.jpg, tiger18_unknownvp_54.png, unknownID74_right_32.jpg), we also provide a Rename tool that automatically renames images based on a simple Excel (example for Excel is also provided).
In case of feature requests, bugs or errors, please raise an issue on GitHub. We are happy to help you with the setup and running the tool on your own computer and own data.
For more, read our preprint and watch the video abstract.
- accurate ID predictions + confidence scores 🎯
- real-time processing (even without GPU) ⚡
- optimal for edge devices, e.g. drones 🌿
- works with multiple species 🌎
- no need for large training data 📷
- localizable keypoints for visual verification 👀
- works with patterned animals
- needs cropped bounding boxes (however, not necessarily very tight)
- not automated for open-set scenarios (however, can be used as a supporting tool)
- similar viewpoint to the query should be in the database for successful reID
Top-1 accuracies on publicly available benchmark datasets:
| Accuracy (Top-1) | Species | Dataset |
|---|---|---|
| 99% | 🦓 Plains and Grevy's zebra | StripeSpotter |
| 95% | 🐅 Amur tiger | ATRW |
| 99% | 🐄 Holstein Friesian Cattle | AerialCattle |
| 89% | 🦒 🦓 Masai giraffe and Plains zebra | GiraffeZebraID |
| 99% | 🦓 Grevy's zebra | dataset coming soon... |
| 100% | 🐆 Jaguar | dataset coming soon... |
Query processing speed (FPS). Query processing time meant time spent from loading the raw bounding box until ID prediction and confidence score calculation.
| Hardware | Speed (FPS) |
|---|---|
| 🖥️PC | ~60 FPS |
| 💻Laptop | ~50 FPS |
| 🌿Edge | ~12 FPS |
Hardware used for tests: 1) PC - DELL Precision 3630 Tower with Intel(R)492 Xeon(R) E-2174G@ 3,80GHz CPU, 8 cores, 63 GB RAM; 2) Laptop - VivoBook-ASUSLaptop X513UA-M513UA with AMD Ryzen 7 5700U, Radeon Graphics, 16 cores, 16 GB RAM; 3) Edge - Texas Instruments SK-TDA4VM with ARM Cortex-A72, 2 cores, 2.25 GB RAM
- At the top of the page, click on
Code, thenDownload ZIPand extract the file. Another option is, if you have git installed, to navigate to your desired folder in cmd and:git clone https://github.com/robot-perception-group/Real-time_Animal_reID.git - Go to
scriptsfolder and double-click oninstall_on_windowsto install RAPID (if needed, right-click, and run as administrator). That's all, you are all set.
You can use the demo images provided in ...\data\demo_database and ...\data\demo_query folders to quickly test the tool.
When using your own data, do the same, but provide folder paths pointing to your own images.
- Prepare images
- If images are not named as animalID_viewpoint_frameID.filetype, rename them (see below section). Demo images are named properly.
- Set config
- Provide the database and query paths in
...\config\config_RAPID.yaml(or...\config_FalseTagFinder.yaml) - Save changes
- Provide the database and query paths in
- Run
- Just double-click on
run_RAPID_windows(orrun_FalseTagFinder_windows) and check results under...\saved_RAPID(or...\saved_FalseTagFinder) next to your database folder
- Just double-click on
Note: images should be cropped bounding box images, and named as animalID_viewpoint_frameID.filetype. This
section helps you to rename your images, if they are named differently. We provide demo data (...\demo\example_rename and ...\demo\examle_rename.xlsx) to test renaming.
- Set config
- Prepare your metadata Excel or use the demo provided in
...\demo\rename_example.xlsx - Provide the paths in
...\config\config_Rename.yaml - Save changes
- Prepare your metadata Excel or use the demo provided in
- Run
- Go to scripts and double-click on
\scripts\run_Rename_windows - Check
renamed_imagesdirectory, next to original image directory
- Go to scripts and double-click on
- In general, use only first 5 columns
query_imgcolumn helps you identify the given imageprovided_IDis the first part of the query image filename (see aboveHow to runsection)predicted_IDis the prediction of RAPIDconfidence_scoreis the confidence of the predictionID_matchingchecks if provided query animal ID from the filename is the same as the prediction. This is only meaningful, if you used proper animal IDs in the query image filenames that are part of your database
- other columns provide information about top 5 predictions and their weights that can be used for deeper analysis
- At the top of the page, click on
Code, thenDownload ZIPand extract the file. Another option is, if you have git installed, to navigate to your desired folder in terminal and:git clone https://github.com/robot-perception-group/Real-time_Animal_reID.git - Go to
scriptsdirectory, right click andopen a terminal, so you see.../scripts$ - In terminal, type:
chmod +x install_on_linux.sh - To install RAPID, type:
./install_on_linux.sh
You can use the demo images provided in .../data/demo_database and .../data/demo_query folders to quickly test the tool.
When using your own data, do the same, but provide folder paths pointing to your own images.
- Prepare images
- If images are not named as animalID_viewpoint_frameID.filetype, rename them (see below section). Demo images are named properly.
- Set config
- Provide database and query paths in
.../config/config_RAPID.yaml(orconfig_FalseTagFinder.yaml) - Save changes
- Provide database and query paths in
- Activate virtual environment
- In
Real-time_Animal_reIDdirectory open a terminal, so you see.../Real-time_Animal_reID$ - In terminal:
source .venv/bin/activate, as a result, you should see(.venv)at the beginning of the command line
- In
- Run
- In terminal, run:
RAPID(orFalseTagFinder) - Check results under
.../saved_RAPID(or.../saved_FalseTagFinder) next to your database directory
- In terminal, run:
Note: images should be cropped bounding box images, and named as animalID_viewpoint_frameID.filetype. This
section helps you to rename your images, if they are named differently. We provide demo data (...\demo\example_rename and ...\demo\examle_rename.xlsx) to test renaming.
- Set config
- Prepare your metadata Excel or use the demo provided in
.../data/rename_example.xlsx - Provide the paths in
.../config/config_Rename.yaml - Save changes
- Prepare your metadata Excel or use the demo provided in
- Activate virtual environment
- In
Real-time_Animal_reIDdirectory open a terminal, so you see.../Real-time_Animal_reID$ - In terminal:
source .venv/bin/activate, as a result, you should see(.venv)at the beginning of the command line
- In
- Run
- In terminal, run:
Rename - Check
renamed_imagesdirectory, next to original image directory
- In terminal, run:
Zábó, A., Nagy, M., & Ahmad, A. (2025). RAPID: Real-time Animal Pattern re-Identification on edge Devices. bioRxiv: https://doi.org/10.1101/2025.07.07.663143
