                                How to Train Your Multi-Exit Model?
                              Analyzing the Impact of Training Strategies


      Piotr Kubaty * 1 Bartosz Wójcik * † 1 Bartłomiej Krzepkowski 2 Monika Michaluk 3 Tomasz Trzcinski 2 4 5
                                       Jary Pomponi 6 Kamil Adamczewski † 7 5


                          Abstract
       Early exits enable the network’s forward pass
       to terminate early by attaching trainable inter-
       nal classifiers to the backbone network. Existing
       early-exit methods typically adopt either a joint
       training approach, where the backbone and exit
       heads are trained simultaneously, or a disjoint ap-
       proach, where the heads are trained separately.
       However, the implications of this choice are of-
       ten overlooked, with studies typically adopting
       one approach without adequate justification. This
       choice influences training dynamics and its im-
       pact remains largely unexplored. In this paper,                 Figure 1. Performance-cost trade-off of the multi-exit ViT-T model
       we introduce a set of metrics to analyze early-exit             trained on the ImageNet-1k dataset by using different training
       training dynamics and guide the choice of training              regimes. The choice of the training regime significantly impacts
       strategy. We demonstrate that conventionally used               the performance across all computational budgets.
       joint and disjoint regimes yield suboptimal perfor-
                                                                       of these networks significantly contributes to their enhanced
       mance. To address these limitations, we propose
                                                                       performance, the necessity of using large models for all
       a mixed training strategy: the backbone is trained
                                                                       inputs, especially in resource-constrained environments like
       first, followed by the training of the entire multi-
                                                                       mobile and edge computing devices, is questionable.
       exit network. Through comprehensive evaluations
       of training strategies across various architectures,            Early exit methods for deep neural networks have gained
       datasets, and early-exit methods, we present the                importance due to their potential to significantly improve
       strengths and weaknesses of the early exit training             computational efficiency. By exiting at earlier layers, these
       strategies. In particular, we show consistent im-               methods can decrease the number of operations needed for
       provements in performance and efficiency using                  computation of the forward pass, leading to faster infer-
       the proposed mixed strategy.                                    ence times. In doing so they allow the network to adapt
                                                                       its computational cost to the difficulty of the input sample.
                                                                       Simpler inputs can be processed with fewer layers, while
1. Introduction                                                        more complex inputs can utilize the full capacity of the
                                                                       network.
Deep neural networks have achieved remarkable results
across a variety of machine learning tasks. While the depth            Early exit methods are implemented through augmentation
  *                                           1
                                                                       of the original architecture with internal classifiers (ICs)
    Equal contribution . † Equal supervision. Jagiellonian Uni-
                                                                       attached to selected intermediate layers (Kaya et al., 2019).
versity 2 Warsaw University of Technology 3 University of Warsaw
4
  Tooploox 5 IDEAS Research Institute 6 Department of Informa-         These ICs are designed to perform classification tasks based
tion Engineering, Electronics, and Telecommunications (DIET)           on the representations available at their respective positions
at Sapienza, University of Rome, Italy 7 Wroclaw University of         in the network. A common approach for training early-
Science and Technology. Correspondence to: Bartosz Wójcik             exit models involves training the entire multi-exit network,
<bartwojc@gmail.com>.
                                                                       including the added classifiers, from scratch (Huang et al.,
Proceedings of the 42 nd International Conference on Machine           2018; Yang et al., 2020; Meronen et al., 2024) (”joint”
Learning, Vancouver, Canada. PMLR 267, 2025. Copyright 2025            regime). Alternatively, some methods train the backbone
by the author(s).

                                                                   1
                      How to Train Your Multi-Exit Model? Analyzing the Impact of Training Strategies

network first, then freeze its weights and train the parameters       low frequency elements. This regularity is disrupted in the
of the newly added ICs in the second, separate phase of               case of early exit architectures as the backbone network is
training (Teerapittayanon et al., 2016; Liao et al., 2021;            given additional classifiers that are placed in earlier parts
Zhou et al., 2020) (”disjoint” regime). To the best of our            of the network. These changes in architecture require a
knowledge, no study compares or explores the relationship             different approach for training and more nuanced analysis
between these training regimes.                                       how the training should proceed.
In this study, we perform an extensive assessment of early-           In the early-exit setting, parameters can be divided into
exit regimes and notice the choice of training strategy has           backbone parameters and internal classifier (IC) parameters.
a significant impact on the final model’s performance. We             Each of these two groups can be trained separately or jointly.
identify the relationship between computational budget and            In this paper, we frame the training process of any early-exit
the choice of the regime. Using the disjoint regime results           method as consisting of three following phases:
with a network that is significantly impaired when smaller
                                                                      Phase 1: Train the backbone network parameters θb by
computational budget is assumed. While the joint regime
                                                                      minimizing the loss at the final output layer (could be the
might initially seem as the appropriate way of training multi-
                                                                      last IC or an added final classifier).
exit networks, we demonstrate that due to its training dy-
namics it biases the network and produces a model with                                                  h
                                                                                                                     (K)
                                                                                                                         i
subpar performance on higher computational budgets.                           θb∗ = arg min E(xi ,yi )∼D L(K) (θb , θIC )             (1)
                                                                                           θb

In order to address the weaknesses of multi-exit networks,
we propose a novel “mixed” regime: train the backbone net-            During this phase, θIC are either not trained or not present
work until convergence, then train the entire model jointly,          at all.
including the internal classifiers, until convergence. This ap-       Phase 2: Train both the backbone network and the ICs
proach ensures that the backbone architecture is adequately           simultaneously.
trained before optimizing it alongside the internal classifiers
                                                                                           K
for improved performance.                                                                  X                    h
                                                                                                                             (k)
                                                                                                                                 i
                                                                          θ∗ = arg min           αk E(xi ,yi )∼D L(k) (θb , θIC )     (2)
To gain a deeper understanding of learning and optimization                           θ
                                                                                           k=1
in multi-exit architectures, we propose a set of metrics to           Phase 3: Freeze θb∗ and train only the IC parameters θIC .
describe the training dynamics of early-exit models trained
under various regimes. Through gradient dominance metric                                   K                    h                 i
                                                                                                                              (k)
                                                                                           X
                                                                          ∗
we reveal the set of ICs that have the largest impact on the             θIC = arg min           αk E(xi ,yi )∼D L(k) (θb∗ , θIC )    (3)
                                                                                     θIC
backbone during training and explain the performance gains                                 k=1
of popular technique of loss and gradient scaling depend              Correspondingly, we generalize the early exit training
on the training strategy choices. Furthermore, mode con-              regimes into three types based on which of the phases are
nectivity allows to analyze solution similarities of different        used:
regimes. Moreover, numerical rank, and mutual information
metrics aid to explain the performance of regimes under               Disjoint training (Phases 1+3). The model parameters
different computational budgets.                                      undergo training during the first and third phases. That is,
                                                                      the backbone architecture is trained first, and then the ICs
Finally, we provide a thorough empirical evaluation of early-         are trained separately while the backbone parameters are
exit regimes across different network architectures, data             frozen.
modalities, datasets and early-exit methods. Our results
show that proposed alternative strategy enables significant           Joint training (Phase 2). The training consists only of the
improvements in performance in medium and high budgets                second phase in which the entire model – including the ICs
over the commonly used joint training.                                – is trained. It is currently the most common way of training
                                                                      early-exit models (Matsubara et al., 2022).
2. Training Regimes                                                   Mixed training (Phases 1+2). The training consists of
                                                                      two phases. The backbone is trained in isolation first, and
Early exit methods fundamentally alter the organization of            then the entire network, including the ICs, is trained jointly.
neural networks. It is widely believed that neural networks           The regime emphasizes the importance of backbone pre-
develop a hierarchical representation of features, where ear-         training as a better way to initialize the architecture for
lier layers learn basic shapes and patterns, while later layers       further training. This is our proposed way to improve multi-
progressively capture more complex abstractions (Zeiler &             exit model training.
Fergus, 2014). In other words, the earlier layers are charac-
terized by higher frequency features while later layers learn

                                                                  2
                       How to Train Your Multi-Exit Model? Analyzing the Impact of Training Strategies

3. A Framework for Analyzing Multi-Exit
   Models                                                                            Θ(λ) = (1 − λ)ΘA + λΠ∗ ΘB                    (4)

This section proposes a framework for analysing and com-               The core idea is based on the fact that, if two models trained
paring multiple early exit models. This framework com-                 with different strategy can be interpolated such that the
prises multiple evaluations, each focusing on a different              resulting model has low loss over the whole interpolation
aspect of a model.                                                     path, then the regime solutions lie in the similar loss basin.

3.1. Gradient Dominance                                                3.3. Numerical Rank
The use of internal classifiers during training in early-exit          So far, the proposed tools analyse the gradients of the model
training regime fundamentally alters the training dynamics,            or their final predictions. Here, we propose to evaluate the
as these classifiers contribute to the overall loss. The gradi-        expressiveness of a model by analysing its intermediate
ent update now comes from multiple classifiers instead of              activations, using the numerical ranks of activation maps
just the final one, as in a standard neural network.                   (Masarczyk et al., 2024). Mathematically, for a given layer
                                                                       i, the rank is evaluated as:
To study this phenomenon we calculate which gradient is
more prominent during training. We define gradient dom-                              ri = Rank(Ai ),     Ai ∈ Rn×m                (5)
inance (GD) as the cosine similarity between the gradient
from an individual internal classifier, gi , and the overall           where Ai is the activation matrix of dimensions n (number
gradient of the model gtotal :                                         of samples) and m (number of features).
                                                                       The rank of the internal representations associated with dif-
                    GDi =< gi , gtotal >
                                                                       ferent layers can provide insight into the “expressiveness”,
                                                                       or capacity of the network. A higher rank (closer to the
where < ·, · > is the cosine similarity. Gradient Domi-
                                                                       maximum possible for a given layer’s matrix dimensions)
