Hello Everyone, now I’m trying to build a crop recommendation model using XGBoost Classifier but the accuracy, f1 score, precision, and recall results are so bad, I applied feature engineering but it is the same, can I get a help to improve the model performance?
I am no expert in this area (neither XGBoost nor crop science), but I can perhaps get the conversation started.
A few questions to further detail the issue:
-
What are the classes you are trying to predict with this model?
-
Can you say a little about the dataset you are using? What are the features, and how many labeled examples do you have?
-
Do you have reason to believe that XGBoost is a good model for this task? If so, please elaborate.
-
What ML courses have you attended?
The goal of the problem is to predict “not classify sorry” which crop I can Recommend to plant it according to weather status and soil properties
- Features of my dataset :
- Data Label Class :
I already tried Random Forest Algorithm too but there is no different, I tried to apply upsampling (SMOTE) technique too to solve the problem of imbalanced data but no change - Courses I attended is ML Specialization from Coursera and some courses from youtube, it is the first time to solve a problem like that by the way and first time to use XGBoost too
I can Share the notebook of my code if u want
Thanks in advance
So this is a multi-classification model.
Have you converted the labels to a one-hot representation?
yes, I did
hi @Sahar_Hamdi
how were the result of xgboost without upsampling SMOTE??
the data label list you shared is original data list or the upsampling list? as that would be containing synthetic data to balance the minor classes.
Also what is the data type of the soil condition and weather condition columns, as I see these columns also seems to have different types, so first make a chart based on classes how the soil conditions and weather conditions are divided, then check if the distribution is not too imbalanced, if it is, then using SMOTE wouldn’t help you create a good predictive model.
You also need to share screenshots of the results of predictive model which you got and what better results are expecting in terms predictive model as here weather and soil conditions both can’t be predicted as accurately as possible as it could be seasonal drought one year or any other year you might find floods.
So based on the columns I noticed seems like description model or as the other mentor mentioned creating a classification model would give some overview on which soil conditions or weather is suitable for which crops or I should say your multiclass labels.
Regards
DP
Hi @Deepti_Prasad
The result was the same, okay I will try that
many thanks for your help