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

Remove faulty adapter skip check in InvertibleAdaptersMixin #634

Merged
merged 1 commit into from
Jan 9, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 1 addition & 4 deletions src/adapters/model_mixin.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,10 +134,7 @@ def _get_active_setup(self):
adapter_setup = self.adapters_config.active_setup
else:
adapter_setup = None
skip_adapters = adapter_setup is None or (
self.adapters_config.skip_layers is not None and self.layer_idx in self.adapters_config.skip_layers
)
if not skip_adapters and (len(adapter_setup.flatten()) > 0):
if adapter_setup is not None and (len(adapter_setup.flatten()) > 0):
return adapter_setup
else:
return None
Expand Down
Loading