{ "info": { "author": "Charles Shenton", "author_email": "charlieshenton@me.com", "bugtrack_url": null, "classifiers": [ "Intended Audience :: Developers", "License :: OSI Approved :: Apache Software License", "Natural Language :: English", "Programming Language :: Python :: 2", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.5", "Programming Language :: Python :: 3.6" ], "description": "# Seer Python Client\n[![Build Status](https://travis-ci.org/cshenton/seer-python.svg?branch=master)](https://travis-ci.org/cshenton/seer-python)\n[![Python Version](https://img.shields.io/pypi/pyversions/seer.svg)](https://pypi.org/project/seer/)\n\nThe python client for the seer forecasting server.\n\n\n## Installation\n\nThe seer python client is available on PyPi, so just `pip install seer` to get the latest release.\n\n\n## Usage\n\nIf you don't have a running instance of seer, then run the docker image:\n```bash\ndocker run -d -p 8080:8080 cshenton/seer\n```\n\nThen, to interact over localhost\n```python\nimport datetime\nimport seer\n\n# Input data, parameters\nhost = \"localhost:8080\"\nname = \"myStream\"\nperiod = 3600\ntimes = [...]\nvalues = [...]\nforecast_length = 100\n\n# Connect to the server and create a stream\nclient = seer.Client(host)\nclient.create_stream(name, period)\n\n# Feed in most of the data, generate a forecast\nclient.update_stream(name, times, values)\nf = client.get_forecast(name, forecast_length)\n\n# Graph the forecast against the true result\ndef graph(times, values, forecast):\n pass\n\ngraph(times, values, f)\n```\n\n## (For Contributors) Generating gRPC stubs\n\nAssuming this repo is stored in `cshenton/seer-python`, next to `cshenton/seer`,\nwe generate client stubs with:\n\n```bash\n# Generates seer_pb2.py and seer_pb2_grpc.py\npython -m grpc_tools.protoc -I ../seer/seer --python_out=./seer --grpc_python_out=./seer ../seer/seer/seer.proto\n```\n\nThen, because the grpc devs don't care about python 3, we need to fix the relative imports.\n```python\n# in seer_pb2_grpc.py\n# From this\nimport seer_pb2 as seer__pb2\n\n# To this\nfrom . import seer_pb2 as seer__pb2\n```", "description_content_type": null, "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/cshenton/seer-python", "keywords": "", "license": "Apache 2.0", "maintainer": "", "maintainer_email": "", "name": "seer", "package_url": "https://pypi.org/project/seer/", "platform": "MacOS X", "project_url": "https://pypi.org/project/seer/", "project_urls": { "Homepage": "https://github.com/cshenton/seer-python" }, "release_url": "https://pypi.org/project/seer/0.1.1/", "requires_dist": null, "requires_python": ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*", "summary": "Python client for cshenton/seer", "version": "0.1.1" }, "last_serial": 3667613, "releases": { "0.1": [ { "comment_text": "", "digests": { "md5": "acda05c110f58a350e002c760a30c766", "sha256": "a85c6f2a5a15865082f81a41663510857f373a84991c07b3e60f83aa69652bd5" }, "downloads": -1, "filename": "seer-0.1.tar.gz", "has_sig": false, "md5_digest": "acda05c110f58a350e002c760a30c766", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6165, "upload_time": "2018-03-14T05:32:12", "url": "https://files.pythonhosted.org/packages/00/82/330a7a2bc365e3d47b4eba4be4bc18776bd925da15e064d95fbf1c7072b7/seer-0.1.tar.gz" } ], "0.1.1": [ { "comment_text": "", "digests": { "md5": "a215dad344b05b55c17c507fbdccbd0e", "sha256": "0584ee7be2e51cb6538be89b1c0cb808695980386d857157166c81f79b05c744" }, "downloads": -1, "filename": "seer-0.1.1.tar.gz", "has_sig": false, "md5_digest": "a215dad344b05b55c17c507fbdccbd0e", "packagetype": "sdist", "python_version": "source", "requires_python": ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*", "size": 7760, "upload_time": "2018-03-14T05:46:04", "url": "https://files.pythonhosted.org/packages/e2/a9/2995cd231ad45d80eb2179971156c5bf1ec02385a235abd0da317f90ff45/seer-0.1.1.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "a215dad344b05b55c17c507fbdccbd0e", "sha256": "0584ee7be2e51cb6538be89b1c0cb808695980386d857157166c81f79b05c744" }, "downloads": -1, "filename": "seer-0.1.1.tar.gz", "has_sig": false, "md5_digest": "a215dad344b05b55c17c507fbdccbd0e", "packagetype": "sdist", "python_version": "source", "requires_python": ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*", "size": 7760, "upload_time": "2018-03-14T05:46:04", "url": "https://files.pythonhosted.org/packages/e2/a9/2995cd231ad45d80eb2179971156c5bf1ec02385a235abd0da317f90ff45/seer-0.1.1.tar.gz" } ] }