Skip to content

Commit

Permalink
Fix init
Browse files Browse the repository at this point in the history
  • Loading branch information
calpt committed Oct 10, 2023
1 parent 5959efa commit 199fef5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/adapters/methods/adapter_layer_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,9 @@ class ComposableAdapterLayerBase(AdapterLayerBase):

def __init__(self, *args, **kwargs):
super().__init__(*args, **kwargs)
self._init_mapping()

def _init_mapping(self):
self.composition_to_func_map = {
Stack: self.compose_stack,
Fuse: self.compose_fuse,
Expand Down
1 change: 1 addition & 0 deletions src/adapters/methods/bottleneck.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ def __init__(self, location_key: str):
self.location_key = location_key

def init_adapters(self, model_config, adapters_config):
self._init_mapping()
self.model_config = model_config
self.adapters_config = adapters_config
self.adapters = nn.ModuleDict(dict())
Expand Down

0 comments on commit 199fef5

Please sign in to comment.