-
Notifications
You must be signed in to change notification settings - Fork 214
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Doc] Fix the guidance of installation and setup (#192)
- Loading branch information
1 parent
5c33855
commit c0b49c9
Showing
6 changed files
with
186 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
repos: | ||
- repo: https://github.com/pre-commit/pre-commit-hooks | ||
rev: v4.3.0 | ||
hooks: | ||
- id: check-yaml | ||
exclude: | | ||
(?x)^( | ||
meta.yaml | ||
)$ | ||
- repo: https://github.com/pre-commit/mirrors-yapf | ||
rev: v0.32.0 | ||
hooks: | ||
- id: yapf | ||
- repo: https://github.com/PyCQA/flake8 | ||
rev: 4.0.1 | ||
hooks: | ||
- id: flake8 | ||
- repo: https://github.com/pycqa/isort | ||
rev: 5.10.1 | ||
hooks: | ||
- id: isort | ||
- repo: https://github.com/regebro/pyroma | ||
rev: "4.0" | ||
hooks: | ||
- id: pyroma | ||
args: [--min=9, .] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
set -e | ||
|
||
# Graph | ||
conda install -y pyg==2.0.4 -c pyg | ||
conda install -y rdkit=2021.09.4=py39hccf6a74_0 -c conda-forge | ||
conda install -y nltk | ||
|
||
# Speech and NLP | ||
conda install -y sentencepiece textgrid typeguard -c conda-forge | ||
conda install -y transformers==4.16.2 tokenizers==0.10.3 datasets -c huggingface -c conda-forge | ||
conda install -y torchtext -c pytorch | ||
|
||
conda clean -a -y |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
{% set name = "federatedscope" %} | ||
{% set version = "0.1.9" %} | ||
|
||
package: | ||
name: {{ name|lower }} | ||
version: {{ version }} | ||
|
||
source: | ||
url: https://pypi.io/packages/source/{{ name[0] }}/{{ name }}/federatedscope-{{ version }}.tar.gz | ||
sha256: f7802afa41b7edc34adb3128fbadd18ceb2a92521384e57b9d7cbb9aae894ea6 | ||
|
||
build: | ||
noarch: python | ||
script: {{ PYTHON }} -m pip install . -vv | ||
number: 0 | ||
|
||
requirements: | ||
host: | ||
- pip | ||
- python >=3.9 | ||
run: | ||
- fvcore | ||
- grpcio >=1.45.0 | ||
- grpcio-tools | ||
- iopath | ||
- numpy <1.23.0 | ||
- pandas | ||
- protobuf ==3.19.4 | ||
- pympler | ||
- python >=3.9 | ||
- pyyaml >=5.1 | ||
- scikit-learn >=1.0.2 | ||
- scipy ==1.7.3 | ||
- tensorboard | ||
- tensorboardx | ||
- wandb | ||
|
||
test: | ||
imports: | ||
- federatedscope | ||
commands: | ||
- pip check | ||
requires: | ||
- pip | ||
|
||
about: | ||
home: https://github.com/alibaba/FederatedScope | ||
summary: Federated learning package | ||
license: Apache-2.0 | ||
license_file: LICENSE | ||
|
||
extra: | ||
recipe-maintainers: | ||
- rayrayraykk |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,37 +1,62 @@ | ||
from __future__ import absolute_import | ||
from __future__ import print_function | ||
from __future__ import division | ||
from __future__ import absolute_import, division, print_function | ||
|
||
import setuptools | ||
|
||
__name__ = 'federatedscope' | ||
__version__ = '0.1.9' | ||
URL = 'https://github.com/alibaba/FederatedScope' | ||
|
||
minimal_requires = [ | ||
'numpy<1.23.0', 'scikit-learn==1.0.2', 'scipy==1.7.3', 'pandas', | ||
'grpcio>=1.45.0', 'grpcio-tools', 'pyyaml>=5.1', 'fvcore', 'iopath', | ||
'wandb', 'tensorboard', 'tensorboardX', 'pympler', 'protobuf==3.19.4' | ||
] | ||
|
||
test_requires = [] | ||
|
||
dev_requires = test_requires + ['pre-commit'] | ||
|
||
benchmark_hpo_requires = [ | ||
'configspace==0.5.0', 'hpbandster==0.7.4', 'smac==1.3.3', 'optuna==2.10.0' | ||
] | ||
|
||
# TODO: add requirements for pfl | ||
benchmark_pfl_requires = [] | ||
|
||
# TODO: add requirements for htl | ||
benchmark_htl_requires = [] | ||
|
||
with open("README.md", "r") as fh: | ||
long_description = fh.read() | ||
|
||
setuptools.setup( | ||
name="federatedscope", | ||
version="0.1.0", | ||
name=__name__, | ||
version=__version__, | ||
author="Alibaba Damo Academy", | ||
author_email="", | ||
author_email="[email protected]", | ||
description="Federated learning package", | ||
long_description=long_description, | ||
long_description_content_type="text/markdown", | ||
url="", | ||
url=URL, | ||
download_url=f'{URL}/archive/{__version__}.tar.gz', | ||
keywords=['deep-learning', 'federated-learning', 'benchmark'], | ||
packages=[ | ||
package for package in setuptools.find_packages() | ||
if package.startswith('federatedscope') | ||
], | ||
install_requires=[ | ||
'torch', 'networkx', 'numpy', 'grpcio>=1.45.0', 'grpcio-tools' | ||
if package.startswith(__name__) | ||
], | ||
setup_requires=[], | ||
extras_require={'yaml': ['yaml>=5.1']}, | ||
install_requires=minimal_requires, | ||
extras_require={ | ||
'test': test_requires, | ||
'dev': dev_requires, | ||
'benchmark_hpo': benchmark_hpo_requires, | ||
'benchmark_pfl': benchmark_pfl_requires, | ||
'benchmark_htl': benchmark_htl_requires, | ||
}, | ||
license="Apache License 2.0", | ||
classifiers=[ | ||
"Programming Language :: Python :: 3", | ||
"License :: OSI Approved :: Apache Software License", | ||
"Operating System :: OS Independent", | ||
], | ||
test_suite='nose.collector', | ||
test_require=['nose'], | ||
python_requires='>=3.9', | ||
) |