def unit_convert(byte):
    """ Converts byte into readable formats. """
    power = 1024
    zero = 0
    units = {
        0: 'B',
        1: 'KB',
        2: 'MB',
        3: 'GB'}
    while byte > power:
        byte /= power
        zero += 1
    return f"{round(byte, 2)} {units[zero]}"