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

[Tracker] Migrate test classes to use BaseTester and its functionalities. #2752

Open
johnnv1 opened this issue Jan 23, 2024 · 0 comments
Open
Labels
code heatlh 💊 Improvement the package code health Difficulty: easy Describes the difficulty of an issue to be solved help wanted Extra attention is needed
Milestone

Comments

@johnnv1
Copy link
Member

johnnv1 commented Jan 23, 2024

Following on from #2745

Our tests are grouped using classes for tests. In the past, we could not adopt our BaseTester everywhere, because it had some abstract methods which made it half annoying. With our kinda "new" BaseTester - from testing.base import BaseTester - we can adopt it everywhere.

What needs to be done:

  1. pickup a test file
  2. add the BaseTester as the parent class of the test classes
  3. update the assert_close to be self.assert_close
  4. update the test_gradcheck to use self.gradcheck instead of gradcheck from torch.autograd
  5. delete the use of tensor_to_gradcheck_var on the test_gradcheck - this is automatically handled by the BaseTester class
  6. extra: remove the dtype argument of the test_gradcheck and just run it using torch.float64
  7. open a PR :)

You can check #2745, which has done a bunch of these updates across our tests

The goal here is to reorganize our test suite. If you have any questions, you can call us and/or ask on our Slack page too Slack

@johnnv1 johnnv1 added help wanted Extra attention is needed Difficulty: easy Describes the difficulty of an issue to be solved code heatlh 💊 Improvement the package code health labels Jan 23, 2024
@johnnv1 johnnv1 added this to the kornia v0.8.0 milestone Jan 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
code heatlh 💊 Improvement the package code health Difficulty: easy Describes the difficulty of an issue to be solved help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

1 participant