Update the Lenslet Mask Slope
The lenslet mask stage is preloaded with gratity at a 45 deg angle. The slope of the stepping motor travel may change after thermal cycles, leading to incorrect lenslet illumination when we take recmat scans. See https://keckobservatory.atlassian.net/wiki/x/AYCfBg for examples.
To determine the new slope, i.e. scan position vs. stepping motor location, we march the lenslet mask in given step intervals, illuminate the lenslets, and take data.
Data
The script to run is /home/osrseng/larkin/scripts/measure_mask_steps, and the syntax is measure_mask_steps 10 (this will take exposures every 10 steps).
Data analysis
Compile and run this IDL script /home/osrseng/syeh/RECMAT/mask_steps.pro
IDL> .comp /home/osrseng/syeh/RECMAT/mask_steps.pro
% Compiled module: MASK_STEPS.IDL> mask_steps, dir='260503'
In the pop-up GUI, select any one file from the dataset, except for the first 5 exposures.
In the second pop-up, select the first 5 exposures. These are the darks, and the code will create a master dark file.
Example: first select s230808_a005022.fits, next select s260503_a005001.fits to s260503_a005005.fits (by pressing shift + down arrow)The analysis output s260503_a005_Hn3_0.100.dat will be saved to /home/osrseng/syeh/RECMAT/260503/dat
Run kpython3 /home/osrseng/syeh/RECMAT/mask_step_medians.py s260503_c005_Hn3_0.100.dat
This script looks for the locations of peak illumination, which is usually clustered in 3 or 4 steps, takes the median of the locations. The tolerance of differential illumination is 10%. The script will save the new 52 peak-illuminated mask positions to /home/osrseng/syeh/RECMAT/260503/dat/s260503_c005_Hn3_0.100_offset_positions.csv
We update om4s configuration accordingly, which is explained below.
Here is an example of the output analysis, the location of the stepping motor vs. flux of illuminated lenslets. We look for the locations of peak illumination.
location | flux mean | flux stdev | fwhm mean | fwhm stdev | step | median location |
-5443 | 1 | 1 | 1 | 1 |
|
|
-5443 | 1 | 1 | 1 | 1 |
|
|
-5443 | 1 | 1 | 1 | 1 |
|
|
-5443 | 1 | 1 | 1 | 1 |
|
|
-5443 | 1 | 1 | 1 | 1 |
|
|
-5387 | 1517.48 | 645.313 | 50.3816 | 713.688 |
|
|
-5376 | 4690.44 | 732.389 | 140.653 | 505.496 |
|
|
-5366 | 18530.3 | 23160.3 | 20.3245 | 709.708 |
|
|
-5356 | 124524 | 222357 | 2.56803 | 228.293 | 1 | -5346 |
-5346 | 129158 | 225343 | 2.55663 | 359.357 |
|
|
-5336 | 123884 | 225674 | 2.52299 | 290.989 |
|
|
-5326 | 105820 | 191481 | 64.2687 | 375.174 |
|
|
-5316 | 181562 | 192288 | 2.51478 | 411.973 |
|
|
-5306 | 368045 | 393080 | 2.16993 | 209.348 | 2 | -5296 |
-5296 | 376211 | 394482 | 2.46207 | 386.761 |
|
|
-5287 | 366532 | 392082 | 2.22596 | 255.895 |
|
|
-5276 | 52284.9 | 63903.7 | 3.93793 | 380.468 |
|
|
-5266 | 614617 | 397696 | 2.23279 | 97.0993 | 3 | -5251 |
-5256 | 632251 | 404650 | 2.2602 | 79.2104 |
|
|
-5246 | 629755 | 404879 | 2.2544 | 40.7607 |
|
|
-5237 | 625451 | 401145 | 2.27096 | 30.5194 |
|
|
-5226 | 44280.6 | 22316.7 | 4.14115 | 87.5471 |
|
|
-5216 | 857328 | 206967 | 2.27015 | 5.96484 | 4 | -5201 |
-5206 | 863489 | 206220 | 2.26063 | 3.75333 |
|
|
-5196 | 862940 | 205334 | 2.26356 | 4.51102 |
|
|
-5186 | 855079 | 200073 | 2.27042 | 6.24375 |
|
|
-5176 | 74705 | 20191.2 | 4.55509 | 3.65968 |
|
|
-5166 | 918580 | 156720 | 2.23562 | 4.80443 | 5 | -5151 |
-5156 | 920776 | 157927 | 2.22665 | 3.06446 |
|
|
-5146 | 925012 | 157148 | 2.24961 | 6.65813 |
|
|
-5137 | 861077 | 158174 | 2.21586 | 0.297405 |
|
|
-5126 | 460175 | 175706 | 2.51891 | 4.69936 |
|
|
-5116 | 918448 | 156745 | 2.21999 | 4.75987 | 6 | -5106 |
-5106 | 919978 | 157108 | 2.20973 | 5.21683 |
|
|
-5096 | 915463 | 156308 | 2.2094 | 5.16279 |
|
|
-5086 | 165129 | 140815 | 3.39556 | 1.94601 |
|
|
-5076 | 907510 | 188279 | 2.23926 | 5.56845 | 7 | -5061 |
-5066 | 914993 | 190373 | 2.24783 | 5.09505 |
|
|
-5056 | 912784 | 190373 | 2.2416 | 4.6697 |
|
|
-5046 | 896547 | 191216 | 2.26154 | 6.12843 |
|
|
-5037 | 86905.4 | 28716.3 | 4.59728 | 78.2796 |
|
|
-5026 | 926340 | 155266 | 2.23314 | 6.48522 | 8 | -5011 |
-5016 | 931052 | 155862 | 2.2408 | 6.43884 |
|
|
-5006 | 927134 | 155457 | 2.23606 | 5.48261 |
|
|
-4996 | 821191 | 182377 | 2.22083 | 15.5321 |
|
|
-4987 | 590132 |