{ "info": { "author": "Sidney Li", "author_email": "sidneyli5432@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Intended Audience :: Telecommunications Industry", "License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)", "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", "Topic :: Utilities" ], "description": "pyOTDR: Simple OTDR SOR file parse written in Python\n====================================================\n\nThe SOR (\u201cStandard OTDR Record\u201d) data format is used to store OTDR\n(`optical time-domain\nreflectometer `__\n) fiber data. The format is defined by the Telcordia `SR-4731, issue\n2 `__\nstandard. While it is a standard, it is unfortunately not open, in that\nthe specifics of the data format are not openly available. You can buy\nthe standards document from Telcordia for $750 US (as of this writing),\nbut this was beyond my budget. (And likely comes with all sorts of\nlicensing restrictions. I wouldn\u2019t know; I have never seen the\ndocument!)\n\nThere are several freely available OTDR trace readers available for\ndownload on the web, but most do not allow exporting the trace curve\ninto, say, a CSV file for further analysis, and only one that I\u2019ve found\nthat runs natively on Linux (but without source code; although some of\nthese do work in the Wine emulator). There have been requests on various\nInternet forums asking for information on how to extract the trace data,\nbut I am not aware of anyone providing any answers beyond pointing to\nthe free readers and the Telcordia standard.\n\nFortunately the data format is not particularly hard to decipher. The\ntable of contents on the Telcordia `SR-4731, issue\n2 `__\npage provides several clues, as does the Wikipedia page on `optical\ntime-domain\nreflectometer `__.\n\nUsing a binary-file editor/viewer and comparing the outputs from some\nfree OTDR SOR file readers, I was able to piece together most of the\nencoding in the SOR data format and written a simple program (in Python)\nthat parses the SOR file and dumps the trace data into a file. (For a\nmore detailed description, other than reading the source code, see `my\nblog\npost `__).\n\nPresented here for your entertainment are my findings, in the hope that\nit will be useful to other people. But be aware that the information\nprovided here is based on guess work from looking at a limited number of\nsample files. I can not guarantee that there are no mistakes, or that I\nhave uncovered all possible exceptions to the rules that I have deduced\nfrom the sample files. **use it at your own risk! You have been\nwarned!**\n\nThe program was ported over from my original\n`pubOTDR `__ written in Perl. To\nparse an OTDR SOR file, run the program as\n\n::\n\n pyOTDR.py myfile.sor\n\nwhere \u201cmfile.sor\u201d is the name (path) to your SOR file. A OTDR trace file\n\u201cmyfile-trace.dat\u201d and a JSON file \u201cmyfile-dump.json\u201d will be produced.\nYou can also output the results as an XML file \u201cmyfile-dump.xml\u201d with:\n\n::\n\n pyOTDR.py myfile.sor XML\n\nThere is also a Ruby version\n(`rbOTDR `__), a javascript/node\nversion(\\ `jsOTDR `__), and a Clojure\nversion (`cljotdr `__); the Clojure\nversion may be of interest to people looking for a Java version, since\nClojure runs on top of a Java Virtual Machine (JVM).\n\nInstall\n-------\n\nThis program requires python 2 or python 3. To install dependencies, run\n\n::\n\n pip install -r requirement.txt\n\nI recently reorganized the whole package to submit to PyPI (Python\nPackage Index). You should now be able to install the whole thing with\n\n::\n\n pip install pyOTDR\n\nThis should create an executable called **pyOTDR** that is ready to use.\n\nDocker\n~~~~~~\n\nThere is a docker image that you can download with the command\n\n::\n\n docker pull sidneyli/pyotdr:latest\n\nIf you would like to build the docker image yourself, a docker file\n(*Dockerfile*) is provided to help you test this program. In the top\nlevel directory, type the command\n\n::\n\n make docker-build\n\nor type the command\n\n::\n\n docker build . -t sidneyli/pyotdr:latest\n\nto build the docker image. It will take a while to download the base\nimage and compile. If all goes well, it should successfully build a new\ndocker image *sidneyli/pyotdr:latest*. You can check with the command:\n\n::\n\n docker images\n\nonce the build is completed. You can now run the command\n\n::\n\n make docker-run\n\nor type the docker command:\n\n::\n\n docker run -ti --rm -v $HOME:/data sidneyli/pyotdr:latest /bin/bash\n\nto spin up an instance of the docker image. This will start a command\nshell for you to run the *pyOTDR.py* program. The docker command above\nwill mount your home directory to the */data* folder inside the docker\ninstance. The command pyOTDR.py (installed as */pyOTDR/pyOTDR.py*) will\nbe in your execution path. The docker instance removes itself when you\nexit the instance.\n\n(*Last Revised 2018-01-12*)\n\n\n", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/sid5432/pyOTDR", "keywords": "SR-4731 reflectometer Telcordia OTDR SOR", "license": "", "maintainer": "", "maintainer_email": "", "name": "pyOTDR", "package_url": "https://pypi.org/project/pyOTDR/", "platform": "", "project_url": "https://pypi.org/project/pyOTDR/", "project_urls": { "Homepage": "https://github.com/sid5432/pyOTDR" }, "release_url": "https://pypi.org/project/pyOTDR/1.0.0c1/", "requires_dist": [ "utils", "crcmod", "lazyxml", "pytest; extra == 'test'" ], "requires_python": "", "summary": "A simple OTDR SOR file parser", "version": "1.0.0c1" }, "last_serial": 3893297, "releases": { "1.0.0b1": [ { "comment_text": "", "digests": { "md5": "18f12aa4211c76b5e24538f048fa9d01", "sha256": "970a81368e113c30be9ef60f5a3b60975277814ca8412d0189eb65afd9959eeb" }, "downloads": -1, "filename": "pyOTDR-1.0.0b1-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "18f12aa4211c76b5e24538f048fa9d01", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 22596, "upload_time": "2018-01-13T05:32:21", "url": "https://files.pythonhosted.org/packages/65/d4/606e81357f08fefdf7160638da614a5f14ff0c6412739ef40bf3c58e4404/pyOTDR-1.0.0b1-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "50e02841a478b9a22f0d8dbb420be2a1", "sha256": "ca65bf24961147459d12bb66a86768d0b6a95f287287b6f3fddabc8069135cb1" }, "downloads": -1, "filename": "pyOTDR-1.0.0b1.tar.gz", "has_sig": false, "md5_digest": "50e02841a478b9a22f0d8dbb420be2a1", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 15857, "upload_time": "2018-01-13T05:32:23", "url": "https://files.pythonhosted.org/packages/6c/32/bae0f4c9ea55e3d842fbfc24bc93910d6d7dfb2c3bce92f1f29600c49370/pyOTDR-1.0.0b1.tar.gz" } ], "1.0.0c1": [ { "comment_text": "", "digests": { "md5": "3857b08652dfb382e419ac41e4e65b8f", "sha256": "d184b03d91c845891b4ae545b981497e34d99b64706b78e3a953dd1e77f21597" }, "downloads": -1, "filename": "pyOTDR-1.0.0c1-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "3857b08652dfb382e419ac41e4e65b8f", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 22839, "upload_time": "2018-05-24T00:45:08", "url": "https://files.pythonhosted.org/packages/b0/26/e1fe6b16a17373b479d97c57c1f9adb62f9a2b8c43ccd8e581e58962eb25/pyOTDR-1.0.0c1-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "57055954b99c6cd1878eeaf396132c6c", "sha256": "657e235ec55221e012099d7e7680ef4f8389e0980674796c708a425df23753bc" }, "downloads": -1, "filename": "pyOTDR-1.0.0c1.tar.gz", "has_sig": false, "md5_digest": "57055954b99c6cd1878eeaf396132c6c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 16142, "upload_time": "2018-05-24T00:45:10", "url": "https://files.pythonhosted.org/packages/19/6b/3f7bf71ece889dc64ede9cebbc49ec81b9f86905c374e441756815c5555d/pyOTDR-1.0.0c1.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "3857b08652dfb382e419ac41e4e65b8f", "sha256": "d184b03d91c845891b4ae545b981497e34d99b64706b78e3a953dd1e77f21597" }, "downloads": -1, "filename": "pyOTDR-1.0.0c1-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "3857b08652dfb382e419ac41e4e65b8f", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 22839, "upload_time": "2018-05-24T00:45:08", "url": "https://files.pythonhosted.org/packages/b0/26/e1fe6b16a17373b479d97c57c1f9adb62f9a2b8c43ccd8e581e58962eb25/pyOTDR-1.0.0c1-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "57055954b99c6cd1878eeaf396132c6c", "sha256": "657e235ec55221e012099d7e7680ef4f8389e0980674796c708a425df23753bc" }, "downloads": -1, "filename": "pyOTDR-1.0.0c1.tar.gz", "has_sig": false, "md5_digest": "57055954b99c6cd1878eeaf396132c6c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 16142, "upload_time": "2018-05-24T00:45:10", "url": "https://files.pythonhosted.org/packages/19/6b/3f7bf71ece889dc64ede9cebbc49ec81b9f86905c374e441756815c5555d/pyOTDR-1.0.0c1.tar.gz" } ] }