diff --git a/.travis.yml b/.travis.yml index a817389..9477686 100644 --- a/.travis.yml +++ b/.travis.yml @@ -6,7 +6,7 @@ python: os: - linux # command to install dependencies -install: +install: - pip install -r requirements.txt - pip install --upgrade pytest - pip install --upgrade pylint diff --git a/README.md b/README.md index 1f1e55b..88e72b8 100644 --- a/README.md +++ b/README.md @@ -34,6 +34,12 @@ underlying event outcome distribution as a mixure of some fixed \( K \) parametric distributions. The parameters of these mixture distributions as well as the mixing weights are modelled using Neural Networks. + +Installation +------------ + + $ pip install git+https://github.com/autonlab/DeepSurvivalMachines.git + #### Usage Example >>> from dsm import DeepSurvivalMachines >>> model = DeepSurvivalMachines() diff --git a/requirements.txt b/requirements.txt index 36976d2..ea3254b 100644 --- a/requirements.txt +++ b/requirements.txt @@ -2,4 +2,4 @@ torch>=1.0.0 numpy>=0.14 pandas>=1.0.0 tqdm>=4.0.0 -scikit-learn>=0.18 \ No newline at end of file +scikit-learn>=0.18 diff --git a/setup.py b/setup.py new file mode 100644 index 0000000..c4e03e9 --- /dev/null +++ b/setup.py @@ -0,0 +1,46 @@ +import os + +from setuptools import setup, find_packages + + +def read(fname): + return open(os.path.join(os.path.dirname(__file__), fname)).read() + + +here = os.path.abspath(os.path.dirname(__file__)) +with open(os.path.join(here, "README.md"), encoding="utf-8") as f: + long_description = f.read() + +with open(os.path.join(here, "requirements.txt"), encoding="utf-8") as f: + all_reqs = f.read().split("\n") + +install_requires = [x.strip() for x in all_reqs] + +setup( + name="dsm", + version="0.0.1", + maintainer="Chirag Nagpal", + maintainer_email="chiragn@cs.cmu.edu", + url="https://github.com/autonlab/DeepSurvivalMachines", + description=( + "Python package dsm provides an API to train the Deep Survival Machines and associated models for problems in survival analysis." + ), + long_description=long_description, + long_description_content_type="text/markdown", + license="GPLv3+", + packages=find_packages(exclude=["tests*"]), + package_data = {'dsm': ['datasets/*']}, + keywords=["dsm"], + python_requires=">=3.6", + install_requires=install_requires, + classifiers=[ + "Development Status :: 5 - Production/Stable", + "Intended Audience :: Developers", + "Intended Audience :: Education", + "Intended Audience :: Science/Research", + "Topic :: Scientific/Engineering", + "License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)", + "Programming Language :: Python :: 3", + ], + include_package_data=True, +)