Skip to content

Commit 7207e3b

Browse files
aria1thAUTOMATIC1111
authored andcommitted
remove duplicate keys and lowercase
1 parent de096d0 commit 7207e3b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

modules/hypernetworks/hypernetwork.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ class HypernetworkModule(torch.nn.Module):
3232
"tanh": torch.nn.Tanh,
3333
"sigmoid": torch.nn.Sigmoid,
3434
}
35-
activation_dict.update({cls_name: cls_obj for cls_name, cls_obj in inspect.getmembers(torch.nn.modules.activation) if inspect.isclass(cls_obj) and cls_obj.__module__ == 'torch.nn.modules.activation'})
35+
activation_dict.update({cls_name.lower(): cls_obj for cls_name, cls_obj in inspect.getmembers(torch.nn.modules.activation) if inspect.isclass(cls_obj) and cls_obj.__module__ == 'torch.nn.modules.activation'})
3636

3737
def __init__(self, dim, state_dict=None, layer_structure=None, activation_func=None, weight_init='Normal', add_layer_norm=False, use_dropout=False):
3838
super().__init__()

0 commit comments

Comments
 (0)