def freeze_parameters(model):
    """
    Freezes all parameters from a given model.

    Args:
        model (any of nff.nn.models)
    """
    for param in model.parameters():
        param.requires_grad = False

    return model