pyvene.models.modeling_utils.output_to_subcomponent#
- output_to_subcomponent(output, component, model_type, model_config)[source]#
Split the raw output to subcomponents if specified in the config.
- Parameters:
output – the original output from the model component.
component – types of model component, such as
“block_output” and “query_output” or it can be direct referece, such as “h[0].mlp.act” which we will not splice into any subcomponent. :param model_type: Hugging Face Model Type :param model_config: Hugging Face Model Config