PONAS: Progressive One-shot Neural Architecture Search for Very Efficient Deployment

03/11/2020 ∙ by Sian-Yao Huang, et al. ∙ 0

We achieve very efficient deep learning model deployment that designs neural network architectures to fit different hardware constraints. Given a constraint, most neural architecture search (NAS) methods either sample a set of sub-networks according to a pre-trained accuracy predictor, or adopt the evolutionary algorithm to evolve specialized networks from the supernet. Both approaches are time consuming. Here our key idea for very efficient deployment is, when searching the architecture space, constructing a table that stores the validation accuracy of all candidate blocks at all layers. For a stricter hardware constraint, the architecture of a specialized network can be very efficiently determined based on this table by picking the best candidate blocks that yield the least accuracy loss. To accomplish this idea, we propose Progressive One-shot Neural Architecture Search (PONAS) that combines advantages of progressive NAS and one-shot methods. In PONAS, we propose a two-stage training scheme, including the meta training stage and the fine-tuning stage, to make the search process efficient and stable. During search, we evaluate candidate blocks in different layers and construct the accuracy table that is to be used in deployment. Comprehensive experiments verify that PONAS is extremely flexible, and is able to find architecture of a specialized network in around 10 seconds. In ImageNet classification, 75.2 top-1 accuracy can be obtained, which is comparable with the state of the arts.



There are no comments yet.


page 7

page 11

This week in AI

Get the week's most popular data science and artificial intelligence research sent straight to your inbox every Saturday.

1 Introduction

Deep neural networks have brought surprising advances in various research fields. Promising performance can be achieved if the networks are well designed and trained based on large amounts of data. However, designing good neural networks specific to a collection of constraints requires much domain knowledge, rich experience on model training and tuning, and a lot of time on trials and errors. Neural architecture search (NAS) is thus important and urgently-demanded to automate model design. Generally NAS methods can be categorized according to three dimensions [elsken19]

: search space, search strategy, and performance estimation strategy. There have been a dozen of studies proposed to search for neural architectures, especially for the task of image recognition. However, they are mostly time-consuming because of the intractable search space or expensive search strategy. Moreover, most of them are not scalable to various hardware constraints so that specialized networks should be determined and trained for each case.

Architecture searching is computationally expensive. For example, typical NAS methods based on reinforcement learning (RL) requires tens of GPU days

[baker17][zoph17]. The recent RL-based NAS method, e.g., MnasNet [Tan_2019_CVPR], was estimated to require about GPU hours for one specific network [cai2018proxylessnas].

To reduce search efforts, dfferentiable NAS (DNAS) methods and one-shot NAS methods emerged recently. They both can be viewed as weight sharing approaches. Conceptually, DNAS models the search space as an architecture distribution described by architecture parameters. The architecture distribution is embodied by learning a supernet that is described by supernet weights. Architecture search and model training are tightly coupled. After the supernet is constructed, the optimal architectures are sampled from the trained distribution. However, the network sampled from the architecture distribution is only suitable to a specific hardware constraint. This makes DNAS less scalable. The FBNet [Wu_2019_CVPR] is a differentiable NAS framework that largely speeds up searching for a specific network in GPU hours. But if we need different networks specific to different constraints, GPU hours are still needed.

In contrast to DNAS, one-shot NAS methods [1904.00420][cai2020once][pmlr-v80-bender18a] decouple model training from architecture search. A supernet, or once-for-all (OFA) network [cai2020once], is trained to flexibly support different sub-networks with different depths, widths, kernel sizes, and resolutions. Given hardware and/or latency constraints, a subset of sub-networks are sampled according to a pre-trained accuracy predictor [cai2020once], or are evolved through an evolutionary algorithm [1904.00420]. However, training an accuracy predictor is still expensive (40 GPU hours mentioned in [cai2020once]). The time needed to execute the evolutionary algorithm [1904.00420] is considerable, too.

We conclude two problems in previous weight sharing NAS approaches:

  • High cost of supernet training: Training a supernet needs a lot of computation resource and search time.

  • High cost of sub-network specialization: No matter DNAS or one-shot NAS, considerable time is needed to do network specialization.

In this work, we propose Progressive One-shot Neural Architecture Search (PONAS) that combines the advantages of progressive NAS and the one-shot method. Progressive NASs like [Liu_2018_ECCV] and [Dong_2018_ECCV]

construct convolutional neural networks (CNNs) by stacking some predefined numbers of

cells. The best structure of the cell is searched by progressively expanding blocks (operations). The determined best cell then acts as a layer. The structure of each layer, therefore, keeps the same. In the proposed PONAS, instead of searching the best cell, we search the best block for each layer progressively. In this way, structures of different layers may be different, and richer expressivity may be obtained. To tackle the first problem mentioned above, we propose a two-stage training scheme that separates the searching process into the meta training stage and the fine-tuning stage to make the search process more efficient and stable.

In the progressive search process, we construct an accuracy table that stores validation accuracy of each candidate block in each layer. Given a hardware constraint, a specialized network can be evolved by the evolutionary algorithm. This evolution is extremely efficient because only simple table lookup is needed to estimate performance of any specialized network. In our experiment, architecture of a specialized network can be determined in around 10 seconds. This approach largely resolves the second problem mentioned above.

Notice that, in contrast to FBNet [Wu_2019_CVPR] where sub-networks are sampled from a supernet, we directly derive a network specific to the hardware constraint according to the information obtained during the search process of PONAS. This strategy enables us to get multiple specific networks very efficiently based on the accuracy table that only needs to be constructed once.

2 Related Works

Because the formulation of NAS is similar to reinfocement learning (RL), early NAS methods were firstly proposed based on it. However, such approaches are very computationally expensive. A variety of methods were thus proposed based on progressive learning or weight sharing to reduce computational cost. In the following, we only focus on related works on these two approaches.

2.1 Progressive Neural Architecture Search

Progressive NAS (PNAS) methods [Dong_2018_ECCV][Liu_2018_ECCV] search the architecture space in a progressive way. A sequential model-based optimization (SMBO) strategy [hutter11] is adopted to search for architectures in the order of increasing complexity, while a surrogate model is learnt simultaneously to guide the search. Starting from the first cell, all possible block structures are trained and evaluated. Each of them is then expanded by adding all possible blocks, which largely enlarges the search space. To reduce search time, a performance predictor is trained to evaluate all these extensions, and then only the top blocks are retained. According to [Liu_2018_ECCV], this approach is about 8 times faster than the RL-based method [zoph18] in terms of total compute.

Inspired by PNAS, we also adopt the idea of progressive learning. But different from the SMBO strategy, we construct an accuracy table rather than building a surrogate model as a performance predictor.

2.2 Weight Sharing Neural Architecture Search

Many recent NAS approaches are conceptually based on weight sharing [cai2018proxylessnas] [liu2018darts] [Wu_2019_CVPR] [chu2019fairnas] [Yan_2019_ICCV_Workshops]. The main idea is constructing a supernet to represent the entire search space. Such methods can be generally divided into two categories: differentiable NAS and one-shot NAS.

Differentiable NAS [Wu_2019_CVPR][cai2018proxylessnas][liu2018darts] views the search space as an architecture distribution described by architecture parameters. Architecture parameters are optimized when training a supernet. After supernet training, the optimal architectures are sampled from the trained distribution. Instead of searching over a discrete set of candidate architectures, Liu et al. [liu2018darts] relaxed the search space from discrete to continuous, and thus the gradient descent algorithm can be adopted to find the optimal architecture. Cai et al. [cai2018proxylessnas]binarized the architecture parameters and forced only one path to be active when training the supernet, which reduces the required GPU memory. Wu et al.[Wu_2019_CVPR] used the Gumbel softmax technique [1611.01144] to find the optimal distribution of architecture parameters.

One-shot NAS [pmlr-v80-bender18a][1904.00420][cai2020once][chu2019fairnas] considers the trained supernet as an evaluator to predict performance of all sub-networks. After training a supernet, one-shot NAS can adopt random sampling, evolutionary algorithms, or reinforcement learning to derive multiple specific networks conforming to different constraints without retraining the supernet. Using the trained supernet as the performance evaluator, Guo et al. [1904.00420] used an evolutionary algorithm to find the optimal architecture for the given constraint. Cai et al. [cai2020once] sampled a set of sub-networks to train an accuracy predictor. This guides architecture search to get a specialized network. Chu et al. [chu2019fairnas] pointed out the problem of biased evaluation, which is prone to misjudgments of candidate architectures. They thus proposed to fairly train candidate blocks to get a supernet as a reliable performance evaluator.

3 Progressive One-Shot Neural Architecture Search

Progressive NAS [Dong_2018_ECCV] [Liu_2018_ECCV] adopted the SMBO strategy to search for the best structure of the cell by progressively expanding blocks (operations). Inspired by progressive search, the proposed PONAS also searches the architecture progressively, but PONAS directly searches for the best network layer by layer. More importantly, the accuracy table constructed in PONAS process facilitates efficient network specialization without a surrogate model for accuracy prediction.

3.1 Overview

3.1.1 Previous Network Specialization.

Denote the weights of a supernet as . Each sampled architecture inherits weights from . Given a constraint , previous one-shot NAS methods [1904.00420][chu2019fairnas] achieved network specialization by finding the best sub-network that yields the highest accuracy and fits the constraint . That is,


where is the validation accuracy yielded by the architecture . The network deployment process mentioned in Eqn. (1) is time consuming because the validation accuracy of sub-networks ’s should be calculated case by case.

3.1.2 The Proposed Process.

Instead of calculating validation accuracy in each deployment, we propose to build an accuracy table when constructing the supernet. With this table, very efficient network deployment can be achieved because only simple table lookup is needed.

Denote the weights of the -th layer as , and the -th candidate block in the -th layer as . A candidate block is a set of settings of operations, which may include different kernel sizes, expansion settings, and so on. When constructing the supernet, we would like to find the architecture as a stack of blocks that yields the highest accuracy. For the -th layer, the best block is determined by


where is a supernet containing all candidate blocks in the -th layer, while containing the default block in all other layers (details will be given in Sec. 3.2). The term is a sub-network taking the block in the -th layer, which is sampled from . The term is the total number of candidate blocks in a layer. By finding the best blocks , , …, in layers 1 to progressively, we can stack them to construct the supernet, denoted as .

When finding the best architecture of the supernet, we simultaneously construct the accuracy table that stores the validation accuracy of all candidate blocks at all layers:


Given a constraint , we can get the specific network that maximizes the accuracy and fits the constraint by checking the accuracy values stored in .


where is the set of indices of candidate blocks in all layers. The meaning of Eqn. (4) is that we want to find the best sequence of blocks among all combinations such that the architecture yields the highest accuracy and fits the constraint simultaneously. The term denotes the index of the candidate block at the -th layer.

The main difference between Eqn. (4) and Eqn. (1

) is that we do not need to calculate or estimate validation accuracy on the fly, but just need to look at the accuracy table. We adopt the genetic algorithm to find the best sequence among all combinations. Because only table lookup is needed, finding the best sub-network architecture usually can be done in 10 seconds.

Input shape Block Output channel Repeat Stride
Conv 3 3 32 1 2
MBConv E1 16 1 1
Candidate Block 32 1 2
Candidate Block 32 1 1
Candidate Block 40 1 2
Candidate Block 40 3 1
Candidate Block 80 1 2
Candidate Block 96 4 1
Candidate Block 96 3 1
Candidate Block 192 1 2
Candidate Block 320 4 1
Candidate Block 1280 1 1
Avg pool - 1 1
Fully Connected 1000 1 -
Table 1: Macro-architecture of the search space. MBConv E1 denotes MBConv with kernel size 3 and expansion 1. ”Repeat” denotes the number of layers repeat with the corresponding settings.

In this work, the setting of the architecture search space is inspired by [cai2018proxylessnas]. The backbone of candidate block is mobile inverted bottleneck convolution (MBConv) [Sandler_2018_CVPR] with kernel sizes {3,5,7} and expansion {3,6} in depthwise convolution. The squeeze-and-excite [hu2018senet] module is considered to be employed or not to expand the search space. Therefore, we have types of candidate blocks for each layer. The number of layers to be constructed is set to . Accordingly, our search space has a size of in total. Particularly, the macro-architecture of the search space is illustrated in Table 1.

3.2 Two-stage Training

Weight sharing approaches like [Wu_2019_CVPR][1904.00420][chu2019fairnas][liu2018darts] and our approach mentioned in Sec. 3.1 need to construct a generic network (supernet), and then sub-networks are sampled or derived from it to conform to constraints. However, training a supernet needs a lot of computation resource and search time. In [Wu_2019_CVPR], for example, constructing the supernet needs to consider all combinations of candidate blocks in the search space, as illustrated in the left of Fig. 1(a). This makes the structure of the supernet quite complex and thus much resource is required. Some recent works [stamoulis2019singlepath][1912.04749] use the super kernel to encode all candidate blocks into one block, and search the best distribution of architecture parameters to get the best sub-network. But these approaches give rise to the coupling problem mentioned in [1904.00420].

To reduce the cost of training a supernet, we propose a two-stage training scheme. This training scheme is compatible to be integrated with other weight sharing NASs. The first stage of this scheme is called meta training stage, and the second stage is called fine-tuning stage.

In the meta training stage, we construct a meta network which is the largest network in the search space. In each layer of the so-called largest network, only the candidate block with the largest convolution kernel, expansion, and enabled squeeze-and-excite module is used, i.e., kernel size = 7, expansion = 6, with squeeze-and-excite module enabled. Let denote the largest block in the following. Fig. 1(a) illustrates the difference between a supernet and the proposed meta network. The meta network is a single path consisting of the concatenation of ’s, and a supernet is a network consisting of multiple paths of various blocks. Training the meta network is thus easier.

Figure 1: (a) The main difference between a supernet and the proposed meta network is that the former consists of multiple paths of blocks, and the later is single-path. (b) Our two-stage training scheme. In the meta training stage, we only train meta network which is constructed by the largest candidate block. In the fine-tuning stage, we progressively fine-tune the meta network to construct the accuracy table.

Training the meta network acts as finding good initialization parameters based on the largest block. To further elaborate the network, we propose to progressively fine-tune the meta network by finding the best block for each layer. Instead of constructing the entire supernet as the left of Fig. 1(a), we only replace of one layer by 12 candidate blocks each time to construct the supernet . For example, to fine-tune the first layer, the default block is replaced by candidate blocks , and the 2nd layer to the 19th layer keep using the default block (with the parameters discovered in the meta learning stage) to construct . The supernet is fine-tuned based on the training data with strict fairness [chu2019fairnas], respectively. Let denote the specific network from where the block in the first layer is , followed by ’s. The validation accuracy of each specific network is evaluated and stored in the accuracy table , which will play an important role in network specialization described later.

Assume that when replaced by the candidate block , the specific network yields the highest validation accuracy. This network is denoted as . When we try to fine-tune the second layer, parameters of the supernet , , , …, , are updated based on the training data. In the same way, the validation accuracy of each specific network from is evaluated and stored in the accuracy table .

We progressively find the best candidate block for each layer, and store all validation accuracy values in the accuracy table . The progressive fine-tuning process is illustrated in Fig. 1(b). After fine-tuning all layers, we finally get the network and the accuracy table .

The parameters of smaller candidate blocks are initialized by the parameter of the largest block . Fig. 1(b) illustrates how we crop parameters of the largest block

to get the parameters of all smaller blocks. With such initialization, we just need to fine-tune for a few epochs rather than lots of epochs from random initialization. This idea is similar to progressive shrinking mentioned in


3.3 Network Specialization in the Accuracy Loss Domain

Given a constraint, previous one-shot methods derived a specific network based on the evolutionary algorithm [1904.00420][cai2020once]. These methods flexibly support different constraints and only need to train the supernet once. However, the evolutionary method proposed in Guo et al.[1904.00420] required much time in measuring validation accuracy of the population, and the method proposed in Cai et al.[cai2020once] needed to train an accuracy predictor to measure validation accuracy of 16K sub-networks. In our work, we employ the accuracy table as the performance evaluator in the network specialization process.

A problem from Eqn. (4) arises when comparing with the validation accuracy of candidate blocks in different layers. Candidate blocks in different layers are not directly comparable because different levels of information is learnt. Therefore, we argue that they should be compared in a domain commonly for different layers. Chu et al. [chu2019fairnas] pointed out that different choice blocks of the same layer learn similar feature maps on the corresponding channel. Inspired by this observation, we propose to represent performance of each candidate block as the accuracy loss from the best block at the corresponding layer. For example, let be the validation accuracy (evaluated in the training process and stored in the accuracy table ) of the candidate blocks at the -th layer, and let denote the best accuracy yielded by , the accuracy loss is calculated as . In this way, we calculate , and transform the performance of candidate blocks in different layers into the accuracy loss domain.

We then can construct the accuracy loss table . Based on , we make an assumption that the accuracy loss of candidate blocks can quantify importance of candidate blocks in different layers. With the accuracy loss table , we can reformulate Eqn. (4) as


Fig. 2 shows the largest accuracy losses at different layers. As can be seen, different layers learn different information and yield varied accuracy losses. For the layer with smaller accuracy loss, performances of different candidate blocks in this layer are similar. Therefore, when we do network specialization, we prefer to replace by other smaller blocks so that less resource is needed but the validation accuracy just decreases slightly.

The optimization problem mentioned in Eqn. (5) is solved by the genetic algorithm. We represent an architecture sampled from the supernet as a chromosome of length 19. A chromosome denotes the block indices of the sub-network constituted by . We randomly initialize 20 chromosomes in the first population. The cost of each chromosome is calculated based on the accuracy loss table , i.e.,

. The top 10 chromosomes that yields the least accuracy loss are selected and grouped into 5 pairs, which are viewed as parent chromosomes. For each pair, a position from 1 to 19 (length of a chromosome) is randomly selected for the crossover operation. Five pairs of children are generated after crossover. For each of this child chromosome, the index of each position may randomly mutate to another index with probability 0.1. After crossover and mutation, these 10 chromosomes and the 10 parent chromosomes form the second-generation population. Notice that, after each crossover and mutation, the resultant chromosome is checked if it fits the constraint

. If not, another crossover or mutation operation will be conducted to make new chromosomes. In this work, the same evolution process iterates for 1,000 generations, and the best chromosome in the whole process is picked to represent the architecture of the desired specialized network.

Figure 2: The Maximum accuracy losses in different layers. We argue that they can be the indicators to decide the block to be replaced first.

4 Experiments

4.1 Experimental Settings

4.1.1 Datasets.

We perform all experiments based on the ImageNet dataset [imagenet_cvpr09]. Same as the settings in previous works [chu2019fairnas][1904.00420][cai2018proxylessnas][Tan_2019_CVPR], we randomly sample 50,000 images (50 images for each class) from the training set as our validation set, and the rest is kept as our training set. The original validation set is taken as our test set to measure the final performance of each model.

4.1.2 Training Hyperparameters.

We train the meta-network for 50 epochs using batch size 256 and adopt the stochastic gradient descent optimizer with a momentum of 0.9 and weight decay of

, based on data with standard augmentation (random resizing, cropping, and flipping). We set the initial learning rate to be 0.1, and decay 10x at 20 and 40 epochs. For the fine-tuning stage of PONAS, we follow the same strategy as that for meta training. But we only fine tune each layer for 3 epochs and set the initial learning rate to be 0.001 without any decay setting.

After determining the architecture of a specific network that conforms to the given constraint, we train the specific network using the standard SGD optimizer with Nesterov momentum 0.9 and weight decay

. The initial learning rate is 0.045, and we use the cosine scheduler [1608.03983] for learning rate decay. We use 4 NVIDIA GTX 1080Ti GPUs for training.

4.2 ImageNet Classification

Three specific models, named as PONAS-A, PONAS-B, and PONAS-C, are specialized from the supernet according to the accuracy loss table to meet different requirements. It is worth noting again that we only need to search the accuracy loss table and require very little deploy time for finding specific networks. The result is shown in Table 2. As can be seen, the proposed PONAS requires similar search time to the most recent weight sharing approaches [chu2019fairnas][cai2018proxylessnas][Wu_2019_CVPR]. However, thanks to the design of the accuracy loss table, we achieve the one-shot property [1904.00420][chu2019fairnas][cai2020once], and the time for deploy can be almost ignored. Overall, the top-1 accuracies are 74.67%, 74.95%, and 75.2% for PONAS-A, -B, and -C, respectively, which are quite comparable with the state of the arts (FairNAS [chu2019fairnas]).

GPU hours
GPU hours
Params(M) FLOPs(M)
MobileNetV2 [Sandler_2018_CVPR] manual - - - - 3.4 300 72.0
MobileNetV2(1.4X) [Sandler_2018_CVPR] manual - - - - 6.9 585 74.7
ShuffleNetV2(1.5X) [Ma_2018_ECCV] manual - - - - 3.5 299 72.6
PNASNet [Liu_2018_ECCV] SMBO Cell CIFAR-10 - - 5.1 588 74.2
DPP-Net-Panacea [Dong_2018_ECCV] SMBO Cell CIFAR-10 - - 4.8 523 74.02
DARTS [liu2018darts] gradient Cell CIFAR-10 96 96 4.7 574 73.3
FBNet-A [Wu_2019_CVPR] gradient layer ImageNet 216 216 4.3 249 73.0
FBNet-B [Wu_2019_CVPR] gradient layer ImageNet 216 216 4.5 295 74.1
FBNet-C [Wu_2019_CVPR] gradient layer ImageNet 216 216 5.5 375 74.9
SinglePath NAS [stamoulis2019singlepath] gradient layer ImageNet 30 30 4.3 365 75.0
SinglePath OneShot [1904.00420] evolution layer ImageNet 288 24 - 328 74.7
OFA w/ PS [cai2020once] evolution layer ImageNet 1200 40 - 230 76.00
ProxylessNAS-R [cai2018proxylessnas] RL layer ImageNet 200 200 4.1 320 74.6
MnasNet-A1 [Tan_2019_CVPR] RL stage ImageNet 40K 40K 3.9 312 75.2
MnasNet-A2 [Tan_2019_CVPR] RL stage ImageNet 40K 40K 4.8 340 75.6
MobileNetV3-Large [Howard_2019_ICCV] RL stage ImageNet 40K - 5.4 219 75.2
MobileNetV3-Small [Howard_2019_ICCV] RL stage ImageNet 40K - 2.9 66 67.4
FairNas-A [chu2019fairnas] RL layer ImageNet 240 48 4.4 321 74.69
FairNas-B [chu2019fairnas] RL layer ImageNet 240 48 4.5 345 75.10
FairNas-C [chu2019fairnas] RL layer ImageNet 240 48 4.6 388 75.34
PONAS-A evolution layer ImageNet 210 0 5.1 326 74.67
PONAS-B evolution layer ImageNet 210 0 5.1 349 74.95
PONAS-C evolution layer ImageNet 210 0 5.6 376 75.2
Table 2: ImageNet classification performance comparison with the SOTA models.
Figure 3: Architectures of PONAS-A, -B, -C from top to down. MBE3 and MBE6 denote the mobile inverted bottleneck convolution layers with expansion ratios 3 and 6, respectively. K denotes the kernel size of . se denotes whether the squeeze-and-excite [hu2018senet] module is used. The orange blocks are predefined blocks before searching.

Fig. 3 shows architectures of PONAS-A, PONAS-B, and PONAS-C. Notice that the three models tend to choose high expansion rates and large kernel at more important layers (the layers with larger accuracy losses, see Fig. 2), which tends to improve performance. On the other hand, to reduce computational complexity, the three models tend to choose the block with small expansion rate at less important layers.

Fig. 4 shows the evolution curves of finding architectures of three specific models, PONAS-A, PONAS-B, and PONAS-C. Thanks to the accuracy table, we can evolve more generations to get the network with lower accuracy loss.

Figure 4: Evolution curves of the network specialization process for finding architectures of PONAS-A, -B, and -C.

4.3 Ablation Studies

4.3.1 Efficiency of Two-stage Training.

For fair comparison of the proposed two-stage training and FairNAS [chu2019fairnas], which directly trained the entire supernet from random initialization with strict fairness, we train both methods for 50 epochs and set the initial learning rate as 0.1, and decay 10x at 20 and 40 epochs. For two-stage training, we train 30 epochs for the meta training stage and another 20 epochs for the fine-tuning stage. Instead of progressively fine tuning each layer mentioned in Sec. 3.2, we fine tune the entire supernet for fair comparison with FairNAS. The reason to compare with FairNAS is that we both train the supernet with the strict fairness property [chu2019fairnas].