nance measures the consistency of the gradient directions
                                                                       indicates that the layer can capture more complex patterns
produced by the early-exit classifiers and evaluates how well
                                                                       or features in the data, as it implies a greater degree of lin-
gradients from separate classifiers align with the overall gra-
                                                                       ear independence among the feature detectors in that layer.
dient across the entire model. If the cosine similarity is close
                                                                       High-rank activations matrices in a network suggest that
to 1, the auxiliary classifier’s gradient is highly aligned with
                                                                       the network is utilizing its capacity to learn diverse, high-
the total gradient, indicating that it potentially dominates
                                                                       frequency features, whereas a low rank might indicate that
other ICs in its impact on the total gradient.
                                                                       the network is not fully exploiting its potential.
3.2. Mode Connectivity
                                                                       3.4. Mutual Information
Mode connectivity theory suggests that independently
                                                                       Adding intermediate early exits to a model could alter the
trained models often exhibit similar characteristics. No-
                                                                       information flow within the model itself. To study how
tably, after training two independent models, it is possible to
                                                                       much such exits affect this aspect, we use the concept of
find a continuous path in the parameter space where the loss
                                                                       mutual information. In the context of neural networks, the
remains low, enabling the models to be connected without
                                                                       mutual information between X and Z represents how much
encountering high-loss regions (Garipov et al., 2018).
                                                                       information the input X provides about the internal repre-
Building on the observation that independently trained neu-            sentation Z after passing through a neural network. For
ral networks can be linearly connected in weight space after           random variables X and R Z,Rthe mutual information      is de-
                                                                                                                       p(x,z)
accounting for permutation symmetries, as described in                 fined as: I(X; Z) = x∈X z∈Z p(x, z) log p(x)p(z)       dx dz
(Ainsworth et al.), we extend this idea to early-exit architec-        where p(x, z) is the joint probability distribution of X and
tures trained under different regimes.                                 Z, and p(x) and p(z) are the marginal distributions of X
Instead of focusing solely on independently trained net-               and Z, respectively. In practical terms, for neural networks,
works, we investigate early-exit architectures trained in              we use Monte Carlo sampling to estimate I(X; Z) due to
distinct regimes. To align models for mode connectivity,               the high dimensionality of feature spaces, and as such the re-
we define an optimal permutation Π∗ by solving Π∗ =                    sults are not always monotonically decreasing (Shwartz-Ziv
arg minΠ ∥ΘA − ΠΘB ∥F where ∥ · ∥F is the Frobenius                    & Tishby, 2017).
norm, and ΘA and ΘB are the parameters of two early-                   In their work, (Kawaguchi et al., 2023) utilize the concept
exit models trained under different strategies as described            of mutual information between X and Z to study the infor-
in Sec. 2. Given the optimal permutation, the permuted                 mation bottleneck (IB) principle. It aims to find a balance
interpolation path is:

                                                                   3
                        How to Train Your Multi-Exit Model? Analyzing the Impact of Training Strategies




              (a) Joint regime                              (b) Mixed regime                  (c) Avg. difference between joint and mixed

Figure 2. Gradient dominance for different regimes. Each line indicates how well gradients from different ICs align with the total gradient
over the course of the training. The last IC dominates the most in the mixed regime, which explains its excellent performance on higher
computational budgets (ResNet-50, Tinyimagenet).


between the information carried by Z in predicting the tar-             the Cosine Annealing scheduler with warm restarts. To
get Y and its complexity in terms of its mutual information             ensure fair convergence across different regimes, we incor-
with the input X. Specifically, minimizing I(X; Z) reduces              porate an early stopping mechanism. Training is terminated
the complexity and overfitting by ensuring Z retains only               only when, over n consecutive epochs, none of the exits
the essential information from X, and maximizing I(Y ; Z)               achieve an improved performance compared to their best
ensures that the representation Z is informative enough to              scores recorded thus far. These scores – accuracy for classi-
predict the target variable Y effectively. To visually show             fication tasks and loss for regression tasks – are evaluated
how mutual information is affected by the training regime,              on a dedicated early-stopping validation set. All results in
we calculate the mutual information for each layer averaged             this section are averaged over three runs, each one having a
over multiple inputs.                                                   different initial seed.
                                                                        Evaluation protocol. The core of our analysis is the frame-
4. Empirical Evaluation of Training Regimes                             work proposed to understand how adding early exits affects
                                                                        the model’s internal state and hence the predicted values.
4.1. Experimental Setup
                                                                        To this end, in Section 4.2, we use the proposed framework
In this section, we outline the setup for our empirical                 to compare all the training regimes. Additionally, following
experiments. We release the source code of our ex-                      the core idea that a model having early exits must be used
periments at: https://github.com/kamadforge/                            to spare computational power, we evaluate all the resulting
early-exit-benchmark. A more detailed description                       models under the lens of FLOPs saved and the obtained
can be found in Appendix E.                                             accuracy. These results are presented in Section 4.3.
Architectures and datasets. We conduct experiments
                                                                        4.2. Framework Evaluation
across various datasets spanning computer vision (CV)
and natural language processing (NLP). For CV, we uti-                  In this section, we evaluate the training regimes through the
lize CIFAR-100 (Krizhevsky, 2009), ImageNet-1k (Rus-                    framework proposed in Section 3.
sakovsky et al., 2015), TinyImageNet (Le & Yang, 2015),
and Imagenette (Howard, 2019). For NLP, we evaluate on                  Gradient Dominance. In Figure 2, we present the gra-
20-Newsgroups (Lang, 1995) and STS-B (Wang et al., 2019)                dient dominance results for the joint and mixed regimes,
datasets. As far as vision architectures are concerned, we              highlighting their distinct training dynamics. In the joint
evaluate ResNet (He et al., 2016) and Vision Transformers               regime, optimization focuses on subnetworks in the mid-
(ViT) (Dosovitskiy et al.). Additionally, we explore MS-                dle of the architecture, where gradients from intermediate
DNet (Huang et al., 2018), an architecture dedicated for                classifiers exert the strongest influence. Conversely, in the
multi-exit models. For NLP tasks, we utilize BERT (Devlin               mixed regime, gradients are dominated by deeper classifiers,
et al., 2019). Unless otherwise specified, the Shallow-Deep             causing the early layers to primarily support the learning
Network (SDN) (Kaya et al., 2019) early exit model is im-               objectives of later classifiers, potentially at the expense of
plemented on top of a chosen backbone.                                  earlier ones.

Training set-up. We train our models, employing the                     The dominance of the final intermediate classifier (IC) in
AdamW optimizer (Loshchilov & Hutter, 2019) alongside                   the mixed regime suggests its suitability for scenarios with


                                                                    4
                         How to Train Your Multi-Exit Model? Analyzing the Impact of Training Strategies




                                                                            Figure 4. Numerical ranks as measured in the backbone network
                                                                            of the multi-exit model which was trained with different regimes.
                                                                            The rank increases when the ICs are allowed to affect the backbone
Figure 3. Mode connectivity between models trained with different
                                                                            network.
training regimes . Colors represent the values of loss function, with
yellow representing high loss (≥ 2.0). Disjoint and mixed regimes           the layers, becoming comparable to the numerical rank of a
produce similar models, while the model trained in joint regime
                                                                            multi-exit network trained entirely from scratch. This sug-
lies in a different basin (ResNet-20, CIFAR-10).
                                                                            gests that well-functioning multi-exit models require layers
higher computational budgets, which is supported by our                     with greater expressiveness, which underpins the effective
empirical results. This behavior mirrors the training of a                  operation of all subsequent internal classifiers. Such an in-
backbone, where the model is primarily guided by the loss                   crease in expressiveness is impeded when employing the
from the final classifier. Consequently, the mixed regime                   disjoint training strategy.
tends to produce models that closely resemble standard neu-                 Mutual Information. Early-exit architectures attach in-
ral networks, a fact we confirm in the next section through                 termediate classifiers (ICs) to internal layers, altering the
mode connectivity analysis.                                                 distribution of information flow as seen in Figure 5. The
Mode Connectivity. After accounting for permutation sym-                    effect is two-fold and differs between earlier and later lay-
metries, the loss remains low during linear interpolation                   ers. Earlier layers: The mutual information between X
of the weights of models trained in the mixed and disjoint                  and Z is larger compared to a network trained without addi-
regimes, as shown in the mode connectivity plot in Figure 3.                tional classifiers. Deeper layers: The mutual information
This indicates that the resulting weights lie in the same basin,            for early-exit architecture is lower in the final layers.
and the two regimes produce similar solutions. However,                     The above effect is seen in both regimes but is more pro-
the disjoint regime is more constrained because it trains only              nounced in the joint regime. The information flow in the
the internal classifiers during the second phase. In contrast,              joint regime is more skewed and different from backbone-
the mixed regime updates the backbone to accommodate                        only training. Backbone training in the mixed regime makes
the added ICs, resulting in lower overall loss.                             the information flow fall between backbone-only and joint
Joint training, on the other hand, leads to a model in a differ-            training. This is due to the fact that the representation of
ent basin of the loss landscape. This suggests that training                easy samples is not complex (that is, it is processed with
the entire model at once, without ”pre-trained” backbones,                  just a few layers before exiting through an early IC). As
produces solutions that differ significantly in structure and
performance.
Numerical Rank. In our framework, we analyze the nu-
merical rank of the backbone model under different early-
exit regimes. A regular neural network typically exhibits
a higher rank in earlier layers and a lower rank in deeper
layers, as illustrated in Figure 4. Note that training only
the backbone corresponds to the model obtained in the dis-
joint regime, as this training strategy does not modify the
backbone.
We observe a distinct change in network expressiveness                      Figure 5. Mutual information I(X; Z) between the input X and
once intermediate classifiers are attached and permitted to                 the internal representation Z of the backbone at different depths
influence the backbone. The numerical rank rises across                     for the three multi-exit model training regimes.


                                                                        5
                       How to Train Your Multi-Exit Model? Analyzing the Impact of Training Strategies


