Skip to content

added code for model merging and sparse training methods #167

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

Open
wants to merge 21 commits into
base: main
Choose a base branch
from

Conversation

SaminYeasar
Copy link

  • Added merging methods:
    • SLERP
    • LERP
    • TiesMerge: made correction
    • TaskArithmatic
    • ModelBreadcrumbs
    • UniformMerge
    • UniformSparseMerge
  • Added different scoring functions
    • grow and drop
    • layer drop + sparse
    • model wise sparse
    • gradient-magnitude based sparse
    • weight-magnitude based sparse
    • added backwardhook: will mask gradient during backdrop
  • iterative and one-shot sparse training
  • efficient sparse expert saving

def __init__(self, config: SLERPMergeConfig = None):
super().__init__(config or SLERPMergeConfig())

def load_mask(self, expert):
Copy link
Contributor

Choose a reason for hiding this comment

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

Is it possible to transition all logic for saving and loading of the mask to be done via the state_dict, as is currently implemented in the main branch?

In other words, can we remove the need for ever loading a .npz file?

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