Skip to content

Commit

Permalink
Update train.py
Browse files Browse the repository at this point in the history
  • Loading branch information
Jack-Cherish authored Jan 30, 2018
1 parent 461a7cc commit dec0ff9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Discuz/train.py
Original file line number Diff line number Diff line change
Expand Up @@ -286,11 +286,11 @@ def crack_captcha_cnn(self, w_alpha=0.01, b_alpha=0.1):
# [?, 1024]
dense = tf.nn.relu(tf.add(tf.matmul(dense, w_d), b_d))
dense = tf.nn.dropout(dense, self.keep_prob)
# [1024, 37*4=148]
# [1024, 63*4=252]
w_out = tf.Variable(w_alpha*tf.random_normal([1024, self.max_captcha*self.char_set_len]))

b_out = tf.Variable(b_alpha*tf.random_normal([self.max_captcha*self.char_set_len]))
# [?, 148]
# [?, 252]
out = tf.add(tf.matmul(dense, w_out), b_out)
# out = tf.nn.softmax(out)
return out
Expand Down

0 comments on commit dec0ff9

Please sign in to comment.