paddlepaddle2.0开启enable_mkldnn报错
Created by: iwctwbai
版本:paddlepaddle==2.0.0b0
报错内容:
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/paddleocr/paddleocr.py", line 222, in __init__ super().__init__(postprocess_params) File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/paddleocr/tools/infer/predict_system.py", line 41, in __init__ self.text_detector = predict_det.TextDetector(args) File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/paddleocr/tools/infer/predict_det.py", line 80, in __init__ utility.create_predictor(args, mode="det") File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/paddleocr/tools/infer/utility.py", line 121, in create_predictor config.set_mkldnn_cache_capacity(10) AttributeError: 'paddle.fluid.core_avx.AnalysisConfig' object has no attribute 'set_mkldnn_cache_capacity'
配置:
Namespace(cls=False, cls_batch_num=30, cls_image_shape='3, 48, 192', cls_model_dir='/Users/upuni/.paddleocr/cls', cls_thresh=0.9, det=True, det_algorithm='DB', det_db_box_thresh=0.5, det_db_thresh=0.3, det_db_unclip_ratio=2.0, det_east_cover_thresh=0.1, det_east_nms_thresh=0.2, det_east_score_thresh=0.8, det_max_side_len=2400, det_model_dir='/Users/upuni/.paddleocr/det', enable_mkldnn=True, gpu_mem=8000, image_dir=None, ir_optim=True, label_list=['0', '180'], lang='ch', max_text_length=1500, rec=True, rec_algorithm='CRNN', rec_batch_num=18, rec_char_dict_path='./ppocr/utils/ppocr_keys_v1.txt', rec_char_type='ch', rec_image_shape='3, 32, 320', rec_model_dir='/Users/upuni/.paddleocr/rec/ch', use_angle_cls=False, use_gpu=False, use_space_char=True, use_tensorrt=True, use_zero_copy_run=True)