def yaml(self):
        return yaml.dump(self.serialized, default_flow_style=False,
                         encoding=None)
def sample_fn(x):
    return utils.optimise_and_sample(x, module=model,
                                     data=None, is_training=False)[0]