HimaxWiseEyePlus / himax_tflm

Apache License 2.0
24 stars 15 forks source link

Measure processing time #14

Closed AcculusSasao closed 2 years ago

AcculusSasao commented 2 years ago

How can I measure the processing time in the program ? eg. start = gettime(); ...; end = gettime(); time = end - start; I'd like to measure the inference time of WE-I plus in HIMAX_Yolo_Fastest_Person_Detection_Example.

kris-himax commented 2 years ago

Hi @AcculusSasao You can measure the inference time of WE-I plus by the Himax API at ./himax_we1_sdk/hx_drv_tflm.h. ex: uint32_t tick_start = 0, tick_end = 0; hx_drv_uart_initial(UART_BR_115200); hx_drv_tick_start(); hx_drv_tick_get(&tick_start); // your code hx_drv_tick_get(&tick_end); hx_drv_uart_print("time used :%d(msec)\n", (tick_end-tick_start)/400000);

AcculusSasao commented 2 years ago

Hi @kris-himax It looks succeeded to measure time. Thank you !