Skip to content

Commit

Permalink
Merge pull request #41 from grommy/31-fix-save-model-error
Browse files Browse the repository at this point in the history
Fixed issue #31. Error on model saving
  • Loading branch information
richliao authored Sep 12, 2019
2 parents 93c9e2f + f3ff6c1 commit 3d6f630
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions textClassifierHATT.py
Original file line number Diff line number Diff line change
Expand Up @@ -143,9 +143,9 @@ def __init__(self, attention_dim):

def build(self, input_shape):
assert len(input_shape) == 3
self.W = K.variable(self.init((input_shape[-1], self.attention_dim)))
self.b = K.variable(self.init((self.attention_dim, )))
self.u = K.variable(self.init((self.attention_dim, 1)))
self.W = K.variable(self.init((input_shape[-1], self.attention_dim)), name='W')
self.b = K.variable(self.init((self.attention_dim, )), name='b')
self.u = K.variable(self.init((self.attention_dim, 1)), name='u')
self.trainable_weights = [self.W, self.b, self.u]
super(AttLayer, self).build(input_shape)

Expand Down

0 comments on commit 3d6f630

Please sign in to comment.