nrtk.impls.perturb_image.generic.water_droplet_perturber
# This file includes code originally posted on Stack Overflow # (https://stackoverflow.com/posts/50751932/revisions) and is licensed under the # Creative Commons Attribution-ShareAlike 4.0 International License. # https://creativecommons.org/licenses/by-sa/4.0/ # # © 2025 Kitware, Inc
WaterDropletPerturber Implementation based on the work from these source papers: (1) https://openaccess.thecvf.com/content_ICCVW_2019/papers/PBDL/Hao_Learning_From_Synthetic_Photorealistic_Raindrop_for_Single_Image_Raindrop_Removal_ICCVW_2019_paper.pdf (2) https://www.giss.nasa.gov/pubs/abs/er05000f.html
For additional research regarding Water Droplet modeling, please refer to this paper: https://www.cvlibs.net/publications/Roser2010ACCVWORK.pdf
- Classes:
WaterDropletPerturber: Implements the physics-based, photorealistic water/rain droplet model, utilizing OpenCV and Shapely functionalities.
- Dependencies:
OpenCV for image processing.
Shapely for Curve generation related operations.
nrtk.interfaces.perturb_image.PerturbImage as the base interface for image perturbation.
- Example usage:
size_range = (0.0, 1.0) num_drops = 20 perturber = WaterDropletPerturber(size_range=size_range, num_drops=num_drops) perturbed_image, boxes = perturber.perturb(image, boxes)
- Notes:
The boxes returned from perturb are identical to the boxes passed in.
Classes
Implements the physics-based, photorealistic water/rain droplet model. |