# Guidelineѕ to re-generate the REFLINES

1. CLEANUP

cd /home_eso/yjung/P_kmos/REFLINES/
rm -rf /home_eso/yjung/P_kmos/REFLINES/wave_cal_ref_lines
rm -rf /home_eso/yjung/P_kmos/REFLINES/kmos-calib
rm -rf /home_eso/yjung/P_kmos/REFLINES/ref_lines

2. Run kmo_wave_cal to generate slitlet edges files (ref_lines/)

setenv KMO_WAVE_CAL_DATA_PREFIX .wave_cal_data
setenv KMO_WAVE_LINE_ESTIMATE 0

-> Use recent data
esorex kmo_wave_cal sof

mkdir /home_eso/yjung/P_kmos/REFLINES/ref_lines
cp .wave_cal* /home_eso/yjung/P_kmos/REFLINES/ref_lines/.

3. Create the latest static calibration files (kmos-calib/)

svn export -r HEAD $SH/Pipelines/kmos/kmos-calib

4. Install and setup IDL (wave_cal_ref_lines/)

svn export -r HEAD $SH/Pipelines/kmos/kmosp/tools/wave_cal_ref_lines

5. (IF ASTRON NOT THERE) Install the astron library (astron/)

cp /scratch/yjung/packages/astron.lib.gz .
tar -xzf astron.lib.gz
rm astron.lib.gz

6. RUN IDL

ssh -Y psdlin2.hq.eso.org
cd P_kmos/REFLINES/wave_cal_ref_lineѕ
idl main.pro

7. Instructions

