Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -47,7 +47,7 @@ def train(data: str, message: str):
|
|
47 |
|
48 |
model.fit(X, y, epochs=10, batch_size=8, workers=4, use_multiprocessing=True)
|
49 |
tokens = tokenizer.texts_to_sequences([message,])[0]
|
50 |
-
prediction = model.predict(np.array((list(tokens)+[0,]*inp_len)[:inp_len]))
|
51 |
max_o = 0
|
52 |
max_v = 0
|
53 |
for ind, i in enumerate(prediction):
|
|
|
47 |
|
48 |
model.fit(X, y, epochs=10, batch_size=8, workers=4, use_multiprocessing=True)
|
49 |
tokens = tokenizer.texts_to_sequences([message,])[0]
|
50 |
+
prediction = model.predict(np.array([(list(tokens)+[0,]*inp_len)[:inp_len],]))
|
51 |
max_o = 0
|
52 |
max_v = 0
|
53 |
for ind, i in enumerate(prediction):
|