-
-
Notifications
You must be signed in to change notification settings - Fork 77
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
AttributeError: 'list' object has no attribute 'shape' #20
Comments
@Ureisen I have the same issue, did you figure out the solution? |
@AndrewTKent! What is the format of your labels, its in coco format or YOLO format? |
@RizwanMunawar Hi! Yes I have it in coco format (JSON) and I'm working out of a folder called coco_custom, and I have a coco_custom.yaml pointing to this folder coco_custom |
Hi! Is it fixed? I have the same issue. My dataset is in yolo format. |
@AndrewTKent The format is wrong, you will need to convert the labels to yolo (Polygon box) format. Also I will recommend to follow the tutorial for data labeling, that I already recommended for proper training. |
The required labeling format is Polygon box (with YOLO format). You can follow the tutorial for data labeling, that I already recommended for proper training. |
I have this with the existing code base as well, with labels in YOLO format... digging into it to propose a fix. |
It's late, but I'll leave it here in case anyone gets lost. Check you are running |
Hi!
I encountered such an error in the training process of using my own dataset (exported by RoboFlow). Is it because I have only one segmentation object?
It will be appreciated if you could give me some suggestions!
Traceback (most recent call last):
File "train.py", line 613, in
main(opt)
File "train.py", line 509, in main
train(opt.hyp, opt, device, callbacks)
File "train.py", line 291, in train
loss, loss_items = compute_loss(pred, targets.to(device)) # loss scaled by batch_size
File "/home/yolov7-segmentation-main/utils/loss.py", line 127, in call
tcls, tbox, indices, anchors = self.build_targets(p, targets) # targets
File "/home/yolov7-segmentation-main/utils/loss.py", line 200, in build_targets
anchors, shape = self.anchors[i], p[i].shape
AttributeError: 'list' object has no attribute 'shape'
The text was updated successfully, but these errors were encountered: