Children were beaten, sexually abused and used to test drugs at several institutions.