AI0-001 Machine Learning and Deep Learning Practice Question
A data engineer is designing a pipeline to train a linear regression model on a dataset with 10 million rows and 50 features. The dataset fits in memory. Which approach should the engineer use to train the model efficiently?
⚠ Common exam trap
CompTIA often tests the misconception that the normal equation is always the best for small feature sets, but the trap here is that candidates overlook the massive computational cost of the O(n * f^2) matrix multiplication when n is large (10 million rows), even though f is small (50 features).
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
Stochastic gradient descent
Stochastic gradient descent (SGD) is the most efficient approach for training a linear regression model on a dataset with 10 million rows and 50 features because it updates the model parameters using only one training example per iteration, leading to much faster convergence per epoch compared to batch methods. Since the dataset fits in memory, SGD can still be implemented efficiently without the overhead of loading data in batches from disk, and it scales well to large datasets where the normal equation or batch gradient descent would be computationally prohibitive.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
Normal equation
Why it's wrong here
Normal equation requires computing (X^T X)^{-1}, which is computationally expensive for large datasets.
- ✗
Batch gradient descent
Why it's wrong here
Batch gradient descent uses the whole dataset for each update, which is slow for large datasets.
- ✗
Principal component analysis
Why it's wrong here
PCA reduces dimensionality but does not train a model.
- ✓
Stochastic gradient descent
Why this is correct
SGD updates weights per sample, making it efficient for large datasets.
About these practice questions
This AI0-001 question is part of Courseiva's 754-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This AI0-001 practice question is part of Courseiva's free CompTIA certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the AI0-001 exam.