Skip to content

Port normalize, linear_transformation, compose, random_apply, gaussian_blur to pytest #4023

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

Merged

Conversation

vivekkumar7089
Copy link
Contributor

Refactor Group E as mentioned in #3987

  • group E
    • test_normalize
    • test_linear_transformation
    • test_compose
    • test_random_apply
    • test_gaussian_blur -- parametrize over meth_kwargs

@NicolasHug
Copy link
Member

Thanks @vivekkumar7089 ! from a quick look it looks like there were some merging issues: I see no deleted tested, and it seems that there are tests like test_five_crop etc that we recently ported in #4010

Would you mind fixing these?

@vivekkumar7089
Copy link
Contributor Author

@NicolasHug, I will fix them out.

torch.manual_seed(12)
transformed_tensor_script = scripted_fn(tensor)
assert_equal(transformed_tensor, transformed_tensor_script, msg="{}".format(transforms))
def test_five_crop(self):
Copy link
Member

Choose a reason for hiding this comment

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

I think this (and some other tests) should be left out, as they've been ported to pytest already

@vivekkumar7089
Copy link
Contributor Author

Hi @NicolasHug !!
Now can you please review, all those tests are removed or not?

Copy link
Member

@NicolasHug NicolasHug 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 @vivekkumar7089 ! LGTM

@NicolasHug NicolasHug merged commit 5d614bd into pytorch:master Jun 9, 2021
@github-actions
Copy link

github-actions bot commented Jun 9, 2021

Hey @NicolasHug!

You approved or merged this PR, but no labels were added.

@NicolasHug
Copy link
Member

Good bot!
CC @pmeier ;)

@vivekkumar7089 vivekkumar7089 deleted the port-test_transformtensor_to_pytest branch June 9, 2021 16:20
facebook-github-bot pushed a commit that referenced this pull request Jun 14, 2021
…, gaussian_blur to pytest (#4023)

Reviewed By: fmassa

Differential Revision: D29097715

fbshipit-source-id: 4e6b3a8f5fc82f45bd89223f86adb077be9ab576
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants