КОМЕНТАРІ •

  • @sammydarden6104
    @sammydarden6104 2 роки тому +9

    Heres some of the code that was totally 'linked in the description'
    #im suffering
    def stackImages(scale, imgArray):
    rows = len(imgArray)
    cols = len(imgArray[0])
    rowsAvailable = isinstance(imgArray[0], list)
    width =imgArray[0][0].shape[1]
    height = imgArray[0][0].shape[0]
    if rowsAvailable:
    for x in range (0, rows):
    for y in range(0, cols):
    if imgArray[x][y].shape[:2] == imgArray[0][0].shape[:2]:
    imgArray[x][y] = cv2.resize(imgArray[x][y], (0,0), None, scale, scale)
    else:
    imgArray[x][y] = cv2.resize(imgArray[x][y], (imgArray[0][0].shape[1], imgArray[0][0].shape[0]), None, scale, scale)
    if len(imgArray[x][y].shape) == 2: imgArray[x][y] = cv2.cvtColor(imgArray[x][y], cv2.COLOR_GRAY2BGR)
    imageBlank = np.zeros((height, width, 3), np.uint8)
    hor = [imageBlank]*rows
    hor_con = [imageBlank] *rows
    for x in range (0,rows):
    hor[x] = np.hstack(imgArray[x])
    ver = np.vstack(hor)
    else:
    for x in range(0,rows):
    if imgArray[x].shape[:2] == imgArray[0].shape[:2]:
    imgArray[x] = cv2.resize(imgArray[x], (0,0), None, scale, scale)
    else:
    imgArray[x] = cv2.resize(imgArray[x], (imgArray[0].shape[1], imgArray[0]), None, scale, scale)
    if len(imgArray[x].shape) ==2: imgArray[x] = cv2.cvtColor(imgArray[x], cv2.COLOR_GRAY2BGR)
    hor = np.hstack(imgArray)
    ver = hor
    return ver

  • @serjkp
    @serjkp 4 роки тому

    Моє шанування! Прекрасні уроки, дякую!

  • @renanstn7659
    @renanstn7659 3 роки тому +6

    I can't thank you enough for this!
    Incredible and very well explained tutorial

  • @qzorn4440
    @qzorn4440 Рік тому +1

    A most interesting OpenCV video. I have a new Orange Pi-5 SBC and would like to do some OpenCV Python examples on it. The Raspberry Pi-4 has a wealth of examples to practice with first. This wonderful Tutorial Shape Detection lesson [9] will be very helpful. 😎 Thank you.

  • @ajaynair4657
    @ajaynair4657 4 роки тому +4

    Thank you so much for the clear explanation. I am currently working on a project,This will definitely help me.

  • @SubaBlubba
    @SubaBlubba 2 роки тому

    I appreciate the little adjustments before using the "main" feature detector more and more

  • @ankitpandeynitdurgapur9813
    @ankitpandeynitdurgapur9813 2 роки тому +1

    Thank you for explaining it in such an easy and simple way. A Must watch video for everyone. ❤️

  • @arnezor
    @arnezor 3 роки тому +3

    Can you give me the link for this course, the link in description just redirects me to the new website of yours. I cant find this particular project there. Thanks

  • @amandanamikata9600
    @amandanamikata9600 5 місяців тому

    i love you you are awesome, the best videos on youtube for computer vision!

  • @raushankumarrauniyar6170
    @raushankumarrauniyar6170 11 місяців тому

    GREAT TO HAVE THIS ON UA-cam SIR

  • @tomasaraujo1640
    @tomasaraujo1640 2 роки тому

    Thank you my friend. It took an hour to translate from python to C++ but I made it

  • @googlecolab7388
    @googlecolab7388 Рік тому

    by now, already have image stack function support by library? so we don't need your custime fuction? library function like below? stacked = np.hstack((frame, foregroundPart, frameCopy))

  • @sumanachakraborty9559
    @sumanachakraborty9559 Рік тому

    Thanks for the informative video, can u help me once...how could i label the individual objects? Actually i want to calculate how many objects and their total area.

  • @siddharthmodi2740
    @siddharthmodi2740 2 роки тому +1

    I am little confuse here? Is it calculating are of the bounding box around the object or area of the object itself?
    I think it's calculating of bounding box?
    Btw the tutorial is good ❤️💯

  • @pierrealmhanna2226
    @pierrealmhanna2226 3 роки тому +1

    Thank you so much
    You help me to start with my final year project idea
    I just need to know how can I crop each rectangle and show it as many photos

  • @강웨이-v3x
    @강웨이-v3x 3 роки тому +1

    Is this AWESOME! but i cant find this code in website,,,,, also i dont know this opencv's version,, i want slove error plz answer my Q i wait your answer,,

  • @TehJellyLord
    @TehJellyLord 3 роки тому +1

    What a great tutorial! You are really saving my grades right now! I've just gotta apply this to only the pip symbols on playing cards. Which of the links in the description leads to the imgStack function?

  • @walidhassan5816
    @walidhassan5816 4 роки тому

    This Channel deserve more Subscribes than it has..!!

  • @viralmakwana9848
    @viralmakwana9848 Рік тому

    Hello sir,
    I have one doubt on ..."is it possible to identification of object in sort manner like....example on one table 5-6 different nd same objects are there, in that 2 glass are at different corners...so i want to show that was not proper that 2 glasses should be placed in one place. Like that i have to show through objects detection is it feasible?
    Looking for your suggestions
    Thank you

  • @albertalmonte6045
    @albertalmonte6045 2 роки тому +1

    When I click the link to get the code, it says the webpage has been moved. How can I obtain the code? Anyone has a direct link?

  • @YazeedAlkosai
    @YazeedAlkosai 3 роки тому

    great work Dr Murtaza, is it possible to like this work with think speak to show the detection of the object.thanks in advance

  • @vihaanthebot429
    @vihaanthebot429 Рік тому

    Can't you use the Numpy function "hstack" (like this: "images = np.hstack((img1, img2))") instead of creating a new function called "stackedImages" ?

  • @UddhikaIshara
    @UddhikaIshara 2 роки тому

    Great tutorial Thank you very much, Unfortunately, The reference code is not available in the links. So i had to type all from the beginning.

  • @zakariaabderrahmanesadelao3048
    @zakariaabderrahmanesadelao3048 4 роки тому +1

    exactly what i was looking for thank you a million! subbed

  • @cesarenriquevillarguerra8270
    @cesarenriquevillarguerra8270 2 роки тому

    First, I gave you a LIKE! , Second: I have a question, What code(s) can we use to get the poinst (x,y) of the shape to draw (after) the shape in Autocad?? Thanks for the answer!

  • @arturkaczan1776
    @arturkaczan1776 4 роки тому +1

    Everything is clear now. Thanks :)

  • @dennyssantiago3165
    @dennyssantiago3165 2 роки тому

    Good contribution, I have a question, how you can transform the area that you get with the function into a value of square meters? Thank you

  • @jayantagrawal8325
    @jayantagrawal8325 3 роки тому +2

    Anyone knows how to find out the coordinates of the shapes detected? Any help would be really appreciated. Also the tutorial's really really helpful. Thanks!

  • @mazlum7367
    @mazlum7367 10 місяців тому

    hi, whats happens the area value if object moving opposite the camare direction?

  • @testingtoolsco
    @testingtoolsco 3 роки тому

    this is really great video, just wondering as a next step can we name them as what are these objects? like detecting them as a certain type of object, that is classifying it as a car, scissors and rectangle etc? that will be great help

    • @anupambanerjee8336
      @anupambanerjee8336 3 роки тому

      Yolo does that for you.

    • @testingtoolsco
      @testingtoolsco 3 роки тому

      @@anupambanerjee8336 it does not do automatically, we have to train it, which is what i want to learn too

  • @AyieJosh
    @AyieJosh 2 роки тому

    i have a problem where if there's nothing is detected it will error. especially when i remove the object from camera view. it is either from lines convert into gray or in get contour lines where it says expecting 2 argument received 0.

  • @mehrdadm.5804
    @mehrdadm.5804 9 місяців тому

    Greate tutorial, thanks lot

  • @surajtakkekar227
    @surajtakkekar227 Рік тому

    Project is good ❤️....But How to detect size in mm like width and height ....

  • @felixmaas375
    @felixmaas375 3 роки тому

    Hi there! I have got a question: I am looking for an algorithm which gives a proposal on the region of interest in an image. Based on this proposal I want then to run an object detection. Is this video now more a "proposal on the region of interest" or is it alreday the "object detection"? Thanks! :-)

  • @kirubakirubakar2554
    @kirubakirubakar2554 3 роки тому

    If I use my normal laptop webcam is not detecting properly the objects. I have to take it really close to the screen, then I am getting the details properly. Is there anything wrong with how I am doing it

  • @salix_qmeou
    @salix_qmeou 4 роки тому +2

    i'm tryng to run the code but i'm getting
    cv2.error: OpenCV(4.3.0) /io/opencv/modules/highgui/src/window_QT.cpp:462: error: (-27:Null pointer) NULL window handler in function 'icvFindTrackBarByName'

    • @saphead-invader3100
      @saphead-invader3100 4 роки тому +1

      Try pasting this error code in google or stack overflow you may get the answer

  • @jamescurious1990
    @jamescurious1990 2 роки тому

    Hi, can We store the value of points and area of the object detected outside the for loop?

  • @pranavlad3319
    @pranavlad3319 3 роки тому +2

    Where is the code you just for the program on your site ? and please mention the installation process too.

    • @tlmyasirs
      @tlmyasirs 3 роки тому +2

      check his github

    • @kamathprajna
      @kamathprajna 3 роки тому

      @@tlmyasirs where is the image file 😭

    • @tlmyasirs
      @tlmyasirs 3 роки тому

      @@kamathprajna use any image

  • @amandanamikata9600
    @amandanamikata9600 5 місяців тому

    omg you do it with no model lol awesome

  • @tarektabba9726
    @tarektabba9726 4 роки тому

    I love your channel. Keep up the great projects!

  • @yonathangov77
    @yonathangov77 3 роки тому +2

    could you post a git hub repository?

  • @nitraautomation9426
    @nitraautomation9426 9 місяців тому

    How to detect object with position x,y and rotation angle alpha?

  • @phudinhtruong
    @phudinhtruong 4 роки тому +1

    Thank you your video help me alot

  • @rutujalahoti5790
    @rutujalahoti5790 4 роки тому

    The area which is the output that is in mm ?And instead of area can we find height and width of that bounding box ? Please help..

  • @pudu315
    @pudu315 2 роки тому

    It is really helpful. Thank you...

  • @meronabate8694
    @meronabate8694 3 роки тому

    helpful, but can contours used to detect texts from distorted image?

  • @kaveeshamadhubhashana3094
    @kaveeshamadhubhashana3094 2 роки тому

    can i use this with infrared images to get animal's name as a output

  • @aminahnurulhuda
    @aminahnurulhuda 3 місяці тому +1

    import cv2
    import numpy as np
    framewidth = 640
    frameheight = 480
    cap = cv2.VideoCapture(0)
    cap.set(3, framewidth)
    cap.set(4, frameheight)
    def empty(a):
    pass
    cv2.namedWindow("Parameters")
    cv2.resizeWindow("Parameters", 640, 240)
    cv2.createTrackbar("Threshold1", "Parameters", 150, 255, empty)
    cv2.createTrackbar("Threshold2", "Parameters", 150, 255, empty)
    cv2.createTrackbar("Area", "Parameters", 5000, 30000, empty)
    def stackImages(scale, imgArray):
    rows = len(imgArray)
    cols = len(imgArray[0])
    rowsAvailable = isinstance(imgArray[0], list)
    width =imgArray[0][0].shape[1]
    height = imgArray[0][0].shape[0]
    if rowsAvailable:
    for x in range (0, rows):
    for y in range(0, cols):
    if imgArray[x][y].shape[:2] == imgArray[0][0].shape[:2]:
    imgArray[x][y] = cv2.resize(imgArray[x][y], (0,0), None, scale, scale)
    else:
    imgArray[x][y] = cv2.resize(imgArray[x][y], (imgArray[0][0].shape[1], imgArray[0][0].shape[0]), None, scale, scale)
    if len(imgArray[x][y].shape) == 2: imgArray[x][y] = cv2.cvtColor(imgArray[x][y], cv2.COLOR_GRAY2BGR)
    imageBlank = np.zeros((height, width, 3), np.uint8)
    hor = [imageBlank]*rows
    hor_con = [imageBlank] *rows
    for x in range (0,rows):
    hor[x] = np.hstack(imgArray[x])
    ver = np.vstack(hor)
    else:
    for x in range(0,rows):
    if imgArray[x].shape[:2] == imgArray[0].shape[:2]:
    imgArray[x] = cv2.resize(imgArray[x], (0,0), None, scale, scale)
    else:
    imgArray[x] = cv2.resize(imgArray[x], (imgArray[0].shape[1], imgArray[0].shape[0]), None, scale, scale)
    if len(imgArray[x].shape) ==2: imgArray[x] = cv2.cvtColor(imgArray[x], cv2.COLOR_GRAY2BGR)
    hor = np.hstack(imgArray)
    ver = hor
    return ver
    def getContours(img, imgContour):
    contours, hierarchy = cv2.findContours(img, cv2.RETR_EXTERNAL, cv2.CHAIN_APPROX_NONE)
    for cnt in contours:
    area = cv2.contourArea(cnt)
    areaMin = cv2.getTrackbarPos("Area", "Parameters")
    if area > areaMin:
    cv2.drawContours(imgContour, contours, -1, (255, 0, 255), 2)
    perimeter = cv2.arcLength(cnt, True)
    approx = cv2.approxPolyDP(cnt, 0.02 * perimeter, True)
    print(len(approx))
    x, y, w, h = cv2.boundingRect(approx)
    cv2.rectangle(imgContour, (x, y), (x+w, y+h), (0, 255, 0), 2)
    cv2.putText(imgContour, "Points: " + str(len(approx)), (x + w + 20, y + 20), cv2.FONT_HERSHEY_COMPLEX, 0.7, (0, 255, 0), 2)
    cv2.putText(imgContour, "Area: " + str(int(area)), (x + w + 20, y + 45), cv2.FONT_HERSHEY_COMPLEX, 0.7, (0, 255, 0), 2)
    while True:
    success, img = cap.read()
    imgContour = img.copy()
    imgBlur = cv2.GaussianBlur(img, (7, 7), 1)
    imgGray = cv2.cvtColor(imgBlur, cv2.COLOR_BGR2GRAY)
    threshold1 = cv2.getTrackbarPos("Threshold1", "Parameters")
    threshold2 = cv2.getTrackbarPos("Threshold2", "Parameters")
    imgCanny = cv2.Canny(imgGray, threshold1, threshold2)
    kernel = np.ones((5, 5))
    imgDil = cv2.dilate(imgCanny, kernel, iterations=1)
    getContours(imgDil, imgContour)
    imgStack = stackImages(0.8, ([img, imgBlur, imgCanny],
    [imgDil, imgContour, imgContour]))
    cv2.imshow("Result", imgStack)
    if cv2.waitKey(1) & 0xFF == 27: # Escape key
    break
    cap.release()
    cv2.destroyAllWindows()

  • @sampritipatel8981
    @sampritipatel8981 3 роки тому

    Amazing tutorial! very insightful

  • @lamnhatoan9944
    @lamnhatoan9944 6 місяців тому

    Thank you!

  • @Ben.N
    @Ben.N 3 роки тому +1

    anyone got a link for the split windows function?

  • @rahmandani2374
    @rahmandani2374 4 роки тому

    Bro, u have journal of this method? i mean finding contour

  • @Ben.N
    @Ben.N 3 роки тому +1

    nicely done :)

  • @busrabetten9040
    @busrabetten9040 Рік тому

    Thanks a lot!

  • @eminpakdemir
    @eminpakdemir 3 роки тому

    You are the man.

  • @byeolkim2685
    @byeolkim2685 4 роки тому

    Thank you very much@@
    I have a question about your video.
    I wanna detect shapes of objects from video files.
    so I add the code that below. But it doesn't work. what is the problem?
    cap = cv2.VideoCapture('../2.mp4')
    while True:
    success, img = cap.read()

    • @murtazasworkshop
      @murtazasworkshop 4 роки тому +1

      Your file might not be in the correct folder. Try the code in the link for the video . github.com/murtazahassan/OpenCV-Python-Tutorials-for-Beginners/blob/master/Basics/Read_Image_Video_Webcam.py
      If you are still unable to run . Share the error message and i will have a look .

    • @byeolkim2685
      @byeolkim2685 4 роки тому

      Murtaza's Workshop - Robotics and AI Thank you for your kindness. 😊😊 It works well.

  • @humoruniverse6399
    @humoruniverse6399 3 роки тому

    why we used success,img at the 12th lines?

  • @chakloongchong545
    @chakloongchong545 2 роки тому

    Your video is awesome, I can't find your code, can you share it?

  • @XxRoxX511
    @XxRoxX511 4 роки тому

    Hi thank you for this , I have a quick question , why i have (invalid syntax) in( ; 0xFF) The last line

    • @murtazasworkshop
      @murtazasworkshop 4 роки тому

      this is an html issue of the website. I will fix this. if you find 'amp' remove it.

  • @namhunhyung1353
    @namhunhyung1353 3 роки тому

    thanks, how can i get cord?

  • @changelife2179
    @changelife2179 4 роки тому

    thanks for video!!

  • @joyaljohnvi-d29
    @joyaljohnvi-d29 3 роки тому

    i can't find stackImage funtion code anywhere

  • @varshinimb491
    @varshinimb491 2 роки тому

    How can we detect only textboxes in an image

  • @josecarloscruzcastaneda8056
    @josecarloscruzcastaneda8056 4 роки тому +1

    Great video bro, but, how can i know the area in cm2?

    • @dennyssantiago3165
      @dennyssantiago3165 2 роки тому +1

      Hola, has logrado conseguir información de como pasar el área que se obtiene a cm2?

    • @Tuncaydin0
      @Tuncaydin0 Рік тому

      @@dennyssantiago3165 can anyone learn

  • @veekeshpydannah704
    @veekeshpydannah704 3 роки тому

    How can i use it for detecting only human contours please, i really need help on that.

    • @murtazasworkshop
      @murtazasworkshop 3 роки тому

      I suggest you to check my Pose Estimation video

  • @baraalsaeed6865
    @baraalsaeed6865 2 роки тому

    thank you , but the link does not work

  • @3elmashy522
    @3elmashy522 4 роки тому

    How to get the summation of areas of more than one object ?

  • @sarathkumar-gq8be
    @sarathkumar-gq8be 4 роки тому

    can we upload the images and find out the area of that image or pic, using that reference object

    • @murtazasworkshop
      @murtazasworkshop 4 роки тому +1

      Yes i have a similar tutorial on this called object measurement.

    • @sarathkumar-gq8be
      @sarathkumar-gq8be 2 роки тому

      @@murtazasworkshop here you represent the area in which format, because in video has 4digit and 5digit valuess , but i don't know the mm2 or cm2

  • @-C-ARBHARADWAJ
    @-C-ARBHARADWAJ Рік тому

    where we must see the codes

  • @otabek_dev
    @otabek_dev 3 роки тому

    How can i take the stack images function on the video ???

    • @murtazasworkshop
      @murtazasworkshop 3 роки тому

      Follow the link in the description and go to chapter 6 .

    • @otabek_dev
      @otabek_dev 3 роки тому

      @@murtazasworkshop Thanks a lot 👍👍

  • @karlokajbasimanic8223
    @karlokajbasimanic8223 3 роки тому

    How can I use this to detect circle? Circle has infinite number of "points" so we cant use points for that.

    • @teslamodel314
      @teslamodel314 3 роки тому +1

      it seems a matter of how you aproximate the contour, and the shape you draw around it. Maybe there's a function to measure the angles between the segments, and maybe you can compare the are and the perimeter, to see if they are compatible with a circle.

  • @ericcute6471
    @ericcute6471 4 роки тому

    Great one.

  • @priyankavelumani3327
    @priyankavelumani3327 3 роки тому

    What is the use of it?

  • @donaldkimpoua2853
    @donaldkimpoua2853 5 років тому

    thank you so much Murtaza's

  • @erinwolf1563
    @erinwolf1563 5 років тому

    Thank you very much sir👍

  • @sammydarden6104
    @sammydarden6104 2 роки тому

    By the way, the link you claimed to give in the video(s) are broken :). I had to copy 45 lines of complicated code from a freakinf 144p screen, and i just hope that nobody else had to go throught that, because by the end, i just gave up on the project entirely. I dont know how to get access to the code, but PLEASE PLEASE PLEASE FIX THE LINK!!!!!! (good video btw)

    • @sammydarden6104
      @sammydarden6104 2 роки тому

      def stackImages(scale, imgArray):
      rows = len(imgArray)
      cols = len(imgArray[0])
      rowsAvailable = isinstance(imgArray[0], list)
      width =imgArray[0][0].shape[1]
      height = imgArray[0][0].shape[0]
      if rowsAvailable:
      for x in range (0, rows):
      for y in range(0, cols):
      if imgArray[x][y].shape[:2] == imgArray[0][0].shape[:2]:
      imgArray[x][y] = cv2.resize(imgArray[x][y], (0,0), None, scale, scale)
      else:
      imgArray[x][y] = cv2.resize(imgArray[x][y], (imgArray[0][0].shape[1], imgArray[0][0].shape[0]), None, scale, scale)
      if len(imgArray[x][y].shape) == 2: imgArray[x][y] = cv2.cvtColor(imgArray[x][y], cv2.COLOR_GRAY2BGR)
      imageBlank = np.zeros((height, width, 3), np.uint8)
      hor = [imageBlank]*rows
      hor_con = [imageBlank] *rows
      for x in range (0,rows):
      hor[x] = np.hstack(imgArray[x])
      ver = np.vstack(hor)
      else:
      for x in range(0,rows):
      if imgArray[x].shape[:2] == imgArray[0].shape[:2]:
      imgArray[x] = cv2.resize(imgArray[x], (0,0), None, scale, scale)
      else:
      imgArray[x] = cv2.resize(imgArray[x], (imgArray[0].shape[1], imgArray[0]), None, scale, scale)
      if len(imgArray[x].shape) ==2: imgArray[x] = cv2.cvtColor(imgArray[x], cv2.COLOR_GRAY2BGR)
      hor = np.hstack(imgArray)
      ver = hor
      return ver
      #Your Welcome :)

    • @murtazasworkshop
      @murtazasworkshop 2 роки тому

      Thanks for letting me know. Stack image function can be found in Chapter 6 of the link below
      www.computervision.zone/courses/learn-opencv-in-3-hours/

  • @ericcute6471
    @ericcute6471 4 роки тому

    Can you show us sir on how to compute the weight based on an image? Thanks

    • @murtazasworkshop
      @murtazasworkshop 4 роки тому

      You could find it based on the area. if your environment is fixed.

    • @ericcute6471
      @ericcute6471 4 роки тому

      @@murtazasworkshop can you demo it Sir show how pls

  • @Marcshields
    @Marcshields 3 роки тому

    Can you do a tutorial on detecting plants in real time?

  • @BiranchiNarayanNayak
    @BiranchiNarayanNayak 5 років тому

    Nice tutorial !!

  • @ishankrajpal8231
    @ishankrajpal8231 3 роки тому

    can anybody give me the stacking code..thanks.

  • @nikolauskopernikus7207
    @nikolauskopernikus7207 4 роки тому

    i love this video

  • @jericreyechavez9
    @jericreyechavez9 4 роки тому

    Superb tutorial! Can you do a tutorial that can measure a height of a person using open cv ? Kind regards

    • @murtazasworkshop
      @murtazasworkshop 4 роки тому +1

      I will look into it .

    • @jericreyechavez9
      @jericreyechavez9 4 роки тому

      @@murtazasworkshop Thank you. It will be a great help of my project in which the dealine is this coming feb haha.

    • @murtazasworkshop
      @murtazasworkshop 4 роки тому +1

      @@jericreyechavez9 You can follow this tutorial ( ua-cam.com/video/dZ4itBvIjVY/v-deo.html ) with the full body cascade which should give you a bounding box around a human body. Then u could used a fixed coefficient for pixel to cm to find the height. Your camera and target position should be fixed though.

    • @jericreyechavez9
      @jericreyechavez9 4 роки тому

      @@murtazasworkshop Thank you so much! You deserve more followers!

    • @jericreyechavez9
      @jericreyechavez9 4 роки тому

      @@murtazasworkshop But I will also love to watch your tutorial about this, if you're planning to.

  • @amandanamikata9600
    @amandanamikata9600 5 місяців тому

    Corrected piece of code:
    def stackImages(scale, imgArray):
    rows = len(imgArray)
    cols = len(imgArray[0])
    rowsAvailable = isinstance(imgArray[0], list)
    width =imgArray[0][0].shape[1]
    height = imgArray[0][0].shape[0]
    if rowsAvailable:
    for x in range (0, rows):
    for y in range(0, cols):
    if imgArray[x][y].shape[:2] == imgArray[0][0].shape[:2]:
    imgArray[x][y] = cv2.resize(imgArray[x][y], (0,0), None, scale, scale)
    else:
    imgArray[x][y] = cv2.resize(imgArray[x][y], (imgArray[0][0].shape[1], imgArray[0][0].shape[0]), None, scale, scale)
    if len(imgArray[x][y].shape) == 2: imgArray[x][y] = cv2.cvtColor(imgArray[x][y], cv2.COLOR_GRAY2BGR)
    imageBlank = np.zeros((height, width, 3), np.uint8)
    hor = [imageBlank]*rows
    hor_con = [imageBlank] *rows
    for x in range (0,rows):
    hor[x] = np.hstack(imgArray[x])
    ver = np.vstack(hor)
    else:
    for x in range(0,rows):
    if imgArray[x].shape[:2] == imgArray[0].shape[:2]:
    imgArray[x] = cv2.resize(imgArray[x], (0,0), None, scale, scale)
    else:
    imgArray[x] = cv2.resize(imgArray[x], (imgArray[0].shape[1], imgArray[0].shape[0]), None, scale, scale)
    if len(imgArray[x].shape) ==2: imgArray[x] = cv2.cvtColor(imgArray[x], cv2.COLOR_GRAY2BGR)
    hor = np.hstack(imgArray)
    ver = hor
    return ver

  • @pythonner3644
    @pythonner3644 4 роки тому +1

    rather than stacking with this long function u can use numpy to that

  • @nabsmyfoot5308
    @nabsmyfoot5308 4 роки тому

    hi how can i get the full code for this?

    • @murtazasworkshop
      @murtazasworkshop 4 роки тому

      follow the link in the description and enroll to get access to the code

  • @makeitsimple2306
    @makeitsimple2306 4 роки тому

    Thanx so much 💔💔

  • @marcinek656
    @marcinek656 4 роки тому

    Hey, can i have question for you on priv? 😀

    • @murtazasworkshop
      @murtazasworkshop 4 роки тому

      sure . you can contact me through this page. facebook.com/murtazasworkshop

  • @dubito_joy
    @dubito_joy 2 роки тому

    thanks god

  • @aysegulakman503
    @aysegulakman503 11 місяців тому

    ---------------------------------------------------------------------------
    NameError Traceback (most recent call last)
    in
    16
    17 imgStack = stackImages(0.8, ([img,imgGray,imgCanny],
    ---> 18 [imgDil,imgDil,imgDil]))
    19
    20
    I'm getting an error, what should I do?

  • @IkramAli-ze8um
    @IkramAli-ze8um 4 роки тому +1

    need stack function code

  • @smiley3753
    @smiley3753 4 роки тому

    I want to draw contour around my eye pupil only how to do it

    • @murtazasworkshop
      @murtazasworkshop 4 роки тому

      you can use the face dlib to get the contours. If you want to use this method in the video, then its better to first detect the face and eye using the haarcascade method. (here is the tutorial).

  • @miguelguerreiro5280
    @miguelguerreiro5280 4 роки тому

    subbed

  • @astar777
    @astar777 3 роки тому

    File "d:\J.A.R.V.I.S\jarvis.py", line 384, in
    getContours(imgDil, imgContour)
    File "d:\J.A.R.V.I.S\jarvis.py", line 172, in getContours
    cv2.rectangle(imgContour, (x, y), (x + w + y + h), (0, 255, 0), 5)
    TypeError: function takes exactly 4 arguments (2 given)
    I am getting this error pls help me.....
    (in that qr code script same error is coming named "TypeError: function takes exactly 2 arguments (3 given)
    I am using python 3.9.2

  • @abiskardahal3288
    @abiskardahal3288 3 роки тому

    My image is so noisy how to remove noise

    • @murtazasworkshop
      @murtazasworkshop 3 роки тому

      Usually depends on the type of noise. You can try median filter.

  • @brkaya6778
    @brkaya6778 3 роки тому

    kaynak kod paylaş haci

  • @hajar2629
    @hajar2629 5 років тому

    Where code

  • @jayeshkumeriya5984
    @jayeshkumeriya5984 3 роки тому

    can anyone give me that stack code please