Answers.Body: <p>In state-of-the-art papers. researcher managed to achieve 90-100% accuracy on gender classification on just human faces, so both method may work just fine, with minor improvements maybe using the first method. However using the image of the entire body enhances overfitting as there is more input features and increases overfitting. For a very large dataset it might be better to use the first method as chances of overfitting are low while for a smaller one you should probably go for the second method or even just the face as that won't make such a huge differnce. </p>
  
  <p>A better way to input the data to the network is through landmarks of a body.
  <a href="https://i.sstatic.net/chrDs.jpg" rel="nofollow noreferrer"><img src="https://i.sstatic.net/chrDs.jpg" alt="enter image description here"></a></p>
  
  <p>Inputting the landmarks of the body helps reduce the features to the minimal and also keeps only the relevant features. The main difference in body between women and men is perhaps the torso and shoulder width, which you can get from body landmark detection. You can input both the image of the face and the body landmark as input to the network, and it would probably increase in accuracy. However this solution is not an one stage method, meaning it requires an extra model to predict the landmark.</p>
  
  <p>Hope I can help you.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-12-15T14:57:58.503Z
Answers.LastActivityDate: 2019-12-15T14:57:58.503Z
Answers.UserDisplayName: Clement
Body: <p>I wonder what is the better way of drawing rectangles on images for gender classification. My task is to create a classifier (CNN based) to detect gender from pictures of entire bodies (not just faces). When I started labeling pictures I noticed that I am not sure whether I should draw it around an entire person like example 1 (including hands and legs and some background space between them) or just the inner part like example 2 (where there is almost no background), in order to achieve better results?</p>
  
  <h3>Example 1</h3>
  
  <p><a href="https://i.sstatic.net/lRDJP.jpg" rel="nofollow noreferrer"><img src="https://i.sstatic.net/lRDJP.jpg" alt="enter image description here"></a></p>
  
  <h3>Example 2</h3>
  
  <p><a href="https://i.sstatic.net/awi8U.jpg" rel="nofollow noreferrer"><img src="https://i.sstatic.net/awi8U.jpg" alt="gend"></a></p>
  
Tags: <convolutional-neural-networks><classification><computer-vision>
Title: How to draw bounding boxes for gender classification?
UserDisplayName: GKozinski
ThreadText: # How to draw bounding boxes for gender classification?
  
  (Asked by: username_0 on 2019-12-14)
  
  I wonder what is the better way of drawing rectangles on images for gender classification. My task is to create a classifier (CNN based) to detect gender from pictures of entire bodies (not just faces). When I started labeling pictures I noticed that I am not sure whether I should draw it around an entire person like example 1 (including hands and legs and some background space between them) or just the inner part like example 2 (where there is almost no background), in order to achieve better results?
  
  ### Example 1
  
  [![enter image description here](https://i.sstatic.net/lRDJP.jpg)](https://i.sstatic.net/lRDJP.jpg)
  
  ### Example 2
  
  [![gend](https://i.sstatic.net/awi8U.jpg)](https://i.sstatic.net/awi8U.jpg)
  
  **Tags:** convolutional-neural-networks, classification, computer-vision
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2019-12-15. Score: 2
  
  In state-of-the-art papers. researcher managed to achieve 90-100% accuracy on gender classification on just human faces, so both method may work just fine, with minor improvements maybe using the first method. However using the image of the entire body enhances overfitting as there is more input features and increases overfitting. For a very large dataset it might be better to use the first method as chances of overfitting are low while for a smaller one you should probably go for the second method or even just the face as that won't make such a huge differnce.
  
  A better way to input the data to the network is through landmarks of a body.
  [![enter image description here](https://i.sstatic.net/chrDs.jpg)](https://i.sstatic.net/chrDs.jpg)
  
  Inputting the landmarks of the body helps reduce the features to the minimal and also keeps only the relevant features. The main difference in body between women and men is perhaps the torso and shoulder width, which you can get from body landmark detection. You can input both the image of the face and the body landmark as input to the network, and it would probably increase in accuracy. However this solution is not an one stage method, meaning it requires an extra model to predict the landmark.
  
  Hope I can help you.
  
  
  ---
  
  