-
Notifications
You must be signed in to change notification settings - Fork 11
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
Merge develop into main #58
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.
Comments suppressed due to low confidence (2)
fusion_bench/programs/fabric_fusion_program.py:188
- The previous implementation used 'pop' to remove the 'model' key from the dictionary, which is no longer present in the new implementation. This might lead to incorrect handling of the dictionary items.
report = {}
fusion_bench/method/task_singular_vector/utils/TSVM_utils.py:310
- [nitpick] The parameter name 'exclude_keys' is ambiguous. It should be renamed to 'exclude_svd_keys' to be more descriptive.
exclude_keys: Optional[List[str]] = None,
new_vector[key] = {} | ||
for i, task_vector in enumerate(task_vectors): | ||
vec = task_vector[key].to(accelerator) | ||
|
||
if len(task_vector[key].shape) == 2 and "text_projection" not in key: | ||
if len(task_vector[key].shape) == 2 and key not in exclude_keys: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The check for 'exclude_keys' should be done before checking the shape of the tensor to avoid unnecessary computations.
if len(task_vector[key].shape) == 2 and key not in exclude_keys: | |
if key in exclude_keys: |
Copilot is powered by AI, so mistakes are possible. Review output carefully before use.
Co-authored-by: Copilot <[email protected]>
No description provided.