Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Requesting guidance for error during validation : KeyError: 'i' #118

Open
Abhijeet241093 opened this issue May 31, 2024 · 0 comments
Open

Comments

@Abhijeet241093
Copy link

Commond :

python tools/valid.py --cfg experiments/coco/higher_hrnet/w32_512_adam_lr1e-3.yaml TEST.MODEL_FILE /home/tricubics/Desktop/HigherHRNet-Human-Pose-Estimation/output/coco_kpt/pose_higher_hrnet/w32_512_adam_lr1e-3/model_best.pth.tar

Error generated :
=> classes: ['background', 'holding', 'nonholding']
Traceback (most recent call last):
File "tools/valid.py", line 220, in
main()
File "tools/valid.py", line 153, in main
for i, (images, annos) in enumerate(data_loader):
File "/home/tricubics/anaconda3/envs/hrnet/lib/python3.8/site-packages/torch/utils/data/dataloader.py", line 631, in next
data = self._next_data()
File "/home/tricubics/anaconda3/envs/hrnet/lib/python3.8/site-packages/torch/utils/data/dataloader.py", line 675, in _next_data
data = self._dataset_fetcher.fetch(index) # may raise StopIteration
File "/home/tricubics/anaconda3/envs/hrnet/lib/python3.8/site-packages/torch/utils/data/_utils/fetch.py", line 51, in fetch
data = [self.dataset[idx] for idx in possibly_batched_index]
File "/home/tricubics/anaconda3/envs/hrnet/lib/python3.8/site-packages/torch/utils/data/_utils/fetch.py", line 51, in
data = [self.dataset[idx] for idx in possibly_batched_index]
File "/home/tricubics/Desktop/HigherHRNet-Human-Pose-Estimation/tools/../lib/dataset/COCODataset.py", line 109, in getitem
file_name = coco.loadImgs(img_id)[0]['file_name']
File "/home/tricubics/.local/lib/python3.8/site-packages/pycocotools/coco.py", line 227, in loadImgs
return [self.imgs[id] for id in ids]
File "/home/tricubics/.local/lib/python3.8/site-packages/pycocotools/coco.py", line 227, in
return [self.imgs[id] for id in ids]
KeyError: 'i'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant