from tensorflow.keras.layers import Dense,Flatten, Embedding,Input
from tensorflow.keras.models import Model
from tensorflow.keras.preprocessing import sequence,text
from tensorflow.keras.metrics import binary_accuracy
from tensorflow.keras.preprocessing.sequence import pad_sequences
from tensorflow.keras.preprocessing.text import one_hot
import numpy as np
# define class labels
labels = np.array([1, 1, 1, 1, 1, 0, 0, 0, 0, 0])
max_length=4
size=50
encode_docs=[one_hot(d,size) for d in docs]