transformers
This module offers Hugging Face Transformers specific tools.
Hint
Use pip to install the necessary dependencies for this module:
pip install mltb2[transformers]
- class mltb2.transformers.KFoldLabeledDataset(n_splits=7, n_repeats=1, random_state=None)[source]
Bases:
object
Utility to do k-fold cross-validation on
LabeledDataset
.
- class mltb2.transformers.LabeledDataset(encodings, labels)[source]
Bases:
Dataset
Dataset with labes.