updated nki preprocesing