AI开发平台ModelArts-日志提示“AttributeError: 'NoneType' object has no attribute 'dtype'”:处理方法

时间:2025-02-12 15:02:57

处理方法

在代码中打印出numpy的版本,查看是否为1.18.5版本,如果非该版本号则在代码开始处执行:

import osos.system('pip install numpy==1.18.5')

如果依旧有报错情况,将以上代码修改为:

import osos.system('pip install numpy==1.18.5')os.system('pip install keras==2.6.0')os.system('pip install tensorflow==2.6.0')
support.huaweicloud.com/trouble-modelarts/modelarts_trouble_0063.html
提示

您即将访问非华为云网站,请注意账号财产安全