A training dataset is the portion of prepared data from which a model learns. It supplies inputs and ground-truth targets: transaction features and fraud labels for tabular detection, transaction-node features and licit/illicit labels for Bitcoin classification, or audio and real/fake labels for voice detection. Training updates model parameters through prediction, loss calculation, and backpropagation. section 3.4.1 section 9.2.3 section 8.2.2
Prepare the dataset before training in a form the model can consume. For Slovakian ID documents, annotations are converted from JSON into DONUT-friendly text, images are resized to the average dataset dimensions, text is tokenized, and padded label tokens are ignored before the processed data is split. For audio, a custom Torch Dataset loads waveforms, extracts MFCC features, and returns each feature set with its class. section 7.3.2 section 8.1.3
Keep training data separate from data used to steer and judge learning:
- Use a test set as unseen final evaluation data. For time-series transactions, reserve the most recent 20% rather than randomly splitting the sequence. section 3.4.1
- Create a validation set from training data to monitor learning and correct course if the model begins overfitting; the Elliptic workflow randomly allocates 20% of training transactions to validation. section 9.1.3
- Train on the training mask only, then calculate validation accuracy and F1 separately; use F1 alongside accuracy when classes are imbalanced. section 9.2.3
Building a fraud-training split
For tabular fraud detection, select feature columns as X and isFraud as y, calculate an 80% split index, and take earlier rows for X_train and y_train. The later rows become X_test and y_test, preserving the dataset’s time order. A final random-forest workflow adds engineered features before splitting, training, evaluation, and deployment-threshold selection. section 3.4.1 section 3.7
Figure 7.25 Sequence of steps covered in this section to process the Slovakian ID dataset, starting with handling the text annotations by converting JSON format into a DONUT-friendly format, tokenizing the annotation text, resizing all ID images to a fixed shape and finally splitting the dataset into training and test sets.
Follow the ID-document preparation sequence from JSON annotations through tokenization and fixed-size images to a 90/10 training/test split. section 7.3.2

















































