Mpavan45 commited on
Commit
adb4ddb
·
verified ·
1 Parent(s): 4092ad2

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -5
app.py CHANGED
@@ -8,9 +8,9 @@ import pandas as pd
8
  # Load Model
9
  model = tf.keras.models.load_model("news_classification_rnn.h5")
10
 
11
- # Load Preprocessing Function
12
- with open("preprocessing1.pkl", "rb") as f:
13
- clean_text = pickle.load(f)
14
 
15
  # Load TF-IDF Vectorizer
16
  with open("text_vectorizer.pkl", "rb") as f:
@@ -27,8 +27,8 @@ user_input = st.text_area("Enter News Text:", "")
27
 
28
  if st.button("Classify"):
29
  if user_input:
30
- # Preprocess Input
31
- processed_text = clean_text(user_input)
32
 
33
  # Convert text to integer sequence
34
  text_sequence = tokenizer.texts_to_sequences([processed_text])
 
8
  # Load Model
9
  model = tf.keras.models.load_model("news_classification_rnn.h5")
10
 
11
+ # # Load Preprocessing Function
12
+ # with open("preprocessing1.pkl", "rb") as f:
13
+ # clean_text = pickle.load(f)
14
 
15
  # Load TF-IDF Vectorizer
16
  with open("text_vectorizer.pkl", "rb") as f:
 
27
 
28
  if st.button("Classify"):
29
  if user_input:
30
+ # # Preprocess Input
31
+ # processed_text = clean_text(user_input)
32
 
33
  # Convert text to integer sequence
34
  text_sequence = tokenizer.texts_to_sequences([processed_text])