from typing import Dict
import torch


def default_fn(x, models, **kwargs) -> Dict[str, torch.Tensor]:
    """
    The default inference function for [BaseAdapter][pytorch_adapt.adapters.BaseAdapter].
    """
    features = models["G"](x)
    logits = models["C"](features)
    return {"features": features, "logits": logits}