NAN management for pixels value