def METHOD_NAME(pb):
    cnf = pb.conf
    out = []
    yield pb, out
    if hasattr(cnf, 'opt_data'):
        # store homogenized tensor
        pb.conf.opt_data['D_homog'] = out[-1].D.copy()
    yield None