diff --git a/pyproject.toml b/pyproject.toml new file mode 100644 index 0000000000..8fe2f47af9 --- /dev/null +++ b/pyproject.toml @@ -0,0 +1,3 @@ +[build-system] +requires = ["setuptools>=42", "wheel"] +build-backend = "setuptools.build_meta" diff --git a/setup.cfg b/setup.cfg new file mode 100644 index 0000000000..b3a639a384 --- /dev/null +++ b/setup.cfg @@ -0,0 +1,97 @@ +[metadata] +url = https://github.com/microsoft/FLAML +maintainer = Microsoft Corporation +maintainer_email = hpo@microsoft.com +name = FLAML +version = attr: flaml.version.__version__ +description = A fast library for automated machine learning and tuning +long_description = file:README.md +long_description_content_type = text/markdown; charset=UTF-8 +license = MIT +classifiers = + Programming Language :: Python :: 3 + License :: OSI Approved :: MIT License + Operating System :: OS Independent + +[options] +python_requires = >= 3.7 +install_requires = + numpy >= 1.17.0rc1 + lightgbm >= 2.3.1 + xgboost >= 0.90 + scipy >= 1.4.1 + pandas >= 1.1.4 + scikit-learn >= 0.24 +packages = find: +include_package_data = True + +[options.packages.find] +include = + flaml* + +[options.package_data] +flaml.default = + */*.json + +[options.extras_require] +notebook = + openml == 0.10.2 + jupyter + matplotlib + rgf-python + catboost >= 0.26 +test = + flake8 >= 3.8.4 + pytest >= 6.1.1 + coverage >= 5.3 + pre-commit + catboost >= 0.26 + rgf-python + optuna == 2.8.0 + vowpalwabbit + openml + statsmodels >= 0.12.2 + psutil == 5.8.0 + dataclasses + transformers >= 4.14 + datasets + torch + nltk + rouge_score + hcrystalball == 0.1.10 + seqeval + protobuf < 4 # to prevent TypeError in ray +catboost = + catboost >= 0.26 +blendsearch = + optuna == 2.8.0 +ray = + ray[tune] ~= 1.10 + protobuf < 4 # to prevent TypeError in ray +azureml = + azureml-mlflow +nni = + nni +vw = + vowpalwabbit +nlp = + transformers >= 4.14 + datasets + torch + seqeval + nltk + rouge_score +ts_forecast = + holidays < 0.14 # to prevent installation error for prophet + prophet >= 1.0.1 + statsmodels >= 0.12.2 + hcrystalball == 0.1.10 +forecast = + holidays < 0.14 # to prevent installation error for prophet + prophet >= 1.0.1 + statsmodels >= 0.12.2 + hcrystalball == 0.1.10 +benchmark = + catboost >= 0.26 + psutil == 5.8.0 + xgboost == 1.3.3 \ No newline at end of file diff --git a/setup.py b/setup.py deleted file mode 100644 index de126ca073..0000000000 --- a/setup.py +++ /dev/null @@ -1,114 +0,0 @@ -import setuptools -import os - -here = os.path.abspath(os.path.dirname(__file__)) - -with open("README.md", "r", encoding="UTF-8") as fh: - long_description = fh.read() - - -# Get the code version -version = {} -with open(os.path.join(here, "flaml/version.py")) as fp: - exec(fp.read(), version) -__version__ = version["__version__"] - -install_requires = [ - "NumPy>=1.17.0rc1", - "lightgbm>=2.3.1", - "xgboost>=0.90", - "scipy>=1.4.1", - "pandas>=1.1.4", - "scikit-learn>=0.24", -] - - -setuptools.setup( - name="FLAML", - version=__version__, - author="Microsoft Corporation", - author_email="hpo@microsoft.com", - description="A fast library for automated machine learning and tuning", - long_description=long_description, - long_description_content_type="text/markdown", - url="https://github.com/microsoft/FLAML", - packages=setuptools.find_packages(include=["flaml*"]), - package_data={ - "flaml.default": ["*/*.json"], - }, - include_package_data=True, - install_requires=install_requires, - extras_require={ - "notebook": [ - "openml==0.10.2", - "jupyter", - "matplotlib", - "rgf-python", - "catboost>=0.26", - ], - "test": [ - "flake8>=3.8.4", - "pytest>=6.1.1", - "coverage>=5.3", - "pre-commit", - "catboost>=0.26", - "rgf-python", - "optuna==2.8.0", - "vowpalwabbit", - "openml", - "statsmodels>=0.12.2", - "psutil==5.8.0", - "dataclasses", - "transformers>=4.14", - "datasets", - "torch", - "nltk", - "rouge_score", - "hcrystalball==0.1.10", - "seqeval", - "protobuf<4", # to prevent TypeError in ray - ], - "catboost": ["catboost>=0.26"], - "blendsearch": ["optuna==2.8.0"], - "ray": [ - "ray[tune]~=1.10", - "protobuf<4", # to prevent TypeError in ray - ], - "azureml": [ - "azureml-mlflow", - ], - "nni": [ - "nni", - ], - "vw": [ - "vowpalwabbit", - ], - "nlp": [ - "transformers>=4.14", - "datasets", - "torch", - "seqeval", - "nltk", - "rouge_score", - ], - "ts_forecast": [ - "holidays<0.14", # to prevent installation error for prophet - "prophet>=1.0.1", - "statsmodels>=0.12.2", - "hcrystalball==0.1.10", - ], - "forecast": [ - "holidays<0.14", # to prevent installation error for prophet - "prophet>=1.0.1", - "statsmodels>=0.12.2", - "hcrystalball==0.1.10", - ], - "benchmark": ["catboost>=0.26", "psutil==5.8.0", "xgboost==1.3.3"], - }, - classifiers=[ - "Programming Language :: Python :: 3", - "License :: OSI Approved :: MIT License", - "Operating System :: OS Independent", - ], - python_requires=">=3.7", -) diff --git a/website/docs/Contribute.md b/website/docs/Contribute.md index 579a04609b..241fc36590 100644 --- a/website/docs/Contribute.md +++ b/website/docs/Contribute.md @@ -16,7 +16,7 @@ Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit . -If you are new to GitHub [here](https://help.github.com/categories/collaborating-with-issues-and-pull-requests/) is a detailed help source on getting involved with development on GitHub. +If you are new to GitHub, [here](https://help.github.com/categories/collaborating-with-issues-and-pull-requests/) is a detailed help source on getting involved with development on GitHub. When you submit a pull request, a CLA bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., status check, comment). Simply follow the instructions @@ -35,6 +35,7 @@ There is currently no formal reviewer solicitation process. Current reviewers id ### Setup ```bash +pip install -U pip git clone https://github.com/microsoft/FLAML.git pip install -e FLAML[test,notebook] ```