Table 1. Testset accuracy of multi-exit models trained with dif-       Table 2. Testset accuracy (classification) and MSE (regression) of
ferent regimes on the CV datasets. Each column represents the          multi-exit BERT-B models trained using different regimes on the
maximum averaged computational budget assumed for the model,           NLP datasets. The results align with those observed for classifica-
indicated as a percentage of the computational cost of the back-       tion tasks.
bone. The mixed regime achieves significant improvements over             Dataset     Regime       25%       50%       75%      100%
the commonly used joint and disjoint regimes.
                                                                                      Disjoint    68.53     83.75     85.75     85.69
   Setting      Regime       25%      50%      75%      100%             Newsgr.
                                                                                       Joint      84.24     84.41     84.41     84.41
                                                                         (class.)
                Disjoint    52.57    67.56     73.49    73.79                         Mixed       84.99     85.25     85.25     85.25
 ResNet-34
                 Joint      62.84    72.80     74.32    74.17
  C-100                                                                               Disjoint     2.37      1.55      0.54      0.51
                Mixed       62.24    73.81     75.92    75.88             STS-B
                                                                                       Joint       1.70      0.61      0.53      0.52
                                                                          (regr.)
                Disjoint    56.74    63.96     68.59    70.36                         Mixed        2.43      0.59      0.53      0.51
  MSDNet
                 Joint      65.93    72.02     74.73    75.86
   C-100
                Mixed       65.94    72.01     75.46    76.51          ure 1, demonstrate a similar trend, but also highlighting
                Disjoint    28.33    47.32     61.50    63.99          that the joint regime experiences a performance gap at
    ViT-T                                                              higher computational budgets. The mixed regime per-
                 Joint      40.87    60.48     66.22    66.49
    C-100                                                              forms consistently well across all scenarios. Due to space
                Mixed       41.65    64.07     70.09    70.25
                                                                       constraints in the main paper we present the result averaged
                Disjoint    38.49    49.25     60.50    65.71
 ResNet-50                                                             over three runs, but in Appendix C we present these results
                 Joint      52.98    62.16     65.14    65.01
  Tiny-IN                                                              with standard deviations. In Appendix A we also examine
                Mixed       52.89    63.28     67.20    67.24
                                                                       four alternative training regimes.
                Disjoint    10.22    35.15     61.23    71.61
    ViT-T
                 Joint      36.39    61.89     68.08    68.39          Generalization to Natural Language Processing & Re-
    IN-1k
                Mixed       35.91    62.96     70.79    71.20          gression Tasks. To explore the generalizability of these
                Disjoint    10.23    33.91     68.02    78.38          results, we first conduct similar experiments on natural lan-
    ViT-S                                                              guage processing data and on a regression task, with the
                 Joint      50.10    73.99     76.38    76.44
    IN-1k                                                              results presented in Table 2. These results are consistent
                Mixed       49.50    75.17     78.28    78.33
                                                                       with those observed before, further highlighting the weak-
the sample is easy, it is clearly and distinctly located within        nesses of both the joint and disjoint regimes.
the boundaries of a single class. To describe it in terms of
mutual information, the network does not need to reduce the            Generalization to Other Early-Exit Methods. To show
complexity of X to fit the internal representation Z, as X             that our conclusions extend to other early-exit approaches,
has little irrelevant details. Consequently, the input X is not        we conduct three additional experiments for different early-
compressed and the internal representation Z has similar               exit methods: GPF (Liao et al., 2021), PBEE (Zhou et al.,
complexity to the representation of X, hence I(X; Z) is                2020), and one that uses entropy instead of max-softmax
higher.                                                                probability as a proxy for confidence (Teerapittayanon et al.,
                                                                       2016). The findings from these experiments are consistent
Following this observation, we note that with higher
                                                                       with our main results, again showing the effectiveness of
I(X; Z) in earlier layers, the joint strategy is more suit-
                                                                       the mixed regime.
able for easy datasets where more samples exit at earlier
layers. Similarly, the mixed regime learns more uniform
representation of the I(X; Z) across the network (one may              Generalization to the Pre-trained Setup. Nowadays,
observe an analogy to the numerical rank results in Sec-               most applications begin with a model pre-trained on a
tion 3.3) and may be preferred for more difficult datasets             large dataset, which is then fine-tuned for a specific tar-
that exit at later internal classifiers.                               get task. We emphasize that during the fine-tuning step,
                                                                       any of the multi-exit training regimes can be applied. To
4.3. Performance-Cost Evaluation                                       assess whether our findings extend to this scenario, we use
                                                                       the weights of a pre-trained ViT-B model from the torchvi-
Table 1 presents the performance of the training regimes               sion library and fine-tune it on CIFAR-100 using the three
on various dataset and architectures. The disjoint regime              training regimes. The results, presented in Table 4, demon-
shows weaker performance under lower computational                     strate patterns similar to those observed in the from-scratch
budgets, as freezing the backbone limits the ability to learn          training setup. Specifically: (1) the disjoint regime contin-
effective early-layer representations for classification. The          ues to show significantly lower performance under lower
results for ImageNet-1k, which are also reported in Fig-               computational budgets, and (2) the joint regime still exhibits

                                                                   6
                         How to Train Your Multi-Exit Model? Analyzing the Impact of Training Strategies


Table 3. CIFAR-100 testset accuracy of multi-exit models trained             Table 5. Accuracy improvement on the Tinyimagenet dataset when
with different regimes on the following early-exit methods: GPF              using various IC loss and gradient scaling methods. While gradient
(Liao et al., 2021), PBEE (Zhou et al., 2020), and entropy-based             equilibrium enhances performance in the joint regime, it does not
exit criterion (Teerapittayanon et al., 2016). The results are consis-       benefit the mixed regime, highlighting the effectiveness of the
tent with the main experiments.                                              mixed regime for training multi-exit models.
 EE Method          Regime      25%        50%       75%      100%            Regime      Scaling      25%        50%       75%       100%
                    Disjoint    19.28     44.11     57.85     63.91            Joint        Inc.      −1.7       +0.4      +0.98      +1.06
     PBEE            Joint      28.66     56.49     64.31     66.52            Mixed        Inc.      −1.08      −0.27     +0.22      +0.25
                    Mixed       28.87     59.42     68.33     70.33
                                                                               Joint        Dec.      +0.6       −0.29     −0.08      +0.0
                    Disjoint    33.16     53.19     62.54     64.01            Mixed        Dec.      +0.69      +0.32     −0.44      −0.46
     GPF             Joint      46.21     62.23     66.84     67.19
                                                                               Joint        SDN       −3.75      −0.33     +0.89      +0.94
                    Mixed       47.21     64.51     68.92     69.10
                                                                               Mixed        SDN       −3.39      −1.1      +0.07      +0.23
                    Disjoint    27.14     46.09     60.30     63.99
                                                                               Joint         GE       +0.31      +0.4      +0.73      +0.71
   Entropy           Joint      41.16     58.60     65.69     66.49
                                                                               Mixed         GE       −1.16      −0.11     +0.02      −0.02
                    Mixed       41.54     62.20     69.63     70.25

                                                                             et al., 2019). For the joint regime, gradient scaling improves
Table 4. Test accuracy of a ViT-B model pre-trained on ImageNet-             performance at higher computational budgets. However,
1k and fine-tuned on CIFAR-100. The disjoint regime struggles                for the mixed regime, there is no additional benefit, further
at low budgets, while the joint regime shows a slight but notable            confirming that they achieve a similar effect. The mixed
performance gap at higher budgets. The mixed regime performs                 regime achieve superior results and it obviates the need
consistently well, aligning with the patterns observed in the main           for application of gradient equilibrium.
experiments.
         Regime        35%       50%       75%      100%                     4.5. Impact of IC Size
         Disjoint     28.50     55.64     87.49      89.95                   The size of an internal classifier (IC) in early exit archi-
          Joint       73.18     85.41     87.82      87.85                   tectures refers to the number of layers and neurons within
         Mixed        73.38     85.70     88.06      88.23                   the internal classifier. Smaller ICs are computationally effi-
                                                                             cient and enable faster early exits with minimal overhead.
a performance gap at higher computational budgets.                           Conversely, larger ICs offer greater capacity, potentially en-
                                                                             hancing accuracy, but may offset the computational benefits
4.4. Impact of Gradient and Loss Scaling                                     of multi-exit models.

The gradient dominance results demonstrated how the mixed                    A recent study by (Wójcik et al., 2023) investigated the
regime prioritizes deeper intermediate classifiers. A similar                impact of IC size and found that larger heads significantly
effect can also be achieved by adjusting the loss coefficients               improve performance. However, this analysis focused solely
for deeper ICs, as proposed in prior work (Kaya et al., 2019;                on the disjoint training regime. In our study, we examine the
Han et al., 2022), or by scaling the gradients of each IC, as                effect of varying IC sizes using a ViT-T model trained on the
proposed by Li et al. (Li et al., 2019). We revisit these tech-              TinyImagenet dataset. Each IC consists of either one or two
niques within both the joint and mixed regimes to evaluate                   fully connected layers with hidden dimensions of 1024 or
their impact, with the results presented in Table 5.                         2048, followed by a softmax layer. As summarized in Table
                                                                             6, under the disjoint regime larger ICs indeed yield clear
