I really love the way of your teaching, I will be waiting for your uploads. Please provide the video for how to do object tracking from scratch. It will be helpful for the learners.
Instead and of random color generation for each detection in the detect function, define a fixed color for each class and then use that for each class id in detections.
@@TheCodingBug Yeah, but since it is a instance segmentation, we'll have multiple instances belongs to one class. In that case, we need to have four constant colors of four persons without changing.
@@TheCodingBug I tried it. Since, cars are belongs to one class, all cars are appearing in same color. But I need every instance of a object calls have a constant color through out the video. So, could you please help me to get it?
hello, thanks for your video, i have one question here, as detectron2 has already done the segmentation, why we still need yolov7 ? Does yolo v7 do the segmentation individually or it borrows the segmentation part from detectron2 ?
Great video! I am running this on CPU only and it seems to throw an error of incompatible tensors, do you know how i can fix this? RuntimeError: Input type (torch.FloatTensor) and weight type (torch.HalfTensor) should be the same or input should be a MKLDNN tensor and weight is a dense tensor I need to change the code in the function processFrame(image) ?
Hello, The issue is that the model must be cast into float type. in __main__ you have the following lines of code: if half: model = model.half() You must add the following lines: else: model = model.float() It should work after that.
Thanks for your video, it really help a lot. I am wondering what is the function of parameter "recompute_scle_factor...", and if I want to consistent the color for each instance object how can I do ? Appreciation for your willingness to share your thoughts.
Thanks for the Video but apart from Webcams, can we also detect from an external camera with an RTSP link? I would like to apply instance segmentation for an external camera (not Webcam) and would be really helpful if it would work!
@TheCodingBug Thanks for the video! But, in line 34, when you call model on image, the output is a tuple instead of a dictionary and thus it gives error in line 36 when you compute inf_out, train_out, ... Can you please help?
Thanks for the video. i got error NameError: name 'model' is not defined while make def processFrame(image): output = model(image) on line 34. any solution?
Thanks for the detailed and useful explanation. I am searching for a way to recognize all objects but then apply segmentation to hide persons. Is there a way to apply segmentation selectively using yolov7? Thanks in advance
As far as I know, the train.py in the mask-branch is still under development due to unresolved detectron2 dependencys. If you want to train on your custom dataset you should use the u7-Seg branch. It has been tested successfully and shows similar results to the mask-branch.
Hi, I am trying to do instance segementation with yolov7 using custom dataset, but I am struggling to convert coco style annotations to yolo style annotations. I know how to convert bounding boxes, but how to convert the segmentation list or RLE?
Hi sir, thankt for uploading great video. I have some errors when I load 'yolov7-mask.pt' I got these errors (torch.load('yolov7-mask.pt') -> AttributeError: Can't get attribute 'Merge' on ). But if I load 'yolo7-tiny.pt' error does not occur and the code runs very well. How can I load 'yolov7-mask.pt' like your videos?
@@TheCodingBug I am facing the same error although i installed the same torch and cuda version same like you (torch 1.11 and cuda 11.3), how to solve this ?
hello sir, while installing the detectron2 I get this error 5 errors detected in the compilation of "D:/Pothole_detection/detectron2/detectron2/layers/csrc/nms_rotated/nms_rotated_cuda.cu". nms_rotated_cuda.cu error: command 'C:\\Program Files\\NVIDIA GPU Computing Toolkit\\CUDA\\v11.6\\bin\ vcc.exe' failed with exit code 1
i want yolov5 deepsparse custom training tutorial using collab. and convert .pt to .onnx and run .onnx for detection. if you do this perfectly i will give DONATE 1000rs. NO CAP!
hi. I followed the instruction but why am I getting this error. Traceback (most recent call last): File "C:\Users\jisi\Desktop\YoloV7_Instance\yolov7-mask\segment.py", line 67, in onImage() NameError: name 'onImage' is not defined tia
I really love the way of your teaching, I will be waiting for your uploads. Please provide the video for how to do object tracking from scratch. It will be helpful for the learners.
It will be uploaded by the end of this month.
@@TheCodingBug Thank you so much 🙂
@@TheCodingBug Really happy to hear that video is coming up. I started to learn about this field and your videos are helping me a lot.
i have been do same thing with ur tutorial but why only image showing, not show bonding box or segmentation over the image
I am getting pred, and pred_masks as None, None. what could be the reasons for this?
Thank you very much for your video. Could you please tell me how to get constant color of the mask of the detected objects in a video?
Instead and of random color generation for each detection in the detect function, define a fixed color for each class and then use that for each class id in detections.
@@TheCodingBug Yeah, but since it is a instance segmentation, we'll have multiple instances belongs to one class. In that case, we need to have four constant colors of four persons without changing.
@@TheCodingBug I tried it. Since, cars are belongs to one class, all cars are appearing in same color. But I need every instance of a object calls have a constant color through out the video. So, could you please help me to get it?
hello, thanks for your video, i have one question here, as detectron2 has already done the segmentation, why we still need yolov7 ? Does yolo v7 do the segmentation individually or it borrows the segmentation part from detectron2 ?
Great video! I am running this on CPU only and it seems to throw an error of incompatible tensors, do you know how i can fix this?
RuntimeError: Input type (torch.FloatTensor) and weight type (torch.HalfTensor) should be the same or input should be a MKLDNN tensor and weight is a dense tensor
I need to change the code in the function processFrame(image) ?
+1
Hello,
The issue is that the model must be cast into float type. in __main__ you have the following lines of code:
if half:
model = model.half()
You must add the following lines:
else:
model = model.float()
It should work after that.
Thank for the video.
May I know is it possible to train custom 'mask.pt' file? I need it for my school work. Thx
u know why i failed isntall detectron2? that error with pycocotools
Thank u very much for the tutorial, but i have a question on if i can deploy this segmentation model on android? Is there a way for that to be done?
Excelent content, please do Tracking / counting with this yolov7, thanks !
Tracking tutorial is already made. I couldn't upload due to some health issues. Will post it by Tuesday.
Thanks for your video, it really help a lot.
I am wondering what is the function of parameter "recompute_scle_factor...", and if I want to consistent the color for each instance object how can I do ?
Appreciation for your willingness to share your thoughts.
First of all thank you for such neat teaching... How to do detection for custom objects??
I will make the tutorial in the next month on custom dataset.
Do you offer training hours via Teams against payment?
Not at the moment.
Thanks for the Video but apart from Webcams, can we also detect from an external camera with an RTSP link? I would like to apply instance segmentation for an external camera (not Webcam) and would be really helpful if it would work!
Yes. Just use rstp url as source for video instead of mp4 file.
Thanks a lot for this, man. ❤
would u help to to draw mask only body outline not fill the body with color
how to training and deploy model
@TheCodingBug
Thanks for the video! But, in line 34, when you call model on image, the output is a tuple instead of a dictionary and thus it gives error in line 36 when you compute inf_out, train_out, ...
Can you please help?
do you solve the question? I have same error, can tell me ? thank you
Thanks for the video.
i got error NameError: name 'model' is not defined while make def processFrame(image):
output = model(image) on line 34. any solution?
Check spellings... It's not "model".
@@TheCodingBug what correct spelling then?
@@TheCodingBug cuz on your video, it said output = model(image)
is the difference much to the yolov7?
Thanks a lot for this. I have a question that how can I get prediction keypoints or coordinates of segmentation from the result ?
Hey is it possible to train this implementation in a custom dataset? the same way we train yolov7 for object detection?
Nice video. Is there any way to do image classification based on yolov7 easily?
Yes. I'll make a video next month.
@@TheCodingBug thank you very much!
Thanks for the detailed and useful explanation. I am searching for a way to recognize all objects but then apply segmentation to hide persons. Is there a way to apply segmentation selectively using yolov7? Thanks in advance
Hi! How to reparameterize a model and convert to onnx?
Thank you so much. How do I train custom instance segmentation?
As far as I know, the train.py in the mask-branch is still under development due to unresolved detectron2 dependencys. If you want to train on your custom dataset you should use the u7-Seg branch. It has been tested successfully and shows similar results to the mask-branch.
Hi, I am trying to do instance segementation with yolov7 using custom dataset, but I am struggling to convert coco style annotations to yolo style annotations. I know how to convert bounding boxes, but how to convert the segmentation list or RLE?
Hello sir have you already converted coco format annotation to Yolo style annotation? Because it's also my problem now, Thank You sir.
I need to have gpu for instance segmentation ???
If you want a decent FPS, then yes.
but sir detectron will not install in cpu I think??
@@joart333 I recall that it'll throw an error when installing pycocotools.... I will check that on the weekend and let you know.
@@TheCodingBug OK sir
Hi sir, thankt for uploading great video. I have some errors when I load 'yolov7-mask.pt' I got these errors (torch.load('yolov7-mask.pt') -> AttributeError: Can't get attribute 'Merge' on ). But if I load 'yolo7-tiny.pt' error does not occur and the code runs very well. How can I load 'yolov7-mask.pt' like your videos?
Make sure your version of torch is the same as mine.
@@TheCodingBug I am facing the same error although i installed the same torch and cuda version same like you (torch 1.11 and cuda 11.3), how to solve this ?
have you found a solution to this issue?
We want to collaborate! What is the best email?
0:18
hello sir, while installing the detectron2 I get this error
5 errors detected in the compilation of "D:/Pothole_detection/detectron2/detectron2/layers/csrc/nms_rotated/nms_rotated_cuda.cu".
nms_rotated_cuda.cu
error: command 'C:\\Program Files\\NVIDIA GPU Computing Toolkit\\CUDA\\v11.6\\bin\
vcc.exe' failed with exit code 1
You should install ninja before detectron : conda install -c conda-forge ninja
i want yolov5 deepsparse custom training tutorial using collab. and convert .pt to .onnx and run .onnx for detection. if you do this perfectly i will give DONATE 1000rs. NO CAP!
Great video, but why is it so slow? I thought Yolov7 makes up to 150 fps?
That's on V100 GPU using YOLOV7 tiny.
@@TheCodingBug ok thanks!
hi. I followed the instruction but why am I getting this error.
Traceback (most recent call last):
File "C:\Users\jisi\Desktop\YoloV7_Instance\yolov7-mask\segment.py", line 67, in
onImage()
NameError: name 'onImage' is not defined
tia
The method onImage have wrong spellings or you've missed something there