def get_alpha_weights(w_fp):
    """Return alpha weight for determining opacity of each rate. The rates are FPR, FNR, FDR and FOR. These are also listed in `level_2 Documentation`_. 
    
    Args:   
        w_fp (int or float): False positive weight. Must be in interval [0,1].

    Returns: 
        dict: Dict with weights for each rate. Rate names are keys and weights are values. 
    """
    c = 0.2  # Factor added to make colors stronger
    if w_fp == 0.5:
        alpha_weights = {'FPR': 1, 'FNR': 1, 'FDR': 1, 'FOR': 1, 'WMR': 1}
    elif w_fp > 0.5:
        alpha_weights = {'FPR': 1, 'FNR': 1+c-w_fp,
                         'FDR': 1, 'FOR': 1+c-w_fp, 'WMR': 1}
    else:
        alpha_weights = {'FPR': c+w_fp, 'FNR': 1,
                         'FDR': c+w_fp, 'FOR': 1, 'WMR': 1}
    return alpha_weights