fmcquillan99 commented on issue #408: DL: Fix predict with 'NULL' string class values URL: https://github.com/apache/madlib/pull/408#issuecomment-500069416 OK, I see what you mean. (a) I tried again with postgres NULL and got this validation accuracy: ``` madlib=# SELECT * FROM iris_validate; loss | metric | metrics_type -------------------+-------------------+-------------- 0.370797485113144 | 0.966666638851166 | {accuracy} (1 row) ``` and got for 'response' : ``` id | estimated_class_text -----+---------------------- 1 | Iris-setosa 17 | Iris-setosa 22 | Iris-setosa 25 | Iris-setosa 30 | Iris-setosa 33 | Iris-setosa 35 | Iris-setosa 36 | Iris-setosa 37 | Iris-setosa 43 | Iris-setosa 54 | Iris-versicolor 60 | Iris-versicolor 61 | Iris-versicolor 65 | Iris-versicolor 78 | Iris-versicolor 83 | Iris-versicolor 85 | 86 | Iris-versicolor 87 | Iris-versicolor 89 | Iris-versicolor 90 | Iris-versicolor 101 | 102 | 105 | 107 | 111 | 116 | 122 | 130 | 132 | (30 rows) ``` and for 'prob' got: ``` id | prob_NULL | prob_Iris-setosa | prob_Iris-versicolor -----+--------------+------------------+---------------------- 1 | 0.0058149546 | 0.9535293 | 0.040655766 17 | 0.0029750224 | 0.9685903 | 0.028434642 22 | 0.0064940196 | 0.94757706 | 0.045928854 25 | 0.01801381 | 0.90317166 | 0.0788145 30 | 0.015129516 | 0.91151124 | 0.073359266 33 | 0.0025097213 | 0.9788625 | 0.018627675 35 | 0.011897468 | 0.92281824 | 0.06528429 36 | 0.0066208234 | 0.9458502 | 0.047529057 37 | 0.003969666 | 0.96007407 | 0.03595623 43 | 0.010739818 | 0.9353564 | 0.053903878 54 | 0.41993847 | 0.056902103 | 0.5231593 60 | 0.41656876 | 0.08917717 | 0.49425402 61 | 0.36664253 | 0.071211495 | 0.56214595 65 | 0.23836957 | 0.124019586 | 0.6376108 78 | 0.43752182 | 0.038337186 | 0.5241411 83 | 0.2775729 | 0.08097425 | 0.6414528 85 | 0.5225256 | 0.06703041 | 0.41044396 86 | 0.37119105 | 0.088775426 | 0.54003346 87 | 0.3131629 | 0.052819572 | 0.6340176 89 | 0.33914825 | 0.092558645 | 0.56829304 90 | 0.39448565 | 0.06741446 | 0.5380998 101 | 0.7732106 | 0.01892336 | 0.207866 102 | 0.7110707 | 0.025220562 | 0.26370868 105 | 0.746146 | 0.016710982 | 0.23714297 107 | 0.69249976 | 0.04219299 | 0.26530722 111 | 0.53794557 | 0.041301906 | 0.42075253 116 | 0.6647183 | 0.0316999 | 0.30358183 122 | 0.70391405 | 0.03334239 | 0.2627436 130 | 0.52652866 | 0.018300744 | 0.4551706 132 | 0.52941144 | 0.01968225 | 0.45090634 (30 rows) ``` which seems fine. (b) Testing with string 'NULL' with 'response' : ``` id | estimated_class_text -----+---------------------- 2 | Iris-setosa 17 | Iris-setosa 19 | Iris-setosa 24 | Iris-setosa 28 | Iris-setosa 42 | Iris-setosa 50 | Iris-setosa 51 | Iris-versicolor 53 | NULL 61 | Iris-versicolor 65 | Iris-setosa 68 | Iris-versicolor 74 | NULL 81 | Iris-versicolor 82 | Iris-versicolor 85 | NULL 91 | NULL 94 | Iris-versicolor 98 | Iris-versicolor 102 | NULL 104 | NULL 110 | NULL 121 | NULL 123 | NULL 132 | NULL 133 | NULL 138 | NULL 140 | NULL 145 | NULL 147 | NULL (30 rows) ``` with prob: ``` id | prob_Iris-setosa | prob_Iris-versicolor | prob_"NULL -----+------------------+----------------------+------------- 2 | 0.86741406 | 0.11051855 | 0.022067426 17 | 0.9408939 | 0.04947116 | 0.009634982 19 | 0.92537063 | 0.064182 | 0.010447428 24 | 0.8627186 | 0.108796224 | 0.028485179 28 | 0.9129784 | 0.073638536 | 0.013383085 42 | 0.7377237 | 0.2109664 | 0.051309958 50 | 0.8998648 | 0.08398796 | 0.016147207 51 | 0.28117836 | 0.3808793 | 0.3379423 53 | 0.21290395 | 0.37267473 | 0.41442132 61 | 0.22640292 | 0.40469477 | 0.36890227 65 | 0.34674126 | 0.31846282 | 0.3347959 68 | 0.3128222 | 0.38111794 | 0.30605987 74 | 0.22101794 | 0.37295923 | 0.40602285 81 | 0.25727415 | 0.38995618 | 0.35276967 82 | 0.29354596 | 0.39554545 | 0.3109085 85 | 0.19547577 | 0.28230718 | 0.5222171 91 | 0.20004117 | 0.35288966 | 0.44706917 94 | 0.307107 | 0.3765777 | 0.31631526 98 | 0.26774555 | 0.3694436 | 0.36281085 102 | 0.082255706 | 0.25484738 | 0.66289693 104 | 0.08049299 | 0.26610076 | 0.65340626 110 | 0.05680401 | 0.1775315 | 0.7656645 121 | 0.06644246 | 0.23137672 | 0.7021808 123 | 0.06698035 | 0.32560945 | 0.6074102 132 | 0.11041918 | 0.28520143 | 0.60437936 133 | 0.06854575 | 0.24578539 | 0.6856689 138 | 0.09461178 | 0.2672287 | 0.6381595 140 | 0.078201465 | 0.26475808 | 0.6570405 145 | 0.06050809 | 0.177617 | 0.76187485 147 | 0.089041755 | 0.30964842 | 0.60130984 ```
---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected] With regards, Apache Git Services
