kazu.training.modelling¶
Functions
|
Classes
- class kazu.training.modelling.BertForMultiLabelTokenClassification[source]¶
Bases:
BertForTokenClassification
- __init__(config)[source]¶
Initialize internal Module state, shared by both nn.Module and ScriptModule.
- Parameters:
config (PretrainedConfig)
- Return type:
None
- forward(input_ids=None, attention_mask=None, token_type_ids=None, position_ids=None, head_mask=None, inputs_embeds=None, labels=None, output_attentions=None, output_hidden_states=None, return_dict=None)[source]¶
- Parameters:
- Returns:
- Return type:
TokenClassifierOutput | Tuple[Tensor, …]
- class kazu.training.modelling.DebertaForMultiLabelTokenClassification[source]¶
Bases:
DebertaV2ForTokenClassification
- __init__(config)[source]¶
Initialize internal Module state, shared by both nn.Module and ScriptModule.
- Parameters:
config (PretrainedConfig)
- Return type:
None
- class kazu.training.modelling.DistilBertForMultiLabelTokenClassification[source]¶
Bases:
DistilBertForTokenClassification
- __init__(config)[source]¶
Initialize internal Module state, shared by both nn.Module and ScriptModule.
- Parameters:
config (PretrainedConfig)
- Return type:
None
- forward(input_ids=None, attention_mask=None, head_mask=None, inputs_embeds=None, labels=None, output_attentions=None, output_hidden_states=None, return_dict=None)[source]¶
- Parameters:
- Returns:
- Return type:
TokenClassifierOutput | Tuple[Tensor, …]
- kazu.training.modelling.multi_label_forward(model, outputs, return_dict, device, ignore_index, labels=None)[source]¶
- Parameters:
- Return type:
TokenClassifierOutput | Tuple[Tensor, …]