We report an algorithm designed to perform computer-automated tuning of a single quantum dot with a charge sensor. The algorithm performs an adaptive measurement sequence of sub-sized stability diagrams until the single-electron regime is identified and reached. For each measurement, the signal processing module removes the physical background of the charge sensor to generate a binary image of charge transitions. Then, the image analysis module identifies the position and number of lines using two line detection schemes that are robust to noise and missing data.