setup.py 3.02 KB
Newer Older
1
2
3
#!/usr/bin/env python
# -*- coding: utf-8 -*-

4
from setuptools import setup, find_packages
5
import warnings
6
from importlib import util
7
8
9
10
11
12
13
14

with open('README.rst') as readme_file:
    readme = readme_file.read()

with open('HISTORY.rst') as history_file:
    history = history_file.read()

requirements = [
15
16
    'matplotlib', 'numpy', 'scikit-learn', 'scipy', 'gdal', 'pyproj', 'shapely', 'ephem', 'pyorbital', 'dill', 'pytz',
    'pandas', 'numba', 'spectral>=0.16', 'geopandas', 'iso8601', 'pyinstrument', 'geoalchemy2', 'sqlalchemy',
17
    'psycopg2', 'py_tools_ds>=0.9.1', 'geoarray>=0.6.12', 'arosics>0.6.2', 'six'
Daniel Scheffler's avatar
Daniel Scheffler committed
18
    # spectral<0.16  has some problems with writing signed integer 8bit data
19
    # fmask # conda install -c conda-forge python-fmask
20
21
    # 'pyhdf', # conda install --yes -c conda-forge pyhdf
    # 'sicor', # pip install git+https://gitext.gfz-potsdam.de/hollstei/sicor.git
22
]
23
24
setup_requirements = []  # TODO(danschef): put setup requirements (distutils extensions, etc.) here
test_requirements = requirements + ['coverage', 'nose', 'nose-htmloutput', 'rednose']
25
26

setup(
27
    name='gms_preprocessing',
Daniel Scheffler's avatar
Daniel Scheffler committed
28
    version='0.9.1',
29
30
31
32
    description="GeoMultiSens - Scalable Multi-Sensor Analysis of Remote Sensing Data",
    long_description=readme + '\n\n' + history,
    author="Daniel Scheffler",
    author_email='daniel.scheffler@gfz-potsdam.de',
33
    url='https://gitext.gfz-potsdam.de/geomultisens/gms_preprocessing',
34
35
    packages=find_packages(),  # searches for packages with an __init__.py and returns them as properly formatted list
    package_dir={'gms_preprocessing': 'gms_preprocessing'},
36
    package_data={"database": ["gms_preprocessing/database/*"]},
37
38
    include_package_data=True,
    install_requires=requirements,
Daniel Scheffler's avatar
Daniel Scheffler committed
39
    scripts=["bin/run_gms.py", "bin/run_gms.sh"],
40
41
    license="GNU General Public License v3",
    zip_safe=False,
42
    keywords='gms_preprocessing',
43
    classifiers=[
Daniel Scheffler's avatar
Daniel Scheffler committed
44
        'Development Status :: 4 - Beta',
45
46
47
        'Intended Audience :: Developers',
        'License :: OSI Approved :: GNU General Public License v3 (GPLv3)',
        'Natural Language :: English',
48
        "Programming Language :: Python :: 2",
49
        'Programming Language :: Python :: 2.7',
50
51
52
53
54
        'Programming Language :: Python :: 3',
        'Programming Language :: Python :: 3.3',
        'Programming Language :: Python :: 3.4',
        'Programming Language :: Python :: 3.5',
        'Programming Language :: Python :: 3.6',
55
56
57
58
    ],
    test_suite='tests',
    tests_require=test_requirements
)
59
60
61


# check for pyhdf
62
if not util.find_spec('pyhdf'):
63
64
    warnings.warn('If you have not compiled GDAL with HDF4 support you need to install pyhdf manually '
                  '(see http://pysclint.sourceforge.net/pyhdf/install.html) for processing Terra ASTER data.'
65
                  'It is not automatically installed.')
66
67

# check for fmask
68
if not util.find_spec('fmask'):
69
70
    warnings.warn("FMask library is missing. If you want to compute cloud masks via FMask, you have to install it "
                  "manually (e.g., by running 'conda install -c conda-forge python-fmask').")