The principle sounds very simple. But, before the target spectrum can be meaningfully compared to the spectra of the library, many steps are required. The main instrumental feature is the modulation of the spectra by the blaze profile of each order. If the two objects to be compared had the same radial velocity with respect to the instrument, at the time of the exposures, this modulation would cancel out. But most of the time there is a significant difference, and the blaze efficiency is shifted in wavelength between the two exposures.
Cosmic rays are a big nuisance in all instruments using CCDs as detectors.
Unfortunately many cosmics escape the trap, because too few pixels are illuminated along the direction perpendicular to the dispersion. Equally disturbing are the telluric lines which change in intensity and position with time in the rest frame of the object. After these different steps, three other actions remain to be performed. If the target star and a reference star of the library have a different line-broadening, because they have a different projected rotational velocity , we must not be fooled into considering them as objects of different effective temperature, gravity and metallicity. A large fraction of our observing time was devoted to the aquisition of the library of reference stars, which includes 211 spectra at the present time.