初版:教务抢课系统 jwxt(从线上实例导出)
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
import ddddocr, base64, json
|
||||
|
||||
with open("captcha_b64.txt") as f:
|
||||
b64 = f.read().strip()
|
||||
|
||||
img = base64.b64decode(b64)
|
||||
with open("captcha_new.png", "wb") as f:
|
||||
f.write(img)
|
||||
|
||||
ocr = ddddocr.DdddOcr(show_ad=False)
|
||||
with open("captcha_new.png", "rb") as f:
|
||||
result = ocr.classification(f.read())
|
||||
|
||||
print(result)
|
||||
Reference in New Issue
Block a user