adil9858 commited on
Commit
e549286
1 Parent(s): ebc6dfd

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -1
app.py CHANGED
@@ -1,10 +1,13 @@
1
  import streamlit as st
2
  import pandas as pd
 
3
  from sklearn.naive_bayes import GaussianNB
4
  import joblib
5
 
6
  # Load the trained model
7
- model = joblib.load('naive_bayes_model.pkl')
 
 
8
 
9
  # Define the Streamlit app
10
  def main():
 
1
  import streamlit as st
2
  import pandas as pd
3
+ import pickle
4
  from sklearn.naive_bayes import GaussianNB
5
  import joblib
6
 
7
  # Load the trained model
8
+ # Load the trained model using pickle
9
+ with open('naive_bayes_model.pkl', 'rb') as file:
10
+ model = pickle.load(file)
11
 
12
  # Define the Streamlit app
13
  def main():