S2 data preprocessing