We first evaluate the loss scaling method proposed by                        gains: moving from a single-layer IC with 1024 units to a
Kaya et al.(Kaya et al., 2019) (SDN) by training multi-                      two-layer IC with 2048 units can increase top-1 accuracy
exit ResNet-50 models on the TinyImageNet dataset. We                        by up to 7.6 percentage points, and this effect is especially
also test (Han et al., 2022) constant loss weighting scheme,                 visible for lower budgets. However, in the mixed regime
which adjusts the loss coefficients by either increasing (Inc.)              this trend reverses, and the change can result in an actual
or decreasing (Dec.) them along the model’s depth. These                     performance degradation. These results demonstrate that
schemes allow the model to prioritize different computa-                     optimal IC architecture depends critically on the chosen
tional budgets. However, the improvements observed in                        training strategy, and that conclusions drawn under a disjoint
the mixed regime are notably smaller compared to those                       setup may not transfer when the backbone is also trained.
seen in the joint regime.
Finally, we evaluate the gradient equilibrium method (Li


                                                                         7
                        How to Train Your Multi-Exit Model? Analyzing the Impact of Training Strategies


Table 6. The effect of varying head size on the ViT-T model. Larger       Table 7. The effect of varying head placement schemes on the SDN
heads translate to inferior performance for the mixed regime. In          early-exit architecture with ResNet-50 as a backbone, trained on
contrast, the disjoint model clearly benefits from larger ICs when        the TinyImagenet dataset.
small budgets are considered.                                              Scheme        Regime      25%       50%      75%       100%
  Regime       IC arch.     25%       50%       75%      100%
                                                                                         Disjoint    38.92     49.25    60.10     65.76
                 1L         26.35     41.69     53.06     56.72            Every-1       Joint       52.20     62.49    65.52     65.59
  Disjoint     2L-1024      33.85     47.21     54.97     56.72                          Mixed       52.22     63.03    67.21     67.35
               2L-2048      33.96     45.98     54.74     56.72
                                                                                         Disjoint    37.34     48.03    60.34     65.65
                 1L         42.47     53.24     56.02     56.03            Every-2       Joint       51.81     62.60    65.55     65.38
    Joint      2L-1024      45.59     55.11     57.73     57.66                          Mixed       52.41     63.19    67.14     67.33
               2L-2048      43.60     53.89     56.94     57.00
                                                                                         Disjoint    −         47.91    60.95     65.77
                 1L         44.03     57.91     60.42     60.28            Every-3       Joint       −         63.33    67.22     67.21
   Mixed       2L-1024      44.92     57.11     59.32     59.22                          Mixed       −         62.52    66.72     66.71
               2L-2048      44.61     56.94     60.18     60.15
                                                                                         Disjoint    −         41.32    57.78     65.78
                                                                           Every-4       Joint       −         62.54    66.30     66.27
4.6. Impact of IC Placement Scheme                                                       Mixed       −         62.07    67.08     67.14
The scheme of placing the internal classifiers in early exit                             Disjoint    −         39.85    56.20     65.72
architectures refers to where these classifiers are inserted               Every-5       Joint       −         61.10    65.61     65.79
at different layers within the model. This can range from                                Mixed       −         61.95    67.33     67.40
being placed at every layer to being placed at strategically
                                                                                         Disjoint    38.47     50.64    62.04     65.74
selected layers. To explore the impact of the placement
                                                                           Den.-Spa.     Joint       53.14     62.23    64.76     64.93
scheme on the final performance, we train a ResNet-50
                                                                                         Mixed       53.48     63.17    66.24     66.27
model with different regimes for every placement scheme.
An IC can be placed at any block from index 0 to 14 for                                  Disjoint    37.12     47.03    59.79     65.68
this architecture; however, we do not place it at index 0, as              Spa.-Den.     Joint       50.47     61.19    65.36     65.42
this would entirely bypass the backbone. In the Every-n                                  Mixed       51.19     62.27    67.26     67.47
placement scheme, an IC is inserted at every n-th block. In
the Dense-Sparse configuration, ICs are placed at blocks:                 was the fastest and took 523 (±156, averaged over multiple
[1, 2, 3, 4, 5, 6, 7, 11], while in the Sparse-Dense scheme,              seeds) epochs on average. Joint training converged after
they are placed at blocks: [1, 4, 8, 9, 10, 11, 12, 13, 14].              1610 (±395), while mixed training required 1166 (±136)
The placement scheme plays a significant role in shaping                  epochs. These results indicate that while disjoint training
network performance across different training regimes, as                 converges most rapidly, the mixed regime offers a substan-
shown in Table 7. While densely placed ICs generally en-                  tial speed-up over joint training by alleviating the interfer-
sure strong performance across a range of computational                   ence effect between intermediate classifiers.
budgets, the model can be tailored to prioritize a particular
budget by using the Dense-Sparse or Sparse-Dense schemes.                 5. Related Work
In most cases, models trained with the mixed regime outper-
form those trained under other regimes.                                   Early exiting is a notable application of the conditional com-
                                                                          putation paradigm (Bengio et al., 2013). While conceptually
4.7. Training time                                                        similar to earlier classifier cascades (Xu et al., 2014; Wang
                                                                          et al., 2018), it differs in that all classifiers are integrated
The ultimate aim of a majority of multi-exit models is                    within a single model, enabling end-to-end training. The
achieving the Pareto frontier in model performance and                    first multi-exit model was introduced by (Teerapittayanon
computational cost of the model during inference (Scarda-                 et al., 2016), and the field has expanded considerably since
pane et al., 2020; Han et al., 2021). As such, to prevent                 its inception.
under-training, we apply an early-stopping criterion in every
experiment in this work. However, this raises an interest-                Joint training is the most widely used and well-established
ing question: how long does it take for the training in each              strategy for early-exit models (Matsubara et al., 2022). This
regime to converge?                                                       approach has been successfully applied to dynamic infer-
                                                                          ence under various constraints, such as energy or time limita-
We explore the training time of the ResNet-50 model trained               tions (Wang et al., 2020), and extended to diverse early-exit
on the TinyImagenet dataset (see Table 1). Disjoint training

                                                                      8
                       How to Train Your Multi-Exit Model? Analyzing the Impact of Training Strategies

applications, including low-resolution classification (Xing              vide a detailed analysis and evaluation of various training
et al., 2020), quality enhancement (Yang et al., 2020), and              approaches for early-exit architectures in deep neural net-
Question-Answering systems (Soldaini & Moschitti, 2020).                 works. Our findings reveal that the manner in which the
While joint training has proven effective, several studies               backbone and internal classifiers are trained has a significant
have demonstrated significant improvements through modi-                 impact on the performance and efficiency of these models.
fications of the training process. For instance, knowledge               Furthermore, we show that when using the mixed training
distillation from the final classifier to earlier internal classi-       regime, gradient scaling is unnecessary. Below we sum-
fiers has been shown to enhance their performance (Phuong                marize some practical takeaways for the selection of the
& Lampert, 2019; Li et al., 2019; Liu et al., 2020). Similarly,          training regime.
ensembling multiple intermediate classifiers can improve
                                                                         Mixed. Mixed regime demonstrates substantial robustness
the prediction accuracy (Qendro et al., 2021; Sarti et al.,
                                                                         across various factors, including different data modalities
2023). The Global Past-Future (GPF) method (Liao et al.,
                                                                         and early-exit approaches with varying exit criteria. There-
2021) goes a step further and incorporates information from
                                                                         fore, the mixed regime is generally preferred, combining
both earlier predictions and surrogate later predictions to
                                                                         the benefits of both disjoint and joint training. The mixed
improve inference. Additionally, recent works (Han et al.,
                                                                         regime ensures that the backbone network is well-optimized
2022; Yu et al., 2023; Chataoui et al., 2023) identify a train-
                                                                         before integrating internal classifiers, leading to improved
test mismatch in conventional multi-exit approaches and
                                                                         computational efficiency and accuracy. It is particularly
propose strategies that address this issue, further enhancing
                                                                         recommended for cases where the performance on medium
the robustness of early-exit models.
                                                                         and high computational budgets is the main requirement.
SDN (Kaya et al., 2019) was one of the first to explore the
                                                                         Joint. The joint regime is simple to implement and can
training of early-exit models through the pre-training of
                                                                         perform well for small computational budgets. However, it
the architecture’s backbone followed by separate training
                                                                         generally underperforms, especially for medium to higher
of the classifiers. Multiple subsequent works have focused
                                                                         budgets, which are more relevant in practical applications.
on optimizing early-exit models based only on this setup
(Wójcik et al., 2023; Lahiany & Aperstein, 2022; Liu et al.,            Disjoint. This regime is generally inferior compared to
2020), potentially limiting the general applicability of their           the others in most setups, but performs well for the highest
findings. For instance, (Wołczyk et al., 2021) employ an                 budgets. It may be preferred when the backbone is shared, or
ensembling technique that combines predictions from ear-                 the lack of resources prevents us from training the backbone
lier internal classifiers, weights of which are trained in a             network.
separate, third training phase. (Lahiany & Aperstein, 2022)
propose PTEENet, which augments pre-trained networks                     Acknowlegdements
with confidence heads that dynamically adjust based on
available resources and unlabeled data.                                  The research was funded by the program Excellence Initia-
                                                                         tive – Research University at the Jagiellonian University in
(Kaya et al., 2019) were the first to explore both joint and
                                                                         Kraków.
disjoint training approaches for early-exit models. These
approaches are also briefly reviewed in surveys such as                  This research has been supported by a grant from the Faculty
(Scardapane et al., 2020; Matsubara et al., 2022). Further-              of Mathematics and Computer Science under the Strategic
more, techniques like weighting the losses at each exit head             Programme Excellence Initiative at Jagiellonian University.
(Zhou et al., 2020; Kaya et al., 2019; Han et al., 2022) or
                                                                         This research was partially funded by National Science
scaling the individual gradients (Li et al., 2019) can be re-
                                                                         Centre, Poland, grant no 2022/45/B/ST6/02817.
garded as variations of the joint training paradigm. In the
context of LLMs, a concurrent work of Bae et al. (2024) in-              We gratefully acknowledge Polish high-performance com-
cludes an empirical comparison of joint and disjoint training            puting infrastructure PLGrid (HPC Center: ACK Cyfronet
strategies, with similar conclusions about the weaknesses of             AGH) for providing computer facilities and support
both approaches. To the best of our knowledge, our work                  within computational grants no.      PLG/2023/016270,
is the first to present a broad and systematic analysis of the           PLG/2024/017185, and PLG/2024/017385, and the LUMI
early-exit training strategies.                                          consortium through PLL/2024/07/017641.
                                                                         The contribution of Bartosz Wójcik to this research was
6. Conclusion                                                            conducted at the Faculty of Mathematics and Computer
                                                                         Science, and the Doctoral School of Exact and Natural
This study emphasizes the critical importance of training
                                                                         Sciences of the Jagiellonian University.
regimes for early-exit models, an aspect that has been largely
neglected in prior research. Addressing this gap, we pro-

                                                                     9
                     How to Train Your Multi-Exit Model? Analyzing the Impact of Training Strategies

Impact Statement                                                      and fast ensembling of dnns. In Bengio, S., Wallach,
                                                                      H. M., Larochelle, H., Grauman, K., Cesa-Bianchi, N.,
This paper presents work whose goal is to advance the field           and Garnett, R. (eds.), Advances in Neural Information
of Machine Learning. There are many potential societal                Processing Systems 31: Annual Conference on Neural
consequences of our work, none of which we feel must be               Information Processing Systems 2018, NeurIPS 2018,
specifically highlighted here.                                        December 3-8, 2018, Montréal, Canada, pp. 8803–
                                                                      8812, 2018.        URL https://proceedings.
References                                                            neurips.cc/paper/2018/hash/
                                                                      be3087e74e9100d4bc4c6268cdbe8456-Abstract.
Ainsworth, S., Hayase, J., and Srinivasa, S. Git re-basin:
                                                                      html. 3
  Merging models modulo permutation symmetries. In The
  Eleventh International Conference on Learning Repre-              Han, Y., Huang, G., Song, S., Yang, L., Wang, H., and Wang,
  sentations. 3                                                       Y. Dynamic neural networks: A survey. IEEE Transac-
                                                                      tions on Pattern Analysis and Machine Intelligence, 44
Bae, S., Fisch, A., Harutyunyan, H., Ji, Z., Kim, S., and
                                                                      (11):7436–7456, 2021. 8
  Schuster, T. Relaxed recursive transformers: Effective
  parameter sharing with layer-wise lora. ArXiv preprint,           Han, Y., Pu, Y., Lai, Z., Wang, C., Song, S., Cao, J., Huang,
  abs/2410.20672, 2024. URL https://arxiv.org/                        W., Deng, C., and Huang, G. Learning to weight samples
  abs/2410.20672. 9                                                   for dynamic early-exiting networks. In European Confer-
Bengio, Y., Léonard, N., and Courville, A. Estimat-                  ence on Computer Vision, pp. 362–378. Springer, 2022.
  ing or propagating gradients through stochastic neu-                7, 9
  rons for conditional computation. ArXiv preprint,                 He, K., Zhang, X., Ren, S., and Sun, J. Deep resid-
  abs/1308.3432, 2013. URL https://arxiv.org/                         ual learning for image recognition. In 2016 IEEE
  abs/1308.3432. 8                                                    Conference on Computer Vision and Pattern Recogni-
Chataoui, J., Coates, M., et al. Jointly-learned exit and             tion, CVPR 2016, Las Vegas, NV, USA, June 27-30,
  inference for a dynamic neural network. In The Twelfth              2016, pp. 770–778. IEEE Computer Society, 2016. doi:
  International Conference on Learning Representations,              10.1109/CVPR.2016.90. URL https://doi.org/
  2023. 9                                                             10.1109/CVPR.2016.90. 4

Devlin, J., Chang, M.-W., Lee, K., and Toutanova, K. BERT:          Howard, J. Imagenette: A smaller subset of 10 easily
  Pre-training of deep bidirectional transformers for lan-            classified classes from imagenet, 2019. URL https:
  guage understanding. In Proceedings of the 2019 Confer-            //github.com/fastai/imagenette. Accessed:
  ence of the North American Chapter of the Association for           2025-01-28. 4
  Computational Linguistics: Human Language Technolo-
                                                                    Huang, G., Chen, D., Li, T., Wu, F., van der Maaten,
  gies, Volume 1 (Long and Short Papers), pp. 4171–4186,
                                                                      L., and Weinberger, K. Q. Multi-scale dense networks
  Minneapolis, Minnesota, 2019. Association for Compu-
                                                                      for resource efficient image classification. In 6th In-
  tational Linguistics. doi: 10.18653/v1/N19-1423. URL
                                                                      ternational Conference on Learning Representations,
  https://aclanthology.org/N19-1423. 4
                                                                     ICLR 2018, Vancouver, BC, Canada, April 30 - May
Dosovitskiy, A., Beyer, L., Kolesnikov, A., Weissenborn,             3, 2018, Conference Track Proceedings. OpenReview.net,
  D., Zhai, X., Unterthiner, T., Dehghani, M., Minderer, M.,          2018. URL https://openreview.net/forum?
  Heigold, G., Gelly, S., et al. An image is worth 16x16              id=Hk2aImxAb. 1, 4
 words: Transformers for image recognition at scale. In
 International Conference on Learning Representations. 4            Kawaguchi, K., Deng, Z., Ji, X., and Huang, J. How does
                                                                      information bottleneck help deep learning? In Inter-
Elhoushi, M., Shrivastava, A., Liskovich, D., Hosmer, B.,             national Conference on Machine Learning, pp. 16049–
  Wasti, B., Lai, L., Mahmoud, A., Acun, B., Agarwal, S.,            16096. PMLR, 2023. 3
  Roman, A., et al. Layerskip: Enabling early exit inference
  and self-speculative decoding. In Proceedings of the 62nd         Kaya, Y., Hong, S., and Dumitras, T. Shallow-deep net-
  Annual Meeting of the Association for Computational                 works: Understanding and mitigating network overthink-
  Linguistics (Volume 1: Long Papers), pp. 12622–12642,               ing. In Chaudhuri, K. and Salakhutdinov, R. (eds.),
  2024. 13                                                            Proceedings of the 36th International Conference on
                                                                     Machine Learning, ICML 2019, 9-15 June 2019, Long
Garipov, T., Izmailov, P., Podoprikhin, D., Vetrov, D. P.,            Beach, California, USA, volume 97 of Proceedings of
  and Wilson, A. G. Loss surfaces, mode connectivity,                Machine Learning Research, pp. 3301–3310. PMLR,

                                                               10
                     How to Train Your Multi-Exit Model? Analyzing the Impact of Training Strategies

  2019. URL http://proceedings.mlr.press/                         Loshchilov, I. and Hutter, F. Decoupled weight decay regu-
  v97/kaya19a.html. 1, 4, 7, 9, 17                                  larization. In 7th International Conference on Learning
                                                                    Representations, ICLR 2019, New Orleans, LA, USA,
Krizhevsky, A. Learning multiple layers of features from            May 6-9, 2019. OpenReview.net, 2019. URL https://
  tiny images. Technical report, 2009. 4                            openreview.net/forum?id=Bkg6RiCqY7. 4
Lahiany, A. and Aperstein, Y. Pteenet: Post-trained early-        maintainers, T. and contributors. Torchvision: Pytorch’s
  exit neural networks augmentation for inference cost op-         computer vision library. https://github.com/
  timization. IEEE Access, 10:69680–69687, 2022. 9                 pytorch/vision, 2016. 20
Lang, K. 20 newsgroups dataset, 1995. URL http://                 Masarczyk, W., Ostaszewski, M., Imani, E., Pascanu, R.,
  qwone.com/˜jason/20Newsgroups/. Accessed:                        Miłoś, P., and Trzcinski, T. The tunnel effect: Building
  2025-01-28. 4                                                    data representations in deep neural networks. Advances
Le, Y. and Yang, X. S. Tiny imagenet visual recog-                 in Neural Information Processing Systems, 36, 2024. 3
  nition challenge.  2015.  URL https://api.                      Matsubara, Y., Levorato, M., and Restuccia, F. Split com-
  semanticscholar.org/CorpusID:16664790.                           puting and early exiting for deep learning applications:
  4                                                                Survey and research challenges. ACM Computing Sur-
                                                                   veys, 55(5):1–30, 2022. 2, 8, 9
Li, H., Xu, Z., Taylor, G., Studer, C., and Goldstein,
  T. Visualizing the loss landscape of neural nets. In        Meronen, L., Trapp, M., Pilzer, A., Yang, L., and Solin,
   Bengio, S., Wallach, H. M., Larochelle, H., Grauman,         A. Fixing overconfidence in dynamic neural networks.
   K., Cesa-Bianchi, N., and Garnett, R. (eds.), Advances in    In Proceedings of the IEEE/CVF Winter Conference on
  Neural Information Processing Systems 31: Annual Con-         Applications of Computer Vision, pp. 2680–2690, 2024.
   ference on Neural Information Processing Systems 2018,       1
  NeurIPS 2018, December 3-8, 2018, Montréal, Canada,
   pp. 6391–6401, 2018. URL https://proceedings. Phuong, M. and Lampert, C. Distillation-based training
   neurips.cc/paper/2018/hash/                                  for multi-exit architectures. In 2019 IEEE/CVF Inter-
   a41b3bb3e6b050b6c9067c67f663b915-Abstract. national Conference on Computer Vision, ICCV 2019,
   html. 13                                                     Seoul, Korea (South), October 27 - November 2, 2019, pp.
                                                                1355–1364. IEEE, 2019. doi: 10.1109/ICCV.2019.00144.
Li, H., Zhang, H., Qi, X., Yang, R., and Huang, G. Improved     URL https://doi.org/10.1109/ICCV.2019.
   techniques for training adaptive deep networks. In 2019      00144. 9
  IEEE/CVF International Conference on Computer Vision,
  ICCV 2019, Seoul, Korea (South), October 27 - November      Qendro, L., Campbell, A., Lio, P., and Mascolo, C. Early
  2, 2019, pp. 1891–1900. IEEE, 2019. doi: 10.1109/ICCV.        exit ensembles for uncertainty quantification. In Machine
   2019.00198. URL https://doi.org/10.1109/                     Learning for Health, pp. 181–195. PMLR, 2021. 9
   ICCV.2019.00198. 7, 9
                                                              Rahmath P, H., Srivastava, V., Chaurasia, K., Pacheco, R. G.,
Liao, K., Zhang, Y., Ren, X., Su, Q., Sun, X., and              and Couto, R. S. Early-exit deep neural network-a com-
   He, B. A global past-future early exit method for            prehensive survey. ACM Computing Surveys, 57(3):1–37,
   accelerating inference of pre-trained language mod-          2024. 13
   els. In Proceedings of the 2021 Conference of the          Russakovsky, O., Deng, J., Su, H., Krause, J., Satheesh, S.,
  North American Chapter of the Association for Com-            Ma, S., Huang, Z., Karpathy, A., Khosla, A., Bernstein,
   putational Linguistics: Human Language Technologies,         M., Berg, A. C., and Fei-Fei, L. ImageNet Large Scale
   pp. 2013–2023, Online, 2021. Association for Compu-          Visual Recognition Challenge. International Journal of
   tational Linguistics. doi: 10.18653/v1/2021.naacl-main.      Computer Vision (IJCV), 115(3):211–252, 2015. doi:
  162. URL https://aclanthology.org/2021.                       10.1007/s11263-015-0816-y. 4
   naacl-main.162. 2, 6, 7, 9
                                                              Sarti, S., Lomurno, E., and Matteucci, M. Anticipate, ensem-
Liu, W., Zhou, P., Wang, Z., Zhao, Z., Deng, H., and Ju, Q.     ble and prune: Improving convolutional neural networks
   FastBERT: a self-distilling BERT with adaptive inference     via aggregated early exits. Procedia Computer Science,
   time. In Proceedings of the 58th Annual Meeting of the As-   222:519–528, 2023. 9
   sociation for Computational Linguistics, pp. 6035–6044,
   Online, 2020. Association for Computational Linguistics.   Scardapane, S., Scarpiniti, M., Baccarelli, E., and Uncini,
   doi: 10.18653/v1/2020.acl-main.537. URL https://             A. Why should we add early exits to neural networks?
   aclanthology.org/2020.acl-main.537. 9                        Cognitive Computation, 12(5):954–966, 2020. 8, 9, 13

                                                             11
                     How to Train Your Multi-Exit Model? Analyzing the Impact of Training Strategies

Shwartz-Ziv, R. and Tishby, N. Opening the black box of               Linguistics: Main Volume, pp. 91–104, Online, 2021. As-
  deep neural networks via information. arXiv preprint                sociation for Computational Linguistics. URL https:
  arXiv:1703.00810, 2017. 3                                           //aclanthology.org/2021.eacl-main.8. 13

Soldaini, L. and Moschitti, A. The cascade transformer:             Xing, Q., Xu, M., Li, T., and Guan, Z. Early exit or not:
  an application for efficient answer sentence selection.             Resource-efficient blind quality enhancement for com-
  In Proceedings of the 58th Annual Meeting of the Asso-              pressed images. In European Conference on Computer
  ciation for Computational Linguistics, pp. 5697–5708,               Vision, pp. 275–292. Springer, 2020. 9
  Online, 2020. Association for Computational Linguistics.
  doi: 10.18653/v1/2020.acl-main.504. URL https://                  Xu, Z., Kusner, M. J., Weinberger, K. Q., Chen, M., and
  aclanthology.org/2020.acl-main.504. 9                               Chapelle, O. Classifier cascades and trees for minimizing
                                                                      feature evaluation cost. The Journal of Machine Learning
Teerapittayanon, S., McDanel, B., and Kung, H.-T.                    Research, 15(1):2113–2144, 2014. 8
  Branchynet: Fast inference via early exiting from deep
  neural networks. In Proceedings of the International Con-         Yang, L., Han, Y., Chen, X., Song, S., Dai, J., and Huang,
  ference on Pattern Recognition, ICPR, pp. 2464–2469,                G. Resolution adaptive networks for efficient inference.
  2016. 2, 6, 7, 8                                                    In 2020 IEEE/CVF Conference on Computer Vision and
                                                                      Pattern Recognition, CVPR 2020, Seattle, WA, USA, June
Wang, A., Singh, A., Michael, J., Hill, F., Levy, O., and             13-19, 2020, pp. 2366–2375. IEEE, 2020. doi: 10.1109/
 Bowman, S. R. GLUE: A multi-task benchmark and                       CVPR42600.2020.00244. URL https://doi.org/
 analysis platform for natural language understanding. In             10.1109/CVPR42600.2020.00244. 1, 9
 7th International Conference on Learning Representa-
 tions, ICLR 2019, New Orleans, LA, USA, May 6-9, 2019.             Yu, H., Li, H., Hua, G., Huang, G., and Shi, H. Boosted dy-
 OpenReview.net, 2019. URL https://openreview.                        namic neural networks. In Proceedings of the AAAI Con-
 net/forum?id=rJ4km2R5t7. 4                                           ference on Artificial Intelligence, volume 37, pp. 10989–
                                                                      10997, 2023. 9
Wang, X., Luo, Y., Crankshaw, D., Tumanov, A., Yu, F.,
 and Gonzalez, J. E. IDK cascades: Fast deep learning by            Yun, S., Han, D., Chun, S., Oh, S. J., Yoo, Y., and Choe,
 learning not to overthink. In Globerson, A. and Silva, R.            J. Cutmix: Regularization strategy to train strong clas-
 (eds.), Proceedings of the Thirty-Fourth Conference on               sifiers with localizable features. In 2019 IEEE/CVF In-
 Uncertainty in Artificial Intelligence, UAI 2018, Monterey,          ternational Conference on Computer Vision, ICCV 2019,
 California, USA, August 6-10, 2018, pp. 580–590. AUAI                Seoul, Korea (South), October 27 - November 2, 2019, pp.
 Press, 2018. URL http://auai.org/uai2018/                            6022–6031. IEEE, 2019. doi: 10.1109/ICCV.2019.00612.
 proceedings/papers/212.pdf. 8                                        URL https://doi.org/10.1109/ICCV.2019.
                                                                      00612. 19
Wang, Y., Shen, J., Hu, T.-K., Xu, P., Nguyen, T., Bara-
 niuk, R., Wang, Z., and Lin, Y. Dual dynamic inference:            Zeiler, M. D. and Fergus, R. Visualizing and understand-
 Enabling more efficient, adaptive, and controllable deep             ing convolutional networks. In Computer Vision–ECCV
 inference. IEEE Journal of Selected Topics in Signal                 2014: 13th European Conference, Zurich, Switzerland,
 Processing, 14(4):623–633, 2020. 8                                   September 6-12, 2014, Proceedings, Part I 13, pp. 818–
                                                                      833. Springer, 2014. 2
Wójcik, B., Przewieźlikowski, M., Szatkowski, F., Wołczyk,
 M., Bałazy, K., Krzepkowski, B., Podolak, I., Tabor, J.,           Zhang, H., Cissé, M., Dauphin, Y. N., and Lopez-Paz, D.
 Śmieja, M., and Trzciński, T. Zero time waste in pre-              mixup: Beyond empirical risk minimization. In 6th
 trained early exit neural networks. Neural Networks, 168:            International Conference on Learning Representations,
 580–601, 2023. 7, 9                                                  ICLR 2018, Vancouver, BC, Canada, April 30 - May 3,
                                                                      2018, Conference Track Proceedings. OpenReview.net,
Wołczyk, M., Wójcik, B., Bałazy, K., Podolak, I. T., Ta-             2018. URL https://openreview.net/forum?
 bor, J., Śmieja, M., and Trzcinski, T. Zero time waste:             id=r1Ddp1-Rb. 19
 Recycling predictions in early exit neural networks. Ad-
 vances in Neural Information Processing Systems, 34:               Zhou, W., Xu, C., Ge, T., McAuley, J., Xu, K., and Wei,
 2516–2528, 2021. 9                                                   F. Bert loses patience: Fast and robust inference with
                                                                      early exit. Advances in Neural Information Processing
Xin, J., Tang, R., Yu, Y., and Lin, J. BERxiT: Early ex-              Systems, 33:18330–18341, 2020. 2, 6, 7, 9
  iting for BERT with better fine-tuning and extension to
  regression. In Proceedings of the 16th Conference of the
  European Chapter of the Association for Computational

                                                               12
                      How to Train Your Multi-Exit Model? Analyzing the Impact of Training Strategies

A. Alternative Regimes
In addition to the training regimes discussed in the main paper, early-exit surveys describe alternative training strategies
(Scardapane et al., 2020; Rahmath P et al., 2024). Moreover, (Xin et al., 2021) have proposed the ”Alternating” approach,
which also attempts to combine the advantages of joint and disjoint regimes. Additionally, we propose a refinement of the
mixed regime, termed the mixed-gradual training regime.
We describe these alternative regimes below:


   • Branch-wise training. In this regime, ICs are trained sequentially, with only the part of the backbone corresponding to
     the current IC being unfrozen.

   • Separate training. Similar to branch-wise training, ICs are optimized sequentially. However, at each step, the
     preceding ICs are jointly trained along with the current one. The entire model is unfrozen during the training process.

   • Alternating training. Proposed in (Xin et al., 2021), this regime alternates between training the backbone independently
     (Equation (1)) and jointly training the backbone with all ICs (Equation (2)) in each training step.

   • Mixed-gradual training. Building on the strengths of the mixed regime, we propose a more gradual optimization
     approach. Training proceeds in m phases, where m is the number of ICs. In the i-th phase, the last i ICs are jointly
     optimized, and no weights are frozen at any stage. This ensures flexibility throughout the training process while
     allowing the model to adapt more effectively to the optimization landscape. This approach is similar to gradual early
     exit curriculum proposed by the concurrent work of Elhoushi et al. (2024), with the difference being that we utilize
     early-stopping, while they enable the next IC at constant intervals of training steps.


In Appendix C, we present the results for these alternative training regimes. Both the branch-wise and separate training
approaches demonstrate subpar performance when evaluated under higher computational budgets. Although the alternating
training regime resembles the mixed regime in its motivation, its performance consistently falls short of both the mixed and
joint regimes. Interestingly, the mixed-gradual regime outperforms the mixed regime, providing strong evidence in favor of
our approach to enhancing early-exit optimization.

B. Loss Landscape
The concept of a loss landscape in the context of neural networks is crucial for understanding the training dynamics and
generalization properties of models. The loss landscape provides a visual and analytical representation of how the loss
function changes with respect to the model’s parameters. By visualizing the loss landscapes of different neural network
architectures, we can understand how design choices affect the shape of the loss function.
For a trained model with parameters θ∗ , one can evaluate the loss function for the numbers x, y

                                                  f (x, y) = L(θ∗ + xδ + yη)                                                   (6)
such that δ, η are random directions sampled from a probability distribution, usually a Gaussian distribution, filter-normalized
(Li et al., 2018), obtaining a 3D plot. In contrast to a typical neural network architecture, in early-exit set-up, both the final
and internal classifiers are considered. We consider total training loss and separate losses for each IC.
When evaluating head losses, we use common random directions(δ, η) for each IC. The δ, η directions contain both backbone
and head parameters.
As shown in Figure 6 there is a significant difference in loss landscapes between the Disjoint regime and the Joint one. The
Joint and Mixed regimes are similar in this regard.

C. Full Results
Due to space constraints in the main paper we have presented only the averaged results. In this section, we present the main
results with the standard deviation reported for each experiment. Furthermore, we include the results for additional training
regimes, which are described in Appendix A.

                                                               13
                      How to Train Your Multi-Exit Model? Analyzing the Impact of Training Strategies




Figure 6. Training loss landscapes: comparison for Joint, Mixed, and Disjoint regimes (left to right), head 1. Landscapes for SDN
architecture with Resnet20 as backbone trained on the CIFAR-10 dataset.


                                                 Table 8. ResNet-34 CIFAR-100
                  Regime              25%             50%              75%             100%          Unlimited
                Disjoint         52.57 ±0.07      67.56 ±0.22       73.49 ±0.93    73.79 ±1.00      73.79 ±1.00
                  Joint          62.84 ±0.67      72.80 ±0.34       74.32 ±0.08    74.17 ±0.10      74.19 ±0.09
                 Mixed           62.24 ±0.78      73.81 ±0.51       75.92 ±0.44    75.88 ±0.40      75.88 ±0.40
              Branch-wise        64.19 ±0.47      67.03 ±0.76       66.88 ±0.60    66.75 ±0.68      66.75 ±0.68
                Separate         66.25 ±0.54      72.57 ±0.38       72.87 ±0.41    72.82 ±0.46      72.82 ±0.46
               Alternating       60.35 ±1.15      71.99 ±0.45       74.57 ±0.17    74.37 ±0.02      74.36 ±0.09
              Mixed-gradual      60.11 ±0.68      73.16 ±0.70       76.08 ±0.54    75.94 ±0.75      75.94 ±0.75




                                                  Table 9. MSDNet CIFAR-100
                  Regime              25%             50%              75%             100%          Unlimited
                Disjoint         56.74 ±0.41      63.96 ±0.74       68.59 ±0.72    70.36 ±0.84      70.54 ±0.93
                  Joint          65.93 ±0.20      72.02 ±0.27       74.73 ±0.18    75.86 ±0.26      75.93 ±0.21
                 Mixed           65.94 ±0.55      72.01 ±0.47       75.46 ±0.15    76.51 ±0.08      76.71 ±0.17
              Branch-wise        58.24 ±0.45      59.73 ±0.41       60.16 ±0.47    59.97 ±0.38      59.73 ±0.29
                Separate         64.90 ±0.56      67.84 ±0.17       69.02 ±0.25    69.21 ±0.23      69.15 ±0.23
               Alternating       64.69 ±0.45      71.67 ±0.27       74.93 ±0.16    76.06 ±0.25      76.34 ±0.31
              Mixed-gradual      64.73 ±0.66      72.10 ±0.47       75.66 ±0.51    77.21 ±0.61      77.49 ±0.64




                                                   Table 10. ViT-T CIFAR-100
                  Regime              25%             50%              75%             100%          Unlimited
                Disjoint         28.33 ±0.47      47.32 ±0.81       61.50 ±1.82    63.99 ±1.68      63.99 ±1.68
                  Joint          40.87 ±0.84      60.48 ±0.94       66.22 ±1.07    66.49 ±1.08      66.49 ±1.08
                 Mixed           41.65 ±0.19      64.07 ±0.38       70.09 ±0.64    70.25 ±0.56      70.25 ±0.56
              Branch-wise        32.41 ±1.32      33.46 ±0.76       34.33 ±0.49    34.51 ±0.45      34.51 ±0.45
                Separate         42.67 ±0.89      51.48 ±3.58       54.29 ±4.68    54.42 ±4.83      54.42 ±4.83
               Alternating       37.85 ±0.40      59.11 ±0.20       67.81 ±0.69    68.39 ±0.78      68.39 ±0.78
              Mixed-gradual      40.61 ±0.08      64.83 ±0.46       71.42 ±0.34    71.60 ±0.38      71.60 ±0.38


                                                               14
      How to Train Your Multi-Exit Model? Analyzing the Impact of Training Strategies


                              Table 11. ResNet-50 Tinyimagenet
   Regime         35%            50%              75%            100%          Unlimited
  Disjoint    38.49 ±0.46     49.25 ±1.33    60.50 ±1.27       65.71 ±0.90    65.80 ±0.90
   Joint      52.98 ±0.77     62.16 ±0.61    65.14 ±0.57       65.01 ±0.75    65.00 ±0.75
  Mixed       52.89 ±0.23     63.28 ±0.59    67.20 ±0.65       67.24 ±0.71    67.22 ±0.71




                                Table 12. ViT-T ImageNet-1k
   Regime         25%            50%              75%            100%          Unlimited
  Disjoint    10.22 ±0.15     35.15 ±0.97    61.23 ±1.37       71.61 ±0.68    71.61 ±0.68
   Joint      36.39 ±0.12     61.89 ±0.71    68.08 ±0.84       68.39 ±0.87    68.39 ±0.87
  Mixed       35.91 ±0.19     62.96 ±0.12    70.79 ±0.36       71.20 ±0.34    71.20 ±0.34




                              Table 13. BERT-B 20-Newsgroups
   Regime           25%             50%              75%            100%          Unlimited
  Disjoint      68.53 ±0.97     83.75 ±0.34       85.75 ±0.16    85.69 ±0.28    85.54 ±0.34
    Joint       84.24 ±0.48     84.41 ±0.41       84.41 ±0.41    84.41 ±0.41    84.51 ±0.60
   Mixed        84.99 ±0.84     85.25 ±0.64       85.25 ±0.64    85.25 ±0.64    85.46 ±0.44
Branch-wise     80.20 ±0.19     80.05 ±0.12       80.05 ±0.12    80.05 ±0.12    79.83 ±0.06
  Separate      79.87 ±0.36     79.87 ±0.36       79.87 ±0.36    79.87 ±0.36    79.78 ±0.30
 Alternating    83.51 ±0.33     83.92 ±0.06       83.92 ±0.06    83.92 ±0.06    84.18 ±0.34
Mixed-gradual   81.35 ±1.24     81.35 ±1.24       81.35 ±1.24    81.35 ±1.24    81.24 ±0.93




                                  Table 14. BERT-B STS-B
     Regime             25%            50%           75%           100%        Unlimited
    Disjoint       2.37 ±0.01     1.55 ±0.11      0.54 ±0.00     0.51 ±0.02    0.51 ±0.02
      Joint        1.70 ±0.23     0.61 ±0.02      0.53 ±0.01     0.52 ±0.02    0.52 ±0.01
     Mixed         2.43 ±0.03     0.59 ±0.01      0.53 ±0.01     0.51 ±0.00    0.51 ±0.00
  Branch-wise      2.14 ±0.24     0.82 ±0.09      0.84 ±0.10     0.83 ±0.10    0.84 ±0.10
    Separate       2.69 ±0.14     1.41 ±0.09      1.41 ±0.09     1.40 ±0.08    1.39 ±0.0
   Alternating     1.76 ±0.33     0.60 ±0.00      0.51 ±0.01     0.50 ±0.01    0.50 ±0.01
  Mixed-gradual    2.37 ±0.03     0.51 ±0.00      0.48 ±0.00     0.46 ±0.01    0.46 ±0.01




                              Table 15. ViT-T PBEE CIFAR-100
   Regime         25%            50%              75%            100%          Unlimited
  Disjoint    19.28 ±0.32     44.11 ±1.73    57.85 ±1.61       63.91 ±1.68    63.99 ±1.68
   Joint      28.66 ±0.50     56.49 ±1.48    64.31 ±0.87       66.52 ±1.08    66.49 ±1.08
  Mixed       28.87 ±0.44     59.42 ±0.50    68.33 ±0.60       70.33 ±0.68    70.25 ±0.56


                                             15
       How to Train Your Multi-Exit Model? Analyzing the Impact of Training Strategies


                                   Table 16. ViT-T GPF CIFAR-100
    Regime          25%              50%              75%            100%            Unlimited
    Disjoint    33.16 ±0.64      53.19 ±0.66     62.54 ±1.59      64.01 ±1.67       63.99 ±1.68
     Joint      46.21 ±0.30      62.23 ±0.81     66.84 ±0.68      67.19 ±0.78       67.19 ±0.80
    Mixed       47.21 ±1.02      64.51 ±0.84     68.92 ±0.30      69.10 ±0.38       69.10 ±0.38



                                 Table 17. ViT-T Entropy CIFAR-100
    Regime          25%              50%              75%            100%            Unlimited
    Disjoint    27.14 ±0.36      46.09 ±0.59     60.30 ±1.41      63.99 ±1.68       63.99 ±1.68
     Joint      41.16 ±0.82      58.60 ±0.89     65.69 ±1.23      66.49 ±1.08       66.49 ±1.08
    Mixed       41.54 ±0.52      62.20 ±0.35     69.63 ±0.47      70.25 ±0.56       70.25 ±0.56



                      Table 18. ViT-B pretrained on ImageNet-1k to CIFAR-100
    Regime          35%              50%              75%            100%            Unlimited
    Disjoint    28.50 ±2.02      55.64 ±3.71     87.49 ±0.40      89.95 ±0.18       89.95 ±0.18
     Joint      73.18 ±1.36      85.41 ±0.23     87.82 ±0.22      87.85 ±0.29       87.84 ±0.29
    Mixed       73.38 ±0.35      85.70 ±0.63     88.06 ±0.31      88.23 ±0.29       88.23 ±0.29



                Table 19. ResNet-50 Tinyimagenet loss and gradient scaling experiment
    Regime            25%              50%             75%             100%             Unlimited
     Joint         52.98 ±0.77     62.16 ±0.61     65.14 ±0.57      65.01 ±0.75      65.00 ±0.75
   Joint GE        53.29 ±0.90     62.56 ±0.15     65.87 ±0.36      65.72 ±0.56      65.69 ±0.57
   Joint Inc.      51.28 ±0.19     62.56 ±0.12     66.12 ±0.39      66.07 ±0.42      66.06 ±0.41
  Joint Dec.       53.58 ±0.44     61.87 ±0.45     65.06 ±0.35      65.01 ±0.29      65.00 ±0.30
  Joint SDN        49.23 ±0.64     61.83 ±0.32     66.03 ±0.18      65.95 ±0.25      65.93 ±0.24
    Mixed          52.89 ±0.23     63.28 ±0.59     67.20 ±0.65      67.24 ±0.71      67.22 ±0.71
  Mixed GE         51.73 ±0.12     63.17 ±0.33     67.22 ±0.39      67.22 ±0.10      67.21 ±0.12
  Mixed Inc.       51.81 ±0.24     63.01 ±0.49     67.42 ±0.39      67.49 ±0.32      67.47 ±0.34
  Mixed Dec.       53.58 ±0.69     63.60 ±0.25     66.76 ±0.50      66.78 ±0.47      66.75 ±0.47
  Mixed SDN        49.50 ±0.74     62.18 ±0.76     67.27 ±0.68      67.47 ±0.55      67.47 ±0.56



                           Table 20. ViT-T Imagenette head size experiment
 Regime, Head             25%              50%              75%              100%         Unlimited
  Disjoint 1L        75.61 ±0.10     78.72 ±1.24      78.32 ±1.62     78.29 ±1.63        78.28 ±1.65
Disjoint 2L-1024     77.41 ±0.39     79.04 ±1.26      78.36 ±1.63     78.29 ±1.63        78.28 ±1.65
Disjoint 2L-2048     77.10 ±0.40     79.02 ±1.26      78.39 ±1.69     78.30 ±1.65        78.28 ±1.65
    Joint 1L         81.44 ±1.54     82.51 ±1.40      82.46 ±1.41     82.46 ±1.41        82.45 ±1.40
 Joint 2L-1024       80.00 ±0.69     81.06 ±0.57      80.99 ±0.69     80.99 ±0.69        81.00 ±0.68
 Joint 2L-2048       79.68 ±0.28     80.67 ±0.08      80.64 ±0.15     80.64 ±0.15        80.61 ±0.13
   Mixed 1L          82.21 ±0.08     83.20 ±0.39      83.19 ±0.41     83.19 ±0.41        83.18 ±0.45
Mixed 2L-1024        80.25 ±0.59     81.28 ±0.44      81.13 ±0.40     81.13 ±0.40        81.11 ±0.37
Mixed 2L-2048        79.63 ±0.67     80.77 ±0.58      80.70 ±0.51     80.70 ±0.51        80.67 ±0.52


                                                 16
                       How to Train Your Multi-Exit Model? Analyzing the Impact of Training Strategies

D. Results as Performance-Cost plots
Following Kaya et al. (2019), we presented most of the results in this paper in the form of tables. In this section, we provide
the same results as model performance vs. computational costs plots.




Figure 7. Performance–cost trade-off of the multi-exit ResNet-34        Figure 8. Performance–cost trade-off of the MSDNet architecture
on the CIFAR-100 dataset                                                on the CIFAR-100 dataset




Figure 9. Performance–cost trade-off of the multi-exit ViT-T on         Figure 10. Performance–cost trade-off of the ViT-T architecture
the CIFAR-100 dataset                                                   on the ImageNet-1k dataset




Figure 11. Performance–cost trade-off of the multi-exit BERT-B          Figure 12. Performance–cost trade-off of the BERT-B architec-
on the 20Newsgroups dataset                                             ture on the STS-B dataset




                                                                   17
                       How to Train Your Multi-Exit Model? Analyzing the Impact of Training Strategies




Figure 13. Performance–cost trade-off of the multi-exit PBEE with         Figure 14. Performance–cost trade-off of the multi-exit GPF with
ViT-T as the backbone on the CIFAR-100 dataset                            ViT-T as the backbone on the CIFAR-100 dataset




Figure 15. Performance–cost trade-off of the multi-exit ViT-T on          Figure 16. Performance–cost trade-off of the multi-exit ViT-B on
the CIFAR-100 dataset, using normalized entropy as the exit crite-        the CIFAR-100 dataset, pre-trained on ImageNet-1k and fine-tuned
rion                                                                      on CIFAR-100




                                   Figure 17. Performance–cost trade-off of the multi-exit ViT-S on
                                   the ImageNet-1k dataset

E. Training Details
Here we provide more information training setup, in addition to what is described in Section 4.1

E.1. ResNet-34, CIFAR-100
Model set-up. Exit heads are placed at positions {2, 4, . . . , 14}.


                                                                     18
                      How to Train Your Multi-Exit Model? Analyzing the Impact of Training Strategies

Training set-up. We train each model with batch size of 128. We use a learning rate of 5e−4 and no weight decay. We set
the early stopping patience to 50 epochs. CutMix and Mixup are used as augmentations.

E.2. MSDNet, CIFAR-100
Model set-up. We use CIFAR variant of MSDNet with 7 blocks. Exit heads are placed at positions {0, 1, . . . , 17}.

Training set-up We train each model with batch size of 512. We use a learning rate of 1e−3 and no weight decay. We set
the early stopping patience to 50 epochs. CutMix and Mixup are used as augmentations.

E.3. ViT-T, CIFAR-100
Model set-up. ViT-T hyperparameters are as follows: a patch size of 4, an embedding size of 256, an MLP dimension of
256, 7 layers and 8 attention heads. Exit heads are placed at positions {0, 1, . . . , 6}. For GPF we set head embedding size to
512.

Training set-up We train each model with batch size of 256. We use a learning rate of 5e−4 and no weight decay. We set
the early stopping patience to 30 epochs. Following augmentations are used: random resizing, cropping, rotation, contrast
adjustment, random erasing, CutMix and Mixup.

E.4. ResNet-50, Tinyimagenet
Model set-up. Exit heads are placed at block positions {1..14}.

Training set-up. We train each model with batch size of 256. We use a learning rate of 1e−3 and no weight decay. We set
the early stopping patience to 50 epochs. CutMix and Mixup are used as augmentations.

E.5. ViT-T, ImageNet-1k
Model set-up. ViT-T hyperparameters are as follows: a patch size of 16, an embedding size of 192, an MLP dimension of
768, 12 layers, and 3 attention heads. Exit heads are placed at positions {1, 2, . . . , 10}.

Training set-up. We train each model using 4 A-100 GPUs with an effective batch size of 2048. We use a learning rate of
5e−4 and no weight decay. We set the early stopping patience to 25 epochs. Following augmentations are used: random
resizing, cropping, rotation, contrast adjustment, random erasing, CutMix (Yun et al., 2019) and Mixup (Zhang et al., 2018).

E.6. 20 Newsgroups, Bert-B
Model set-up     We set maximum sequence length to 512. Exit heads are placed at positions {1, 3, . . . , 21}

Training set-up We train each model with batch size of 32. We use a learning rate of 5e−5 and a weight decay of 1e−2.
We set the early stopping patience to 3 epochs.

E.7. STS-B, Bert-B
Model set-up     We set maximum sequence length to 128. Exit heads are placed at positions {1, 3, . . . , 21}

Training set-up We train each model with batch size of 16. We use a learning rate of 1e−5 and a weight decay of 1e−4.
We set the early stopping patience to 3 epochs.

E.8. ViT-B, CIFAR-100
Model set-up. ViT-B hyperparameters are as follows: a patch size of 16, an embedding size of 768, an MLP dimension of
3072, 12 layers and 12 attention heads. Exit heads are placed at positions {3, 5, . . . , 9}.

                                                              19
                    How to Train Your Multi-Exit Model? Analyzing the Impact of Training Strategies

Training set-up We use pretrained weights from torchvision (maintainers & contributors, 2016), trained on ImageNet-
1k. To fine-tune, we use a learning rate of 2e−5 and a weight decay of 3e−2. We set the early stopping patience to 30
epochs. We use Mixup as an augmentation.




                                                          20
