Hardware limitation for RapidOCR #146
Closed
Iambestfeed
started this conversation in
Ideas
Replies: 1 comment 5 replies
-
You can change the source code as the following: RapidOCR/python/rapidocr_onnxruntime/utils.py Lines 31 to 34 in f686541 Add options like below: sess_opt = SessionOptions()
sess_opt.log_severity_level = 4
sess_opt.enable_cpu_mem_arena = False
sess_opt.graph_optimization_level = GraphOptimizationLevel.ORT_ENABLE_ALL
# If you want to use 6 CPUs, you can set the intra_op_num_threads=6
sess_options.intra_op_num_threads = 6 See details for onnxruntime docs |
Beta Was this translation helpful? Give feedback.
5 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
First of all, I would like to thank you for your contribution to this project.
While using RapidOCR, I wondered if I could limit the number of CPUs used during inference?
I tried looking at the issues as well as reading the Documentation but since I don't know Chinese, I really don't know if there is any way to limit the number of CPUs used? I hope if possible, can you answer me or at least give me a suggestion for a solution?
Thanks.
Beta Was this translation helpful? Give feedback.
All reactions