Correct some errors in DataGenerator