def calc_percent(whole, total):
    """
    """
    try:
        pct = whole / total
    except ZeroDivisionError:
        pct = 0
    else:
        pct * 100

    return pct
dataset/ETHPy150Open california-civic-data-coalition/django-calaccess-raw-data/calaccess_raw/management/commands/reportcalaccessrawdata.py/calc_percent/original