cd /news/machine-learning/what-has-your-experience-with-knowle… · home › topics › machine-learning › article
[ARTICLE · art-140627] src=discuss.huggingface.co ↗ pub= topic=machine-learning verified=true sentiment=· neutral

What has your experience with knowledge distillation been like?

Practitioners distilling vision models report that a temperature around T=3-4 best transfers the teacher's inter-class "dark knowledge" to the student, while higher values degrade the signal into uniform noise. The student also inherits the teacher's calibration rather than only its accuracy, so an overconfident teacher yields an overconfident student that serving-time softmax temperature cannot correct, making ECE worth checking alongside accuracy. Cross-architecture distillation (CNN teacher to ViT student) requires feature-level hints beyond logits, and pruning before distilling generally beats distilling before pruning because the student learns the teacher's behavior on the exact sparse structure it will serve with.

read1 min views1 publishedSep 27, 2026

Two things that surprised me when I distilled vision models:

The temperature is doing double duty. High temperature softens the teacher’s logits so the student learns the dark knowledge — which wrong classes look plausible, not just the right answer. That inter-class similarity is the actual transfer; hard labels never carry it. Too hot and it all becomes uniform noise the student memorizes. Somewhere around T=3-4 is usually where the dark knowledge is legible without washing out.

The student inherits the teacher’s calibration, not just its accuracy. If the teacher is overconfident (most are), the student comes out overconfident too — and no serving-time softmax temperature fixes what the training temperature already baked in. Worth checking ECE on the student, not just accuracy, or the “smaller model” quietly becomes a confidently-wrong one.

The non-obvious one from my side: distilling across architectures hurts more than the papers suggest. ResNet-18 from a ResNet-50 teacher works because the inductive biases rhyme. Cross-family (CNN teacher, ViT student) needs feature-level hints, not just logits — the logit surface alone doesn’t carry enough of the “how to see” part.

Your pruning-then-distilling combo is interesting — recovering into the sparse structure usually beats distilling first and pruning after, because the student gets to learn the teacher’s behavior on the exact structure it will serve with.

── more in #machine-learning 4 stories · sorted by recency
── more on @resnet-18 3 stories trending now
sponsored brought to you by zahid.host 4,200+ EU-deployed projects
reading about agents? ship yours in a single git push.

Run your AI side-project on zahid.host

EU-based hosting, git-push deploys, automatic HTTPS, no cold starts. Free tier with a custom domain — perfect for shipping the agent you just read about.

$git push zahid main
→ Live at https://your-agent.zahid.host ✓
Get free account → Pricing
from €0/mo · no card required
LIVE [news/what-has-your-experi…] indexed:0 read:1min 2026-09-27 · —