File size: 2,391 Bytes
a706d11 dd84729 a706d11 dd84729 a706d11 dd84729 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 |
---
library_name: unity-sentis
pipeline_tag: object-detection
---
# LaboroTomato for Unity Sentis (Version 1.4.0-pre.3*)
[LaboroTomato](https://github.com/laboroai/LaboroTomato) is is an image dataset of growing tomatoes at different stages of their ripening.
This model was trained on the LaboroTomato image dataset using the Ultralytics [YOLOv8n](https://docs.ultralytics.com/models/yolov8/) object detection framework. The sentis example implementation was copied from [sentis-YOLOv8n](https://huggingface.co/unity/sentis-YOLOv8n).
## How to Use
First get the package `com.unity.sentis` from the package manager.
You will also need the Unity UI package.
* Create a new scene in Unity 6.
* Install `com.unity.sentis` version `1.4.0-pre.3` from the package manager, and enable the 'Video' built-in module.
* Add the c# script to the Main Camera.
* Create a Raw Image in the scene and link it as the `displayImage`
* Drag the laboro_tomato_yolov8.sentis file into the model asset field
* Drag the classes.txt on to the labelAssets field
* Put a video file in the Assets/StreamingAssets folder and set the name of videoName to the filename in the script ("tomatoes.mp4")
* Set the fields for the bounding box texture sprite (you can [create your own one](https://docs.unity3d.com/Manual/9SliceSprites.html) using a transparent texture or use an inbuilt one) and the font
## Preview
If working correctly you should see something like this:

## Information
The onnx model was designed with the same inputs as [sentis-YOLOv8n](https://huggingface.co/unity/sentis-YOLOv8n). If you are using that implementation, you can simply swap out the model and labels with the ones in this project and it should work.
## References
For information on how the model was trained and exported to onnx, see the [project github page](https://github.com/DavidAtRedpine/LaboroTomatoYoloV8).
## Unity Sentis
Unity Sentis is the inference engine that runs in Unity 3D. More information can be found at [here](https://unity.com/products/sentis)
## License
Ultralytics YOLOv8 uses the GPLv3 license. Details [here](https://github.com/autogyro/yolo-V8?tab=readme-ov-file#license).
The LaboroTomato dataset uses the Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License. Details [here](https://github.com/laboroai/LaboroTomato/blob/master/README.md#license).
|