Skip to content

Commit

Permalink
fix: prevent feature corruption in LRU cache.
Browse files Browse the repository at this point in the history
  • Loading branch information
mrucker committed Oct 9, 2023
1 parent 7ea231f commit 1f3d0ab
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions vowpalwabbit/core/src/reductions/eigen_memory_tree.cc
Original file line number Diff line number Diff line change
Expand Up @@ -780,10 +780,7 @@ void node_predict(emt_tree& b, learner& base, emt_node& cn, emt_example& ex, VW:
auto* closest_ex = node_pick(b, base, cn, ex);
ec.pred.multiclass = (closest_ex != nullptr) ? closest_ex->label : 0;
ec.loss = (ec.l.multi.label != ec.pred.multiclass) ? ec.weight : 0;
if (closest_ex != nullptr) {
tree_bound(b, closest_ex);
}

if (closest_ex != nullptr) { tree_bound(b, closest_ex); }
}

void emt_predict(emt_tree& b, learner& base, VW::example& ec)
Expand Down

0 comments on commit 1f3d0ab

Please sign in to comment.