1. A computer-implemented method for detecting objects in an input image, comprising: receiving a set of training images and associated annotations, the annotations labeling categories and locations of objects which appear in the images; determining one or more subcategories for each of the categories of objects, wherein the number of subcategories for an object category is inferred from the training images and the associated annotations via a clustering technique in which the number of subcategories is driven by appearance variations within the object category, and wherein the clustering technique does not require the number of subcategories for the object category to be specified as an input to the clustering technique; training classifiers for detecting the subcategories; training a respective structured model for each of the categories of objects, the respective structured model accounting for relationships between detected subcategories; and detecting the objects in the input image using the trained subcategory classifiers and structured models.
1. A computer-implemented method for detecting objects in an input image, comprising: receiving a set of training images and associated annotations, the annotations labeling categories and locations of objects which appear in the images; determining one or more subcategories for each of the categories of objects, wherein the number of subcategories for an object category is inferred from the training images and the associated annotations via a clustering technique in which the number of subcategories is driven by appearance variations within the object category, and wherein the clustering technique does not require the number of subcategories for the object category to be specified as an input to the clustering technique; training classifiers for detecting the subcategories; training a respective structured model for each of the categories of objects, the respective structured model accounting for relationships between detected subcategories; and detecting the objects in the input image using the trained subcategory classifiers and structured models. 6. The computer-implemented method of claim 1 , wherein the structured model for one of the categories of objects includes one or more of a root model representing a confidence that a given object belongs to the one of the categories based on output of a subcategory classifier, a spatial context model representing a confidence that a given object belongs to the object-level category based on spatial positions of other subcategories detected in the image, a weak spatial contextual model that encodes whether objects are above/below or to the left/right of other objects, and a co-occurrence model representing a confidence that the given object belongs to the object-level category based on the co-occurrence of two subcategories.