Register
Login
Resources
Docs Blog Datasets Glossary Case Studies Tutorials & Webinars
Product
Data Engine LLMs Platform Enterprise
Pricing Explore
Connect to our Discord channel

setup.py 2.9 KB

You have to be logged in to leave a comment. Sign In
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
  1. #MIT License
  2. #
  3. #Copyright (c) 2018 Dafiti OpenSource
  4. #
  5. #Permission is hereby granted, free of charge, to any person obtaining a copy
  6. #of this software and associated documentation files (the "Software"), to deal
  7. #in the Software without restriction, including without limitation the rights
  8. #to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
  9. #copies of the Software, and to permit persons to whom the Software is
  10. #furnished to do so, subject to the following conditions:
  11. #
  12. #The above copyright notice and this permission notice shall be included in all
  13. #copies or substantial portions of the Software.
  14. #
  15. #THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
  16. #IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
  17. #FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
  18. #AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
  19. #LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
  20. #OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  21. #SOFTWARE.
  22. # We used setup.py from the requests library as reference:
  23. # https://github.com/requests/requests/blob/master/setup.py
  24. import os
  25. import re
  26. import sys
  27. from codecs import open
  28. from setuptools import setup
  29. from setuptools.command.test import test as TestCommand
  30. here = os.path.abspath(os.path.dirname(__file__))
  31. if sys.argv[-1] == 'publish':
  32. os.system('python setup.py sdist bdist_wheel')
  33. os.system('twine upload dist/*')
  34. sys.exit()
  35. install_requires = [
  36. 'numpy',
  37. 'scipy',
  38. 'statsmodels>=0.9.0',
  39. 'matplotlib',
  40. 'jinja2'
  41. ]
  42. test_requires = [
  43. 'pytest',
  44. 'pytest-coverage',
  45. 'flake8',
  46. 'isort',
  47. 'tox',
  48. 'mock'
  49. ]
  50. packages = ['causalimpact']
  51. _version = {}
  52. _version_path = os.path.join(here, 'causalimpact', '__version__.py')
  53. with open(_version_path, 'r', 'utf-8') as f:
  54. exec(f.read(), _version)
  55. with open('README.md', 'r', 'utf-8') as f:
  56. readme = f.read()
  57. setup(
  58. name='pycausalimpact',
  59. version=_version['__version__'],
  60. author='Willian Fuks',
  61. author_email='willian.fuks@gmail.com',
  62. url='https://github.com/dafiti/causalimpact',
  63. description= "Python version of Google's Causal Impact model",
  64. long_description=readme,
  65. long_description_content_type='text/markdown',
  66. packages=packages,
  67. include_package_data=True,
  68. install_requires=install_requires,
  69. test_requires=test_requires,
  70. license='MIT',
  71. classifiers=[
  72. 'Development Status :: 4 - Beta',
  73. 'Environment :: Console',
  74. 'Intended Audience :: Developers',
  75. 'Intended Audience :: Science/Research',
  76. 'License :: OSI Approved :: MIT License',
  77. 'Natural Language :: English',
  78. 'Operating System :: Unix',
  79. 'Programming Language :: Python :: 3',
  80. 'Programming Language :: Python :: Implementation :: CPython',
  81. 'Topic :: Scientific/Engineering',
  82. ]
  83. )
Tip!

Press p or to see the previous file or, n or to see the next file

Comments

Loading...