import potencent # 可以填写本地图片的地址:img_path,也可以填写在线图片的地址:img_url # 如果2个都填,则只用在线图片 res = potencent.ocr.IDCardOCR( img_path=r'/Users/wangvivi/Desktop/Code/ocrtest/images/id_card.JPG', img_url='', configPath=r'配置文件的信息,可以不填') print(res)