Skip to content

Functional affine documentation for Version 1.6.0 on torchvision.functional.transform.affine does not match code #2551

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

Closed
Mut1nyJD opened this issue Aug 4, 2020 · 3 comments

Comments

@Mut1nyJD
Copy link

Mut1nyJD commented Aug 4, 2020

📚 Documentation

If you check the documentation on pytorch.org go to Libraries torchvision/ transforms / functional transforms

https://pytorch.org/docs/stable/torchvision/transforms.html#functional-transforms

Look at torchvision.transforms.functional.affine
the documentation says under parameters:

img (PIL Image or Tensor) – image to be rotated.

But when you actually use a tensor as input using the official pywheel torchvision0.7cu101 package a tensor import is not supported if you look at the source code torchvision/transforms/functional.py from the installed package, there is a line like this:

if not _is_pil_image(img):
raise TypeError('img should be PIL Image. Got {}'.format(type(img)))

Also that source code from the installed package for the function does not match the source link in the pytorch.,org online documentation

@fmassa
Copy link
Member

fmassa commented Aug 4, 2020

Hi,

I think there might be an issue with the documentation, which is pointing to the master branch and not the 1.6.0 branch.

@jlin27 can you look into this?

@jlin27
Copy link

jlin27 commented Aug 10, 2020

Looks like for the last release, the vision docs were pinned to another version instead of release/0.7. I'll check if there is any issue reversing that and if not, re-build the docs based off of stable

Commit hash called from here and set here.

@jlin27
Copy link

jlin27 commented Aug 19, 2020

Rebuilt the docs and pushed out the release/0.7 vision docs in this PR: pytorch/pytorch.github.io#458

@jlin27 jlin27 closed this as completed Aug 19, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants