Git Product home page Git Product logo

nas-bench-macro's Introduction

NAS-Bench-Macro

This repository includes the benchmark and code for NAS-Bench-Macro in paper "Prioritized Architecture Sampling with Monto-Carlo Tree Search", CVPR2021.

NAS-Bench-Macro is a NAS benchmark on macro search space. The NAS-Bench-Macro consists of 6561 networks and their test accuracies, parameters, and FLOPs on CIFAR-10 dataset.

Each architecture in NAS-Bench-Macro is trained from scratch isolatedly.

Benchmark

All the evaluated architectures are stored in file nas-bench-macro_cifar10.json with the following format:

{
    arch1: {
        test_acc: [float, float, float], // the test accuracies of three independent training
        mean_acc: float, // mean accuracy
        std: float, // the standard deviation of test accuracies
        params: int, // parameters
        flops: int, // FLOPs 
    },
    arch2: ......
}

Search Space

The search space of NAS-Bench-Macro is conducted with 8 searching layers; each layer contains 3 candidate blocks, marked as Identity, MB3_K3, and MB6_K5.

  • Identity: identity connection (encoded as '0')
  • MB3_K3: MobileNetV2 block with kernel size 3 and expansion ratio 3
  • MB6_K5: MobileNetV2 block with kernel size 5 and expansion ratio 6

Network structure

Statistics

Visualization of the best architecture

Histograms

Reproduce the Results

Requirements

torch>=1.0.1
torchvision

Training scripts

cd train
python train_benchmark.py

The test result of each architecture will be stored into train/bench-cifar10/<arch>.txt

After all the architectures are trained, you can collect the results into a final benchmark file:

python collect_benchmark.py

Citation

If you find that NAS-Bench-Macro helps your research, please consider citing it:

@inproceedings{su2021prioritized,
  title={Prioritized Architecture Sampling with Monto-Carlo Tree Search},
  author={Su, Xiu and Huang, Tao and Li, Yanxi and You, Shan and Wang, Fei and Qian, Chen and Zhang, Changshui and Xu, Chang},
  booktitle={Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition},
  pages={10968--10977},
  year={2021}
}

nas-bench-macro's People

Contributors

hunto avatar xiusu avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

nas-bench-macro's Issues

run into error when running the code

I tried to run your code without any modification.
i just clone it and run the train_benchmark.py file. And it gave me this error.

lready evaluated. Evaluating (985/6561): 01100111 Experiment dir : bench-cifar10 Traceback (most recent call last): File "train.py", line 39, in <module> fh = logging.FileHandler(os.path.join(args.save, 'log', '{}.log'.format(utils.get_real_arch(args.arch)))) File "/usr/lib/python3.8/logging/__init__.py", line 1143, in __init__ StreamHandler.__init__(self, self._open()) File "/usr/lib/python3.8/logging/__init__.py", line 1172, in _open return open(self.baseFilename, self.mode, encoding=self.encoding) FileNotFoundError: [Errno 2] No such file or directory:

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.