The Vision Journalmodel cards for computer vision

Model library › Tutorials

Stop Tuning Hyperparameters: Choose ResNet or EfficientNet

Model card filed 2026-10-18

01 Overview

The title of this article is deliberately provocative, because the honest advice is not that hyperparameters never matter. It is that architecture choice is a decision you can make early, cheaply, and with far more leverage than another week of learning-rate sweeps. When you pick a residual-style network or a compound-scaled network, you inherit a design that already encodes a great deal of empirical engineering: how depth should be arranged, how width and resolution should trade off, and how gradient flow should be preserved through many layers. That inheritance reduces the number of decisions you must make from scratch.

Hyperparameter tuning is expensive in a way that is easy to underestimate. Every trial costs compute, wall-clock time, and human attention, and the returns diminish quickly once you are near a reasonable operating point. Architecture selection, by contrast, changes the shape of the entire search space. A network that is well matched to your data scale and your deployment budget will often outperform a poorly matched network even when the latter receives far more tuning effort.

This article treats architecture choice as a first-class engineering decision. We will look at what these two families are for, what data they need, how they work in plain terms, how to train and evaluate them, where they fail, and how to answer the questions that come up most often. The goal is a repeatable decision procedure rather than a leaderboard claim.

02 What the model is for

Both families are general-purpose image classifiers. You give them an image, they produce a probability distribution over your classes. That single capability underpins a surprising amount of practical computer vision: sorting photos, flagging defects on a production line, triaging medical images for human review, filtering user-generated content, and acting as the feature extractor inside a larger detection or segmentation system. In each case the classifier is not the whole product, but it is often the part that determines whether the product is feasible.

The two families occupy different points on the efficiency spectrum. Residual-style networks are the workhorse: deep, straightforward, well understood, and easy to adapt. They tend to reward generous compute and large datasets, and they are a sensible default when you have the budget to train them properly. Compound-scaled networks are designed around the observation that depth, width, and input resolution should grow together rather than independently. That makes them attractive when you care about accuracy per unit of compute, or when you must hit a latency or memory target on constrained hardware.

Neither family is specialized for a single domain. They are backbones, not solutions. The same architecture can be excellent on one dataset and mediocre on another depending on how well its inductive biases match the visual structure of the problem. That is why the decision should be driven by your constraints and your data, not by a generic ranking.

03 The data it needs

These models learn from labeled examples, and the quality of those labels usually matters more than the exact architecture you choose. A few thousand well-curated images with consistent labeling rules can beat a much larger set collected carelessly. Before you compare architectures, invest in a clear labeling guide, a held-out validation split that reflects deployment conditions, and a check for near-duplicate images that could leak between training and validation.

Input size is a practical constraint as much as a modeling one. A common baseline is 224 by 224 pixels, but you can train at other resolutions, and resolution interacts strongly with accuracy and cost. Higher resolution helps when fine detail distinguishes classes, such as reading small text or spotting tiny surface defects, but it also increases memory and compute roughly with the square of the side length. Downsampling aggressively can erase the very signal you need.

Class balance and domain coverage deserve attention early. If one class dominates, the model may learn to predict it and still look accurate on aggregate metrics. If your deployment images differ from your training images in lighting, camera, or background, the gap will show up as a failure mode rather than a tuning problem. Augmentation, resampling, and targeted collection of hard examples are usually more valuable than another architecture swap.

04 Architecture in plain terms

A residual-style network is built from blocks that learn a small adjustment to their input rather than the full transformation. The block computes a function and adds it back to its input, so information and gradients have a short path through the network. This addition is why very deep networks became trainable: the identity path gives gradients a direct route, and each block only needs to learn what to change. Stack enough of these blocks and you get a hierarchy that moves from edges and textures to parts and objects.

A compound-scaled network starts from the same convolutional foundation but treats scaling as a coordinated design problem. Instead of making a network deeper and deeper, or wider and wider, it scales depth, width, and input resolution by related factors chosen through a search over small base configurations. The intuition is that these dimensions are not independent: a deeper network benefits from more width, and both benefit from higher resolution, up to a point. Coordinating them tends to produce better accuracy for a given compute budget than scaling any one dimension alone.

In plain terms, residuals are about making depth trainable, while compound scaling is about spending a fixed budget wisely across depth, width, and resolution. Both use convolution, pooling, normalization, and nonlinear activations. Neither is magic; they are different answers to the question of where to put your capacity.

05 Training and evaluation

Start with a strong, simple recipe before you tune anything. Train from scratch if you have enough labeled data, or fine-tune a pretrained backbone if you do not. Use a held-out validation set for model selection and keep a separate test set untouched until the end. Report top-1 accuracy as your primary metric, and add per-class accuracy or a confusion matrix so you can see which classes are actually failing. Aggregate accuracy can hide a class that the model never learned.

When comparing the two families, control the variables that matter. Match the input resolution, the augmentation pipeline, the optimizer family, and the training schedule as closely as you can, then compare accuracy at a fixed compute or latency budget rather than at a fixed epoch count. Measure inference latency on the hardware you will actually deploy to, including preprocessing, because theoretical operation counts do not always predict real speed. Memory footprint matters too, especially on edge devices.

Tuning still has a role, but it should be targeted. A small sweep over learning rate and weight decay, plus a decision about resolution, usually captures most of the available gain. If a model is far behind after that, the problem is more likely data, labels, or architecture fit than a missing hyperparameter. Treat tuning as refinement, not as a substitute for choosing the right backbone.

06 Limitations and failure modes

No architecture guarantees accuracy, and neither family is universally best. Performance depends on dataset size, label quality, class difficulty, and the match between pretraining data and your domain. A model that wins on one benchmark can lose on your problem, so benchmarks are a starting point for hypotheses, not a verdict. Claims of superiority should always be read as conditional on a specific budget and dataset.

Both families are sensitive to distribution shift. If deployment images differ from training images in lighting, blur, compression, or viewpoint, accuracy can drop sharply even when validation looked strong. They can also latch onto spurious cues, such as background texture or watermark patterns, that happen to correlate with labels in the training set. Careful validation splits and error analysis are the main defenses.

Other failure modes are practical. Very deep or very wide models can overfit small datasets, and compound-scaled models can be harder to fit onto tight memory budgets at high resolution. Latency may be dominated by preprocessing or by layers that do not parallelize well. Finally, class imbalance and rare but important classes are often where these models fail most visibly, which is why per-class evaluation matters as much as the headline metric.

07 Frequently asked questions

Which family should I choose first? If you have ample compute and data, a residual-style network is a dependable default that is easy to train and adapt. If you are constrained by latency, memory, or a fixed compute budget, a compound-scaled network is often the better starting point because its design targets efficiency. In practice, train one strong baseline from each family at matched resolution and compare on your own validation set.

Do I still need to tune hyperparameters? Yes, but far less than you might think. A modest sweep over learning rate, weight decay, and input resolution usually captures most of the gain. If large tuning efforts are needed to make a model competitive, that is a signal that the architecture or the data is mismatched, not that you need more trials.

Can I use these models for detection or segmentation? Yes. Both families are commonly used as backbones inside larger systems, where a detection or segmentation head is attached to the feature hierarchy. The classification training recipe still matters because the backbone's features determine what the downstream head can learn.

How do I know when to stop? Stop when improvements on your validation set are smaller than the noise between runs, or when you hit your deployment budget. Always confirm with a final test-set evaluation and an error analysis on real deployment-like images before shipping.