setup.py 2.72 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

Daniel Scheffler's avatar
Daniel Scheffler committed
8
with open('README.rst') as readme_file:
9 10 11 12 13 14
    readme = readme_file.read()

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

requirements = [
15
    'py_tools_ds>=0.10.0', 'numpy', 'matplotlib', 'six', 'gdal', 'shapely', 'geopandas', 'pandas', 'dill', 'mpld3',
Daniel Scheffler's avatar
Daniel Scheffler committed
16 17 18 19
    'geojson', 'folium', 'scikit-image', 'dask>=0.15.0'
    # dask is only indirectly needed but updating to >=0.15.0 resolves https://stackoverflow.com/questions/43833081/
    #   attributeerror-module-object-has-no-attribute-computation
    # 'holoviews', #  conda install --yes -c ioam bokeh holoviews ; \
20
    # git+https://github.com/matplotlib/basemap.git  # conda install --yes -c conda-forge basemap
21
    ]
22
setup_requirements = ['dask>=0.15.0']
Daniel Scheffler's avatar
Daniel Scheffler committed
23
test_requirements = requirements + ["coverage", "nose", "nose2", "nose-htmloutput", "rednose"]
24 25 26

setup(
    name='geoarray',
Daniel Scheffler's avatar
Fix.  
Daniel Scheffler committed
27
    version='0.7.5',
28 29 30 31
    description="Fast Python interface for geodata - either on disk or in memory.",
    long_description=readme + '\n\n' + history,
    author="Daniel Scheffler",
    author_email='danschef@gfz-potsdam.de',
32
    url='https://gitext.gfz-potsdam.de/danschef/geoarray',
33 34
    packages=find_packages(),  # searches for packages with an __init__.py and returns them as properly formatted list
    package_dir={'geoarray': 'geoarray'},
35 36 37 38
    include_package_data=True,
    install_requires=requirements,
    license="GNU General Public License v3",
    zip_safe=False,
39
    keywords=['geoarray', 'geoprocessing', 'gdal', 'numpy'],
40
    classifiers=[
41
        'Development Status :: 4 - Beta',
42 43 44
        'Intended Audience :: Developers',
        'License :: OSI Approved :: GNU General Public License v3 (GPLv3)',
        'Natural Language :: English',
45
        "Programming Language :: Python :: 2",
46
        'Programming Language :: Python :: 2.7',
47 48 49 50 51
        'Programming Language :: Python :: 3',
        'Programming Language :: Python :: 3.3',
        'Programming Language :: Python :: 3.4',
        'Programming Language :: Python :: 3.5',
        'Programming Language :: Python :: 3.6',
52 53
    ],
    test_suite='tests',
54 55
    tests_require=test_requirements,
    setup_requires=setup_requirements
56
)
57 58 59


# check for holoviews
60
if not util.find_spec('holoviews'):
61
    warnings.warn('You need to install holoviews manually (see www.holoviews.org) if you want to use interactive '
62
                  'plotting. It is not automatically installed.')
63 64

# check for basemap
65
if not util.find_spec('mpl_toolkits.basemap'):
66
    warnings.warn('You need to install basemap manually (see www./matplotlib.org/basemap) if you want to plot maps. '
67
                  'It is not automatically installed.')