Add possibility to cast NaNs to Infs in KL

11 jobs for nan_to_inf in 8 minutes and 53 seconds (queued for 2 seconds)