chore(archai): Adds updated files.

This commit is contained in:
Gustavo Rosa 2022-05-02 21:46:13 -03:00
Родитель a705a60076
Коммит 1dab9295bf
19 изменённых файлов: 251 добавлений и 63 удалений

Просмотреть файл

@ -1,4 +1,7 @@
# Folders to be ignored when using Amulet
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.
# Folders to be ignored when using AMLT
tests/
tools/
archived/

37
.github/pull_request_template.md поставляемый Normal file
Просмотреть файл

@ -0,0 +1,37 @@
# Pull Request Template
## Description
Please include a list of changes, relevant information, context and new dependencies.
Fixes: # (issue)
## Changes
Please delete options that are not relevant.
- [ ] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (causes existing functionality to not work as expected)
- [ ] Documentation update
## Tests
Describe if additional tests have been implemented and reproduced.
**Configuration**:
* Archai version:
* Platform:
* Environment:
## Final checks:
- [ ] Follows guidelines of project
- [ ] Self-review of code
- [ ] Commented code in hard-to-understand areas
- [ ] Corresponding changes to the documentation
- [ ] Changes generate no new warnings
- [ ] Added tests to assert changes
- [ ] Unit tests pass locally with added changes
- [ ] Dependent changes have already been merged
- [ ] Checked code correction any misspellings

41
.github/workflows/build-publish-docs.yml поставляемый Normal file
Просмотреть файл

@ -0,0 +1,41 @@
name: Build and Publish Documentation
on:
push:
branches:
- master
pull_request:
branches:
- master
jobs:
build-publish:
name: Builds and publishes a Sphinx-based documentation
runs-on: ubuntu-latest
steps:
- name: Pulls the repository
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Sets up the conda environment
uses: conda-incubator/setup-miniconda@v2
with:
python-version: 3.7
activate-environment: archai
- name: Installs the requirements
shell: bash -l {0}
run: |
python -m pip install --user -e .
cd docs
python -m pip install --user -r requirements.txt
- name: Builds the documentation
shell: bash -l {0}
run: |
cd docs
make clean
make html
- name: Pushes to remote branch
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: docs/_build/html/

42
.github/workflows/build-release-pypi.yml поставляемый Normal file
Просмотреть файл

@ -0,0 +1,42 @@
name: Build and Release to PyPI
on:
push:
tags:
- "**"
jobs:
publish-pypi:
name: Publishes release candidate to PyPI
runs-on: ubuntu-latest
steps:
- name: Pulls the repository
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Sets the Environment
# Installs a Python 3.7 environment
uses: actions/setup-python@v1
with:
python-version: 3.7
- name: Installs pypa/build
# Install the `build` package for further building
run: >-
python -m
pip install
build
--user
- name: Builds the Wheel
# Runs the `build` command to create the wheel and source tarball
run: >-
python -m
build
--sdist
--wheel
--outdir dist/
.
- name: Publishes to PyPI
# Publishes the builded package to PyPI
uses: pypa/gh-action-pypi-publish@master
with:
password: ${{ secrets.PYPI_API_TOKEN }}

4
.gitignore поставляемый
Просмотреть файл

@ -33,8 +33,8 @@ wheels/
MANIFEST
# PyInstaller
# Usually these files are written by a python script from a template
# before PyInstaller builds the exe, so as to inject date/other infos into it.
# Usually these files are written by a python script from a template
# before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec

Просмотреть файл

@ -1,4 +1,4 @@
# Authors
- [Shital Shah](http://www.shitalshah.com)
- [Debadeepta Dey](https://www.debadeepta.com/)
- [Debadeepta Dey](https://www.debadeepta.com)

Просмотреть файл

@ -1,5 +1,3 @@
Archai
MIT License
Copyright (c) Microsoft Corporation.
@ -20,4 +18,4 @@
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE
SOFTWARE

Просмотреть файл

@ -1,10 +1,10 @@
NOTICES AND INFORMATION
Do Not Translate or Localize
This software incorporates material from third parties. Microsoft makes certain
open source code available at http://3rdpartysource.microsoft.com, or you may
send a check or money order for US $5.00, including the product name, the open
source component name, and version number, to:
This software incorporates material from third parties.
Microsoft makes certain open source code available at https://3rdpartysource.microsoft.com,
or you may send a check or money order for US $5.00, including the product name,
the open source component name, platform, and version number, to:
Source Code Compliance Team
Microsoft Corporation
@ -12,10 +12,10 @@ One Microsoft Way
Redmond, WA 98052
USA
Notwithstanding any other terms, you may reverse engineer this software to the
extent required to debug changes to any libraries licensed under the GNU Lesser
General Public License.
Notwithstanding any other terms, you may reverse engineer this software to the extent
required to debug changes to any libraries licensed under the GNU Lesser General Public License.
The following components are used within Archai and are presented along their license.
**Component.** https://github.com/kakaobrain/fast-autoaugment

Просмотреть файл

@ -63,7 +63,7 @@ We would love community contributions, feedback, questions, algorithm implementa
Join the Archai group on [Facebook](https://www.facebook.com/groups/1133660130366735/) to stay up to date or ask any questions.
## Team
Archai has been created and maintained by [Shital Shah](https://shitalshah.com) and [Debadeepta Dey](www.debadeepta.com) in the [Reinforcement Learning Group](https://www.microsoft.com/en-us/research/group/reinforcement-learning-redmond/) at Microsoft Research AI, Redmond, USA. Archai has benefited immensely from discussions with [John Langford](https://www.microsoft.com/en-us/research/people/jcl/), [Rich Caruana](https://www.microsoft.com/en-us/research/people/rcaruana/), [Eric Horvitz](https://www.microsoft.com/en-us/research/people/horvitz/) and [Alekh Agarwal](https://www.microsoft.com/en-us/research/people/alekha/).
Archai has been created and maintained by [Shital Shah](https://shitalshah.com), [Debadeepta Dey](www.debadeepta.com), [Gustavo de Rosa](https://www.microsoft.com/en-us/research/people/gderosa/), [Caio Cesar Teodoro Mendes]() in the [Reinforcement Learning Group](https://www.microsoft.com/en-us/research/group/reinforcement-learning-redmond/) at Microsoft Research, Redmond, USA. Archai has benefited immensely from discussions with [Ofer Dekel](https://www.microsoft.com/en-us/research/people/oferd/), [John Langford](https://www.microsoft.com/en-us/research/people/jcl/), [Rich Caruana](https://www.microsoft.com/en-us/research/people/rcaruana/), [Eric Horvitz](https://www.microsoft.com/en-us/research/people/horvitz/) and [Alekh Agarwal](https://www.microsoft.com/en-us/research/people/alekha/).
We look forward to Archai becoming more community driven and including major contributors here.

Просмотреть файл

@ -14,7 +14,7 @@ Instead, please report them to the Microsoft Security Response Center (MSRC) at
If you prefer to submit without logging in, send email to [secure@microsoft.com](mailto:secure@microsoft.com). If possible, encrypt your message with our PGP key; please download it from the [Microsoft Security Response Center PGP Key page](https://www.microsoft.com/en-us/msrc/pgp-key-msrc).
You should receive a response within 24 hours. If for some reason you do not, please follow up via email to ensure we received your original message. Additional information can be found at [microsoft.com/msrc](https://www.microsoft.com/msrc).
You should receive a response within 24 hours. If for some reason you do not, please follow up via email to ensure we received your original message. Additional information can be found at [microsoft.com/msrc](https://www.microsoft.com/msrc).
Please include the requested information listed below (as much as you can provide) to help us better understand the nature and scope of the possible issue:

Просмотреть файл

@ -1,8 +1,5 @@
# Python package
# Create and test a Python package on multiple Python versions.
# Add steps that analyze code, save the dist with the build record, publish to a PyPI-compatible index, and more:
# https://docs.microsoft.com/azure/devops/pipelines/languages/python
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.
trigger:
- master
@ -11,8 +8,6 @@ pool:
vmImage: 'windows-latest'
strategy:
matrix:
# Python36:
# python.version: '3.6'
Python37:
python.version: '3.7'

20
docs/Makefile Normal file
Просмотреть файл

@ -0,0 +1,20 @@
# Minimal makefile for Sphinx documentation
#
# You can set these variables from the command line, and also
# from the environment for the first two.
SPHINXOPTS ?=
SPHINXBUILD ?= sphinx-build
SOURCEDIR = .
BUILDDIR = _build
# Put it first so that "make" without argument is like "make help".
help:
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
.PHONY: help Makefile
# Catch-all target: route all unknown targets to Sphinx using the new
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
%: Makefile
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)

Просмотреть файл

@ -11,8 +11,7 @@
# documentation root, use os.path.abspath to make it absolute, like shown here.
#
import recommonmark
from recommonmark.transform import AutoStructify
# from recommonmark.transform import AutoStructify
import os
import sys
@ -22,7 +21,7 @@ sys.path.insert(0, os.path.abspath('../archai'))
# -- Project information -----------------------------------------------------
project = 'Archai'
copyright = '2020, Microsoft'
copyright = '2022, Microsoft'
author = ''
@ -32,8 +31,8 @@ author = ''
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
# ones.
extensions = [
'rinoh.frontend.sphinx', 'sphinx.ext.autodoc', 'sphinx.ext.todo',
'sphinx.ext.viewcode', 'recommonmark', 'sphinx_rtd_theme' #, 'sphinx.ext.autosectionlabel' #, 'm2r2'
'sphinx.ext.autodoc', 'sphinx.ext.todo',
'sphinx.ext.viewcode', 'recommonmark', 'sphinx_rtd_theme'
]
# Add any paths that contain templates here, relative to this directory.
@ -46,7 +45,7 @@ exclude_patterns = [
#'.*/',
'cifar10_models/**',
'data_aug/**',
'netowrks/**',
'networks/**',
# 'confs/',
# 'dockers/',
# 'models/',
@ -61,17 +60,16 @@ exclude_patterns = [
# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
#
import sphinx_rtd_theme
html_theme = 'sphinx_rtd_theme' # 'klink' #'bizstyle' #'alabaster'
# Add any paths that contain custom static files (such as style sheets) here,
# relative to this directory. They are copied after the builtin static files,
# so a file named "default.css" will overwrite the builtin "default.css".
html_static_path = ['_static']
# html_static_path = ['_static']
def setup(app):
app.add_config_value('recommonmark_config', {
'url_resolver': lambda url: github_doc_root + url,
'auto_toc_tree_section': 'Contents',
}, True)
app.add_transform(AutoStructify)
# def setup(app):
# app.add_config_value('recommonmark_config', {
# 'url_resolver': lambda url: github_doc_root + url,
# 'auto_toc_tree_section': 'Contents',
# }, True)
# app.add_transform(AutoStructify)

35
docs/make.bat Normal file
Просмотреть файл

@ -0,0 +1,35 @@
@ECHO OFF
pushd %~dp0
REM Command file for Sphinx documentation
if "%SPHINXBUILD%" == "" (
set SPHINXBUILD=sphinx-build
)
set SOURCEDIR=.
set BUILDDIR=_build
if "%1" == "" goto help
%SPHINXBUILD% >NUL 2>NUL
if errorlevel 9009 (
echo.
echo.The 'sphinx-build' command was not found. Make sure you have Sphinx
echo.installed, then set the SPHINXBUILD environment variable to point
echo.to the full path of the 'sphinx-build' executable. Alternatively you
echo.may add the Sphinx directory to PATH.
echo.
echo.If you don't have Sphinx installed, grab it from
echo.http://sphinx-doc.org/
exit /b 1
)
%SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%
goto end
:help
%SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%
:end
popd

3
docs/requirements.txt Normal file
Просмотреть файл

@ -0,0 +1,3 @@
recommonmark>=0.7.1
sphinx>=4.1.2
sphinx-rtd-theme>=0.5.2

Просмотреть файл

@ -1,4 +1,7 @@
REM below will be required for Python 3.7 and below if pickle wasn't updated
REM Copyright (c) Microsoft Corporation.
REM Licensed under the MIT license.
REM Below will be required for Python 3.7 and below if pickle wasn't updated
REM otherwise ray.init() fails if below is not done
REM CALL conda install -y -c conda-forge pickle5

Просмотреть файл

@ -1,9 +1,13 @@
#!/bin/bash
#fail if any errors
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.
# Fails if any errors
set -e
set -o xtrace
# below will be required for Python 3.7 and below if pickle wasn't updated
# Below will be required for Python 3.7 and below if pickle wasn't updated
# otherwise ray.init() fails if below is not done
# conda install -y -c conda-forge pickle5

2
setup.cfg Normal file
Просмотреть файл

@ -0,0 +1,2 @@
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.

Просмотреть файл

@ -1,38 +1,45 @@
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.
import setuptools
from setuptools import find_packages, setup
with open('README.md', 'r', encoding='utf_8') as fh:
with open("README.md", "r", encoding='utf_8') as fh:
long_description = fh.read()
install_requires = [
'pystopwatch2 @ git+https://github.com/ildoonet/pystopwatch2.git',
install_requires=[
'pystopwatch2',
'hyperopt',
'tensorwatch>=0.9.1', 'tensorboard',
'pretrainedmodels', 'tqdm', 'sklearn', 'matplotlib', 'psutil',
'requests', 'seaborn', 'h5py', 'rarfile',
'gorilla', 'pyyaml', 'overrides<4.0.0', 'runstats', 'psutil', 'statopt',
'pyunpack', 'patool', 'ray>=1.0.0', 'Send2Trash'
'gorilla', 'pyyaml', 'overrides==3.1.0', 'runstats', 'psutil', 'statopt',
'pyunpack', 'patool', 'ray>=1.0.0', 'Send2Trash',
'transformers', 'pytorch_lightning', 'tokenizers', 'datasets',
'ftfy', # needed for text scoring, fixes text for you
# nvidia transformer-xl
'nv_dllogger', # needed for compatibility between pip and setuptools
'pytorch-transformers', 'sacremoses', 'pynvml'
]
setuptools.setup(
name='archai',
version='0.5.2',
author='Shital Shah, Debadeepta Dey,',
author_email='shitals@microsoft.com, dedey@microsoft.com',
description='Research platform for Neural Architecture Search',
setup(
name="archai",
version="0.6.4",
description="Research platform for Neural Architecture Search",
long_description=long_description,
long_description_content_type='text/markdown',
url='https://github.com/microsoft/archai',
packages=setuptools.find_packages(),
license='MIT',
classifiers=(
'Programming Language :: Python :: 3',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Intended Audience :: Science/Research',
),
long_description_content_type="text/markdown",
author="Shital Shah, Debadeepta Dey",
author_email="shitals@microsoft.com, dedey@microsoft.com",
url="https://github.com/microsoft/archai",
license="MIT",
install_requires=install_requires,
packages=find_packages(),
include_package_data=True,
install_requires=install_requires
classifiers=[
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Developers",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: MIT License",
"Topic :: Software Development :: Libraries",
"Topic :: Software Development :: Libraries :: Python Modules",
],
)