-
Notifications
You must be signed in to change notification settings - Fork 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
Cleanup functional_tensor.py (#3159) #3171
Conversation
Hi @avijit9! Thank you for your pull request and welcome to our community. We require contributors to sign our Contributor License Agreement, and we don't seem to have you on file. In order for us to review and merge your code, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA. If you have received this in error or have any questions, please contact us at [email protected]. Thanks! |
…9/vision into cleanup_functional_tensor
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.
@avijit9 Thanks a lot for the PR and for your investigation on the original proposal!
I left a few comments, please let me know what you think.
Codecov Report
@@ Coverage Diff @@
## master #3171 +/- ##
==========================================
+ Coverage 73.09% 73.48% +0.39%
==========================================
Files 99 99
Lines 9241 9230 -11
Branches 1493 1476 -17
==========================================
+ Hits 6755 6783 +28
+ Misses 2015 1991 -24
+ Partials 471 456 -15
Continue to review full report at Codecov.
|
@avijit9 Thanks for the changes. Your PR looks great! Note that we just merged a PR that adds a 6 more functional transforms. Would you mind making your changes to those as well? vision/torchvision/transforms/functional_tensor.py Lines 1187 to 1188 in 83171d6
vision/torchvision/transforms/functional_tensor.py Lines 1200 to 1201 in 83171d6
vision/torchvision/transforms/functional_tensor.py Lines 1214 to 1215 in 83171d6
vision/torchvision/transforms/functional_tensor.py Lines 1248 to 1249 in 83171d6
vision/torchvision/transforms/functional_tensor.py Lines 1260 to 1261 in 83171d6
vision/torchvision/transforms/functional_tensor.py Lines 1300 to 1301 in 83171d6
If you are busy let me know and I'll do it. Just make sure I got write access to your branch and I'll push it there so that you get credit for the changes. |
@datumbox No problem. I have made the changes and pushing them now. Thanks for being awesome :) |
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.
@avijit9 Looks great! I added one comment which I think it's due to wrong copy-paste. Let me know if you agree. :)
… testing Co-authored-by: Vasilis Vryniotis <[email protected]>
Summary: * added the helper method for dimension checks * unit tests for dimensio check function in functional_tensor * code formatting and typing * moved torch image check after tensor check * unit testcases for test_assert_image_tensor added and refactored * separate unit testcase file deleted * assert_image_tensor added to newly created 6 methods * test cases added for new 6 mthohds * removed wrongly pasted posterize method and added solarize method for testing Reviewed By: fmassa Differential Revision: D25679214 fbshipit-source-id: 60ca5c1e6a653195a3dd07755b7ac7fa6d4eaf4b Co-authored-by: Vasilis Vryniotis <[email protected]> Co-authored-by: Vasilis Vryniotis <[email protected]>
Fixes #3159