Skip to main content

Consult the module API page at

https://engineering.purdue.edu/kak/distWatershed/Watershed-2.2.3.html

for all information related to this module, including information related to the latest changes to the code. The page at the URL shown above lists all of the module functionality you can invoke in your own code. That page also describes how you can directly access the segmented blobs in your own code and how you can apply a color filter to an image before its segmentation.

With regard to the basic purpose of the module, it is a Python implementation of the watershed algorithm for image segmentation. This implementation allows for both fully automatic and marker-assisted segmentation of an image.

Typical usage syntax:

    from Watershed import *
    shed = Watershed(
               data_image = "orchid0001.jpg",
               binary_or_gray_or_color = "color",
               size_for_calculations = 128,
               sigma = 1,
               gradient_threshold_as_fraction = 0.1,
               level_decimation_factor = 16,
               padding = 20,
           )
    shed.extract_data_pixels()
    shed.display_data_image()
    shed.mark_image_regions_for_gradient_mods()                     #(A)
    shed.compute_gradient_image()
    shed.modify_gradients_with_marker_minima()                      #(B)
    shed.compute_Z_level_sets_for_gradient_image()
    shed.propagate_influence_zones_from_bottom_to_top_of_Z_levels()
    shed.display_watershed()
    shed.display_watershed_in_color()
    shed.extract_watershed_contours_seperated()
    shed.display_watershed_contours_in_color()

The statements in lines (A) and (B) are needed only for marker-assisted
segmentation with the module.  For a fully automated implemented of the
BLM algorithm, you would need to delete those two statements.

Metadata

Release files for Watershed 2.2.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for Watershed 2.2.3
File Size Uploaded Provenance Actions
watershed-2.2.3.tar.gz 12.9 MB Without provenance Details for watershed-2.2.3.tar.gz

Release files / watershed-2.2.3.tar.gz

Download URL watershed-2.2.3.tar.gz
Size 12.9 MB
Tags Source
SHA-256 checksum
How to use checksums
258a0e6489b4224bcb2e4ddfbcfb0b3f5237d0c8d08263b8255ca9f663618cdb
BLAKE2b-256 checksum
How to use checksums
eb64dd8ba4700a8b32b0558fb6e6d8d7ff341924f02cd3572b4974a3f4f73a9b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.10.12

Security for Watershed 2.2.3

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page