yoloOutput.h 1.3 KB

123456789101112131415161718192021222324252627282930313233
  1. /* ----------------------------------------------------------------------
  2. * Project: TinyEngine
  3. * Title: yoloOutput.h
  4. *
  5. * Reference papers:
  6. * - MCUNet: Tiny Deep Learning on IoT Device, NeurIPS 2020
  7. * - MCUNetV2: Memory-Efficient Patch-based Inference for Tiny Deep Learning, NeurIPS 2021
  8. * - MCUNetV3: On-Device Training Under 256KB Memory, NeurIPS 2022
  9. * Contact authors:
  10. * - Wei-Ming Chen, wmchen@mit.edu
  11. * - Wei-Chen Wang, wweichen@mit.edu
  12. * - Ji Lin, jilin@mit.edu
  13. * - Ligeng Zhu, ligeng@mit.edu
  14. * - Song Han, songhan@mit.edu
  15. *
  16. * Target ISA: ARMv7E-M
  17. * -------------------------------------------------------------------- */
  18. typedef struct box{
  19. float x0;
  20. float y0;
  21. float x1;
  22. float y1;
  23. float score;
  24. } det_box;
  25. det_box** postprocessing(signed char *input_data[3], signed char y_zero[3], float y_scale[3],
  26. unsigned char *data_buf, int w, int h, int output_c, int num_classes, const int anchors[3][3][2], int outputs,
  27. const float NMS_threshold, const float VALID_THRESHOLD, int* box_ret, det_box** ret_box);
  28. det_box** postprocessing_fp(float *input_data[3], signed char y_zero[3], float y_scale[3],
  29. unsigned char *data_buf, int w, int h, int output_c, int num_classes, const int anchors[3][3][2], int outputs,
  30. const float NMS_threshold, const float VALID_THRESHOLD, int* box_ret, det_box** ret_box);