Skip to content

Conversation

@nune-tadevosyan
Copy link
Collaborator

@nune-tadevosyan nune-tadevosyan commented Jun 16, 2025

  • Replace FlashAttention with torch based implementation
  • Add masking for paddings

GitHub Actions CI

The Jenkins CI system has been replaced by GitHub Actions self-hosted runners.

The GitHub Actions CI will run automatically when the "Run CICD" label is added to the PR.
To re-run CI remove and add the label again.
To run CI on an untrusted fork, a NeMo user with write access must first click "Approve and run".

Before your PR is "Ready for review"

Pre checks:

  • Make sure you read and followed Contributor guidelines
  • Did you write any new necessary tests?
  • Did you add or update any necessary documentation?
  • Does the PR affect components that are optional to install? (Ex: Numba, Pynini, Apex etc)
    • Reviewer: Does the PR have correct import guards for all optional libraries?

PR Type:

  • New Feature
  • Bugfix
  • Documentation

If you haven't finished some of the above items you can still open "Draft" PR.

Who can review?

Anyone in the community is free to review the PR once the checks have passed.
Contributor guidelines contains specific people who can review PRs to various areas.

Additional Information

  • Related to # (issue)

Signed-off-by: Nune <ntadevosyan@nvidia.com>
Signed-off-by: Nune <ntadevosyan@nvidia.com>
Signed-off-by: Nune <ntadevosyan@nvidia.com>
@github-actions github-actions bot added the ASR label Jun 16, 2025
@nune-tadevosyan nune-tadevosyan requested a review from pzelasko June 16, 2025 13:44
return ans

def normalize_matrices(self):
with torch.no_grad():
Copy link
Collaborator

Choose a reason for hiding this comment

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

why remove torch.no_grad?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Missed it. Updated

from collections import OrderedDict
from dataclasses import dataclass

from rotary_embedding_torch import RotaryEmbedding
Copy link
Collaborator

Choose a reason for hiding this comment

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

double import

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Removed



def justnorm(x, fp32: bool = False, idim: int = -1):
def justnorm(x, fp32: bool = False, idim: int = -1,eps: float = 1e-10):
Copy link
Collaborator

@pzelasko pzelasko Jun 17, 2025

Choose a reason for hiding this comment

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

instead of 1e-10 which might be not representable in low precision types, use torch.finfo(x.dtype).eps https://docs.pytorch.org/docs/stable/type_info.html#torch.torch.finfo

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Done

nune-tadevosyan and others added 2 commits June 17, 2025 17:35
Signed-off-by: Nune <ntadevosyan@nvidia.com>
Signed-off-by: nune-tadevosyan <152167970+nune-tadevosyan@users.noreply.github.com>
@nune-tadevosyan nune-tadevosyan marked this pull request as ready for review June 17, 2025 13:49
@pzelasko pzelasko merged commit 3ef3971 into asr-aed-ngpt Jun 17, 2025
18 checks passed
@pzelasko pzelasko deleted the rope-asr-aed-ngpt branch June 17, 2025 14:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants