remove the check_input parameter. I don't think it is used.