stripe-archive / brushfire

Distributed decision tree ensemble learning in Scala
Other
391 stars 50 forks source link

Add new `SparseEqualTo[V]` predicate #41

Closed tixxit closed 8 years ago

tixxit commented 9 years ago

Create a SparseEqualTo[V] predicate that defaults to false for missing data (eg None).

tixxit commented 8 years ago

I believe this is covered by IsPresent predicate. I'm still not a huge fan of either of these, but not sure of a better way to handle it quite yet.

NathanHowell commented 8 years ago

Just spent a little bit debugging some unit tests and was surprised to find the default predicates returning true for missing features. Seems like it might be better to opt-in to this instead of having to opt-out.

tixxit commented 8 years ago

Perhaps it would make the most sense to push this decision to TreeTraversal instead. We would then not deal with missing features in predicates at all and, instead, depend on people using actual Option types for feature values if they want to represent missing features in their tree. This would certainly simplify the predicates.