What is the correct way to create representative dataset for TFliteconverter?
问题 I am trying to infer tinyYOLO-V2 with INT8 weights and activation. I can convert the weights to INT8 with TFliteConverter. For INT8 activation, I have to give representative dataset to estimate the scaling factor. My method of creating such dataset seems wrong. What is the correct procedure ? def rep_data_gen(): a = [] for i in range(160): inst = anns[i] file_name = inst['filename'] img = cv2.imread(img_dir + file_name) img = cv2.resize(img, (NORM_H, NORM_W)) img = img / 255.0 img = img