Skip to content

Use constant refs for passing samples into encoder #712

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
merged 1 commit into from
Jun 5, 2025

Conversation

scotts
Copy link
Contributor

@scotts scotts commented Jun 4, 2025

Since we're using these values in a constant ref context anyway, we should pass them that way. In practice, this probably won't make much of a performance difference even if the samples are large since I believe tensors are already basically smart pointers. But it's good code hygiene.

@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Meta Open Source bot. label Jun 4, 2025
@scotts scotts marked this pull request as ready for review June 4, 2025 19:51
@NicolasHug NicolasHug merged commit d49d72c into pytorch:main Jun 5, 2025
45 of 47 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Meta Open Source bot.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants