Skip to main content

Neural Network Intelligence project

Project description


MIT licensed Build Status Issues Bugs Pull Requests Version Join the chat at https://gitter.im/Microsoft/nni Documentation Status

NNI Doc | 简体中文

NNI (Neural Network Intelligence) is a lightweight but powerful toolkit to help users automate Feature Engineering, Neural Architecture Search, Hyperparameter Tuning and Model Compression.

The tool manages automated machine learning (AutoML) experiments, dispatches and runs experiments' trial jobs generated by tuning algorithms to search the best neural architecture and/or hyper-parameters in different training environments like Local Machine, Remote Servers, OpenPAI, Kubeflow, FrameworkController on K8S (AKS etc.), DLWorkspace (aka. DLTS), AML (Azure Machine Learning), AdaptDL (aka. ADL) , other cloud options and even Hybrid mode.

Who should consider using NNI

  • Those who want to try different AutoML algorithms in their training code/model.
  • Those who want to run AutoML trial jobs in different environments to speed up search.
  • Researchers and data scientists who want to easily implement and experiment new AutoML algorithms, may it be: hyperparameter tuning algorithm, neural architect search algorithm or model compression algorithm.
  • ML Platform owners who want to support AutoML in their platform.

What's NEW!  

NNI capabilities in a glance

NNI provides CommandLine Tool as well as an user friendly WebUI to manage training experiments. With the extensible API, you can customize your own AutoML algorithms and training services. To make it easy for new users, NNI also provides a set of build-in state-of-the-art AutoML algorithms and out of box support for popular training platforms.

Within the following table, we summarized the current NNI capabilities, we are gradually adding new capabilities and we'd love to have your contribution.

Frameworks & Libraries Algorithms Training Services
Built-in
  • Supported Frameworks
    • PyTorch
    • Keras
    • TensorFlow
    • MXNet
    • Caffe2
    • More...
  • Supported Libraries
    • Scikit-learn
    • XGBoost
    • LightGBM
    • More...
Hyperparameter Tuning Neural Architecture Search (Retiarii) Model Compression Feature Engineering (Beta) Early Stop Algorithms
References

Installation

Install

NNI supports and is tested on Ubuntu >= 16.04, macOS >= 10.14.1, and Windows 10 >= 1809. Simply run the following pip install in an environment that has python 64-bit >= 3.6.

Linux or macOS

python3 -m pip install --upgrade nni

Windows

python -m pip install --upgrade nni

If you want to try latest code, please install NNI from source code.

For detail system requirements of NNI, please refer to here for Linux & macOS, and here for Windows.

Note:

  • If there is any privilege issue, add --user to install NNI in the user directory.
  • Currently NNI on Windows supports local, remote and pai mode. Anaconda or Miniconda is highly recommended to install NNI on Windows.
  • If there is any error like Segmentation fault, please refer to FAQ. For FAQ on Windows, please refer to NNI on Windows.

Verify installation

  • Download the examples via clone the source code.

    git clone -b v2.4 https://github.com/Microsoft/nni.git
    
  • Run the MNIST example.

    Linux or macOS

    nnictl create --config nni/examples/trials/mnist-pytorch/config.yml
    

    Windows

    nnictl create --config nni\examples\trials\mnist-pytorch\config_windows.yml
    
  • Wait for the message INFO: Successfully started experiment! in the command line. This message indicates that your experiment has been successfully started. You can explore the experiment using the Web UI url.

INFO: Starting restful server...
INFO: Successfully started Restful server!
INFO: Setting local config...
INFO: Successfully set local config!
INFO: Starting experiment...
INFO: Successfully started experiment!
-----------------------------------------------------------------------
The experiment id is egchD4qy
The Web UI urls are: http://223.255.255.1:8080   http://127.0.0.1:8080
-----------------------------------------------------------------------

You can use these commands to get more information about the experiment
-----------------------------------------------------------------------
         commands                       description
1. nnictl experiment show        show the information of experiments
2. nnictl trial ls               list all of trial jobs
3. nnictl top                    monitor the status of running experiments
4. nnictl log stderr             show stderr log content
5. nnictl log stdout             show stdout log content
6. nnictl stop                   stop an experiment
7. nnictl trial kill             kill a trial job by id
8. nnictl --help                 get help information about nnictl
-----------------------------------------------------------------------
  • Open the Web UI url in your browser, you can view detailed information of the experiment and all the submitted trial jobs as shown below. Here are more Web UI pages.
webui

Releases and Contributing

NNI has a monthly release cycle (major releases). Please let us know if you encounter a bug by filling an issue.

We appreciate all contributions. If you are planning to contribute any bug-fixes, please do so without further discussions.

If you plan to contribute new features, new tuners, new training services, etc. please first open an issue or reuse an exisiting issue, and discuss the feature with us. We will discuss with you on the issue timely or set up conference calls if needed.

To learn more about making a contribution to NNI, please refer to our How-to contribution page.

We appreciate all contributions and thank all the contributors!

Feedback

Join IM discussion groups:

Gitter WeChat
image OR image

Test status

Essentials

Type Status
Fast test Build Status
Full linux Build Status
Full windows Build Status

Training services

Type Status
Remote - linux to linux Build Status
Remote - linux to windows Build Status
Remote - windows to linux Build Status
OpenPAI Build Status
Frameworkcontroller Build Status
Kubeflow Build Status
Hybrid Build Status
AzureML Build Status

Related Projects

Targeting at openness and advancing state-of-art technology, Microsoft Research (MSR) had also released few other open source projects.

  • OpenPAI : an open source platform that provides complete AI model training and resource management capabilities, it is easy to extend and supports on-premise, cloud and hybrid environments in various scale.
  • FrameworkController : an open source general-purpose Kubernetes Pod Controller that orchestrate all kinds of applications on Kubernetes by a single controller.
  • MMdnn : A comprehensive, cross-framework solution to convert, visualize and diagnose deep neural network models. The "MM" in MMdnn stands for model management and "dnn" is an acronym for deep neural network.
  • SPTAG : Space Partition Tree And Graph (SPTAG) is an open source library for large scale vector approximate nearest neighbor search scenario.
  • nn-Meter : An accurate inference latency predictor for DNN models on diverse edge devices.

We encourage researchers and students leverage these projects to accelerate the AI development and research.

License

The entire codebase is under MIT license

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

nni-2.4-py3-none-win_amd64.whl (53.4 MB view details)

Uploaded Python 3Windows x86-64

nni-2.4-py3-none-manylinux1_x86_64.whl (56.6 MB view details)

Uploaded Python 3

nni-2.4-py3-none-macosx_10_9_x86_64.whl (54.4 MB view details)

Uploaded Python 3macOS 10.9+ x86-64

File details

Details for the file nni-2.4-py3-none-win_amd64.whl.

File metadata

  • Download URL: nni-2.4-py3-none-win_amd64.whl
  • Upload date:
  • Size: 53.4 MB
  • Tags: Python 3, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.8.10

File hashes

Hashes for nni-2.4-py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 a30771a4d4853f82e7c4696ba12fc5cace1d9826ad0e40d79130b4ac7ef296f5
MD5 37166a9d7e55f3460a7858530b25939d
BLAKE2b-256 84c610ae908cf7f0a9989a513c18e87b0b225c7c4ac6e2e411da79ff44151780

See more details on using hashes here.

File details

Details for the file nni-2.4-py3-none-manylinux1_x86_64.whl.

File metadata

  • Download URL: nni-2.4-py3-none-manylinux1_x86_64.whl
  • Upload date:
  • Size: 56.6 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.8.11

File hashes

Hashes for nni-2.4-py3-none-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 a8190911559f029ebea45c9b575c5d11885b1f413a988a3b8537fdd59ec3d590
MD5 5ef7c909fc5b06c201470547ef41499a
BLAKE2b-256 639aadab4dacad850faa206bcb4127fbf8a411b41e1636d069110383115c6c84

See more details on using hashes here.

File details

Details for the file nni-2.4-py3-none-macosx_10_9_x86_64.whl.

File metadata

  • Download URL: nni-2.4-py3-none-macosx_10_9_x86_64.whl
  • Upload date:
  • Size: 54.4 MB
  • Tags: Python 3, macOS 10.9+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.8.11

File hashes

Hashes for nni-2.4-py3-none-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 da796869989f54fb32f9f13d565e40f382ebd6aaeed539b5c783730ac7f6bcd8
MD5 a7e08b719799df439d0096f96f50eb3b
BLAKE2b-256 2122ec9250e17e38dfa30d2774865b6deda1a70e804fb614b1005f1bd3b13f34

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page