代码拉取完成,页面将自动刷新
同步操作将从 mirrors_RJT1990/pyflux 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
import io
import os
import re
import sys
import subprocess
# Use of SETUP built-in adapted from scikit-learn's setup structure.
if sys.version_info[0] < 3:
import __builtin__ as builtins
else:
import builtins
builtins.__PYFLUX_SETUP__ = True
PACKAGE_NAME = 'pyflux'
DESCRIPTION = "PyFlux: A time-series analysis library for Python"
LONG_DESCRIPTION = DESCRIPTION
AUTHOR = "Ross Taylor"
AUTHOR_EMAIL = "rj-taylor@live.co.uk"
URL = 'https://github.com/rjt1990/pyflux'
DOWNLOAD_URL = 'https://github.com/rjt1990/pyflux/tarball/0.4.17'
LICENSE = 'BSD'
def version(package, encoding='utf-8'):
"""Obtain the packge version from a python file e.g. pkg/__init__.py
See <https://packaging.python.org/en/latest/single_source_version.html>.
"""
path = os.path.join(os.path.dirname(__file__), package, '__init__.py')
with io.open(path, encoding=encoding) as fp:
version_info = fp.read()
version_match = re.search(r"""^__version__ = ['"]([^'"]*)['"]""",
version_info, re.M)
if not version_match:
raise RuntimeError("Unable to find version string.")
return version_match.group(1)
def generate_cython(package):
"""Cythonize all sources in the package"""
cwd = os.path.abspath(os.path.dirname(__file__))
print("Cythonizing sources")
p = subprocess.call([sys.executable,
os.path.join(cwd, 'tools', 'cythonize.py'),
package],
cwd=cwd)
if p != 0:
raise RuntimeError("Running cythonize failed!")
def configuration(parent_package='',top_path=None):
from numpy.distutils.misc_util import Configuration
config = Configuration(None, parent_package, top_path)
config.set_options(ignore_setup_xxx_py=True,
assume_default_configuration=True,
delegate_options_to_subpackages=True,
quiet=True)
config.add_subpackage(PACKAGE_NAME)
return config
def setup_package():
from numpy.distutils.core import setup
old_path = os.getcwd()
local_path = os.path.dirname(os.path.abspath(sys.argv[0]))
src_path = local_path
os.chdir(local_path)
sys.path.insert(0, local_path)
# Run build
old_path = os.getcwd()
os.chdir(src_path)
sys.path.insert(0, src_path)
cwd = os.path.abspath(os.path.dirname(__file__))
if not os.path.exists(os.path.join(cwd, 'PKG-INFO')):
# Generate Cython sources, unless building from source release
generate_cython(PACKAGE_NAME)
try:
setup(name=PACKAGE_NAME,
author=AUTHOR,
author_email=AUTHOR_EMAIL,
url=URL,
download_url=DOWNLOAD_URL,
description=DESCRIPTION,
long_description = LONG_DESCRIPTION,
version=version(PACKAGE_NAME),
license=LICENSE,
configuration=configuration,
keywords = ['time series','machine learning','bayesian statistics'],
install_requires=['numpy', 'pandas', 'scipy', 'numdifftools','patsy'])
finally:
del sys.path[0]
os.chdir(old_path)
return
if __name__ == '__main__':
setup_package()
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。