PigeonColumba compressa

Deleting whole layers: plain vs. residual

Remove k of 8 hidden layers from a deep teacher. Residual nets are said to behave like ensembles of shallow paths. Does that make depth removable? And is initializing a shallow student from the teacher's layers worth it?

Methods: Layer dropping, ShortGPT (block influence)

Line chart of test accuracy (20-way) against layers removed (of 8), one line per configuration. Titled “Deleting whole layers: plain vs. residual”. The numbers are in the table below.
Test accuracy (20-way) against layers removed (of 8)
Bar chart of test accuracy (20-way) for each init. Titled “4-layer residual student, KD, different init”. The numbers are in the table below.
Test accuracy (20-way) for each init: 4-layer residual student, KD, different init

Table

Mean over the seeds; ± is the standard deviation where more than one seed ran. The experiment took 138 s.

KindLayers removed (of 8)RecoveryInitTest accuracy (20-way)Target-class AP ('bird')Test NLLKL(Bayes || model)Parameters (nonzero)
plain0none0.9100.9850.5380.471119,828
plain1none0.0620.1266.5796.480103,316
plain1KD0.916 ± 0.0020.986 ± 0.0020.339 ± 0.0010.268 ± 0.002103,316
plain2none0.0660.1475.1515.06586,804
plain2KD0.916 ± 0.0010.987 ± 0.0010.300 ± 0.0000.228 ± 0.00186,804
plain4none0.0530.0416.4906.39953,780
plain4KD0.917 ± 0.0010.988 ± 0.0000.280 ± 0.0010.205 ± 0.00053,780
plain6none0.0570.0414.2194.13020,756
plain6KD0.914 ± 0.0010.989 ± 0.0000.266 ± 0.0010.189 ± 0.00120,756
residual0none0.9110.9850.3940.335119,828
residual1none0.8670.9780.4970.419103,316
residual1KD0.917 ± 0.0010.988 ± 0.0000.297 ± 0.0020.231 ± 0.002103,316
residual2none0.8040.9340.6390.56086,804
residual2KD0.918 ± 0.0010.987 ± 0.0010.294 ± 0.0030.227 ± 0.00386,804
residual4none0.5320.6791.4881.40553,780
residual4KD0.917 ± 0.0010.988 ± 0.0000.274 ± 0.0010.205 ± 0.00153,780
residual6none0.2580.1142.5942.51020,756
residual6KD0.912 ± 0.0000.989 ± 0.0000.260 ± 0.0010.187 ± 0.00020,756
every-other teacher layer0.916 ± 0.0010.987 ± 0.0000.297 ± 0.0000.231 ± 0.00253,780
random0.919 ± 0.0020.989 ± 0.0000.267 ± 0.0020.193 ± 0.00153,780

Reference points

Teacher (the large model)
The full-size network trained on the labeled data; the smaller models here are measured against it. Test accuracy (20-way) 0.910, target-class AP ('bird') 0.985, test NLL 0.538, KL(Bayes || model) 0.471, parameters (nonzero) 119,828.
Bayes-optimal (the best any model can do on this problem)
Predictions from the exact class probabilities, which the lab can compute because it generated the data. Test accuracy (20-way) 0.973, target-class AP ('bird') 0.999, test NLL 0.079.

Birds in this experiment

The table's 18 smaller models hatch 8 kinds of bird. Each kind is drawn once, for one model: the smallest if the bird is healthy or bones, the one that keeps the most if it's starving.

Measured against this experiment's teacher, the plain 8x128 net: 119,828 parameters, 3834.5 kbit, accuracy 0.910. The residual rows are measured against it too, as the reference points are. Storage is 32 bits a parameter, the lab's rule for a dense fp32 net, which every model drawn here is. Species follows how many times smaller a model is. A bird stays healthy while its model keeps at least 95% of the reference's score, and turns to bones at 60% or less.

These are the lab's recorded results, so they aren't added to anyone's life list. Birds you hatch yourself, in the Coop or from a Field Guide run, are saved to your life list.