'Higher weights win.'

def _weigh_object(self, host_state, request_spec):

    if (not request_spec.instance_group):
        return 0
    policies = request_spec.instance_group.policies
    if (self.policy_name not in policies):
        return 0
    instances = set(host_state.instances.keys())
    members = set(request_spec.instance_group.members)
    member_on_host = instances.intersection(members)
    return len(member_on_host)
