{ "info": { "author": "FNNDSC", "author_email": "dev@babymri.org", "bugtrack_url": null, "classifiers": [], "description": "pfdicom_rev\n==================\n\n.. image:: https://badge.fury.io/py/pfdicom_rev.svg\n :target: https://badge.fury.io/py/pfdicom_rev\n\n.. image:: https://travis-ci.org/FNNDSC/pfdicom_rev.svg?branch=master\n :target: https://travis-ci.org/FNNDSC/pfdicom_rev\n\n.. image:: https://img.shields.io/badge/python-3.5%2B-blue.svg\n :target: https://badge.fury.io/py/pfdicom_rev\n\n.. contents:: Table of Contents\n\n\nQuick Overview\n--------------\n\n- ``pfdicom_rev`` processes DICOM trees for the ReV viewer.\n\nOverview\n--------\n\n``pfdicom_rev`` processes directories containing DICOM files for the ReV viewer by converting DCM files to JPG previews and generating JSON series and study summary files, as well as index.html per study.\n\nThe script accepts an ```` which should be the (absolute) root dir of the ReV library. All file locations will be referenced relative to this root dir in the JSON descriptor files.\n\n``pfdicom_rev`` performs a mulit-pass loop over the file tree space as defined in the ``[--stage ]`` flag below.\n\nNOTE:\n\n* ``pfdicom_rev`` relies on ImageMagick for many of its operations, including the DCM to JPG conversion, JPG resize, and preview strip creation.\n\n* In some cases, default limits for ``ImageMagick`` are too low for generating preview strips, especially if a given DICOM series has many (more than 100) DICOM files. One fix for this is to edit the ``policy.xml`` file pertaining to ``ImageMagick`` and set the image ``width`` and ``height`` specifiers to 100 kilo-pixels (the default is about 16KP).\n\n.. code:: xml\n\n \n \n\nPlease see here_ for more information.\n\n.. _here: https://imagemagick.org/script/resources.php\n\nInstallation\n------------\n\nDependencies\n~~~~~~~~~~~~\n\nThe following dependencies are installed on your host system/python3 virtual env (they will also be automatically installed if pulled from pypi):\n\n- ``pfmisc`` (various misc modules and classes for the pf* family of objects)\n- ``pftree`` (create a dictionary representation of a filesystem hierarchy)\n- ``pfdicom`` (handle underlying DICOM file reading)\n\nUsing ``PyPI``\n~~~~~~~~~~~~~~\n\nThe best method of installing this script and all of its dependencies is\nby fetching it from PyPI\n\n.. code:: bash\n\n pip3 install pfdicom_rev\n\nCommand line arguments\n----------------------\n\n.. code:: html\n\n -I|--inputDir \n Input DICOM directory to examine. By default, the first file in this\n directory is examined for its tag information. There is an implicit\n assumption that each contains a single DICOM series.\n\n [-e|--extension ]\n An optional extension to filter the DICOM files of interest from the \n .\n\n -O|--outputDir \n The output root directory that will contain a tree structure identical\n to the input directory, and each \"leaf\" node will contain the analysis\n results.\n\n For ReV, this is often the special directive '%inputDir' which directs\n the system to generate all outputs in the input tree directly.\n\n [--outputLeafDir ]\n If specified, will apply the to the output\n directories containing data. This is useful to blanket describe\n final output directories with some descriptive text, such as \n 'anon' or 'preview'. \n\n This is a formatting spec, so \n\n --outputLeafDir 'preview-%s'\n\n where %s is the original leaf directory node, will prefix each\n final directory containing output with the text 'preview-' which\n can be useful in describing some features of the output set.\n\n [-T|--tagStruct ]\n Parse the tags and their \"subs\" from a JSON formatted \n passed directly in the command line. This is used in the optional \n DICOM anonymization.\n\n [-S|--server ]\n The name of the server hosting the ReV viewer.\n\n Defaults to empty string '' which is interpreted as the current host, \n i.e. the host running `pfdicom_rev`. If the actual viewer is hosted\n elsewhere, use this flag to specify the *viewer* host.\n\n [--stage ]\n Stage to execute -- mostly for debugging purposes and useful if running a \n particular stage repeatedly. There are some caveats to this -- mostly that\n stages are serially dependent, thus running \"--stage 4\" off the bat will\n not work since previous stages have not completed.\n\n The actual thread of stage flow and dependencies are:\n\n\n\n /--stage 2 \n / \n stage 1-- \n \\ \n \\--stage 3----stage 4 \n\n\n [1] analyize all the DCM files in the \n * convert each DCM to JPG (native)\n * resize all JPGs to 96x96 and generate mosaic preview strip\n * resize all JPGs to 300x300 and generate DCMtag preview\n * tag middle JPG in series based on series length\n * create JSON per example series-level descriptors in each example\n directory:\n * declare location of actual series DCM files\n * create JSON per month example-level descriptors in each month \n directory: \n * declare location of middle thumbnail JPGs\n \n In each series directory:\n -yr/-mo/-ex/\n forall():\n o dcm2jpgDCMresize/*jpg\n o dcm2jpgRaw/*jpg\n o preview.jpg\n o raw-preview.jpg\n o -series.json\n -yr/-mo/\n o ex.json\n\n [2] analyze all the JSON series-level descriptors from stage [1] and \n in each example directory:\n * create study-level JSON descriptors that summarize\n all series JSON data into one file\n * create study-level index.html that directs to the ReV viewer\n with this yr/mo/ex tuple.\n\n In each study directory:\n -yr/-mo/-ex/\n o description.json\n o index.html\n\n [3] analyze all the JSON per month example-level descriptors\n from stage [1] and in each month directory:\n * create overview per-month index.html that shows\n per-example thumbnails\n\n In each month direcory:\n -yr/-mo\n o index.html\n\n [4] analyze all JSON study level descriptors from stage [2]\n * create tree map for mapping of arbitrary patient age to\n closest hits in tree\n \n In the root dir:\n o map.json\n\n [--studyJSON ]\n The name of the study JSON file. \n\n Defaults to 'description.json'.\n\n [--threads ]\n If specified, break the innermost analysis loop into \n threads.\n\n [-x|--man]\n Show full help.\n\n [-y|--synopsis]\n Show brief help.\n\n [--json]\n If specified, output a JSON dump of final return.\n\n [--followLinks]\n If specified, follow symbolic links.\n\n [-v|--verbosity ]\n Set the app verbosity level. \n\n 0: No internal output;\n 1: Run start / stop output notification;\n 2: As with level '1' but with simpleProgress bar in 'pftree';\n 3: As with level '2' but with list of input dirs/files in 'pftree';\n 5: As with level '3' but with explicit file logging for\n - read\n - analyze\n - write\n \nExamples\n--------\n\nProcess a tree containing DICOM files for ReV:\n\n.. code:: bash\n\n pfdicom_rev \\\\\n -I /var/www/html/rev \\\\\n -O %inputDir \\\\\n --threads 0 --printElapsedTime \\\\\n -v 3\n\nwhich will run a DCM and JSON analysis, printing the final elapsed processing time.", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/FNNDSC/pfdicom_rev", "keywords": "", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "pfdicom-rev", "package_url": "https://pypi.org/project/pfdicom-rev/", "platform": "", "project_url": "https://pypi.org/project/pfdicom-rev/", "project_urls": { "Homepage": "https://github.com/FNNDSC/pfdicom_rev" }, "release_url": "https://pypi.org/project/pfdicom-rev/2.4.6/", "requires_dist": null, "requires_python": "", "summary": "Process DICOM trees and create JSON summares for the ReV viewer.", "version": "2.4.6" }, "last_serial": 4560820, "releases": { "1.0.0": [ { "comment_text": "", "digests": { "md5": "c70a4560d3c3a8ba7d13fef658ccbf51", "sha256": "7b46634c932d1b9d6fea886ea7bf4a5cadf9c5a2370609ce89cd86129ef39391" }, "downloads": -1, "filename": "pfdicom_rev-1.0.0.tar.gz", "has_sig": false, "md5_digest": "c70a4560d3c3a8ba7d13fef658ccbf51", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 12453, "upload_time": "2018-10-09T17:41:46", "url": "https://files.pythonhosted.org/packages/6b/ae/5cbf0a66ee6b7edab40973ccc480b015119e68d5be3d43696d3315c1d2c3/pfdicom_rev-1.0.0.tar.gz" } ], "1.0.2": [ { "comment_text": "", "digests": { "md5": "e0d3d0f50dc63832b5a6d30bcf2c9680", "sha256": "7a3dc2724c5641f632e0d8643f376d40ebe20349baf7d5226e989b8a95204f18" }, "downloads": -1, "filename": "pfdicom_rev-1.0.2.tar.gz", "has_sig": false, "md5_digest": "e0d3d0f50dc63832b5a6d30bcf2c9680", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 12470, "upload_time": "2018-10-09T20:47:03", "url": "https://files.pythonhosted.org/packages/11/99/2aabf9f5a5ea5e0ddc27a21096959b52310e2fe25ae293f90745a0b9feb5/pfdicom_rev-1.0.2.tar.gz" } ], "1.0.4": [ { "comment_text": "", "digests": { "md5": "1be002120ee1f9b227e325320c5c60a3", "sha256": "813ca8296cac77358b003d7b465cfb12f476ab6e8a26d531f5aebe1c24ff108d" }, "downloads": -1, "filename": "pfdicom_rev-1.0.4.tar.gz", "has_sig": false, "md5_digest": "1be002120ee1f9b227e325320c5c60a3", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 13311, "upload_time": "2018-10-09T21:08:22", "url": "https://files.pythonhosted.org/packages/aa/37/814933fcade38621b246fc1505996052136fb49db3e5cad8ce02eb70ceca/pfdicom_rev-1.0.4.tar.gz" } ], "1.0.6": [ { "comment_text": "", "digests": { "md5": "2f99bc3a865bdd530f1a5913c4134509", "sha256": "e8b033c28b21393bd79e5da3bee442d135904d6bd94711a7c956987f2dc1434f" }, "downloads": -1, "filename": "pfdicom_rev-1.0.6.tar.gz", "has_sig": false, "md5_digest": "2f99bc3a865bdd530f1a5913c4134509", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 13604, "upload_time": "2018-10-09T21:46:49", "url": "https://files.pythonhosted.org/packages/59/88/b9ff83637331876186d5e937c949725f01d26ddeb16a806de8a7f9c2449e/pfdicom_rev-1.0.6.tar.gz" } ], "2.0.0": [ { "comment_text": "", "digests": { "md5": "0ace6c4609ade1a40ec4bf49a7c97ad6", "sha256": "a60513e8846f545df85e5b70933c3d2e7fec608acd02420e46dd1f65486036e5" }, "downloads": -1, "filename": "pfdicom_rev-2.0.0.tar.gz", "has_sig": false, "md5_digest": "0ace6c4609ade1a40ec4bf49a7c97ad6", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 16234, "upload_time": "2018-10-18T18:31:19", "url": "https://files.pythonhosted.org/packages/7e/1e/32aec2bcfbd917053985c3d7ff8a9a48a924ba1432e849883010867c819a/pfdicom_rev-2.0.0.tar.gz" } ], "2.0.2": [ { "comment_text": "", "digests": { "md5": "037230c55722d4261321e7824055adeb", "sha256": "1d1df559cebf3ec406dae5c5552b3de9546f9c682203ea9c6bc6d6fdabe6af46" }, "downloads": -1, "filename": "pfdicom_rev-2.0.2.tar.gz", "has_sig": false, "md5_digest": "037230c55722d4261321e7824055adeb", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 16230, "upload_time": "2018-10-18T18:57:43", "url": "https://files.pythonhosted.org/packages/c3/6b/ed93dac260931b4f90ce502df5e348e5f4c62ada478b1f8fb9100331a9a4/pfdicom_rev-2.0.2.tar.gz" } ], "2.0.4": [ { "comment_text": "", "digests": { "md5": "cd09d42a31b22e8f1084e1775d48559c", "sha256": "4f0201624281970a34d179cecd88922672e54bc8c9b06bfface9ddb8013d1582" }, "downloads": -1, "filename": "pfdicom_rev-2.0.4.tar.gz", "has_sig": false, "md5_digest": "cd09d42a31b22e8f1084e1775d48559c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 16247, "upload_time": "2018-10-18T20:15:42", "url": "https://files.pythonhosted.org/packages/a0/02/349ebf978136df878e955cab14501536cf6e9c99613787a5167ea572b8e5/pfdicom_rev-2.0.4.tar.gz" } ], "2.0.6": [ { "comment_text": "", "digests": { "md5": "ffb428b6251775de3de422c566cb2c7c", "sha256": "8e1c95a33a3d716e11212b078cb57d8b6fb8e16c34d6056c80816cac9a9d75db" }, "downloads": -1, "filename": "pfdicom_rev-2.0.6.tar.gz", "has_sig": false, "md5_digest": "ffb428b6251775de3de422c566cb2c7c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 16249, "upload_time": "2018-10-22T15:19:44", "url": "https://files.pythonhosted.org/packages/f5/d6/ed98e1bfdc8aa7d215b50ff7f4c7bff20d597c873810dc8bf530b1bb544e/pfdicom_rev-2.0.6.tar.gz" } ], "2.2.0": [ { "comment_text": "", "digests": { "md5": "063a68015037f8e0388082db3e9c77d5", "sha256": "893c4ee0cdf257dd5465452f11c8ac0be854e6e11afc1459e7356e2ce38a0d66" }, "downloads": -1, "filename": "pfdicom_rev-2.2.0.tar.gz", "has_sig": false, "md5_digest": "063a68015037f8e0388082db3e9c77d5", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 16057, "upload_time": "2018-10-26T02:31:42", "url": "https://files.pythonhosted.org/packages/01/d1/63e0f0b7d78df7c91893aea8cf77da1d39b47085bbc5381f635e00221326/pfdicom_rev-2.2.0.tar.gz" } ], "2.2.2": [ { "comment_text": "", "digests": { "md5": "ed88edca7ae35de911c081f7b3aeb128", "sha256": "f4a0d54741628f871792fb9d2428c36bfbe386520aa4923653402150d51c0172" }, "downloads": -1, "filename": "pfdicom_rev-2.2.2.tar.gz", "has_sig": false, "md5_digest": "ed88edca7ae35de911c081f7b3aeb128", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 16593, "upload_time": "2018-11-14T13:07:30", "url": "https://files.pythonhosted.org/packages/50/bf/7f602bd722876ff2457c2313632938043c71c1bb3e413dc0221a775fe69d/pfdicom_rev-2.2.2.tar.gz" } ], "2.2.4": [ { "comment_text": "", "digests": { "md5": "bfe72e9a92ee05c6cf14f4c5ab97d59e", "sha256": "d6a61f87bd83521ee5f5ed741f44be675034204987ae02da3696d0ef172f7607" }, "downloads": -1, "filename": "pfdicom_rev-2.2.4.tar.gz", "has_sig": false, "md5_digest": "bfe72e9a92ee05c6cf14f4c5ab97d59e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 17331, "upload_time": "2018-11-15T16:19:47", "url": "https://files.pythonhosted.org/packages/b0/47/9781738922623052b35e22a8715883c88a9a666997689054de000e40b0cb/pfdicom_rev-2.2.4.tar.gz" } ], "2.2.6": [ { "comment_text": "", "digests": { "md5": "174ef4d4dde87f0d9c89485bdff9b8de", "sha256": "4f26aa48c377b96e319db2c54485f1b811db9e382d301c645c602d9ccb719ebe" }, "downloads": -1, "filename": "pfdicom_rev-2.2.6.tar.gz", "has_sig": false, "md5_digest": "174ef4d4dde87f0d9c89485bdff9b8de", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 26066, "upload_time": "2018-11-20T21:19:33", "url": "https://files.pythonhosted.org/packages/0f/6a/7cedf902d1732c46b2fdb7c6c0f3aafb25849c5e3a5dc38098a122e89ec2/pfdicom_rev-2.2.6.tar.gz" } ], "2.2.8": [ { "comment_text": "", "digests": { "md5": "4ab9fc3fa4907f9c3ce4818a4b6f6647", "sha256": "08238b68d3488d6f8697737792fb83279686e96d36b453cbe34ac069c37f953e" }, "downloads": -1, "filename": "pfdicom_rev-2.2.8.tar.gz", "has_sig": false, "md5_digest": "4ab9fc3fa4907f9c3ce4818a4b6f6647", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 26560, "upload_time": "2018-11-26T19:12:02", "url": "https://files.pythonhosted.org/packages/c7/57/2e93fa3b486682b17a5c054ec59e90254b2b610287f8e4060d2de95be643/pfdicom_rev-2.2.8.tar.gz" } ], "2.4.0": [ { "comment_text": "", "digests": { "md5": "e053881b27905789eadae8dba1d501f7", "sha256": "6668d7ba0d684712c14a2a33d665df3736d895c194326dd38e649a3b5f84d63c" }, "downloads": -1, "filename": "pfdicom_rev-2.4.0.tar.gz", "has_sig": false, "md5_digest": "e053881b27905789eadae8dba1d501f7", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 26559, "upload_time": "2018-11-26T21:29:38", "url": "https://files.pythonhosted.org/packages/c7/ca/b8df358f02ebdd6bce648a56a4581db2a312a99121f06dc6bdaa770cdbea/pfdicom_rev-2.4.0.tar.gz" } ], "2.4.2": [ { "comment_text": "", "digests": { "md5": "7478b757bd20b4d28388e03f7dd41a54", "sha256": "6e1c79d806d1b14c34ea8a3e815102c7f09063330f4f44261043bb67c86d5048" }, "downloads": -1, "filename": "pfdicom_rev-2.4.2.tar.gz", "has_sig": false, "md5_digest": "7478b757bd20b4d28388e03f7dd41a54", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 26885, "upload_time": "2018-11-27T19:02:02", "url": "https://files.pythonhosted.org/packages/4f/0c/c66989c9fe54635a0771a5becb53d1b1ce269762bd9baf7173df1938f1ee/pfdicom_rev-2.4.2.tar.gz" } ], "2.4.4": [ { "comment_text": "", "digests": { "md5": "dd5a339068f05af4010006ab8aecf0d8", "sha256": "f1a5045953231603715f6243c7190b6259a0a5432d1f2243d4adaa191597022d" }, "downloads": -1, "filename": "pfdicom_rev-2.4.4.tar.gz", "has_sig": false, "md5_digest": "dd5a339068f05af4010006ab8aecf0d8", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 27410, "upload_time": "2018-11-27T19:32:39", "url": "https://files.pythonhosted.org/packages/f3/22/51a52350d724cb7a84e940500ee43c331a666a030b895565476f2de16c92/pfdicom_rev-2.4.4.tar.gz" } ], "2.4.6": [ { "comment_text": "", "digests": { "md5": "f02906692de85813fd588d9eb43ca7fd", "sha256": "02ee3f379d3c0278b2cd78078568946f2cd5848bd867c4ec95d0fba88c6e6d6d" }, "downloads": -1, "filename": "pfdicom_rev-2.4.6.tar.gz", "has_sig": false, "md5_digest": "f02906692de85813fd588d9eb43ca7fd", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 27619, "upload_time": "2018-12-04T19:45:31", "url": "https://files.pythonhosted.org/packages/2b/26/94cc784262fc6f39bcfa0bc8a1a5cbb18643d7a90a16032e4332f3b29887/pfdicom_rev-2.4.6.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "f02906692de85813fd588d9eb43ca7fd", "sha256": "02ee3f379d3c0278b2cd78078568946f2cd5848bd867c4ec95d0fba88c6e6d6d" }, "downloads": -1, "filename": "pfdicom_rev-2.4.6.tar.gz", "has_sig": false, "md5_digest": "f02906692de85813fd588d9eb43ca7fd", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 27619, "upload_time": "2018-12-04T19:45:31", "url": "https://files.pythonhosted.org/packages/2b/26/94cc784262fc6f39bcfa0bc8a1a5cbb18643d7a90a16032e4332f3b29887/pfdicom_rev-2.4.6.tar.gz" } ] }