NeerajSarwan / CPT

This is the native Python implementation of CPT(compact Prediction Tree)
MIT License
47 stars 51 forks source link

Unimplemented code in def score(...) #3

Open ghost opened 6 years ago

ghost commented 6 years ago

It looks like some code is unimplemented in the "score(...)" function.

There is a magic number 0.001 hardcoded in this function, and two unused arguments ("length" and "target_size")

Perhaps the dev originally intended to use a ratio of these arguments?

ghost commented 6 years ago

Hrm, here's a "public void push" function of the original Java version. Lots of commented out variation. Suppose the weight is a trial and error thing.

https://github.com/tedgueniche/IPredict/blob/cbdc992394487d8fa2065e43c90301cc6e786a22/src/ca/ipredict/predictor/CPT/CPTPlus/CountTable.java