神经网络智能包
nni-upload-test的Python项目详细描述
NNI(神经网络智能)是一个帮助用户运行自动机器学习(AutoML)实验的工具包。 该工具分派并运行由优化算法生成的试用作业,以便在不同的环境(如本地计算机、远程服务器和云)中搜索最佳的神经体系结构和/或超参数
nniv0.6已释放!
Supported Frameworks | Tuning Algorithms | Training Services |
| Tuner
|
谁应该考虑使用NNI
- 那些想在本地机器上的训练代码(模型)中尝试不同的automl算法的人。
- 那些希望在不同环境中运行automl试用作业以加快搜索速度的人(例如远程服务器和云)。
- 希望实现自己的automl算法并将其与其他算法进行比较的研究人员和数据科学家。
- 希望在其平台中支持AutoML的ML平台所有者
相关项目
以开放性和先进技术为目标,Microsoft Research (MSR)也发布了少数其他开源项目。
- OpenPAI:一个开源平台,提供完整的人工智能模型训练和资源管理能力,易于扩展和支持各种规模的预置、云和混合环境。
- FrameworkController:一个开源的通用kubernetes pod控制器,它通过一个控制器在kubernetes上编排各种应用程序。
- MMdnn:一个全面的、跨框架的解决方案,用于转换、可视化和诊断深层神经网络模型。mm dnn中的“mm”代表模型管理,“dnn”是deep神经网络的缩写。 我们鼓励研究人员和学生利用这些项目来加速人工智能的开发和研究。
安装并验证
通过pip安装
- 我们现阶段支持Linux和MacOS,Ubuntu16.04或更高版本以及MacOS10.14.1都经过测试和支持。只需在具有
python >= 3.5
的环境中运行以下pip install
python3 -m pip install --upgrade nni
注意:
--user
如果要在不需要任何特殊权限的主目录中安装NNI,则可以添加。- 如果有任何类似
Segmentation fault
的错误,请参考FAQ
通过源代码安装
- 我们目前阶段支持Linux(Ubuntu16.04或更高版本)、MacOS(10.14.1)。
- 在具有
python >= 3.5
、git
和wget
的环境中运行以下命令
git clone -b v0.6 https://github.com/Microsoft/nni.git cd nni source install.sh
关于NNI的系统要求,请参考Install NNI
验证安装
下面的例子是一个基于tensorflow的实验。在运行之前,请确保已安装tensorflow。
- 通过克隆源代码下载示例
git clone -b v0.6 https://github.com/Microsoft/nni.git
- 运行mnist示例
nnictl create --config nni/examples/trials/mnist/config.yml
- 在命令行中等待消息
INFO: Successfully started experiment!
。此消息表示您的实验已成功启动。您可以使用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
-----------------------------------------------------------------------
- 打开浏览器中的
Web UI url
,您可以查看实验和所有提交的试用作业的详细信息,如下所示。Here是更多的web ui页面。
文档
如何
- Install NNI
- Use command line tool nnictl
- Use NNIBoard
- How to define search space
- How to define a trial
- How to choose tuner/search-algorithm
- Config an experiment
- How to use annotation
教程
- Run an experiment on local (with multiple GPUs)?
- Run an experiment on multiple machines?
- Run an experiment on OpenPAI?
- Run an experiment on Kubeflow?
- Try different tuners
- Try different assessors
- Implement a customized tuner
- Implement a customized assessor
- Use Genetic Algorithm to find good model architectures for Reading Comprehension task
贡献
这个项目欢迎您的贡献和建议,我们使用GitHub issues来跟踪请求和错误
使用good first issue标签的问题很简单,很容易启动,我们建议您从新的贡献者开始
要设置NNI开发环境,请参阅说明:Set up NNI developer environment
在开始编码之前,请检查并熟悉NNI代码贡献指南:Contributing
我们正在为How to Debug建设说明书,也欢迎您对此领域提出问题或建议
许可证
整个代码库位于MIT license