Skip to content

Commit 91e8cdb

Browse files
author
Suwon Shon
committed
revised for datatype
1 parent e20ac1a commit 91e8cdb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

scripts/siamese_model.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ def xavier_init(self,n_inputs, n_outputs, uniform=True):
5151

5252
def fc_layer(self, bottom, n_weight, name):
5353
print( bottom.get_shape())
54-
n_prev_weight = bottom.get_shape()[1]
54+
n_prev_weight = int(bottom.get_shape()[1])
5555
initer = self.xavier_init(int(n_prev_weight),n_weight)
5656
W = tf.get_variable(name+'W', dtype=tf.float32, shape=[n_prev_weight, n_weight], initializer=initer)
5757
b = tf.get_variable(name+'b', dtype=tf.float32, initializer=tf.random_uniform([n_weight],-0.001,0.001, dtype=tf.float32))

0 commit comments

Comments
 (0)