背景:mmpretrain==2.1.0 模型训练时出现错误。
原因:你环境包下面的类别数没改过来。
解决方法:(你的环境python包下面的mmpretrain的categories.py)\usr\local\lib\python3.8\dist-packages\mmpretrain\datasets\categories.py的IMAGENET_CATEGORIES改成你自己的类别名字,个数要和自己的类别数一致。
AssertionError: The number of subfolders (102) doesn‘t match the number of specified classes (1000)
于 2025-03-17 23:05:59 首次发布