Unverified Commit b6a8bb12 authored by guaneec's avatar guaneec Committed by GitHub

Fix merge

parent 91bb35b1
...@@ -60,7 +60,7 @@ class HypernetworkModule(torch.nn.Module): ...@@ -60,7 +60,7 @@ class HypernetworkModule(torch.nn.Module):
linears.append(torch.nn.LayerNorm(int(dim * layer_structure[i+1]))) linears.append(torch.nn.LayerNorm(int(dim * layer_structure[i+1])))
# Add dropout except last layer # Add dropout except last layer
if use_dropout and i < len(layer_structure) - 2: if use_dropout and i < len(layer_structure) - 3:
linears.append(torch.nn.Dropout(p=0.3)) linears.append(torch.nn.Dropout(p=0.3))
self.linear = torch.nn.Sequential(*linears) self.linear = torch.nn.Sequential(*linears)
...@@ -126,7 +126,7 @@ class Hypernetwork: ...@@ -126,7 +126,7 @@ class Hypernetwork:
filename = None filename = None
name = None name = None
def __init__(self, name=None, enable_sizes=None, layer_structure=None, activation_func=None, weight_init=None, add_layer_norm=False, use_dropout=False, activate_output=False) def __init__(self, name=None, enable_sizes=None, layer_structure=None, activation_func=None, weight_init=None, add_layer_norm=False, use_dropout=False, activate_output=False):
self.filename = None self.filename = None
self.name = name self.name = name
self.layers = {} self.layers = {}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment