Spaces:
Sleeping
Sleeping
Preechanon Chatthai
commited on
Commit
•
5b9b8c3
1
Parent(s):
6a88718
Update app.py
Browse files
app.py
CHANGED
@@ -32,7 +32,7 @@ def model_(n_gram = 21):
|
|
32 |
|
33 |
input1 = Input(shape=(21,),dtype='float32',name = 'char_input')
|
34 |
input2 = Input(shape=(21,),dtype='float32',name = 'type_input')
|
35 |
-
a = Embedding(178, 32
|
36 |
a = SpatialDropout1D(0.15)(a)
|
37 |
#a = TimestepDropout(0.05)(a)
|
38 |
char_input = BatchNormalization()(a)
|
@@ -52,7 +52,7 @@ def model_(n_gram = 21):
|
|
52 |
#lstm_char = Bidirectional(LSTM(64 ,return_sequences=True))(lstm_char)
|
53 |
#lstm_char = Attention(return_sequences=True)(lstm_char)
|
54 |
|
55 |
-
b = Embedding(12, 12
|
56 |
type_inputs = SpatialDropout1D(0.15)(b)
|
57 |
#type_inputs = TimestepDropout(0.05)(b)
|
58 |
x = Concatenate()([type_inputs, char_input, lstm_char, token_max])
|
|
|
32 |
|
33 |
input1 = Input(shape=(21,),dtype='float32',name = 'char_input')
|
34 |
input2 = Input(shape=(21,),dtype='float32',name = 'type_input')
|
35 |
+
a = Embedding(178, 32)(input1)
|
36 |
a = SpatialDropout1D(0.15)(a)
|
37 |
#a = TimestepDropout(0.05)(a)
|
38 |
char_input = BatchNormalization()(a)
|
|
|
52 |
#lstm_char = Bidirectional(LSTM(64 ,return_sequences=True))(lstm_char)
|
53 |
#lstm_char = Attention(return_sequences=True)(lstm_char)
|
54 |
|
55 |
+
b = Embedding(12, 12)(input2)
|
56 |
type_inputs = SpatialDropout1D(0.15)(b)
|
57 |
#type_inputs = TimestepDropout(0.05)(b)
|
58 |
x = Concatenate()([type_inputs, char_input, lstm_char, token_max])
|