def format_seconds(seconds):
    """
    @summary: 将秒转为时分秒
    ---------
    @param seconds:
    ---------
    @result: 2天3小时2分49秒
    """
    seconds = int(seconds + 0.5)
    m, s = divmod(seconds, 60)
    h, m = divmod(m, 60)
    d, h = divmod(h, 24)
    times = ''
    if d:
        times += '{}天'.format(d)
    if h:
        times += '{}小时'.format(h)
    if m:
        times += '{}分'.format(m)
    if s:
        times += '{}秒'.format(s)
    return times
