Skip to content
This repository was archived by the owner on Nov 15, 2022. It is now read-only.

Fixed cuda sync #183

Merged
merged 3 commits into from
Jun 18, 2020
Merged

Fixed cuda sync #183

merged 3 commits into from
Jun 18, 2020

Conversation

izdeby
Copy link
Contributor

@izdeby izdeby commented Jun 17, 2020

Fixed a bug with not passing cuda argument to benchmarks.

@izdeby izdeby requested a review from cpuhrsch June 17, 2020 18:04
@@ -135,7 +135,7 @@ def _batch_norm_nt():
def max_pool2d_tensor_iter(self, module):
def _max_pool2d_tensor_iter():
for t in self.inputs:
module(t.unsqueeze(0)).squeeze(0)
res = module(t.unsqueeze(0)).squeeze(0)
Copy link
Contributor

Choose a reason for hiding this comment

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

why not accumulate in a list? I'd imagine the garbage collector could still get rid of this the next iteration around since it's not referenced anymore.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

hmm. fair enough. let me try and see if behavior changes

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Didn't show any effect yet so removing these changes for now.

@izdeby izdeby merged commit 17fbe15 into pytorch:master Jun 18, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants