class ImagenetDatasetDataset def __init__self path transform=None selftransform = transform selfpaths = selflabels = selflabel_to_idx = defaultdictint selfidx_to_label = selfidx_to_text = s
这个错误是因为在sense_to_name字典中找不到名为'assembly_line'的键。你可以检查一下sense_to_name字典中是否包含了这个键的定义。如果没有,你可以尝试添加这个键到sense_to_name字典中,并为它赋予一个合适的值。
原文地址: https://www.cveoy.top/t/topic/ja3M 著作权归作者所有。请勿转载和采集!