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

Generalize adapter merge strategy for future adapters #4091

Merged
merged 3 commits into from
Apr 30, 2022

Conversation

titu1994
Copy link
Collaborator

@titu1994 titu1994 commented Apr 30, 2022

Signed-off-by: smajumdar titu1994@gmail.com

What does this PR do ?

Generalize the way adapters are merged with their input, so as to allow more complicated adapters for the future, such as SimAdapter or MetaAdapter

Collection: [Core, ASR]

Changelog

  • Add AbstractAdapterStrategy as a base strategy that is used for other adapter strategies
  • Add ResidualAddAdapterStrategy for simple residual addition between input and adapter output
  • Add tests

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

ericharper
ericharper previously approved these changes Apr 30, 2022
Copy link
Collaborator

@ericharper ericharper left a comment

Choose a reason for hiding this comment

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

LGTM. Thanks!

Signed-off-by: smajumdar <titu1994@gmail.com>
Signed-off-by: smajumdar <titu1994@gmail.com>
Signed-off-by: smajumdar <titu1994@gmail.com>
Copy link
Collaborator

@nithinraok nithinraok left a comment

Choose a reason for hiding this comment

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

Changes in ctc_models.py LGTM. Thanks!

@titu1994 titu1994 merged commit 142aa28 into NVIDIA:main Apr 30, 2022
@titu1994 titu1994 deleted the adapters_refactor branch April 30, 2022 03:50
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.

None yet

3 participants