# Benchmarking of Object Detection Model The object detection Model Benchmarking service is a powerful tool that enables users to evaluate the performance of their object detection models built with TensorFlow Lite (.tflite), Keras (.keras), or (.ONNX). With this service, users can easily upload their model and configure the settings to benchmark it and generate various metrics, including memory footprints and inference time. This can be achieved by utilizing the [STEdgeAI Developer Cloud](https://stedgeai-dc.st.com/home) to benchmark on different STM32 target devices or by using [STEdgeAI Core](https://www.st.com/en/development-tools/stedgeai-core.html) to estimate the memory footprints.
1. Configure the YAML file To use this service and achieve your goals, you can use the [user_config.yaml](../user_config.yaml) or directly update the [benchmarking_config.yaml](../config_file_examples/benchmarking_config.yaml) file and use it. This file provides an example of how to configure the benchmarking service to meet your specific needs. Alternatively, you can follow the tutorial below, which shows how to benchmark your pre-trained object detection model using our evaluation service.
2. benchmark your model If you chose to modify the [user_config.yaml](../user_config.yaml), you can evaluate the model by running the following command from the UC folder: ```bash python stm32ai_main.py ``` If you chose to update the [benchmarking_config.yaml](../config_file_examples/benchmarking_config.yaml) and use it, then run the following command from the UC folder: ```bash python stm32ai_main.py --config-path ./config_file_examples/ --config-name benchmarking_config.yaml ``` Note that you can provide YAML attributes as arguments in the command, as shown below: ```bash python stm32ai_main.py operation_mode='benchmarking' ```
3. Visualize the benchmarking results To view the detailed benchmarking results, you can access the log file `stm32ai_main.log` located in the directory `experiments_outputs/`. Additionally, you can navigate to the `experiments_outputs` directory and use the MLflow Webapp to view the metrics saved for each trial or launch. To access the MLflow Webapp, run the following command: ```bash mlflow ui ``` This will open a browser window where you can view the metrics and results of your benchmarking trials.