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

Small improvements to utils #1513

Merged
merged 2 commits into from
Oct 9, 2023

Conversation

BloodAxe
Copy link
Contributor

@BloodAxe BloodAxe commented Oct 9, 2023

Minor PR with two changes:

  • Inside maybe_all_reduce_tensor_average we enforce reduced tensor is dense. Got crash when tried to observe a specific loss component (loss[4] and since indexing does not create a new tensor but rather a view this failed to work with all_reduce).
  • convert_to_tensor now create tensor from numpy in a bit more efficient fashion straight on target device.

Copy link
Contributor

@shaydeci shaydeci left a comment

Choose a reason for hiding this comment

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

LGTM

@BloodAxe BloodAxe merged commit 8de553f into master Oct 9, 2023
3 checks passed
@BloodAxe BloodAxe deleted the feature/SG-000-small-improvements-to-uilts branch October 9, 2023 14:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants