Cleaning graphs