def _bytesHumanReadable(num_bytes, unit_step=1024.0):
    """
    Converts the number of bytes passed into a human-readable format.

    :param The number of bytes: The number to be converted.
    :param The base number: unit_step used in the conversion.
    :return:  Human reaable number
    :rtype str:
    """

    try:
        num_bytes = float(num_bytes)
    except ValueError:
        return ""

    unit = 'bytes'

    if (num_bytes / unit_step) >= 1:
        num_bytes /= unit_step
        unit = 'KB'
    if (num_bytes / unit_step) >= 1:
        num_bytes /= unit_step
        unit = 'MB'
    if (num_bytes / unit_step) >= 1:
        num_bytes /= unit_step
        unit = 'GB'
    if (num_bytes / unit_step) >= 1:
        num_bytes /= unit_step
        unit = 'TB'

    # Rounding to the tenth.
    num_bytes = round(num_bytes, 1)

    if num_bytes == 0:
        unit = ''
        num_bytes = int(0)

    return str(num_bytes) + ' ' + unit