def METHOD_NAME(self, half_life, quad_life):
    # ensure that the gamma, power is solvable
    assert half_life > 0
    # convex monotonically decreasing
    assert quad_life > 2 * half_life
    t = float(quad_life) / float(half_life)
    x = t * (1.0 + np.sqrt(2.0)) / 2.0 - np.sqrt(2.0)
    gamma = (x - 1.0) / float(half_life)
    power = np.log(2.0) / np.log(x)
    logger.info(
        'homotopy_weighting: found lr param: gamma=%g, power=%g' %
        (gamma, power)
    )
    return gamma, power