1. A calibration method comprising: acquiring a captured image of a lattice fringe by providing a reference gauge having a reference surface whose height from a reference plane changes in a first direction, projecting a lattice fringe having the same phase in a first direction with respect to the reference surface and having a phase sinusoidally changing in a second direction crossing the first direction, and imaging the lattice fringe; calculating a phase of a pixel in the first direction in the captured image of the lattice fringe; and generating relational data in which a height of the reference surface corresponding to the pixel, a phase calculated with respect to the pixel, and a period of the lattice fringe in which the phase is calculated are associated with each other.