More in AI & ML — page 9
Interpreting a black-box gradient boosting model
WHAT IT TESTS: model interpretability methods. OUTLINE: global tools like permutation importance or aggregated SHAP rank overall feature influence; local tools like per-instance SHAP or LIME explain one prediction; SHAP unifies both via additive…
Random Forest versus Gradient Boosting
WHAT IT TESTS: understanding bagging versus boosting. OUTLINE: Random Forest trains deep trees in parallel and averages to cut variance; boosting builds shallow trees sequentially, each correcting prior errors to cut bias, often higher accuracy but…
Stemming versus lemmatization in text preprocessing
WHAT IT TESTS: NLP normalization trade-offs. OUTLINE: stemming chops affixes fast but crudely, yielding non-words; lemmatization maps to real dictionary base forms using POS, slower but accurate; skip both for embedding or transformer models.
Handling missing numerical values
WHAT IT TESTS: judgment about imputation trade-offs. OUTLINE: dropping rows is simple but loses data and can bias if missingness is non-random; mean or median imputation keeps rows but shrinks variance and ignores correlations; model-based imputation is…
Pandas loc versus iloc indexing
WHAT IT TESTS: practical pandas selection fluency. OUTLINE: loc selects by label and is inclusive of both endpoints; iloc selects by integer position and is exclusive of the stop; passing a string label to iloc fails.
MLE versus MAP estimation and the role of priors
WHAT IT TESTS: Bayesian versus frequentist parameter estimation. OUTLINE: MLE maximizes likelihood alone; MAP maximizes likelihood times a prior, acting as regularization that shrinks toward prior beliefs; with abundant data they converge.
Eigenvalues, eigenvectors, and their role in PCA
WHAT IT TESTS: linear algebra intuition behind dimensionality reduction. OUTLINE: an eigenvector keeps direction under a matrix, its eigenvalue scales it; PCA finds eigenvectors of the covariance matrix as principal axes.
How gradient descent and the learning rate work
WHAT IT TESTS: optimization fundamentals. OUTLINE: gradient descent steps downhill along the negative gradient to minimize cost; the learning rate sets step size; too high diverges or oscillates, too low converges painfully slowly.
Framing ad-load tradeoffs: revenue versus retention
WHAT IT TESTS: balancing competing metrics over time. OUTLINE: define revenue plus guardrail engagement metrics, run a long-enough experiment to see retention effects, and weigh short-term lift against lifetime-value erosion.
Does forcing profile completion cause retention?
WHAT IT TESTS: distinguishing correlation from causation. OUTLINE: name the confounder (engaged users self-select into completing profiles), warn that forcing it may not transfer the effect, and propose a randomized experiment.
Python Virtual Environments
A virtual environment is an isolated Python installation with its own packages, so each project gets the exact dependency versions it needs without conflicting with other projects or the system Python.
Transformer Architecture
The Transformer replaces recurrence with self-attention, letting every token directly attend to every other token in parallel. This enables long-range context and fast training on GPUs, making it the backbone of modern large language models and much of…
Generative Adversarial Network (GAN)
A GAN trains two networks in competition: a generator that fabricates fake samples and a discriminator that judges real versus fake. Their adversarial game pushes the generator toward realistic outputs, enabling image synthesis and data generation without…
Design an active learning loop for detection
WHAT IT TESTS: active learning system design. OUTLINE: seed-train, score the pool by uncertainty plus diversity, batch to annotators, retrain, repeat. RED FLAG: picking only the most uncertain images and getting redundant near-duplicates.
What does N-way K-shot classification mean?
WHAT IT TESTS: few-shot evaluation vocabulary. OUTLINE: N is classes per episode, K is labeled examples per class in the support set, prediction is on a separate query set. RED FLAG: confusing K with total training data or swapping N and K.
Filter-based vs optimization-based SLAM
WHAT IT TESTS: SLAM estimation paradigms. OUTLINE: EKF folds past poses into one Gaussian; optimization keeps a sparse graph and re-linearizes; the latter wins on accuracy and loop closure. RED FLAG: thinking filters are more accurate because recursive.
Design real-time multi-object tracking for AV
WHAT IT TESTS: tracking-by-detection under latency. OUTLINE: fast detector, Kalman motion model, Hungarian association on IoU plus appearance, track lifecycle for occlusions. RED FLAG: per-frame detection with no temporal state or ID management.
Loss functions for imbalanced medical segmentation
WHAT IT TESTS: imbalanced segmentation losses. OUTLINE: cross-entropy is swamped by background; Dice optimizes overlap directly; Focal down-weights easy pixels. RED FLAG: only tuning class weights and ignoring the gradient problem.
How is IoU computed and why prefer mIoU?
WHAT IT TESTS: segmentation metrics under imbalance. OUTLINE: IoU is intersection over union of predicted and true pixels; mIoU averages per class; pixel accuracy is dominated by background. RED FLAG: equating accuracy with IoU.
Homography vs fundamental matrix degeneracy
WHAT IT TESTS: epipolar geometry degeneracies. OUTLINE: homography fits planar scenes or pure rotation; fitting a fundamental matrix there is degenerate because points lack depth variation. RED FLAG: assuming the fundamental matrix always works.