simpler preprocessing