ml classification using with model for same data give other probabilities,
I developed small ML classification which use with python,
I created model with good precision and recall,
and then save it into pickle,
When I try test , I took one of the object from base data ,and run on pickle got other probabilities ,
If I created again the model and run with all base data getting all time the same values , but when use with his pickle got other results,
the code use with model look like this:
def text_to_features(doc, nlp_model):
print(doc)
try:
features = (nlp_model).transform(doc)
return True, features
except:
return False, ""
text_to_feature_success, ticket_features = text_to_features(df_case_specific, transformer)
def classifications_probabilities(features, classification_model):
try:
probabilities = (classification_model).predict_proba(features).tolist()[0]
return True, probabilities
except:
return False, []
#Predict flow probabilities
probabilities_success, predicted_flow_prob_list = classifications_probabilities(ticket_features, model)
Thanks,