An image processing apparatus applies a separability filter to respective
positions of an inputted image including a linear object, calculates
separability of the respective positions, generates a separability map as
a set of the separability of the respective positions, applies distance
transform or thinning process to the separability map to generate a
skeleton image in which the linear object is displayed, and outputs the
skeleton image.