Fig. 5 shows the relationship between top-1 validation accuracy and training epochs. Basically both methods get increasing accuracy as the number of training epoch increases. For the proposed two-stage training, the validation accuracy drops at the beginning of the fine-tuning stage but rises gradually after a few epochs. After 50 epochs, the proposed two-stage training reaches up to 69%, which is 1% higher than FairNAS. Fig. 5 shows comparison in terms of total GPU hours required for training a supernet. In the meta training stage, the two-stage training scheme is 1.35 times faster than because of the simple architecture of the meta network.

Figure 5: Comparison between the two-stage training and FairNAS [chu2019fairnas]. The black dash line denotes the beginning of the fine-tuning stage in two-stage training. (a) The evolution of validation accuracies of two methods. (b) The total time required to train the supernets in the manners based on two-stage training and random initialization used in FairNAS.

4.3.2 Analysis of the Accuracy Loss Domain.

We purposely sample six different architectures, train six specialized networks from scratch, and then evaluate them. Fig. 7 shows the relationship between an architecture’s accuracy loss (from the table ) and the real validation accuracy. We see that these two factors positively correlated. Inspired by [1902.08142], we adopt the Kendall rank correlation coefficient [10.1093/biomet/30.1-2.81] to measure the correlation. According to the values in Fig. 7, the Kendall’s value is . This means the architecture with less predicted accuracy loss really yields higher validation accuracy, and verifies the assumption we made in Sec. 3.3.

Figure 6: The relationship between validation accuracies of six models and their associated predicted accuracy losses.
Figure 7: The top-1 validation accuracies of three different networks.
Figure 6: The relationship between validation accuracies of six models and their associated predicted accuracy losses.
Model FLOPs(M)
accuracy (%)
worst 279 73.4
worst+least importance
305 73.8
worst+most importance
295 73.9
Table 3: Impact of different layers on performance. The network most importance achieves the highest accuracy with the least FLOPs.

4.3.3 Importance of Different Layers.

To verify the assumption that the accuracy loss of candidate blocks can quantify importance of candidate blocks in different layers, we specialize three models from the supernet. First, for each layer of the supernet, we purposely replace the block with one candidate block that yields the largest accuracy loss. This model is called the worst specific network. Second, we then purposely replace the block in the least important layer of the worst specific network with the best candidate block in that layer to construct the network called worst+least importance. Third, we also replace the block in the most important layer of the worst specific network with the best candidate block in that layer, and obtain a new specific network called worst+most importance. For fair comparison, we actually replace the two least important layers in worst+least importance to achieve similar FLOPs with worst+most importance.

We train the three models for 150 epochs under the same setting in Sec. 4.1.2 and show the result in Table 3. As expected, the worst specific network obtains the worst performance. When the worst network is transformed to worst+least importance, top-1 accuracy boosts to 73.8%. When the worst network is transformed to worst+most importance, the highest accuracy (73.9%) with less FLOPs can be obtained. The differences on accuracy and FLOPs show the impact of importance of different layers. Fig. 7 shows the evolution of top-1 validation accuracy of these networks. The worst+most importance model has higher convergence speed than other networks.

In summary, using better blocks at more important layers is more efficient than that at less important layers. From both Table 3 and Fig. 2, we found that layers with different numbers of channels for input and output have larger accuracy loss and are more impactful to final performance. This observation shows that the accuracy loss of candidate blocks can quantify importance of candidate blocks in different layers.

5 Conclusion

We present a progressive one-shot neural architecture search method which searches the best block in each layer progressively to construct the supernet. When constructing the supernet, we also build a table called accuracy table to store the validation accuracy of each candidate block in each layer. By transforming the accuracy table into the accuracy loss domain, candidate blocks in different layers are comparable, and importance of different layers can be measured. Given a constraint, we can simply check the accuracy table to see performance of various specialized architectures and find a specific architecture in around 10 seconds. This is much more efficient than previous one-shot NAS. To speed up and stabilize supernet training, we propose a two-stage training approach, including the meta training stage and the fine-tuning stage. We demonstrate that two-stage training is more stable and converges faster than previous approaches that train the supernet from random initialization. In the evaluation, we show that the proposed PONAS can achieve the state-of-the-art performance with very low-cost deployment.