Data for Machine Learning
Working with Data
Data is the fuel
Machine learning quality depends heavily on the quality of data. Good data should be relevant, consistent, and large enough to teach the model useful patterns. In many projects, data must be cleaned before training.
Splitting data
A dataset is often divided into training, validation, and test sets. The training set teaches the model, the validation set helps tune choices, and the test set checks final performance.
Common dataset splits
| Set | Purpose | Typical use |
|---|---|---|
| Training | Learn patterns | Fit model parameters |
| Validation | Tune settings | Choose model options |
| Test | Final check | Estimate real-world performance |
Data Leakage
Never let test data influence training decisions, or your evaluation may look better than it really is.
Which set is used to judge final model performance?
The test set is reserved for final evaluation.
Correct answer: Test set
Why do we split data into separate sets?
Separate sets help prevent overfitting and biased evaluation.
Correct answer: To train, tune, and evaluate the model fairly.
What is data leakage?
Leakage can make results look unrealistically good.
Correct answer: Letting evaluation data affect training decisions