guilgautier / DPPy

Python toolbox for sampling Determinantal Point Processes
https://dppy.readthedocs.io
MIT License
219 stars 52 forks source link

k-dpp with float32 data #57

Closed dksahuji closed 4 years ago

dksahuji commented 4 years ago

Describe the bug It is not really a bug but threshold to ignore very small negative eigen values seems high for float32. float32 and float64 should be handled separately.

Atleast other users will get the solution if they face this issue.

I am doing k-dpp sampling. phi = data each row is a sample. L=phi*phi.T when phi is float32 numpy array. it gives a value error corresponding to negative eigen value. when i move to float64 the error goes away. dimension of sample is large, between 2048-4096.