forked from pytorch/botorch
-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.py
executable file
·68 lines (56 loc) · 1.97 KB
/
setup.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
#!/usr/bin/env python3
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
import os
import re
import sys
from setuptools import find_packages, setup
REQUIRED_MAJOR = 3
REQUIRED_MINOR = 6
# Check for python version
if sys.version_info < (REQUIRED_MAJOR, REQUIRED_MINOR):
error = (
"Your version of python ({major}.{minor}) is too old. You need "
"python >= {required_major}.{required_minor}."
).format(
major=sys.version_info.major,
minor=sys.version_info.minor,
required_minor=REQUIRED_MINOR,
required_major=REQUIRED_MAJOR,
)
sys.exit(error)
TEST_REQUIRES = ["pytest", "pytest-cov"]
DEV_REQUIRES = TEST_REQUIRES + ["black", "flake8", "sphinx", "sphinx-autodoc-typehints"]
TUTORIALS_REQUIRES = ["jupyter", "matplotlib", "cma", "torchvision"]
# get version string from module
with open(os.path.join(os.path.dirname(__file__), "botorch/__init__.py"), "r") as f:
version = re.search(r"__version__ = ['\"]([^'\"]*)['\"]", f.read(), re.M).group(1)
setup(
name="botorch",
version=version,
description="Bayesian Optimization in PyTorch",
author="Facebook, Inc.",
license="MIT",
url="https://botorch.org",
project_urls={
"Documentation": "https://botorch.org",
"Source": "https://github.com/pytorch/botorch",
"conda": "https://anaconda.org/pytorch/botorch",
},
keywords=["Bayesian optimization", "PyTorch"],
classifiers=[
"Development Status :: 4 - Beta",
"Programming Language :: Python :: 3 :: Only",
"License :: OSI Approved :: MIT License",
"Topic :: Scientific/Engineering",
"Intended Audience :: Science/Research",
"Intended Audience :: Developers",
],
python_requires=">=3.6",
install_requires=["torch>=1.1", "gpytorch>=0.3.2", "scipy"],
packages=find_packages(),
extras_require={
"dev": DEV_REQUIRES,
"test": TEST_REQUIRES,
"tutorials": TUTORIALS_REQUIRES,
},
)