Python Forum
GradientBoostingClassifier and hashed values - Printable Version

+- Python Forum (https://python-forum.io)
+-- Forum: Python Coding (https://python-forum.io/forum-7.html)
+--- Forum: Homework (https://python-forum.io/forum-9.html)
+--- Thread: GradientBoostingClassifier and hashed values (/thread-7633.html)



GradientBoostingClassifier and hashed values - metalray - Jan-18-2018

Hi,

I noticed that my GradientBoostingClassifier treats my hash content as values and not
as class. Why would that be?


test_df['agency_name'] = test_df['agency_name'].apply(hash)    
test_df['inspector_name'] = test_df['inspector_name'].apply(hash)          
test_df.fillna(value=0, inplace=True)
X_train, X_test, y_train, y_test = train_test_split(test_df.iloc[:,:-1], test_df.iloc[:,-1], random_state=0)  

clftwo = GradientBoostingClassifier(random_state = 0)
clftwo.fit(X_train1, y_train1)  



RE: GradientBoostingClassifier and hashed values - nilamo - Jan-18-2018

Is that from some sort of package? What's a GradientBoostingClassifier?


RE: GradientBoostingClassifier and hashed values - metalray - Jan-22-2018

Hi nilamo,

its a method in machine learning to classify information to see if they are of use or not.

from sklearn.ensemble import GradientBoostingClassifier