rcurtin_irc changed the topic of #mlpack to: mlpack: a scalable machine learning library (https://www.mlpack.org/) -- channel logs: https://libera.irclog.whitequark.org/mlpack -- NOTE: messages sent here might not be seen by bridged users on matrix, gitter, or slack
robobub has quit [Ping timeout: 240 seconds]
robobub has joined #mlpack
heisenbuugGopiMT has joined #mlpack
<akhunti1[m]> Hi Team,
<akhunti1[m]> I have created a Random Forest model using MLpack cli. When I used this model for inference using MLpack cli, I got a prediction score of 0.256234749665911. However, when I loaded this model using the Mlpack C++ load function and performed inference, I got a prediction score of 0.5053640966677341. Could you please let me know why there is a difference in the prediction score?
<akhunti1[m]> I also tried with other computer i got the same out put mentioned above .
<akhunti1[m]> I just wanted to inform you that I have not observed this type of difference for all the records. Out of the 6,000 records I tested, I found only one record that had this type of difference in probability.
<akhunti1[m]> Could you please guide me on any possible solutions or workarounds for this issue?
<akhunti1[m]> * I just wanted to inform you that I have not observed this type of difference for all the records. Out of the 6,000 records I tested, I found only one hundred records that had this type of difference in probability.
<akhunti1[m]> s/only/100/, s/one/records/, s/record//
<rcurtin[m]> the first difference, the very small one, didn't concern me much---that's probably a tiny floating point difference or something. this second one seems a bit more serious but I have a feeling it is a similar cause. can you tell us how you are loading the data and model in each case? and what format the data and model are saved in?
<akhunti1[m]> And this command is for c++ :
<akhunti1[m]> curl --http0.9 -X POST -H 'Content-Type: application/json' -d'{"data": { "ndarray": [4,5,0,0,0,0,0,0,0,0,0]}}' http://localhost:9000/api/v1.0/predictions
<rcurtin[m]> okay, I see... can you show what one of the points that has the difference in probability is, both when calling from C++ and in test.np.without_label.csv?
<akhunti1[m]> which having different probability
<akhunti1[m]> Did i answer your question correctly ?
<akhunti1[m]> yes both in c++ and test.np.without_label.csv file
<rcurtin[m]> okay, thanks... those points are simple enough that there should not be any floating point errors involved
<rcurtin[m]> are you sure that your JSON parsing code is correct? I think that you should carefully check that the point you are reading in your C++ model is exactly the same as what you just pasted above