Skip to content

Commit e939220

Browse files
committed
README.md updated
1 parent 0265d83 commit e939220

File tree

1 file changed

+56
-0
lines changed

1 file changed

+56
-0
lines changed

README.md

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
# YOLO11s Android App
2+
3+
This is an Android application (Java) that runs the **YOLO11s** object detection model on mobile devices using **TensorFlow Lite (TFLite)**. The app allows object detection on captured frames using the YOLO11s model optimized for edge devices.
4+
5+
## Features
6+
- Runs **YOLO11s** model on Android devices using **TFLite**.
7+
- Live camera feed with manual detection.
8+
- Captures the current frame when the **Detect** button is clicked.
9+
- Displays detected objects with bounding boxes, class names, and confidence scores.
10+
11+
## Model Conversion
12+
To convert a YOLO model into the **TFLite** format, refer to the **YOLO11S_Convert_to_TFLite.ipynb** notebook included in this repository.
13+
14+
## Pretrained Model
15+
This repository includes a YOLO11s model pretrained for playing card symbol detection. However, you can use your own trained model by converting it to TFLite format and replacing the provided model.
16+
17+
## Screenshots
18+
### Detection Output
19+
![Detection Screenshot](screenshots/screenshot1.jpg)
20+
21+
### Tensor Shape Output
22+
The output tensor shape and its details can be found in the following GitHub discussion:
23+
[Ultralytics Discussion #17254](https://github.com/orgs/ultralytics/discussions/17254)
24+
25+
![Tensor Output](screenshots/output_shape.png)
26+
27+
## Requirements
28+
- Android 7.0 (API level 24) or higher
29+
- TensorFlow Lite dependencies added to `build.gradle`
30+
- A device with a camera for capturing frames
31+
32+
## Setup & Installation
33+
1. Clone this repository:
34+
```sh
35+
git clone https://github.com/tharushaudana/YOLO11S-TFLite-Android-Java.git
36+
```
37+
2. Open the project in **Android Studio**.
38+
3. Ensure that `TensorFlow Lite` dependencies are added in `build.gradle`:
39+
```gradle
40+
implementation("org.tensorflow:tensorflow-lite:2.9.0")
41+
implementation("org.tensorflow:tensorflow-lite-task-vision:0.3.1")
42+
implementation("org.tensorflow:tensorflow-lite-gpu:2.9.0")
43+
```
44+
4. Place the **TFLite** model and `classes.txt` inside the `assets` folder.
45+
5. Run the app on an Android device/emulator.
46+
47+
## Usage
48+
1. Launch the app.
49+
2. Grant camera permissions.
50+
3. View the live camera feed.
51+
4. Click the **Detect** button to capture the current frame.
52+
5. The detected objects will be displayed with bounding boxes, class names, and confidence scores.
53+
54+
## Acknowledgments
55+
- [TensorFlow Lite](https://www.tensorflow.org/lite)
56+
- [Ultralytics](https://github.com/ultralytics)

0 commit comments

Comments
 (0)