Prageeth-1 commited on
Commit
fbea99b
·
verified ·
1 Parent(s): fe09de4

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -6
app.py CHANGED
@@ -112,7 +112,7 @@ with tab1:
112
  df = pd.read_csv(uploaded_file)
113
 
114
  # Load the fine-tuned news classifier
115
- classifier = pipeline("text-classification", model="Prageeth-1/News_classification.2")
116
 
117
  # Preprocess
118
  # Lowercase
@@ -206,7 +206,7 @@ with tab1:
206
  df["Class"] = df["preprocessed_content"].apply(lambda text: classifier(text)[0]["label"])
207
 
208
  #Delete Unnecessary columns
209
- df = df[['content','preprocessed_content','Class']]
210
 
211
 
212
  # Show results
@@ -217,10 +217,6 @@ with tab1:
217
  st.subheader("Class Distribution")
218
  class_dist = df['Class'].value_counts()
219
  st.bar_chart(class_dist)
220
-
221
-
222
- #Delete Unnecessary columns
223
- df = df[['content','Class']]
224
 
225
 
226
  # Download button
 
112
  df = pd.read_csv(uploaded_file)
113
 
114
  # Load the fine-tuned news classifier
115
+ classifier = pipeline("text-classification", model="Imasha17/News_classification.3")
116
 
117
  # Preprocess
118
  # Lowercase
 
206
  df["Class"] = df["preprocessed_content"].apply(lambda text: classifier(text)[0]["label"])
207
 
208
  #Delete Unnecessary columns
209
+ df = df[['content','Class']]
210
 
211
 
212
  # Show results
 
217
  st.subheader("Class Distribution")
218
  class_dist = df['Class'].value_counts()
219
  st.bar_chart(class_dist)
 
 
 
 
220
 
221
 
222
  # Download button