mlcommons / tiny

MLPerf™ Tiny is an ML benchmark suite for extremely low-power systems such as microcontrollers
https://mlcommons.org/en/groups/inference-tiny/
Apache License 2.0
344 stars 81 forks source link

Facing "e-[Insufficient number of hex digits]" issue in accuracy mode #79

Closed malreddy-commits-pixel closed 3 years ago

malreddy-commits-pixel commented 3 years ago

Facing below issue in "Multiple run mode(accuracy mode)" for anomaly detection. Below attached the screen shot which shows the error message.

image

Could you please take a look ?

petertorelli commented 3 years ago

Data was dropped in the UART path. If you look at the code here you can see that a byte was dropped.

  } else {
    size_t numbytes;
    char test[3];
    long res;

    /* Two hexdigits per byte */
    numbytes = th_strnlen(p_next, EE_CMD_SIZE);

    if ((numbytes & 1) != 0) {
      th_printf("e-[Insufficent number of hex digits]\r\n");
      return EE_ARG_CLAIMED;
    }
    test[2] = 0;

This can be cause by too high a baud rate, or an error in the Rx code, or an issue with the Host<>UART hardware driver (e.g., the Prolific USB<>TTL, SiLabs USB<>TTL, and STM VCP driver could be the issue).

Peter

petertorelli commented 3 years ago

Also, the latest 3.0.6 version has a setting in the ini file called disable-mute. Set that to true to disable muting the bload messages. This can help you identify when/where it is failing.

shijay01 commented 3 years ago

Using baudrate of 115200 during compilation of the bin and for the runs solved the issue , though it is recommended in the reference submission's Readme that 921600 is the desirable baudrate.

cskiraly commented 3 years ago

Thanks @shijay01 . 921600 is recommended to speed up the accuracy test that downloads lots of data over serial. However, it seems the higher baud rate is not working on all systems. I'm glad 115200 solved it for you. I'm adding a note on this in the README https://github.com/mlcommons/tiny/pull/82

petertorelli commented 3 years ago

@shijay01 That is good news. Please close the issue if resolved. Cheers, Peter

shijay01 commented 3 years ago

Thankyou @cskiraly and @petertorelli . Closing the issue.