get_adapter_params¶
- torchtune.modules.peft.get_adapter_params(model: Module) Dict[str, Parameter] [source]¶
Return the subset of parameters from a model that correspond to an adapter. Assumes that any adapter class has defined the
adapter_params()
method.- Parameters:
model (nn.Module) – Instance of model class containing some adapter params.
- Returns:
the subset of model’s state dict containing only adapter parameters.
- Return type:
Dict[str, nn.Parameter]