2018-11-19 13:29:47 -08:00
|
|
|
# Copyright 2018 Google LLC
|
|
|
|
#
|
|
|
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
|
|
# you may not use this file except in compliance with the License.
|
|
|
|
# You may obtain a copy of the License at
|
|
|
|
#
|
|
|
|
# https://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
#
|
|
|
|
# Unless required by applicable law or agreed to in writing, software
|
|
|
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
|
# See the License for the specific language governing permissions and
|
|
|
|
# limitations under the License.
|
|
|
|
|
2018-12-11 15:45:56 -08:00
|
|
|
from setuptools import setup, find_packages
|
2019-02-13 20:02:14 -08:00
|
|
|
|
2021-03-17 10:46:38 -07:00
|
|
|
# The following should be updated with each new jaxlib release.
|
2021-05-17 17:48:46 -07:00
|
|
|
_current_jaxlib_version = '0.1.67'
|
|
|
|
_available_cuda_versions = ['101', '102', '110', '111']
|
2019-08-04 12:12:53 -04:00
|
|
|
|
2021-03-17 10:46:38 -07:00
|
|
|
_dct = {}
|
2019-02-13 20:02:14 -08:00
|
|
|
with open('jax/version.py') as f:
|
2021-03-17 10:46:38 -07:00
|
|
|
exec(f.read(), _dct)
|
|
|
|
__version__ = _dct['__version__']
|
|
|
|
_minimum_jaxlib_version = _dct['_minimum_jaxlib_version']
|
2018-11-18 15:17:32 -08:00
|
|
|
|
|
|
|
setup(
|
|
|
|
name='jax',
|
2019-02-13 20:02:14 -08:00
|
|
|
version=__version__,
|
2018-11-18 15:17:32 -08:00
|
|
|
description='Differentiate, compile, and transform Numpy code.',
|
|
|
|
author='JAX team',
|
2018-12-06 21:35:03 -05:00
|
|
|
author_email='jax-dev@google.com',
|
2019-04-06 14:16:22 -07:00
|
|
|
packages=find_packages(exclude=["examples"]),
|
2021-01-14 15:08:53 -05:00
|
|
|
package_data={'jax': ['py.typed']},
|
2020-03-18 10:54:28 -04:00
|
|
|
python_requires='>=3.6',
|
2019-01-15 20:14:19 -05:00
|
|
|
install_requires=[
|
2021-06-10 12:12:13 -04:00
|
|
|
'numpy>=1.17',
|
2020-12-30 11:29:34 +00:00
|
|
|
'absl-py',
|
|
|
|
'opt_einsum',
|
2019-01-15 20:14:19 -05:00
|
|
|
],
|
2021-03-16 11:40:46 -07:00
|
|
|
extras_require={
|
2021-03-17 10:46:38 -07:00
|
|
|
# Minimum jaxlib version; used in testing.
|
|
|
|
'minimum-jaxlib': [f'jaxlib=={_minimum_jaxlib_version}'],
|
|
|
|
|
2021-03-16 11:40:46 -07:00
|
|
|
# CPU-only jaxlib can be installed via:
|
|
|
|
# $ pip install jax[cpu]
|
|
|
|
'cpu': [f'jaxlib>={_minimum_jaxlib_version}'],
|
|
|
|
|
|
|
|
# CUDA installations require adding jax releases URL; e.g.
|
2021-04-26 09:22:52 -07:00
|
|
|
# $ pip install jax[cuda110] -f https://storage.googleapis.com/jax-releases/jax_releases.html
|
|
|
|
**{f'cuda{version}': f"jaxlib=={_current_jaxlib_version}+cuda{version}"
|
2021-03-16 11:40:46 -07:00
|
|
|
for version in _available_cuda_versions}
|
|
|
|
},
|
2018-11-18 15:17:32 -08:00
|
|
|
url='https://github.com/google/jax',
|
|
|
|
license='Apache-2.0',
|
2020-12-30 11:29:34 +00:00
|
|
|
classifiers=[
|
|
|
|
"Programming Language :: Python :: 3.6",
|
|
|
|
"Programming Language :: Python :: 3.7",
|
2020-12-30 13:20:13 -08:00
|
|
|
"Programming Language :: Python :: 3.8",
|
2021-06-10 16:06:11 +02:00
|
|
|
],
|
|
|
|
zip_safe=False,
|
2018-11-18 15:17:32 -08:00
|
|
|
)
|