Dlib face

Diego Victor de Jesus

Diego Victor de Jesus 2017-03-02

Hello!

In my application i run two face detectors: a detector for normal image and another for upsampled image (same image). Next, i compare the number of detected faces resulted from both detectors and output results of the greater vector (the resulting array of faces rects).

I'm trying to find a way to optimize speed detection by blocking already detected faces from normal image and passing it to the upsampled detector. For example, setting pixels to 0 of all ROIs detected in normal detector.

Would gain on performance be noticeable?

  •  
  • Davis

    Davis 2017-03-03

    This isn't a sensible thing to do. When you run the detector on the
    upsampled image it scans the whole image for faces big and small. So
    running it on a smaller image is totally redundant.

     
    •  
    • Diego Victor de Jesus

      Diego Victor de Jesus 2017-03-03

      Indeed. What i forgot to say is that i want to know the difference in number of detected faces between the normal detection and upsampled detection. I want to create some info about detection success on a dataset of faces of many sizes

       
      •  
      • Davis

        Davis 2017-03-03

        That's still not sensible. The detector literally down samples the image
        internally multiple times and scans all the resulting images. So doing
        what you are doing is literally rerunning the same computation. If all you
        want to know is the minimum sized face it will find then I can tell you it
        doesn't look for faces smaller than about 80x80 pixels.

         
        •  
        • Diego Victor de Jesus

          Diego Victor de Jesus 2017-03-03

          I think i get it. So the detector takes the upsampled image and at a certain detection phase it runs on a downsampled version image which is the same as the original image? If so, the upsampled version will always have the same results as normal detector plus the results from its own starting size?

          By the way, is it correct to assume that the detector will look for 40x40 faces when running on a upsampled frame?

           
          Last edit: Diego Victor de Jesus 2017-03-03
          •  
          • Davis

            Davis 2017-03-03

            Yes, that's how it works.

            Yes, if you double the size of the image then small faces that were 40x40
            will be 2x as big and so the detector will find them.

             

             alternate

            •  

猜你喜欢

转载自blog.csdn.net/CVAIDL/article/details/85061158