-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Updated downscale #2264
Updated downscale #2264
Conversation
Reviewer's Guide by SourceryThis pull request updates the Class diagram showing changes to image transformation classesclassDiagram
class Solarize {
-threshold_range: tuple[float, float]
+__init__(threshold_range: tuple[float, float], p: float)
}
note for Solarize "Removed deprecated 'threshold' parameter"
class GaussNoise {
-std_range: tuple[float, float]
-mean_range: tuple[float, float]
-per_channel: bool
-noise_scale_factor: float
+__init__(std_range: tuple[float, float], mean_range: tuple[float, float], per_channel: bool, noise_scale_factor: float)
+apply(img: np.ndarray)
+get_params_dependent_on_data(data: dict)
}
note for GaussNoise "Added support for legacy var_limit and mean parameters"
class Downscale {
-scale_range: tuple[float, float]
-interpolation_pair: InterpolationDict
+__init__(scale_range: tuple[float, float], interpolation_pair: InterpolationDict)
}
note for Downscale "Removed deprecated scale_min, scale_max, and interpolation parameters"
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @ternaus - I've reviewed your changes - here's some feedback:
Overall Comments:
- Please add equivalent tests for the new parameters (especially for Downscale's scale_range and interpolation_pair) to maintain the same level of test coverage for edge cases and different interpolation methods.
Here's what I looked at during the review
- 🟢 General issues: all looks good
- 🟢 Security: all looks good
- 🟢 Testing: all looks good
- 🟢 Complexity: all looks good
- 🟢 Documentation: all looks good
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #2264 +/- ##
=========================================
+ Coverage 0 89.85% +89.85%
=========================================
Files 0 50 +50
Lines 0 8843 +8843
=========================================
+ Hits 0 7946 +7946
- Misses 0 897 +897
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
Summary by Sourcery
Remove deprecated
threshold
,var_limit
,mean
,scale_min
,scale_max
, andinterpolation
parameters fromSolarize
,GaussNoise
, andDownscale
transforms. Updateprocess_threshold
andcheck_range
methods inSolarize
andGaussNoise
respectively, to handle the changes. Refactor tests accordingly.Enhancements:
Solarize
,GaussNoise
, andDownscale
transforms by removing deprecated parameters.Tests:
Solarize
,GaussNoise
, andDownscale
transforms.