Skip to content

Perf improvement for TopK Accuracy and return all topK in Classification Evaluator #5395

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 29 commits into from
Dec 9, 2020
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
5fbf740
Fix for issue 744
jasallen Sep 8, 2020
1747d3e
cleanup
jasallen Sep 9, 2020
32c244a
fixing report output
jasallen Sep 12, 2020
968b58d
fixedTestReferenceOutputs
jasallen Sep 12, 2020
b7ded43
Fixed test reference outputs for NetCore31
jasallen Sep 12, 2020
685eeb4
change top k acc output string format
jasallen Nov 5, 2020
1eacec7
Ranking algorithm now uses first appearance in dataset rather than wo…
jasallen Nov 6, 2020
ea057ff
fixed benchmark
jasallen Nov 6, 2020
ac08554
various minor changes from code review
jasallen Nov 6, 2020
f0de3ea
limit TopK to OutputTopKAcc parameter
jasallen Nov 6, 2020
30fbd6f
top k output name changes
jasallen Nov 6, 2020
495b4b0
make old TopK readOnly
jasallen Nov 6, 2020
c3afe15
restored old baselineOutputs since respecting outputTopK param means …
jasallen Nov 6, 2020
bfcda22
fix test fails, re-add names parameter
jasallen Nov 6, 2020
563768c
Clean up commented code
jasallen Nov 6, 2020
4a5597a
that'll teach me to edit from the github webpage
jasallen Nov 6, 2020
71390bd
use existing method, fix nits
jasallen Nov 19, 2020
32ab9fa
Slight comment change
jasallen Nov 20, 2020
db2b6b5
Comment change / Touch to kick off build pipeline
jasallen Nov 21, 2020
0d0493b
fix whitespace
jasallen Nov 23, 2020
e6aec98
Merge branch 'master' into jasallenbranch
antoniovs1029 Dec 3, 2020
05e7f91
Added new test
antoniovs1029 Dec 4, 2020
49786ed
Code formatting nits
justinormont Dec 8, 2020
9259031
Code formatting nit
justinormont Dec 8, 2020
98458ba
Fixed undefined rankofCorrectLabel and trailing whitespace warning
antoniovs1029 Dec 8, 2020
86f5c3f
Removed _numUnknownClassInstances and added test for unknown labels
antoniovs1029 Dec 8, 2020
741e9fb
Add weight to seenRanks
antoniovs1029 Dec 8, 2020
dadf793
Nits
antoniovs1029 Dec 9, 2020
9e67751
Removed FastTree import
antoniovs1029 Dec 9, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
restored old baselineOutputs since respecting outputTopK param means …
…no topK in most test output
  • Loading branch information
jasallen committed Nov 6, 2020
commit c3afe152f2a1cc29b38ca77c4b71fe9cade35fd4
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,6 @@ Accuracy(micro-avg): 0.936709
Accuracy(macro-avg): 0.942857
Log-loss: 0.285741
Log-loss reduction: 0.737254
Top K accuracy(All K)K=1: 0.936709
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

Confusion table
||========================
Expand All @@ -41,10 +37,6 @@ Accuracy(micro-avg): 0.957746
Accuracy(macro-avg): 0.953030
Log-loss: 0.160970
Log-loss reduction: 0.851729
Top K accuracy(All K)K=1: 0.957746
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,6 @@ Accuracy(micro-avg): 0.936709
Accuracy(macro-avg): 0.942857
Log-loss: 0.285741
Log-loss reduction: 0.737254
Top K accuracy(All K)K=1: 0.936709
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

Confusion table
||========================
Expand All @@ -41,10 +37,6 @@ Accuracy(micro-avg): 0.957746
Accuracy(macro-avg): 0.953030
Log-loss: 0.160970
Log-loss reduction: 0.851729
Top K accuracy(All K)K=1: 0.957746
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,6 @@ Accuracy(micro-avg): 0.973333
Accuracy(macro-avg): 0.973333
Log-loss: 0.161048
Log-loss reduction: 0.853408
Top K accuracy(All K)K=1: 0.973333
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,6 @@ Accuracy(micro-avg): 0.973333
Accuracy(macro-avg): 0.973333
Log-loss: 0.161048
Log-loss reduction: 0.853408
Top K accuracy(All K)K=1: 0.973333
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,6 @@ Accuracy(micro-avg): 0.629834
Accuracy(macro-avg): 0.500000
Log-loss: 34.538776
Log-loss reduction: -51.407404
Top K accuracy(All K)K=1: 0.629834
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000

Confusion table
||======================
Expand All @@ -32,9 +29,6 @@ Accuracy(micro-avg): 0.682493
Accuracy(macro-avg): 0.500000
Log-loss: 34.538776
Log-loss reduction: -54.264136
Top K accuracy(All K)K=1: 0.682493
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,6 @@ Accuracy(micro-avg): 0.655222
Accuracy(macro-avg): 0.500000
Log-loss: 34.538776
Log-loss reduction: -52.618809
Top K accuracy(All K)K=1: 0.655222
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,6 @@ Accuracy(micro-avg): 0.962025
Accuracy(macro-avg): 0.965079
Log-loss: 0.129858
Log-loss reduction: 0.880592
Top K accuracy(All K)K=1: 0.962025
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

Confusion table
||========================
Expand All @@ -43,10 +39,6 @@ Accuracy(micro-avg): 0.971831
Accuracy(macro-avg): 0.966667
Log-loss: 0.125563
Log-loss reduction: 0.884343
Top K accuracy(All K)K=1: 0.971831
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,6 @@ Accuracy(micro-avg): 0.980000
Accuracy(macro-avg): 0.980000
Log-loss: 0.095534
Log-loss reduction: 0.913041
Top K accuracy(All K)K=1: 0.980000
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
MulticlassLogisticRegression
Accuracy(micro-avg) Accuracy(macro-avg) Log-loss Log-loss reduction /l2 /l1 /ot /nt /nn Learner Name Train Dataset Test Dataset Results File Run Time Physical Memory Virtual Memory Command Line Settings
0.98 0.98 0.095534 0.913041 0.1 0.001 0.001 1 + MulticlassLogisticRegression %Data% %Data% %Output% 99 0 0 maml.exe TrainTest test=%Data% tr=MulticlassLogisticRegression{l1=0.001 l2=0.1 ot=1e-3 nt=1 nn=+} norm=No dout=%Output% data=%Data% out=%Output% seed=1 xf=Term{col=Label} /l2:0.1;/l1:0.001;/ot:0.001;/nt:1;/nn:+
0.98 0.98 0.095534 0.913042 0.1 0.001 0.001 1 + MulticlassLogisticRegression %Data% %Data% %Output% 99 0 0 maml.exe TrainTest test=%Data% tr=MulticlassLogisticRegression{l1=0.001 l2=0.1 ot=1e-3 nt=1 nn=+} norm=No dout=%Output% data=%Data% out=%Output% seed=1 xf=Term{col=Label} /l2:0.1;/l1:0.001;/ot:0.001;/nt:1;/nn:+

Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,6 @@ Accuracy(micro-avg): 0.962025
Accuracy(macro-avg): 0.965079
Log-loss: 0.101866
Log-loss reduction: 0.906331
Top K accuracy(All K)K=1: 0.962025
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

Confusion table
||========================
Expand All @@ -43,10 +39,6 @@ Accuracy(micro-avg): 0.985915
Accuracy(macro-avg): 0.983333
Log-loss: 0.075812
Log-loss reduction: 0.930169
Top K accuracy(All K)K=1: 0.985915
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,6 @@ Accuracy(micro-avg): 0.924051
Accuracy(macro-avg): 0.932540
Log-loss: 0.330649
Log-loss reduction: 0.695959
Top K accuracy(All K)K=1: 0.924051
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

Confusion table
||========================
Expand All @@ -57,10 +53,6 @@ Accuracy(micro-avg): 0.957746
Accuracy(macro-avg): 0.953030
Log-loss: 0.157832
Log-loss reduction: 0.854620
Top K accuracy(All K)K=1: 0.957746
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,6 @@ Accuracy(micro-avg): 0.924051
Accuracy(macro-avg): 0.932540
Log-loss: 0.201590
Log-loss reduction: 0.814633
Top K accuracy(All K)K=1: 0.924051
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

Confusion table
||========================
Expand All @@ -57,10 +53,6 @@ Accuracy(micro-avg): 0.971831
Accuracy(macro-avg): 0.968182
Log-loss: 0.101915
Log-loss reduction: 0.906125
Top K accuracy(All K)K=1: 0.971831
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,6 @@ Accuracy(micro-avg): 0.980000
Accuracy(macro-avg): 0.980000
Log-loss: 0.072218
Log-loss reduction: 0.934264
Top K accuracy(All K)K=1: 0.980000
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,6 @@ Accuracy(micro-avg): 0.980000
Accuracy(macro-avg): 0.980000
Log-loss: 0.048652
Log-loss reduction: 0.955715
Top K accuracy(All K)K=1: 0.980000
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,6 @@ Accuracy(micro-avg): 0.973333
Accuracy(macro-avg): 0.973333
Log-loss: 0.052580
Log-loss reduction: 0.952140
Top K accuracy(All K)K=1: 0.973333
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,6 @@ Accuracy(micro-avg): 0.962025
Accuracy(macro-avg): 0.965079
Log-loss: 0.101866
Log-loss reduction: 0.906331
Top K accuracy(All K)K=1: 0.962025
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

