Skip to content

Conversation

peterbell10
Copy link
Collaborator

@peterbell10 peterbell10 commented Sep 6, 2022

Stack from ghstack (oldest at bottom):

This also includes a small list exception for single element lists since none of the memory usage or performance implications of lists apply there.

@facebook-github-bot
Copy link
Contributor

facebook-github-bot commented Sep 6, 2022

🔗 Helpful links

✅ No Failures (31 Pending)

As of commit a8fc80a (more details on the Dr. CI page):

Expand to see more

💚 💚 Looks good so far! There are no failures yet. 💚 💚


This comment was automatically generated by Dr. CI (expand for details).

Please report bugs/suggestions to the (internal) Dr. CI Users group.

Click here to manually regenerate this comment.

@peterbell10 peterbell10 marked this pull request as draft September 6, 2022 14:46
@pytorch-bot
Copy link

pytorch-bot bot commented Sep 8, 2022

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/84567

Note: Links to docs will display an error until the docs builds have been completed.

✅ No Failures

As of commit 7652954:
💚 Looks good so far! There are no failures yet. 💚

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@pytorch-bot pytorch-bot bot added the topic: not user facing topic category label Sep 20, 2022
This does include a small list exception for less than 4 elements,
but that will be tightened to 1 element in a follow-up PR.

[ghstack-poisoned]
@peterbell10 peterbell10 marked this pull request as ready for review October 17, 2022 12:29
@peterbell10 peterbell10 added the module: testing Issues related to the torch.testing module (not tests) label Oct 17, 2022
@peterbell10 peterbell10 requested a review from mruberry October 17, 2022 12:30
self.assertEqual(s2.name, "foo")


class TestOpInfoSampleFunctions(TestCase):
Copy link
Collaborator

Choose a reason for hiding this comment

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

Add a comment describing this class

else:
self.assertIsInstance(item, Generator)

@ops(op_db, dtypes=OpDTypes.any_one)
Copy link
Collaborator

Choose a reason for hiding this comment

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

These tests make a lot of sense (comments describing each one, please!)

Should we consider adding these checks to the tests in test_ops.py that exercise these generators, instead? That's not conceptually ideal because then those tests are testing multiple things (they probably already are), but it would reduce duplicative work in the test suite, which does a lot already. Or are these new tests so fast we shouldn't be concerned about their speed?

An example of a similar case is the test for "input" tensors having no grad history, which is in the noncontiguous samples test:

# Verifies sample input tensors should have no grad or history

cc @lezcano

Copy link
Collaborator

@lezcano lezcano Oct 17, 2022

Choose a reason for hiding this comment

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

A great thing to have would be a test that tests OpInfo samples themselves, and have all these tests grouped there. Until then, if this test is fast enough, it's probably good enough.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

On my machine

time pytest test_testing.py -k TestOpInfoSampleFunctions

takes less than 10 seconds even on a build with CUDA. So I'm not particularly concerned.

On the other hand if we combine these checks into an existing test, then the test is more likely to be skipped for no good reason.

Copy link
Collaborator

Choose a reason for hiding this comment

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

SGTM

peterbell10 added a commit to peterbell10/pytorch that referenced this pull request Oct 17, 2022
This also includes a small list exception for single element lists.

ghstack-source-id: 9c6f73b
Pull Request resolved: pytorch#84567
This also includes a small list exception for single element lists since none of the memory usage or performance implications of lists apply there.

[ghstack-poisoned]
peterbell10 added a commit that referenced this pull request Oct 17, 2022
This also includes a small list exception for single element lists.

ghstack-source-id: 38914eb
Pull Request resolved: #84567
Copy link
Collaborator

@lezcano lezcano left a comment

Choose a reason for hiding this comment

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

Good stuff.

@pytorch-bot pytorch-bot bot added the ciflow/trunk Trigger trunk jobs on your pull request label Oct 18, 2022
Copy link
Collaborator

@mruberry mruberry left a comment

Choose a reason for hiding this comment

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

Timing looks good, but see notes requesting additional comments and the lint failure may be real!

This also includes a small list exception for single element lists since none of the memory usage or performance implications of lists apply there.

[ghstack-poisoned]
peterbell10 added a commit that referenced this pull request Oct 19, 2022
This also includes a small list exception for single element lists.

ghstack-source-id: 6ef0f06
Pull Request resolved: #84567
…rns a generator"


This also includes a small list exception for single element lists since none of the memory usage or performance implications of lists apply there.

[ghstack-poisoned]
peterbell10 added a commit that referenced this pull request Oct 20, 2022
This also includes a small list exception for single element lists.

ghstack-source-id: cc6164a
Pull Request resolved: #84567
@peterbell10
Copy link
Collaborator Author

@pytorchbot merge

@pytorchmergebot
Copy link
Collaborator

Merge started

Your change will be merged once all checks pass (ETA 0-4 Hours).

Learn more about merging in the wiki.

Questions? Feedback? Please reach out to the PyTorch DevX Team

Advanced Debugging
Check the merge workflow status
here

@pytorchmergebot
Copy link
Collaborator

Merge failed

Reason: The following mandatory check(s) failed (Rule Core Reviewers):

Dig deeper by viewing the failures on hud

Details for Dev Infra team Raised by workflow job

This also includes a small list exception for single element lists since none of the memory usage or performance implications of lists apply there.

[ghstack-poisoned]
peterbell10 added a commit that referenced this pull request Oct 21, 2022
This also includes a small list exception for single element lists.

ghstack-source-id: 4d8f9e9
Pull Request resolved: #84567
@peterbell10
Copy link
Collaborator Author

@pytorchbot merge

@pytorchmergebot
Copy link
Collaborator

Merge started

Your change will be merged once all checks pass (ETA 0-4 Hours).

Learn more about merging in the wiki.

Questions? Feedback? Please reach out to the PyTorch DevX Team

Advanced Debugging
Check the merge workflow status
here

kulinseth pushed a commit to kulinseth/pytorch that referenced this pull request Nov 5, 2022
…#84567)

This also includes a small list exception for single element lists since none of the memory usage or performance implications of lists apply there.
Pull Request resolved: pytorch#84567
Approved by: https://github.com/lezcano, https://github.com/mruberry
kulinseth pushed a commit to kulinseth/pytorch that referenced this pull request Dec 10, 2022
…#84567)

This also includes a small list exception for single element lists since none of the memory usage or performance implications of lists apply there.
Pull Request resolved: pytorch#84567
Approved by: https://github.com/lezcano, https://github.com/mruberry
@facebook-github-bot facebook-github-bot deleted the gh/peterbell10/417/head branch June 8, 2023 18:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ciflow/trunk Trigger trunk jobs on your pull request cla signed Merged module: testing Issues related to the torch.testing module (not tests) open source topic: not user facing topic category

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants