截图&日志
Traceback (most recent call last):
File "run.py", line 21, in
from init import select_ticket_info
File "/home/lsz/workspace/12306/init/select_ticket_info.py", line 16, in
from init.login import GoLogin
File "/home/lsz/workspace/12306/init/login.py", line 8, in
from inter.GetRandCode import getRandCode
File "/home/lsz/workspace/12306/inter/GetRandCode.py", line 12, in
v = Verify()
File "/home/lsz/workspace/12306/verify/localVerifyCode.py", line 49, in init
self.loadImgModel()
File "/home/lsz/workspace/12306/verify/localVerifyCode.py", line 60, in loadImgModel
self.imgModel = models.load_model(PATH('../12306.image.model.h5'))
File "/home/lsz/anaconda3/envs/py3.6/lib/python3.6/site-packages/keras/engine/saving.py", line 419, in load_model
model = _deserialize_model(f, custom_objects, compile)
File "/home/lsz/anaconda3/envs/py3.6/lib/python3.6/site-packages/keras/engine/saving.py", line 224, in _deserialize_model
model_config = json.loads(model_config.decode('utf-8'))
AttributeError: 'str' object has no attribute 'decode'
环境信息
描述问题
重现步骤
截图&日志 Traceback (most recent call last): File "run.py", line 21, in
from init import select_ticket_info
File "/home/lsz/workspace/12306/init/select_ticket_info.py", line 16, in
from init.login import GoLogin
File "/home/lsz/workspace/12306/init/login.py", line 8, in
from inter.GetRandCode import getRandCode
File "/home/lsz/workspace/12306/inter/GetRandCode.py", line 12, in
v = Verify()
File "/home/lsz/workspace/12306/verify/localVerifyCode.py", line 49, in init
self.loadImgModel()
File "/home/lsz/workspace/12306/verify/localVerifyCode.py", line 60, in loadImgModel
self.imgModel = models.load_model(PATH('../12306.image.model.h5'))
File "/home/lsz/anaconda3/envs/py3.6/lib/python3.6/site-packages/keras/engine/saving.py", line 419, in load_model
model = _deserialize_model(f, custom_objects, compile)
File "/home/lsz/anaconda3/envs/py3.6/lib/python3.6/site-packages/keras/engine/saving.py", line 224, in _deserialize_model
model_config = json.loads(model_config.decode('utf-8'))
AttributeError: 'str' object has no attribute 'decode'
环境信息
额外的备注