fixed resampling and switched back to gaussian kernel