You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

setup.py 2.8 kB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. try:
  2. import torch
  3. except ModuleNotFoundError:
  4. raise ModuleNotFoundError(
  5. "PyTorch not installed. "
  6. "Please appropriately install PyTorch, "
  7. "see https://pytorch.org/ for installation."
  8. )
  9. try:
  10. import torch_scatter
  11. import torch_sparse
  12. import torch_geometric
  13. PYG_VER = torch_geometric.__version__.split('.')
  14. PYG_VER = [int(PYG_VER[0]), int(PYG_VER[1])]
  15. assert PYG_VER >= [1, 7], "PyTorch-Geometric version should be at least 1.7.0"
  16. except ModuleNotFoundError:
  17. raise ModuleNotFoundError(
  18. "PyTorch-Geometric not fully installed. "
  19. "Please appropriately install PyTorch-Geometric, "
  20. "see https://pytorch-geometric.readthedocs.io/en/latest/notes/installation.html for installation."
  21. )
  22. if torch.__version__.startswith('1.8.'):
  23. try:
  24. import torch_cluster
  25. import torch_spline_conv
  26. except ModuleNotFoundError:
  27. raise ModuleNotFoundError(
  28. "PyTorch-Geometric not fully installed. "
  29. "For PyTorch version 1.8.x, you should also install torch_cluster and torch_spline_conv "
  30. "see https://pytorch-geometric.readthedocs.io/en/latest/notes/installation.html for installation."
  31. )
  32. from setuptools import setup, find_packages
  33. with open("README.md", 'r') as fh:
  34. long_description = fh.read()
  35. ''' https://packaging.python.org/guides/distributing-packages-using-setuptools/ '''
  36. ''' https://setuptools.readthedocs.io/en/latest/ '''
  37. setup(
  38. name='autogl',
  39. version='0.2.0-pre',
  40. author='THUMNLab/aglteam',
  41. maintainer='THUMNLab/aglteam',
  42. author_email='autogl@tsinghua.edu.cn',
  43. description='AutoML tools for graph-structure dataset',
  44. long_description=long_description,
  45. long_description_content_type='text/markdown',
  46. include_package_data=True,
  47. packages=find_packages(),
  48. # https://packaging.python.org/guides/distributing-packages-using-setuptools/#python-requires
  49. python_requires='~=3.6',
  50. # https://pypi.org/classifiers/
  51. classifiers=[
  52. "Development Status :: 4 - Beta",
  53. "License :: OSI Approved :: Apache Software License",
  54. "Programming Language :: Python :: 3 :: Only",
  55. "Programming Language :: Python :: 3.6"
  56. ],
  57. # https://setuptools.readthedocs.io/en/latest/userguide/dependency_management.html
  58. # note that setup_requires and tests_require are deprecated
  59. install_requires=[
  60. 'bayesian-optimization',
  61. 'chocolate',
  62. 'dill',
  63. 'hyperopt',
  64. 'lightgbm',
  65. 'networkx',
  66. 'numpy',
  67. 'netlsd',
  68. 'ogb',
  69. 'psutil',
  70. 'pyyaml',
  71. 'requests',
  72. 'scikit-learn',
  73. 'scipy',
  74. 'tabulate',
  75. 'torch',
  76. 'torch-geometric',
  77. 'torch-scatter',
  78. 'torch-sparse',
  79. 'tqdm',
  80. 'nni'
  81. ]
  82. )