Explain Batch Normalization and Dropout in a Shelf Image Classifier
Last updated: November 29, 2026
Quick Overview
A convolutional model classifies photos of store shelves to detect empty spots and misplaced items. Explain what batch normalization and dropout each do, and how they behave differently in training and inference.
Walmart Labs
November 29, 20260
0
0 solved
A convolutional model classifies photos of store shelves to detect empty spots and misplaced items. Explain what batch normalization and dropout each do, and how they behave differently in training and inference.
Walmart uses computer vision on shelf images from cameras and handheld devices to spot out of stocks and planogram issues. This screening question checks deep learning fundamentals and whether the candidate knows the training versus inference behavior that causes real production bugs.
What the Interviewer Expects
- Describe the batch norm computation and learnable scale and shift
- Explain why batch norm helps optimization
- Describe dropout as random unit masking with scaling
- Explain train versus eval mode differences for both
- Mention small batch issues and alternatives like group or layer norm
Key Topics to Cover
How to Approach This
- Understand the bias-variance trade-off. High training accuracy but low test accuracy signals overfitting.
- Choose evaluation metrics carefully based on the problem. Accuracy alone is often insufficient.
- Feature engineering is often more impactful than model selection.
- Know when to use tree-based models (tabular data) vs neural networks (unstructured data).
- Handle class imbalance with SMOTE, class weights, or appropriate loss functions.
Possible Follow-up Questions
- What goes wrong if you forget to switch to eval mode before serving?
- Why might batch norm hurt when fine-tuning with batch size 4?
- Where would you place dropout in a modern CNN, if at all?
- How does batch norm interact with transfer learning?
Sharpen Your Skills on Codemia
Practice similar problems with our interactive workspace, get AI feedback, and track your progress.
Explore ML Interview PrepSample Answer
Clarify
Assume a ResNet-style backbone pretrained on ImageNet, fine-tuned on shelf images with labels like empty facing, misplaced item, ok. Images come from different stores with varied lighting and camera a...
Approach
Explain each layer's math and purpose, then the train versus inference behavior, then the practical choices for this dataset....