Skip to content
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

Improved functional tensor geom transforms to work on floatX dtype #2661

Merged

Conversation

vfdev-5
Copy link
Collaborator

@vfdev-5 vfdev-5 commented Sep 9, 2020

Fixes #2600

Description:

Improved functional tensor geom transforms to work on floatX dtype

  • added tests
  • refactored test_affine

@vfdev-5 vfdev-5 requested a review from fmassa September 10, 2020 14:11
@codecov
Copy link

codecov bot commented Sep 11, 2020

Codecov Report

Merging #2661 into master will decrease coverage by 0.26%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #2661      +/-   ##
==========================================
- Coverage   72.41%   72.15%   -0.27%     
==========================================
  Files          95       95              
  Lines        8245     8379     +134     
  Branches     1308     1365      +57     
==========================================
+ Hits         5971     6046      +75     
- Misses       1858     1921      +63     
+ Partials      416      412       -4     
Impacted Files Coverage Δ
torchvision/transforms/functional_tensor.py 67.66% <100.00%> (+0.81%) ⬆️
torchvision/io/video.py 54.77% <0.00%> (-15.06%) ⬇️
torchvision/transforms/functional.py 80.97% <0.00%> (-0.58%) ⬇️
torchvision/datasets/samplers/clip_sampler.py 85.60% <0.00%> (+6.05%) ⬆️
torchvision/io/image.py 79.41% <0.00%> (+7.67%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a4736ea...27b298f. Read the comment docs.

Copy link
Member

@fmassa fmassa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just one comment about float16, otherwise looks great!

Let me know if you disagree with the float16 reasoning.

torchvision/transforms/functional_tensor.py Outdated Show resolved Hide resolved
Copy link
Member

@fmassa fmassa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks a lot @vfdev-5 !

@fmassa fmassa merged commit 5547747 into pytorch:master Sep 14, 2020
@vfdev-5 vfdev-5 deleted the vfdev-5/issue-2600-support-floatX-types branch September 14, 2020 13:45
bryant1410 pushed a commit to bryant1410/vision-1 that referenced this pull request Nov 22, 2020
…ytorch#2661)

* Improved functional tensor geom transforms to work on floatX dtype
- Fixes pytorch#2600
- added tests
- refactored test_affine

* Removed float16/cpu case
vfdev-5 added a commit to Quansight/vision that referenced this pull request Dec 4, 2020
…ytorch#2661)

* Improved functional tensor geom transforms to work on floatX dtype
- Fixes pytorch#2600
- added tests
- refactored test_affine

* Removed float16/cpu case
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Improve transforms if input is tensor on CUDA
2 participants