Added output sample data and input sample correction