• Igor Ostrovsky's avatar
    Fix bits_per_byte metric in PerplexityTask · 38360512
    Igor Ostrovsky authored
    bits_per_byte was calculated as average per-byte loglikelihood, which would work if loglikelihood was base-2 log,
    but it is natural log. To correct for that, bits_per_byte should be divided by math.log(2).
    
    Also, it should be true that 2^bits_per_byte == byte_perplexity, which is true after the fix.
    38360512
base.py 23.1 KB