{ "info": { "author": "Chandan Singh", "author_email": "csinva@virginia.edu", "bugtrack_url": null, "classifiers": [], "description": "# convolutional network metric scripts\n- Code for fast watersheds. Code is based around code from https://bitbucket.org/poozh/watershed described in http://arxiv.org/abs/1505.00249. For use in https://github.com/naibaf7/PyGreentea. \n\n# building \n\n### conda\n- `conda install -c conda-forge zwatershed`\n\n### pip [](https://pypi.python.org/pypi/zwatershed/)\n- `pip install zwatershed`\n\n### from source\n- clone the repository\n- run ./make.sh\n\n### requirements\n- numpy, h5py, cython\n- if using parallel watershed, also requires multiprocessing or pyspark\n- in order to build the cython, requires a c++ compiler and boost\n\n# function api\n- `(segs, rand) = zwatershed_and_metrics(segTrue, aff_graph, eval_thresh_list, seg_save_thresh_list)`\n\t- *returns segmentations and metrics*\n\t- `segs`: list of segmentations\n\t\t- `len(segs) == len(seg_save_thresh_list)`\n\t- `rand`: dict\n\t\t- `rand['V_Rand']`: V_Rand score (scalar)\n\t\t- `rand['V_Rand_split']`: list of score values\n\t\t\t- `len(rand['V_Rand_split']) == len(eval_thresh_list)`\n\t\t- `rand['V_Rand_merge']`: list of score values, \n\t\t\t- `len(rand['V_Rand_merge']) == len(eval_thresh_list)`\n- `segs = zwatershed(aff_graph, seg_save_thresh_list)` \n\t\t- *returns segmentations*\n\t- `segs`: list of segmentations\n\t\t- `len(segs) == len(seg_save_thresh_list)`\n\n##### These methods have versions which save the segmentations to hdf5 files instead of returning them\n- `rand = zwatershed_and_metrics_h5(segTrue, aff_graph, eval_thresh_list, seg_save_thresh_list, seg_save_path)`\n- `zwatershed_h5(aff_graph, eval_thresh_list, seg_save_path)`\n\n##### All 4 methods have versions which take an edgelist representation of the affinity graph\n- `(segs, rand) = zwatershed_and_metrics_arb(segTrue, node1, node2, edgeWeight, eval_thresh_list, seg_save_thresh_list)`\n- `segs = zwatershed_arb(seg_shape, node1, node2, edgeWeight, seg_save_thresh_list)`\n- `rand = zwatershed_and_metrics_h5_arb(segTrue, node1, node2, edgeWeight, eval_thresh_list, seg_save_thresh_list, seg_save_path)`\n- `zwatershed_h5_arb(seg_shape, node1, node2, edgeWeight, eval_thresh_list, seg_save_path)`\n\n# parallel watershed - 4 steps\n- *a full example is given in par_ex.ipynb*\n\n1. Partition the subvolumes\n\t- `partition_data = partition_subvols(pred_file,out_folder,max_len)`\n\t\t- evenly divides the data in *pred_file* with the constraint that no dimension of any subvolume is longer than max_len\n2. Zwatershed the subvolumes\n\t1. `eval_with_spark(partition_data[0])`\n\t\t- *with spark*\n\t2. `eval_with_par_map(partition_data[0],NUM_WORKERS)`\n\t\t- *with python multiprocessing map*\n\t- after evaluating, subvolumes will be saved into the out\\_folder directory named based on their smallest indices in each dimension (ex. path/to/out\\_folder/0\\_0\\_0\\_vol)\n3. Stitch the subvolumes together\n\t- `stitch_and_save(partition_data,outname)`\n\t\t- stitch together the subvolumes in partition_data\n\t\t- save to the hdf5 file outname\n\t\t\t- outname['starts'] = list of min_indices of each subvolume\n\t\t\t- outname['ends'] = list of max_indices of each subvolume\n\t\t\t- outname['seg'] = full stitched segmentation\n\t\t\t- outname['seg_sizes'] = array of size of each segmentation\n\t\t\t- outname['rg_i'] = region graph for ith subvolume\n4. Threshold individual subvolumes by merging\n\t- `seg_merged = merge_by_thresh(seg,seg_sizes,rg,thresh)`\n\t\t- load in these areguments from outname\n", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/TuragaLab/zwatershed", "keywords": null, "license": "MIT", "maintainer": null, "maintainer_email": null, "name": "zwatershed", "package_url": "https://pypi.org/project/zwatershed/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/zwatershed/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/TuragaLab/zwatershed" }, "release_url": "https://pypi.org/project/zwatershed/0.10/", "requires_dist": null, "requires_python": null, "summary": "Fast watersheds", "version": "0.10" }, "last_serial": 2264772, "releases": { "0.1": [ { "comment_text": "", "digests": { "md5": "091144ebabb5c642471a63ffe7312587", "sha256": "8ed1684c174d5a1e0a14cdbcf70a4a00919716105adbc9e2349efcb4cae145eb" }, "downloads": -1, "filename": "zwatershed-0.1.tar.gz", "has_sig": false, "md5_digest": "091144ebabb5c642471a63ffe7312587", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5128, "upload_time": "2016-06-28T15:18:00", "url": "https://files.pythonhosted.org/packages/8b/e4/10081de9195a38f1618d38039d9dd192f30fe9563d95b9574476350547db/zwatershed-0.1.tar.gz" } ], "0.10": [ { "comment_text": "", "digests": { "md5": "c3a292d5bbb058cbc5c5cc908d4ec60a", "sha256": "4892f63d5aefb7dd5ae199c4481e94c88ce7e398d30cd90fa45fa555587ff5c1" }, "downloads": -1, "filename": "zwatershed-0.10.tar.gz", "has_sig": false, "md5_digest": "c3a292d5bbb058cbc5c5cc908d4ec60a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 29627, "upload_time": "2016-08-05T19:07:21", "url": "https://files.pythonhosted.org/packages/fe/4b/fa666cc4c5921bb19250087ce200360923969aaaa902795f7a8794da41e9/zwatershed-0.10.tar.gz" } ], "0.2": [ { "comment_text": "", "digests": { "md5": "674da84c55b5d48346244f268bf3feba", "sha256": "5705ebbf34a338d4e83e70d198bdfb27f0f9aee8250c057428f566ed01f012a3" }, "downloads": -1, "filename": "zwatershed-0.2.tar.gz", "has_sig": false, "md5_digest": "674da84c55b5d48346244f268bf3feba", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5484, "upload_time": "2016-06-28T18:26:43", "url": "https://files.pythonhosted.org/packages/f9/b3/359bfaa30a1b33fd30e8c406d82af7699e0644bc2d443d7ee8fcb6743071/zwatershed-0.2.tar.gz" } ], "0.3": [ { "comment_text": "", "digests": { "md5": "843a1610dab334d150003f6d6698d588", "sha256": "88914b4d8cb30ed751ca0e228b49726b0a21b6a1d397a9b30238354caad32dd8" }, "downloads": -1, "filename": "zwatershed-0.3.tar.gz", "has_sig": false, "md5_digest": "843a1610dab334d150003f6d6698d588", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 27626, "upload_time": "2016-06-28T18:40:13", "url": "https://files.pythonhosted.org/packages/d9/57/645eaa71718c3b6e934b129285221330f702a98fa0cc95c04d4faf2b9674/zwatershed-0.3.tar.gz" } ], "0.4": [ { "comment_text": "", "digests": { "md5": "a6ee1f51753b898d9b0a3fd2db01dd11", "sha256": "d3f6cd1628966192eec2c890aad318aee3ed924a5f63c1c98bc4dd946dd34b4a" }, "downloads": -1, "filename": "zwatershed-0.4.tar.gz", "has_sig": false, "md5_digest": "a6ee1f51753b898d9b0a3fd2db01dd11", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 27839, "upload_time": "2016-06-29T17:35:11", "url": "https://files.pythonhosted.org/packages/33/6f/16c9146366a04c0c67ae5e5028cdae0cddb033d9d2c69b1a0dfae6169295/zwatershed-0.4.tar.gz" } ], "0.5": [ { "comment_text": "", "digests": { "md5": "df5b36634e38012e0fb3b2545d3bfc26", "sha256": "5a5d9795806d977462d5655334d01e619de1072163a6dd76e7aed8206c702177" }, "downloads": -1, "filename": "zwatershed-0.5.tar.gz", "has_sig": false, "md5_digest": "df5b36634e38012e0fb3b2545d3bfc26", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 27829, "upload_time": "2016-06-29T17:36:34", "url": "https://files.pythonhosted.org/packages/8e/ff/e534436e15c53ee90e580cc630ad5f5211314997668fd83da0081bee678b/zwatershed-0.5.tar.gz" } ], "0.6": [ { "comment_text": "", "digests": { "md5": "a0cf54cf6a8eee022ffdc16602044a51", "sha256": "46865c5dd3a7334bbf6af40d1d9b55f7d670bb538cfef212da585bef82d5a611" }, "downloads": -1, "filename": "zwatershed-0.6.tar.gz", "has_sig": false, "md5_digest": "a0cf54cf6a8eee022ffdc16602044a51", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 27902, "upload_time": "2016-06-29T18:39:14", "url": "https://files.pythonhosted.org/packages/f6/6d/6aec8f8d7ca2a1903b168aa58219f25e30d3fa305eea5c6f81cc6b09abd8/zwatershed-0.6.tar.gz" } ], "0.7": [ { "comment_text": "", "digests": { "md5": "dacd83bfde8b70fdf364f09d5024d22b", "sha256": "1d40e25706977188f0f46e1831e306cb9fec7b96f113435218c911846ec7ff53" }, "downloads": -1, "filename": "zwatershed-0.7.tar.gz", "has_sig": false, "md5_digest": "dacd83bfde8b70fdf364f09d5024d22b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 28124, "upload_time": "2016-06-29T19:24:56", "url": "https://files.pythonhosted.org/packages/b7/c9/059a53fa010407824e49147257d677bdff90167236d18b3321c3f007eff1/zwatershed-0.7.tar.gz" } ], "0.8": [ { "comment_text": "", "digests": { "md5": "e48b08909ad95785d9adfee0d1f8d318", "sha256": "4c8b2d4734b9818e748d74e4f3c959e67e6a43442e1803cd0310346a54c82971" }, "downloads": -1, "filename": "zwatershed-0.8.tar.gz", "has_sig": false, "md5_digest": "e48b08909ad95785d9adfee0d1f8d318", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 28146, "upload_time": "2016-07-11T13:46:45", "url": "https://files.pythonhosted.org/packages/86/55/f17d240d6386591e5be87cfa1506bf9f4af101fee2f9a7800c64559469bc/zwatershed-0.8.tar.gz" } ], "0.9": [ { "comment_text": "", "digests": { "md5": "9e40fd30406c60affe927b03d68366a5", "sha256": "487d5842ad7798c205a6139a089bcd9b86bf606eb1daaec5ff78838abb275fe4" }, "downloads": -1, "filename": "zwatershed-0.9.tar.gz", "has_sig": false, "md5_digest": "9e40fd30406c60affe927b03d68366a5", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 29563, "upload_time": "2016-07-20T15:15:52", "url": "https://files.pythonhosted.org/packages/03/1a/8f946b75fbb61a67c366bd5fc31dc7600c62c0ad8e34ca543a659f75c6c1/zwatershed-0.9.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "c3a292d5bbb058cbc5c5cc908d4ec60a", "sha256": "4892f63d5aefb7dd5ae199c4481e94c88ce7e398d30cd90fa45fa555587ff5c1" }, "downloads": -1, "filename": "zwatershed-0.10.tar.gz", "has_sig": false, "md5_digest": "c3a292d5bbb058cbc5c5cc908d4ec60a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 29627, "upload_time": "2016-08-05T19:07:21", "url": "https://files.pythonhosted.org/packages/fe/4b/fa666cc4c5921bb19250087ce200360923969aaaa902795f7a8794da41e9/zwatershed-0.10.tar.gz" } ] }