Confusion table
||========================
Expand All @@ -43,10 +39,6 @@ Accuracy(micro-avg): 0.985915
Accuracy(macro-avg): 0.983333
Log-loss: 0.075796
Log-loss reduction: 0.930183
Top K accuracy(All K)K=1: 0.985915
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
8 changes: 0 additions & 8 deletions test/BaselineOutput/Common/OVA/OVA-CV-iris-out.txt
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,6 @@ Accuracy(micro-avg): 0.974684
Accuracy(macro-avg): 0.977778
Log-loss: 0.352944
Log-loss reduction: 0.675458
Top K accuracy(All K)K=1: 0.974684
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

Confusion table
||========================
Expand All @@ -47,10 +43,6 @@ Accuracy(micro-avg): 0.971831
Accuracy(macro-avg): 0.966667
Log-loss: 0.273754
Log-loss reduction: 0.747843
Top K accuracy(All K)K=1: 0.971831
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
8 changes: 0 additions & 8 deletions test/BaselineOutput/Common/OVA/OVA-FastForest-CV-iris-out.txt
Original file line number Diff line number Diff line change
Expand Up @@ -71,10 +71,6 @@ Accuracy(micro-avg): 0.924051
Accuracy(macro-avg): 0.932540
Log-loss: 0.197783
Log-loss reduction: 0.818133
Top K accuracy(All K)K=1: 0.924051
Top K accuracy(All K)K=2: 0.987342
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

Confusion table
||========================
Expand All @@ -89,10 +85,6 @@ Accuracy(micro-avg): 0.957746
Accuracy(macro-avg): 0.953030
Log-loss: 0.103360
Log-loss reduction: 0.904794
Top K accuracy(All K)K=1: 0.957746
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,6 @@ Accuracy(micro-avg): 0.973333
Accuracy(macro-avg): 0.973333
Log-loss: 0.088201
Log-loss reduction: 0.919716
Top K accuracy(All K)K=1: 0.973333
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
4 changes: 0 additions & 4 deletions test/BaselineOutput/Common/OVA/OVA-TrainTest-iris-out.txt
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,6 @@ Accuracy(micro-avg): 0.960000
Accuracy(macro-avg): 0.960000
Log-loss: 0.254771
Log-loss reduction: 0.768097
Top K accuracy(All K)K=1: 0.960000
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
8 changes: 0 additions & 8 deletions test/BaselineOutput/Common/PKPD/PKPD-CV-iris-out.txt
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,6 @@ Accuracy(micro-avg): 0.974684
Accuracy(macro-avg): 0.977778
Log-loss: 0.359335
Log-loss reduction: 0.669582
Top K accuracy(All K)K=1: 0.974684
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

Confusion table
||========================
Expand All @@ -59,10 +55,6 @@ Accuracy(micro-avg): 0.971831
Accuracy(macro-avg): 0.966667
Log-loss: 0.277823
Log-loss reduction: 0.744095
Top K accuracy(All K)K=1: 0.971831
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
4 changes: 0 additions & 4 deletions test/BaselineOutput/Common/PKPD/PKPD-TrainTest-iris-out.txt
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,6 @@ Accuracy(micro-avg): 0.960000
Accuracy(macro-avg): 0.960000
Log-loss: 0.255665
Log-loss reduction: 0.767284
Top K accuracy(All K)K=1: 0.960000
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,6 @@ Accuracy(micro-avg): 0.946667
Accuracy(macro-avg): 0.946667
Log-loss: 0.433374
Log-loss reduction: 0.605526
Top K accuracy(All K)K=1: 0.946667
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -136,10 +136,6 @@ Accuracy(micro-avg): 0.946667
Accuracy(macro-avg): 0.946667
Log-loss: 0.434962
Log-loss reduction: 0.604081
Top K accuracy(All K)K=1: 0.946667
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,10 +56,6 @@ Accuracy(micro-avg): 0.980000
Accuracy(macro-avg): 0.980000
Log-loss: 0.061647
Log-loss reduction: 0.943887
Top K accuracy(All K)K=1: 0.980000
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,6 @@ Accuracy(micro-avg): 0.900000
Accuracy(macro-avg): 0.900000
Log-loss: 0.431088
Log-loss reduction: 0.607607
Top K accuracy(All K)K=1: 0.900000
Top K accuracy(All K)K=2: 1.000000
Top K accuracy(All K)K=3: 1.000000
Top K accuracy(All K)K=4: 1.000000

OVERALL RESULTS
---------------------------------------
Expand Down
Loading