FIG. 9 illustrates an example of a first part of a second weighting model that is used for automatic exposure control (AEC). In some examples, the second weighting model may treat each object of an image independently of everything else in the image. In such examples, a learning based model (e.g., neural network, clustering, or the like) may be used for each object of the image (or a subset of the objects). The learning based model may output a value to be used as a weight for each pixel group for the object. After a weight is generated for each object of the image, a final weight array may be created by summing each one of the weight arrays for each object. This is different than the first weighting model, where we multiplied the weight arrays together. In other examples, a learning based model may be used for each pixel group of an object. In such examples, the rest of the process would be performed similarly to having a learning based model for each object, except rather than having a single value used for every pixel group of an object, a value would be computed for each pixel group. In other examples, a learning based model may be used for each weight (e.g., object distance, object priority, metering, or the like) for an object. In such examples, the weights for a single object would need to be combined as discussed above for the first weighting model. After the weights for each object are combined, the rest of the process may continue as the second weighting model would.