def METHOD_NAME(self, index, obj_nums, config, base, logger):
    image = ImageF(base['image_bounds'], wcs=base['wcs'], init_value=0.)
    if len(self.scratch) > 0.:
        # If we have been accumulating the variance on the stamps, build the total from them.
        for obj_num in obj_nums:
            stamp = self.scratch[obj_num]
            b = stamp.bounds & image.bounds
            if b.isDefined(): # pragma: no branch
                # This next line is equivalent to:
                #    image[b] += stamp[b]
                # except that this doesn't work through the proxy.  We can only call methods
                # that don't start with _.  Hence using the more verbose form here.
                image.setSubImage(b, image.subImage(b) + stamp[b])
    else:
        # Otherwise, build the variance map now.
        if 'include_obj_var' in config:
            include_obj_var = ParseValue(config, 'include_obj_var', base, bool)[0]
        else:
            include_obj_var = False
        base['current_noise_image'] = base['current_image']
        AddNoiseVariance(base,image,include_obj_var,logger)
    # Now invert the variance image to get weight map.
    # Note that any zeros present in the image are maintained as zeros after inversion.
    # So it is ok to set bad pixels to have zero variance above, and they will invert to have
    # zero weight.
    image.invertSelf()
    self.data[index] = image