WIP: kde calculation is too slow