{ "info": { "author": "Robbie Clarken", "author_email": "robbie.clarken@gmail.com", "bugtrack_url": null, "classifiers": [], "description": "Copyright (c) 2015 Robbie Clarken\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in\nall copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\nTHE SOFTWARE.\n\nDescription: .. image:: https://travis-ci.org/RobbieClarken/channelarchiver.svg\n :target: https://travis-ci.org/RobbieClarken/channelarchiver\n \n A python client for retrieving data from an `EPICS Channel Archiver\n `_.\n \n To get started just import the ``Archiver`` class and specify the\n address of your Channel Archiver server:\n \n .. code:: python\n \n from channelarchiver import Archiver\n archiver = Archiver('http://cr01arc01/cgi-bin/ArchiveDataServer.cgi')\n \n You then fetch data with the ``archiver.get()`` method:\n \n .. code:: python\n \n >>> data = archiver.get('SR00IE01:INJECTION_EFFICIENCY_MONITOR', '2013-08-11', '2013-08-12')\n >>> print(data)\n time value status severity\n 2013-08-11 00:00:02 96.9351518 NO_ALARM NO_ALARM\n 2013-08-11 00:04:20 94.5171233 NO_ALARM NO_ALARM\n 2013-08-11 00:08:38 85.0604361 LOW_ALARM MINOR\n ...\n >>> data.values\n [96.935, 94.517, ..., 97.253]\n \n The returned ``ChannelData`` object has the following fields:\n \n - ``channel``: The channel name.\n - ``times``: A list of datetimes.\n - ``values``: A list of the channel's values corresponding to\n ``times``.\n - ``severities`` and ``statuses``: Diagnostic information about the\n channel state for each time.\n - ``units``: The units of ``values``.\n - ``states``: String values for enum type channels.\n - ``data_type``: Whether the channel values are string, enum, int or\n double (see ``codes.data_type``).\n - ``elements``: The number of elements in an array type channel.\n - ``display_limits``, ``warn_limits``, ``alarm_limits``: Low and high\n limits\n - ``display_precision``: The recommended number of decimal places to to\n display values with in user interfaces.\n - ``archive_key``: The archive the data was retrieved from.\n - ``interpolation``: The interpolation method that was used (see\n ``codes.interpolation``).\n \n Get multiple channels\n ~~~~~~~~~~~~~~~~~~~~~\n \n If you pass a list of channel names to ``.get()`` you will get a list of\n data objects back:\n \n .. code:: python\n \n >>> channels = ['SR00TUM01:X_TUNE', 'SR00TUM01:Y_TUNE']\n >>> x, y = archiver.get(channels, '2013-08-24 09:00', '2013-08-24 19:00')\n >>> print(x.values)\n [0.291, 0.290, ..., 0.289]\n >>> print(y.values)\n [0.216, 0.217, ..., 0.213]\n \n Times and timezones\n ~~~~~~~~~~~~~~~~~~~\n \n The start and end times over which to fetch data can be datetimes\n or strings in ISO 8601 format (eg ``2013-08-10T21:30:00``).\n \n If no timezone is specified, your local timezone will be used. If a timezone is given,\n the returned channel data times will also be in this timezone.\n \n .. code:: python\n \n >>> start = datetime.datetime(2012, 6, 1, tzinfo=pytz.UTC)\n >>> end = datetime.datetime(2012, 6, 30, tzinfo=pytz.UTC)\n >>> data_in_utc = archiver.get('BR00EXS01:TUNNEL_TEMPERATURE_MONITOR', start, end)\n \n Interpolating\n ~~~~~~~~~~~~~\n \n You can control how much data is returned from the archiver with the\n ``limit`` parameter. This is roughly equal to how many data points will\n be returned but the actual value will differ depending on how much data is\n available and the interpolation method.\n \n The interpolation method is determined by the ``interpolation`` parameter. The\n allowed values are the ``'raw'``, ``'spreadsheet'``, ``'averaged'``, ``'plot-binning'``\n and ``'linear'``. The default value is ``'linear'``.\n \n .. code:: python\n \n >>> from channelarchiver import codes\n >>> channel = 'SR00MOS01:FREQUENCY_MONITOR'\n >>> data = archiver.get(channel, '2012', '2013', limit=10000, interpolation='raw')\n \n Speeding up data retrieval\n ~~~~~~~~~~~~~~~~~~~~~~~~~~\n \n By default, for each ``.get`` call ``Archive`` will scan the archives to\n determine which one contains data for the specified channels. This will\n cause a slight delay in retrieving the data. This can be avoided by\n calling the ``.scan_archives()`` method once and then passing\n ``scan_archives=False`` to ``.get()``:\n \n .. code:: python\n \n >>> archiver.scan_archives()\n >>> d1 = archiver.get('SR02GRM01:DOSE_RATE_MONITOR', '2013-07', '2013-08', scan_archives=False)\n >>> d2 = archiver.get('SR11BCM01:LIFETIME_MONITOR', '2013-07', '2013-08', scan_archives=False)\n \nPlatform: UNKNOWN\nClassifier: Development Status :: 4 - Beta\nClassifier: Topic :: Scientific/Engineering\nClassifier: Intended Audience :: Developers\nClassifier: Intended Audience :: Science/Research\nClassifier: Natural Language :: English\nClassifier: Programming Language :: Python\nClassifier: Programming Language :: Python :: 2.6\nClassifier: Programming Language :: Python :: 2.7\nClassifier: Programming Language :: Python :: 3\nClassifier: Programming Language :: Python :: 3.3\nClassifier: License :: OSI Approved :: MIT License\n", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/RobbieClarken/channelarchiver", "keywords": "", "license": "The MIT License (MIT)", "maintainer": "", "maintainer_email": "", "name": "channelarchiver", "package_url": "https://pypi.org/project/channelarchiver/", "platform": "", "project_url": "https://pypi.org/project/channelarchiver/", "project_urls": { "Homepage": "https://github.com/RobbieClarken/channelarchiver" }, "release_url": "https://pypi.org/project/channelarchiver/1.0.0/", "requires_dist": [ "tzlocal" ], "requires_python": "", "summary": "Python client for the EPICS Channel Archiver.", "version": "1.0.0" }, "last_serial": 4038296, "releases": { "0.0.1": [ { "comment_text": "", "digests": { "md5": "9a3687999433f0351f85d016e5e60844", "sha256": "529b64a4e0882c7c806f88f54dfedb3d55e0683d7559fff6394230b6705972ec" }, "downloads": -1, "filename": "channelarchiver-0.0.1.tar.gz", "has_sig": false, "md5_digest": "9a3687999433f0351f85d016e5e60844", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 10609, "upload_time": "2013-08-24T16:58:18", "url": "https://files.pythonhosted.org/packages/f7/37/28347d0876401ff1c79e38ef1d7d43da0641eb13ca2dc9c4274ed40b2e70/channelarchiver-0.0.1.tar.gz" } ], "0.0.2": [ { "comment_text": "", "digests": { "md5": "ef6eee6eae3e455c0a9c241686312b27", "sha256": "b3b6abaae311c982d1f36a01d74280ac15429dd7f3f1f47411b7841632e961c5" }, "downloads": -1, "filename": "channelarchiver-0.0.2.tar.gz", "has_sig": false, "md5_digest": "ef6eee6eae3e455c0a9c241686312b27", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 10588, "upload_time": "2013-08-27T20:36:27", "url": "https://files.pythonhosted.org/packages/9f/ee/7dd52d0d731aec223cf6fd4e3e7278582a30b93b4010262df704bef27dfc/channelarchiver-0.0.2.tar.gz" } ], "0.0.3": [ { "comment_text": "", "digests": { "md5": "5b40e223121ee1743496e38df32d49ac", "sha256": "b1ec39f7a885c92a780a3b7fcb3472b6da8494914f7c43e5743c3f410a0b9e96" }, "downloads": -1, "filename": "channelarchiver-0.0.3.tar.gz", "has_sig": false, "md5_digest": "5b40e223121ee1743496e38df32d49ac", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 10874, "upload_time": "2013-08-28T15:20:26", "url": "https://files.pythonhosted.org/packages/11/89/783201311ca18aa744fb35126bbbd65aa3ac473cd52aa97a240f1a162bab/channelarchiver-0.0.3.tar.gz" } ], "0.0.4": [ { "comment_text": "", "digests": { "md5": "b809a9265c6eda22173b34b542bc8e01", "sha256": "1006289e447d91c9dbe6bc9aba6392a294d4a8942407adf50f1c2bffa465dbbd" }, "downloads": -1, "filename": "channelarchiver-0.0.4.tar.gz", "has_sig": false, "md5_digest": "b809a9265c6eda22173b34b542bc8e01", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 10984, "upload_time": "2014-03-07T06:40:50", "url": "https://files.pythonhosted.org/packages/98/6a/5490a571f2d33616b8872444bd8357d22e291b7c11dcc5fd98be6a139231/channelarchiver-0.0.4.tar.gz" } ], "0.0.5": [ { "comment_text": "", "digests": { "md5": "ec0c0f80af8ebfc11ec239b299182592", "sha256": "6aca7e046ac2f4e5ea6c88e91aa2e2a0d5bc9c384865b66dca52418639827973" }, "downloads": -1, "filename": "channelarchiver-0.0.5.tar.gz", "has_sig": false, "md5_digest": "ec0c0f80af8ebfc11ec239b299182592", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 10980, "upload_time": "2015-02-24T00:07:36", "url": "https://files.pythonhosted.org/packages/63/1c/3c1757ac23d56e2c44bd8a888e19a6110693186e10ddc34801de35211159/channelarchiver-0.0.5.tar.gz" } ], "1.0.0": [ { "comment_text": "", "digests": { "md5": "4776ca0b9e2e086b65a39cf08c50f4fb", "sha256": "e61ce733f89072e4438c6c9b09a26ab1df6cd414c9a07889b45215c54f6212f0" }, "downloads": -1, "filename": "channelarchiver-1.0.0-py3-none-any.whl", "has_sig": false, "md5_digest": "4776ca0b9e2e086b65a39cf08c50f4fb", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 13059, "upload_time": "2018-07-07T02:59:03", "url": "https://files.pythonhosted.org/packages/62/50/a62bcdd0e050c3e0361606736d250bd1efa58818401b74ec14e0c977c54c/channelarchiver-1.0.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "581f2b61e0a9e90d590f352364cfaadb", "sha256": "7be9df23e0b82912205755ccb34424536390cc11f5c82cc94d2046964103564d" }, "downloads": -1, "filename": "channelarchiver-1.0.0.tar.gz", "has_sig": false, "md5_digest": "581f2b61e0a9e90d590f352364cfaadb", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 11031, "upload_time": "2018-07-07T02:59:06", "url": "https://files.pythonhosted.org/packages/2b/1d/b1b611ec18fd7bd12789288fa08e95a6357326075237d02d83bc819eb31d/channelarchiver-1.0.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "4776ca0b9e2e086b65a39cf08c50f4fb", "sha256": "e61ce733f89072e4438c6c9b09a26ab1df6cd414c9a07889b45215c54f6212f0" }, "downloads": -1, "filename": "channelarchiver-1.0.0-py3-none-any.whl", "has_sig": false, "md5_digest": "4776ca0b9e2e086b65a39cf08c50f4fb", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 13059, "upload_time": "2018-07-07T02:59:03", "url": "https://files.pythonhosted.org/packages/62/50/a62bcdd0e050c3e0361606736d250bd1efa58818401b74ec14e0c977c54c/channelarchiver-1.0.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "581f2b61e0a9e90d590f352364cfaadb", "sha256": "7be9df23e0b82912205755ccb34424536390cc11f5c82cc94d2046964103564d" }, "downloads": -1, "filename": "channelarchiver-1.0.0.tar.gz", "has_sig": false, "md5_digest": "581f2b61e0a9e90d590f352364cfaadb", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 11031, "upload_time": "2018-07-07T02:59:06", "url": "https://files.pythonhosted.org/packages/2b/1d/b1b611ec18fd7bd12789288fa08e95a6357326075237d02d83bc819eb31d/channelarchiver-1.0.0.tar.gz" } ] }