EasyOCR
EasyOCR copied to clipboard
Macos M1 CPUs and GPUs get different results
Environment
Macos 14.1 M1 Pro Part of My Image
Code
import easyocr
if __name__ == '__main__':
start_time = time.time()
reader = easyocr.Reader(['ch_sim', 'en'], gpu=False) # this needs to run only once to load the model into memory
result = reader.readtext(r'./images/idalog/screen/qun.screen.0.png', detail = 0)
end_time = time.time()
print("time: {:.2f} seconds".format(end_time - start_time))
Result
CPU
'请点击查看错误日志详情', '收到', '回复' time: 5.74 seconds
GPU
'请点击查看错误日志详情', '收鼢', '鼢复' time: 8.63 seconds
The CPU works well, but the GPU has some problems!
Thank you for all your hard work!
I had the same problem with another language and dataset doing my dissertation. Also our production systems display this behavior, I believe it is related to the word size used in gpu vs cpu, and the precision on the convolution operation of the neural network.
+1