def _compare_entropy(start_slice, end_slice, slice, difference):
    start_entropy = utils.image_entropy(start_slice)
    end_entropy = utils.image_entropy(end_slice)
    if end_entropy and abs(start_entropy / end_entropy - 1) < 0.01:
        # Less than 1% difference, remove from both sides.
        if difference >= slice * 2:
            return slice, slice
        half_slice = slice // 2
        return half_slice, slice - half_slice
    if start_entropy > end_entropy:
        return 0, slice
    else:
        return slice, 0
List of hosts, passives, and arbiters known to this server.
dataset/ETHPy150Open SmileyChris/easy-thumbnails/easy_thumbnails/processors.py/_compare_entropy--crossover with--dataset/ETHPy150Open mongodb/mongo-python-driver/pymongo/ismaster.py/IsMaster.all_hosts