setup.py 1.27 KB
Newer Older
Hannes Diedrich's avatar
Hannes Diedrich committed
1
from setuptools import setup, find_packages
Hannes Diedrich's avatar
Hannes Diedrich committed
2
from importlib import util
Hannes Diedrich's avatar
Hannes Diedrich committed
3

4
requirements = ["proj", "numpy", "imageio", "scipy", "netCDF4", "requests", "scikit-image", "gdal"]
Hannes Diedrich's avatar
Hannes Diedrich committed
5
other_requirements = ["gdal"]
Hannes Diedrich's avatar
Hannes Diedrich committed
6
test_requirements = requirements + ["coverage"]
Hannes Diedrich's avatar
Hannes Diedrich committed
7

Hannes Diedrich's avatar
Hannes Diedrich committed
8 9 10 11 12 13 14 15 16 17 18
# test for packages that do not install well with pip
not_installed = []
for pi in other_requirements:
    is_installed = util.find_spec(pi)
    if is_installed is None:
        not_installed.append(pi)
if not_installed != []:
    raise ModuleNotFoundError(
        "Could not find the following packages (please use different installer, e.g. conda): %s" % (
            ', '.join(not_installed)))

19
setup(name='gts2_client',
20
      version='1.1.1',
Hannes Diedrich's avatar
Hannes Diedrich committed
21
      packages=find_packages(exclude=['tests*']),
Hannes Diedrich's avatar
Hannes Diedrich committed
22
      url='https://gitext.gfz-potsdam.de/gts2/gts2_client.git',
Hannes Diedrich's avatar
Hannes Diedrich committed
23
      license='GNU LESSER GENERAL PUBLIC LICENSE - Version 3, 29 June 2007',
24
      author='Hannes Diedrich, Niklas Bohn, Andre Hollstein',
Hannes Diedrich's avatar
Hannes Diedrich committed
25 26
      author_email='hannes.diedrich@gfz-potsdam.de',
      description='Downloads Sentinel-2 data from GTS2 cloud',
27 28 29 30 31
      entry_points={
        'console_scripts': [
            'gts2_client = gts2_client.gts2_client:main'
        ],
      },
Hannes Diedrich's avatar
Hannes Diedrich committed
32 33
      install_requires=requirements,
      test_suite='tests',
Hannes Diedrich's avatar
Hannes Diedrich committed
34
      tests_require=test_requirements
Hannes Diedrich's avatar
Hannes Diedrich committed
35
      )