Spaces:
Sleeping
Sleeping
Update README.md
Browse files
README.md
CHANGED
|
@@ -1,122 +1,10 @@
|
|
| 1 |
-
|
| 2 |
-
|
| 3 |
-
|
| 4 |
-
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
-
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
- **Detection Metadata**: Displays detection counts and class information
|
| 12 |
-
- **Frame Saving**: Save frames with detections to disk
|
| 13 |
-
|
| 14 |
-
## Requirements
|
| 15 |
-
|
| 16 |
-
- Python 3.8 or higher
|
| 17 |
-
- Webcam or camera device
|
| 18 |
-
- YOLOv8 model file (`yolov8n.pt` - included)
|
| 19 |
-
|
| 20 |
-
## Installation
|
| 21 |
-
|
| 22 |
-
1. Clone or download this repository
|
| 23 |
-
|
| 24 |
-
2. Install dependencies:
|
| 25 |
-
```bash
|
| 26 |
-
pip install -r requirements.txt
|
| 27 |
-
```
|
| 28 |
-
|
| 29 |
-
## Usage
|
| 30 |
-
|
| 31 |
-
### Modern UI (Recommended)
|
| 32 |
-
|
| 33 |
-
Run the modern PyQt5-based UI:
|
| 34 |
-
```bash
|
| 35 |
-
python main_ui.py
|
| 36 |
-
```
|
| 37 |
-
|
| 38 |
-
**Features:**
|
| 39 |
-
- Modern dark theme interface
|
| 40 |
-
- Real-time video display with proper scaling
|
| 41 |
-
- Scrollable sidebar showing all tracked objects
|
| 42 |
-
- Detailed wildlife information cards
|
| 43 |
-
- Interactive buttons for save and reset
|
| 44 |
-
- Real-time statistics display
|
| 45 |
-
- Professional appearance
|
| 46 |
-
|
| 47 |
-
**Controls:**
|
| 48 |
-
- **Save Frame** button: Save current frame to disk
|
| 49 |
-
- **Reset** button: Reset statistics and tracked objects
|
| 50 |
-
- Close window to quit
|
| 51 |
-
|
| 52 |
-
### Legacy OpenCV UI
|
| 53 |
-
|
| 54 |
-
Run the original OpenCV-based UI:
|
| 55 |
-
```bash
|
| 56 |
-
python main.py
|
| 57 |
-
```
|
| 58 |
-
|
| 59 |
-
**Controls:**
|
| 60 |
-
- **'q'**: Quit the application
|
| 61 |
-
- **'s'**: Save current frame to disk
|
| 62 |
-
- **'r'**: Reset statistics (FPS counter, frame count)
|
| 63 |
-
|
| 64 |
-
### Configuration
|
| 65 |
-
|
| 66 |
-
Edit `config.py` to customize:
|
| 67 |
-
|
| 68 |
-
- **Camera Settings**: Change `CAMERA_INDEX`, `CAMERA_WIDTH`, `CAMERA_HEIGHT`
|
| 69 |
-
- **Detection Threshold**: Adjust `CONFIDENCE_THRESHOLD` (0.0-1.0)
|
| 70 |
-
- **Model Path**: Change `YOLO_MODEL` to use a different YOLO model
|
| 71 |
-
- **Tracker**: Change `TRACKER_CONFIG` to use different tracking algorithms
|
| 72 |
-
|
| 73 |
-
## Project Structure
|
| 74 |
-
|
| 75 |
-
```
|
| 76 |
-
tracker_v2/
|
| 77 |
-
βββ main_ui.py # Modern PyQt5 UI application (recommended)
|
| 78 |
-
βββ main.py # Legacy OpenCV UI application
|
| 79 |
-
βββ tracker.py # ObjectTracker and CameraCapture classes
|
| 80 |
-
βββ wildlife_tracker.py # Wildlife tracking manager
|
| 81 |
-
βββ ai_module.py # Wildlife identification module
|
| 82 |
-
βββ config.py # Configuration settings
|
| 83 |
-
βββ requirements.txt # Python dependencies
|
| 84 |
-
βββ yolov8n.pt # YOLO model file
|
| 85 |
-
βββ README.md # This file
|
| 86 |
-
```
|
| 87 |
-
|
| 88 |
-
## Detected Classes
|
| 89 |
-
|
| 90 |
-
The application is configured to detect:
|
| 91 |
-
- Person
|
| 92 |
-
- Bird
|
| 93 |
-
- Cat
|
| 94 |
-
- Dog
|
| 95 |
-
- Horse
|
| 96 |
-
- Sheep
|
| 97 |
-
- Cow
|
| 98 |
-
- Elephant
|
| 99 |
-
- Bear
|
| 100 |
-
- Zebra
|
| 101 |
-
- Giraffe
|
| 102 |
-
|
| 103 |
-
## Troubleshooting
|
| 104 |
-
|
| 105 |
-
### Camera Not Working
|
| 106 |
-
- Make sure your camera is connected and not being used by another application
|
| 107 |
-
- Try changing `CAMERA_INDEX` in `config.py` (try 0, 1, 2, etc.)
|
| 108 |
-
- On Windows, check Device Manager to see available cameras
|
| 109 |
-
|
| 110 |
-
### Low FPS
|
| 111 |
-
- Reduce camera resolution in `config.py`
|
| 112 |
-
- Use a smaller YOLO model (yolov8n.pt is already the smallest)
|
| 113 |
-
- Close other applications using the camera
|
| 114 |
-
|
| 115 |
-
### Model Not Found
|
| 116 |
-
- Ensure `yolov8n.pt` is in the same directory as the scripts
|
| 117 |
-
- The model will be downloaded automatically on first run if not found
|
| 118 |
-
|
| 119 |
-
## License
|
| 120 |
-
|
| 121 |
-
This project is open source and available for modification and distribution.
|
| 122 |
-
|
|
|
|
| 1 |
+
---
|
| 2 |
+
title: Animal Tracking V2
|
| 3 |
+
emoji: π
|
| 4 |
+
colorFrom: yellow
|
| 5 |
+
colorTo: yellow
|
| 6 |
+
sdk: docker
|
| 7 |
+
pinned: false
|
| 8 |
+
---
|
| 9 |
+
|
| 10 |
+
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|