wiki:NightOperations/Commissioning/pFPA

Post FPA taken down science procedures

see also the HET Box folder containing more information:

https://utexas.box.com/s/05ox0s5skp84ydg1sa7hl75o50oee1iv



Closed dome tests

These tests should be carried out as soon as OPS is finished on the afternoon when the FPA is re-mounted and available for use. The first step is to archive the older Marker values and update this page.

Measuring BIB CFB center

  • Open the PFIP shutter
  • Deploy the FCU head
  • Select an FCU lamp and fiber combination to get good flux on the BIB. Be sure to open the FCU shutter with a decent exposure time.
    • Mar2022: used QTH lamp, red light guide; 0.01s exposure on BIB.
  • Save some BIB images.
  • Use ds9 to measure the center of the CFB (can use circular region by eye).
    • be sure the last results are saved under "old results on the wiki"
    • update the wiki value for the BIB center.
    • This should be the CRPIX value for the BIB as well so these numbers should be given to the software team for updating in TCS (note these are in units of binned pixels).


Measuring GC1 and GC2 CFB centers

  • Deploy the FCU head (PFIP shutter can stay closed)
  • Set filters on GC1 and GC2 to g` (not that important for this)
  • Select an FCU lamp and fiber combination to get good flux on GC1 and GC2.
    • Mar2022: used QTH lamp, red light guide; 5s exposures on GC1/GC2; probes at home5
  • Save some GC1 and GC2 images.
  • Use ds9 to measure the center of the CFB diamond (can use rectangular region by eye).
    • be sure the last results are saved under "old results on the wiki"
    • update the wiki value for the GC1 and GC2 center.
    • update the TO setup scripts (ask Amy and Nathan).
    • This should be the CRPIX value for the Guiders as well so these numbers should be given to the software team for updating in TCS (note these are in units of binned pixels).


Check WFS1/2 aperture spots with FCU lamp too, to check for any changes

  • Qth, red guide, 15s exposures on WFS1/WFS2; probes at home5
  • Save some images, use ds9 to get the center of the selected spot by eye (compare before and after). If there is a big change, contact Hanshin to update the apertures on the WFS processing pipeline (required before WFS are useable!)


Measuring center CFB and side CFB centers on HPF ACQ

  • Open the PFIP shutter
  • Deploy the FCU head
  • Select a lamp and fiber combination to get good flux in the HPFACAM. Be sure to open the FCU shutter with a decent exposure time.
    • Mar2022: used QTH lamp, red light guide; 1s exposure on HPFACAM.
  • Store some images on the HPFACAM, where both CFBs are visible.
  • Notify Joe Ninan that the images have been saved and what the image name is.
  • Measure the position for the center of the HPFACAM direct field:
    • Use ds9 measure the center of both CFB: this can be done with circle markers (145 pixel radius is good for both) and then looking at the marker info. You will need to play with the scale to get the off axis one to look like a circle due to the coma at that position.
    • be sure the last results are saved under ”old results on the wiki”
    • update the wiki values for both CFB centers.
    • Note how much rotation is required from the central one to the new off-axis position and this is the delta angle to report to the TCS team.
    • Ask Amy and Nathan to update the TO setup scripts.
    • This should be the CRPIX value for the HPFACAM as well so these numbers should be given to the software team for updating in TCS (note these are in units of binned pixels).


Check PV and CWFS images for centering/functionality

  • store images on PV and CWFS cameras, compare with data from before takedown
  • details TBC here still



Twilight tests

These twilight tests are in additional to the regular evening twilights for all science instruments.

Acquire twilights for both guiders in all filters

  • Start this about 5-7min before sunset
  • Try exposure times like 0.01s with very short cycle times
  • Cycle through all filters: B, g‘, r‘, i‘, (Clear - optional)
  • Adjust exposure times of both GCs to obtain two sets of twilights:
    • 20 "bright" images at 40-50k counts
    • 20 "faint" images at 5-10k counts
  • Full instructions are here: HetProcedures/RA/probecals and include how to take the images, how to process them into flats, and how to install them (either temporarily or permanently) into TCS.

Acquire WFS twilights (high flux and low flux)

  • Start this about 3-5min before sunset.
  • Be sure that "Store images" is selected.
  • Adjust exposure times of both WFS to obtain two sets of twilights:
    • ~20 flats with one with peak flux values around ~3-5k counts
    • ~20 flats with peak flux values at 40-50k counts (saturation is 65k).
  • Try exposure times like *0.01s* with very short cycle times.
  • Verify again that the spot positions are unchanged from flats taken previously (i.e., daily during OPS with dome lights on). If the spots have moved, contact Hanshin to get help updating the PAS pipeline that processes the wavefront sensor images.

Acquire HPFACQ camera twilights (high flux and low flux)

  • Start this about 3-5min before sunset
  • Be sure that "Store images" is selected.
  • Adjust exposure times of the HPF ACQ camera to obtain two sets of twilights:
    • ~20 flats with one with peak flux values around ~200 counts
    • ~20 flats with peak flux values at ~3k counts (saturation is 4095).
  • Try exposure times like *0.01s* with very short cycle times.
  • These are not being used yet but will be invaluable for future comparisons


On-sky tests

Note that these tests rely on good image quality and reasonable transparency. You will want a high-quality stack and good (<2") seeing before attempting them. If the stack quality degrades during these efforts, a re-stack may be necessary to acquire useful data.

Attempt to focus the ACQ camera to match the BIB

This has not been done in recent history, but if the ACQ camera focus stage is functional and reliable, now would be a good time to adjust its focus to match the focus of the BIB. This may be done with a focus curve or "by eye" depending on the conditions.


Measure BIB position on ACQ camera and on IHMP with VIRUS

  • Select a 14th magnitude star with low proper motion in a rich field from the ENGYY-T-000 program (m14_bib_*) which has at least 30 minutes left in its track
    • Note that the BIB is IFU=555
  • Use g` filters for ACQ camera and guiders
  • OPEN the PFIP shutter in order to use the BIB camera
  • Setup on this target and ask TO to center star in BIB (on new coordinates!), handshake to a guider, activate a wavefront sensor and allow it to stabilize for 60s
  • Deploy ACQ camera mirror and store 5x shallow (5s) and 5x deep (10-20s) images in g` and i` filters.
    • Measure the position of the star in the 5x shallow images, average their values together, and update the value on the wiki
    • Stack the 5x deep images and plate solve (add WCS) the stacked image.
  • Retract ACQ camera mirror (or will be done automatically with iexp/OTT)
  • If not running, start BIB camera pipeline and store images (check that start is unsaturated), verify that the star is still well-centered at the center of the BIB camera
  • Run the dithered VIRUS exposure with iexp then modify command to something like this changing the target name if needed:

vlexp -B -i virus -pobj m14_bib_1_555_E -texp 360.0 -dither

  • After it is finished and copied to TACC, tun Remedy on TACC for this VIRUS observation.
    • after logging in to lonestar6 the command will be something like:
      idev -N 1 -m 120 -p development
      python3 /work/03730/gregz/maverick/Remedy/quick_reduction.py 20230905 22 37 /work/03730/gregz/maverick/output/20230301_20230401.h5 -nd 8 -fp /work/03730/gregz/maverick/fplaneall.txt -nD -qs -mc > log_20230905_11_37.txt 2>&1
      
  • Use the WCS solution from Remedy (IHMP coordinates and angle) and the known coordinate of this star to determine the fplane coordinates of the BIB.
    • Remedy will give an output like:
      [INFO - 2022-08-14 00:17:53,138] 20220813 0000012
      Astrometry: 321.395757 24.98419 160.19
      

which is the IHMP position (fplane=0,0) in RA & Dec (in degrees) and the rotation angle (deg, counterclockwise, increasing from N to E)

  • Plot this RA & Dec on the plate-solved deep ACQ image, and verify that its X,Y coordinates on the ACQ camera are consistent with the measurement from the short ACQ images earlier.
  • It is unlikely that we would need to update the fplane file unless something mechanical has changed in the BIB (right??)
  • Send the IHMP pixel value to the software team to update CRPIX on the ACQ camera in TCS (note these are in units of binned pixels).

Measure LRS2-B & LRS2-R positions on ACQ camera

  • Will do each spectrograph (B and R) separately, unless there is enough time on a single trajectory
  • Select a 14th magnitude star with low proper motion in a rich field from the ENGYY-T-000 program (m14_B_* or m14_R_*) which has at least 30 minutes left in its track
    • Note that LRS2-B is IFU=056
    • Note that LRS2-R is IFU=066
  • Setup on this target (ask the TO to set up at the old position on ACQ camera), handshake to a guider, activate a wavefront sensor and allow it to stabilize for 60s
  • Take a 60s exposure with LRS2-B (or LRS2-R), using iexp modified to something like this changing the target name if necessary:

vlexp -B -i lrs2 -pobj m14_B_1_056_E -texp 60.0

or

vlexp -B -i lrs2 -pobj m14_R_1_066_E -texp 60.0

  • Run lmap_markII on this exposure to calculate the offset
    • To do this, open a new terminal (on one of the workstations Zeus, Janus, Juno) and run these commands in your bash session to set up the environment:
      export PATH=$PATH:/usr/local/bin:/bin:/usr/local/sbin/:/usr/sbin:/home/mcs/sco/bin_july:/home/mcs/sco/Installs/install_zeus_20231021/bin/binc/otw:/home/mcs/sco/binpub:/home/mcs/sco/Installs/install_zeus_20231021/bin/binc/support_rhel:/home/mcs/sco/lm_support/LM_sup/loclibs/bin:/home/mcs/sco/lm_support/LM_sup/loclibs/sbin:/home/mcs/sco/lm_support/LM_sup/loclibs/include:/home/mcs/sco/Installs/install_zeus_20231021/bin/python:/opt/het/hetdex/bin:/home/mcs/sco/lm_support/LM_sup/loclibs/lib:/home/mcs/sco/Installs/install_zeus_20231021/bin:/home/mcs/sco/Installs/install_zeus_20231021/bin/bini:/usr/X11R6/bin:/usr/bin:/home/mcs/sco/Installs/install_zeus_20231021/bin/binc/morpho:/home/mcs/sco/Installs/install_zeus_20231021/bin/hetbin
      
      export insdir=install_zeus_20231021
      export scobin=/home/mcs/sco/Installs/$insdir/bin
      export codes=/home/mcs/sco/Installs/$insdir/codes
      export critfils=$codes/fortran/gfortran_compiler/lmgf/src/critical_files
      export LRS2DAT=$critfils/LRS2
      
    • then create a new temporary directory where it can run and create temporary folders/files
    • in that directory, run lmap_markII giving arguments for the Observation #, the Exposure #, and the channel (uv, or(ange), r(e)d, or f(ar)r(ed)). Here's an example for the orange channel of LRS2-B, with the necessary UT date input along the way; type "Y" and press Enter after this to continue:
      [stevenj@zeus tmp_lmap]$ lmap_markII 7 1 or
      Machine you are on is:  zeus.het.astronomy.utexas.edu
      No BaseDir file, enter base path (/hetdata/data):
      No Date file, enter date desired (20160816): 
      Enter response: 20231021
      20231021
      The BaseDir and Date files are established.
      	basedir = /hetdata/data
      	date    = 20231021
      Do these values meet with your approval? (Y/N):
      
    • a DS9 window will open and after 15-30 seconds a reconstructed image will appear in the top right quadrant. Under the "Edit" menu click "Region", then click and drag to create a circular region on the center of the flux in the reconstructed image to mark the source. Press ENTER at the terminal after drawing this region.
    • The ACQ camaera image will appear in the lower right quadrant - click and drag to draw a circular region around the star nearest to the LRS2 IFU of choice. After drawing/centering the region, press ENTER in the terminal again.
    • At this point, the code should ask if you if you want to save your results, and you may select Y or N. What you'll need is the trajectory offset command, like:
      mgp -toff=0.039972,0.111657
      
  • Re-center using small trajectory offset command *ONLY* provided in lmap_markII's output
  • Make sure the ACQ pipeline is running and storing images
  • Take another 60s LRS2 exposure, as described above
  • Run lmap_markII again as described above, and verify centering (repeat if necessary until centered within 0.3")
  • Deploy ACQ camera mirror and store 5x shallow (5s) and 3x deep (10-20s) images in g` filter for LRS2-B (r` filter for LRS2-R)
    • Measure the X,Y position of the star in the 5x shallow images, average the values together, and update the value on the wiki
    • Stack the 5x deep images and plate solve (add WCS) the stacked image.
      • Determine the X,Y coordinates of the star's RA,Dec coordinates, just to verify
  • Retract the ACQ camera mirror
  • Tomorrow afternoon, verify that the Panacea data reductions show nicely centered stars on the LRS2 exposures - that will be the position of all targets hopefully.
  • In the past we took VIRUS exposures here but their actual utility was somewhat limited compared to the ACQ+V tests done next. Consider omitting this step (see older instructions if you want to attempt it)

Measure the mapping between the ACQ camera and the IHMP with VIRUS

  • In this unusual test, we take a dithered VIRUS observation with the ACQ camera mirror deployed and storing images
  • Select on of the VIRUS targets on a rich open/globular cluster field from the ENGYY-T-000 program (VCl_* which has at least 30 minutes left in its track
    • Note that these use IFU=068
    • Note the guiders and ACQ camera should be using the g` filter as usual for VIRUS setups
  • Setup on this target with a blind setup, handshake to a guider, activate a wavefront sensor and allow it to stabilize for about 60 seconds
  • Run iexp for this target and verify that the command looks like:

vlexp -B -i virus -pobj VCl_NGC999_1_068_E -texp 360.0 -dither

  • Ask the TO to click "setup complete"
  • Immediately re-insert the ACQ camera mirror and start the ACQ camera pipeline running and storing images. Use at least a 10s exposure, and possibly up to 60s if necessary to get good observations for later WCS-solving (several dozen stars visible). Allow the ACQ camera to continue storing images throughout the 3x360s VIRUS dither pattern.
  • Run Remedy on TACC for this VIRUS observation.
    • after logging in to lonestar6 the command will be something like:
      idev -N 1 -m 120 -p development
      python3 /work/03730/gregz/maverick/Remedy/quick_reduction.py 20230905 22 37 /work/03730/gregz/maverick/output/20230301_20230401.h5 -nd 8 -fp /work/03730/gregz/maverick/fplaneall.txt -nD -qs -mc > log_20230905_11_37.txt 2>&1
      
  • will produce a line like the following, with WCS coordinates/rotation of IHMP
    log_20201024_10_57.txt:[INFO - 2020-10-27 12:38:32,264] 20201024_0000010 Astrometry: 24.247720 1.10992 58.17
    
  • Stack the first 6 minutes of ACQ camera images (or work with them individually)
  • Plate-solve the stacked (or individual) ACQ camera image (use http://astrometry.net or your own method)
  • Using the WCS-solved ACQ image(s), check which pixel the IHMP coordinates (RA, Dec from Remedy) lands on. In shuffle.cfg the acam_x_origin and acam_y_origin values should match that pixel.
  • Remedy also produces the rotation angle. To compare that with the plate-solved ACQ camera images, check the FITS header keyword CROTA2. The difference between the Remedy-produced VIRUS rotation angle and the ACQ camera rotation angle is the "acam" angle in shuffle.cfg (I think.)

This information from Matthew may help explain the two angles in shuffle.cfg: acam and fplane:

The acam angle sets the ACAM to match the stars.    So I change the ACAM
and IHMPX, and IHMPY until I match the stars for a setup like LRS2-B

The fplane angle sets the IHMP to match the ACAM pixel locations for
different requested setup.  If I setup ACAM to match LRS2-B in the first
step then I simply ask for that star to be on the LRS2-R and look at the
fake acam image and see if the star is on the LRS2-R position (according
to the fake acam image).     It will not be unless the fplane angle is
set correctly.

I iterate these two solutions until I get a match.   It is a unique
solution (within the errors).
  • If necessary, update acam origin and angles in shuffle.cfg file
  • To update shuffle config:
    • Edit cfg file at /opt/het/hetdex/lib/python2.7/site-packages/hetdex_shuffle/configs/shuffle.cfg
    • delete the old data for a given target with shdata_clean (or whole queue -- use very carefully!!!)
    • run target_setup on the target you want to re-run
  • Ultimately, you can test this by running shuffle to observe a star with LRS2-B and making sure it lands in the IFU. Iterating/adjusting may be necessary.
  • It would be best to run 2 or 3 V+ACQ fields and average together the results. VCl* fields are ideal but any of the 14th magnitude star setups should work really.

Measure HPF ACAM center/side CFBs positions on the ACQ camera

  • Select one of the red stars from the ENGYY-T-000 program (r* targets)
    • For the center CFB, run target_setup with -ifu 600 (usual hpfacam setup)
    • For the side CFB, run target_setup with -ifu 610
  • Ask the TO to center and guide on the star on the CFB (center or side) using the new coordinates determined earlier. Note: guiding may not be possible at the side CFB position and may require activating a guider and making small offsets to manually center the star on the side CFB.
    • For the center CFB this is like a normal HPFACAM setup
  • Store images on the HPFACAM and all cameras throughout this test.
  • Activate a WFS and allow focus/guiding to stabilize for ∼60s, BEFORE asking the TO to handshake to a guider.
  • Ask the TO to handshake to a guider and to monitor the star on the side-CFB of the HPFACAM to verify that it stays precisely at the correct location.
  • Verify that all probes are storing images.
  • Deploy the ACQ camera mirror (i` filter),
  • Store 5 ACQ images with short (0.1s) exposures so the target star is not saturated, noting the time stamps, may require 0.1s exposures or shorter (please set ACQ cycle time to ≤1s to speed this up!)
    • stack the images (or use the average from individual images) to measure the X,Y coordinates on the ACQ camera of the star.
  • Retract the ACQ camera mirror
  • Do this for both the center CFB and side CFB; note that it may be faster to do a trajectory offset from the cCFB to the sCFB, or you can send them as separate targets
  • Repeat this for at least 2 or 3 red stars and average the values.
  • now you should have an ACQ camera X,Y coordinate for cCFB and ACQ X,Y for sCFB
    • also from earlier tests you should have the ACQ X,Y coordinates of the BIB, LRS2-B, and LRS2-R
  • populate a data file as shown below, called something like data_YYYYMMDD.txt
    # This is an example file input for the fromscratch sub command of CalculateHPFfiberpositions_new.py
    # IMP: Keywords in this file should not be renamed. All are mandatory
    
    # New ACAM measurements of Central CFB & Side CFB from YYYYMMDD 
    ACAMcCFB = 144.7, 245.1     # This is the Central CFB of HPF ACAM
    ACAMsCFB = 216.2, 172.5     # This is the Side CFB of HPF ACAM
    
    # New ACAM measurements of BIB LRS2R and LRS2B from YYYYMMDD
    
    BIB = 447.95, 398.05
    LRS2R = 729.15, 581.53       # LRS2Red
    LRS2B = 734.97, 212.33       # LRS2Blue
    
    # Latest fplane.txt coordinates of BIB LRS2R and LRS2B (FIXED, rarely changed)
    
    fplaneBIB = 0.7, -73.13
    fplaneLRS2R = 50, -150.0
    fplaneLRS2B = -50, -150.0
    
  • Run Joe's script CalculateHPFfiberpositions_new.py (attached to this page, you can download it) with the argument fromscratch and the data file you just edited the ACQ X,Y coordinates of cCFB, sCFB, BIB, LRS2-R, LRS2-B, as shown:
    ./CalculateHPFfiberpositions_new.py fromscratch data_YYYYMMDD.txt
    
  • The script outputs several details but the part we need is the updated guider fiducial offset which is used in the HPFACAM setup script:
    ********************
    New guider fiducial offset command to go from cCFB to HR Sci fiber is
    syscmd -T 'Guider1_offset_fiducial(dx_asec=-9.6,dy_asec=-5.4,compensate="true")'
    --------------------
    

Measuring HPF CFBs with VIRUS

  • There is another option for this determination which may be more precise although will take more time on sky. If you place a star on the cCFB (and likewise the sCFB) and take 3x360s VIRUS exposures, you can use the Remedy WCS solution and the known coordinates of the star to derive the cCFB (and sCFB) positions more accurately.
  • Continue running the HPFACM throughout the VIRUS exposures
  • To take these VIRUS exposures once the star is centered on the cCFB or sCFB, you'll need to create and run a vlexp command like:
    vlexp -B -i virus -pobj r122_610_E -texp 360 -dither
    
  • In that case, you would use SJ's script called wcs_fplane.py for each measurement, which takes arguments:
    #arg 1 RA of IHMP center [deg]
    #arg 2 Dec of IHMP center [deg]
    #arg 3 angle of IHMP  [deg] (all from remedy)
    #arg 4 correction for differential atmospheric dispersion
    #arg 5 RA [deg] of target star
    #arg 6 Dec [deg] of target star
    
    • the first three arguments come from the Remedy astrometry output. The differential atmospheric dispersion correction (VIRUS at 3500-5500A vs HPF at 9000A) is usually 0.6. The RA & Dec of the target star should be given in degrees. This is a typical run and output of the script:
      ./wcs_fplane.py 328.176676 24.86302 16.85 0.60 328.18504 24.847917
      fplane x,y=-59.955723273918565,-9.789848419618009
      
  • So you would run this wcs_fplane.py script on the cCFB+VIRUS observation and the sCFB+VIRUS observation. With those two fplane coordinates you would create a data file like this, newdata.txt
    ################################################################################
    #### Calculation of the fplane positions of HPF fibres based on VIRUS exposures YYYYMMDD
    cCFB = -40.167, 9.921
    sCFB = -59.956, -9.790
    ################################################################################
    

and then give that as an argument to Joe's script like: ./CalculateHPFfiberpositions_new.py newfplane newdata.txt and it will produce output including:

syscmd -T 'Guider1_offset_fiducial(dx_asec=-9.59,dy_asec=-5.58,compensate="true")'

It wouldn't hurt to do both methods, the triangulation from BIB+LRS2-B+LRS2-R and the simultaneous VIRUS data.



Determine the position of the HPF science fiber on the ACQ camera

  • After the previous test is complete and we have updated the HPF ACQ fiducial and the guider fiducial offset in the HPFACAM setup script:
  • Choose an M dwarf from the ENGYY-T-000 program with a name like Gl*
  • Ask the TO to do an HPFACAM ("regular") setup on one of these targets; pay extra attention to how stable the star is on the HPFACAM after handshaking to a guider - that is critical!
  • Activate a WFS, allow to stabilize for ∼1 minute
  • Be sure that images are being stored on all probes
  • Deploy ACQ mirror and take two exposures (noting time stamps):
    • 5-10 short exposure where target is unsaturated (if possible)
    • 5-10 long exposure with N>6 stars visible
  • retract ACQ mirror



Consider further refinements to the HPF fiber position === #hpf_dither

  • After the previous test is complete and we have updated the HPF ACQ fiducial and the guider fiducial offset in the HPFACAM setup script:
  • Choose an M dwarf from the ENGYY-T-000 program with a name like Gl*
  • Ask the TO to do an HPFACAM ("regular") setup on one of these targets; pay extra attention to how stable the star is on the HPFACAM after handshaking to a guider - that is critical!
  • Activate a WFS, allow to stabilize for ∼1 minute
  • Be sure that images are being stored on all probes
  • Ask the TO to turn off the integral terms in guider PID loops
  • run test script located in /home/mcs/astronomer/stevenj/hpfcent/
    • ./gc1 hpf centering.sh if you are guiding on GC1
    • ./gc2 hpf centering.sh if you are guiding on GC2

This will take 14 exposures at different positions, with appropriate pauses between each move.

  • When finished the ACQ mirror should automatically deploy; take two exposures (noting time stamps):
    • one short exposure where target is unsaturated (if possible)
    • one long exposure with N>6 stars visible
  • That concludes this test - resume science operations.
  • Analysis of these measurements will help verify and refine the guider offset we use to move from the HPFACAM central CFB to the science fiber. These will also be used to update the fplane value of the science fiber. The HPF science fiber is at IFU=603.
  • The pre-test ACQ camera images can also be used to verify the position of the HPF science fiber on the HET ACQ camera, used in the "directACAM" HPF setups
  • to do the analysis, download or copy the Goldilocks reductions of the data
  • measure the mean flux in the region [1002:1051,1017:1024] on the 0th extension for all 14 exposures (Order 19, as usual for HPF SNR)
  • for each exposure, get the tracker coordinates from header keywords RTFTHETA, RTFPHI, RTFRHO and use hetillum to calculate the illumination at the HPF fiber position for each exposure:
    hetillum '[ 0.987817, 1.052546, 2.660203]'  '[-0.008194,0.0042778]' 256
                ^theta    ^phi      ^rho           ^,^ x,y of HPF sci fiber
    
  • also get the average guider transparency and IQ from the RA NR for each of the 14 exposures. If there were big variations or changes you can try to use those measurements to compensate but it may be safer to redo the test under more stable conditions.
  • consider using the supermongo codes (or perhaps re-write this in python) attached at the bottom of this page to calculate the x,y offset of the science fiber. In principle the first and last positions should be the brightest (after correcting for the changing pupil illumination), and the others should fall off symmetrically around them. I made some supermongo code that assumed a PSF and predicted the flux in each of the 14 positions. It allowed the user to guess an x,y offset and it would give you something like a chi-squared value to indicate the goodness of fit. I tweaked the x,y inputs until I found a reasonable minimum. This approach is ripe for improvement! Below is an example graph after doing some tests to find the best x,y offset:

  • In the past we have found that the position was good to within 0.2" of ideal, and have made no changes. This is a nice verification, but if it shows a problem then it may require redoing the measurement of the HPF cCFB/sCFB on the ACQ camera and all the steps after that. Consult with the HPF team when in doubt.



Verify/update the offset to the CWFS position

Details remain to be written, but the idea is to verify the offset between the IHMP position and the CWFS. As of summer 2023 the offset is:

 syscmd -T 'offset_trajectory(dx_ang=-5.1, dy_ang=-3.9, adjust_probes="true")' 

as documented on several CWFS test pages. This offset has changed in the past, due to mechanical problems, and probably should not change. It would be good to verify after an FPA takedown that the offset remains the same.



Still further refinements

If necessary, you might consider the following tests, but they are probably not essential. If anything is inconsistent, weird, or confusing, these may give extra data or insight

Measure LRS2-B position on ACQ with simultaneous VIRUS observations

Measure LRS2-R position on ACQ with simultaneous VIRUS observations





























OLD notes, but with valuable information!

Overview

These tests are intended for moving us from the FPA taken down to full science operations.

Closed dome engineering tests

Getting ready

  • Archive the old best current values for the markers and be ready to create new marker position see HetProcedures/RA/markers

Measure the position of the BIB IFU center

Purpose: We want to know the center of the BIB IFU for the tests that are needed involving the BIB

Procedure:

  • Open the PFIP shutter
  • insert the FCU
  • select a lamp and fiber combination to get good flux in the BIB. Be sure to open the FCU shutter with a decent exposure time.
  • Save some BIB images.
  • Using ds9 measure the center of the IFU. This can be done with circle markers and then looking at the marker info.
  • be sure the last results are saved under "old results on the wiki"
  • update the wiki value for the BIB center.
  • This should be the CRPIX value for the BIB as well so these numbers should be given to the software team for updating in TCS.

Measure the position of the GC1 and GC2 center

Purpose: We want to know the center of the Guider Coherent Bundles for the TO setup scripts.

Procedure:

  • insert the FCU
  • select a lamp and fiber combination to get good flux in GC1 and GC2.
  • Save some GC1 and GC2 images.
  • Using ds9 measure the center of the Coherent Bundle Diamond. This can be done with square markers rotating them using the marker info in DS9; the center of the marker is what we want.
  • be sure the last results are saved under "old results on the wiki"
  • update the wiki value for the GC1 and GC2 center.
  • update the TO setup scripts (to be added by Nathan and Amy).
  • This should be the CRPIX value for the Guiders as well so these numbers should be given to the software team for updating in TCS.

Testing of the HPF-ACAM IFU positions

Purpose: We want to know if the angle for guiding has changed on the HPF ACQ and the centers for setting up when doing HPFACQ regular setups.

Procedure:

  • Open the PFIP shutter
  • insert the FCU
  • select a lamp and fiber combination to get good flux in the HPFACQ. Be sure to open the FCU shutter with a decent exposure time.
  • Save some HPFACQ images.
  • Notify Joe Ninan that the images have been saved and what the image name is.
  • Measure the position for the center of the HPFACQ direct field
  • Update the wiki and the code regularhpfsetup and inform Randy of the new position for the marker file.
  • This should be the CRPIX value for the HPF ACAM as well so these numbers should be given to the software team for updating in TCS.

To measure yourself:

  • Using ds9 measure the center of both IFUs. This can be done with circle markers and then looking at the marker info. You will need to play with the scale to get the off axis one to look like a circle due to the coma of the camera.
  • be sure the last results are saved under "old results on the wiki"
  • update the wiki value for both IFU centers.
  • Note how much rotation is required from the central one to the new off-axis position and this is the delta angle to report to the TCS team.

We need to get from Joe the procedure for updating the HPF-ACQ orientation, ie. what sign is what...

Twilight

Standard science twilights

LRS2 and VIRUS twilights should be taken at the center of track position. Please follow the start of the night procedures on the wiki.

Creating new Guider flats at twilight

Store images on Guider 1 & 2 in all filters (B, g, r, i`, Clear) during twilight, for use in generating new flat fields. These can be taken at the same time as the LRS2 or VIRUS twilight spectra are being taken.

Full instructions are here: HetProcedures/RA/probecals and include how to take the images, how to process them into flats, and how to install them (either temporarily or permanently) into TCS.

Dome Open Tests

Test the WFS focus and theta-phi

Purpose: Make sure that the WFS1 and WFS2 still produce good results.

Procedure:

  • Setup on a star with a guide star in GC1 and GC2 and good WFS stars in both WFS.
  • Get to best focus and best theta and phi with one of the WFS.
  • Make sure that the WFS corrections agree within <0.04 mm in focus and <10" in theta and phi
  • Move out of focus (above and below) by ~0.10 mm.
  • Look at the images on the guiders and see if there is any significant coma
  • Look at the images and make sure they are about the same size, ie. we are at best focus.

Testing of the ACAM position

Purpose: We want to see if the ACAM position changes with respect to the IHMP over time. We want this data every night and when ever we get an unusually high or low temperature. It would be good to vary the Az as well.

Determine the orientation of the ACAM with respect to the sky:

  • Select a 14th mag star in a reasonably rich field with shuffle for the IHMP
  • Setup as if it were a blind setup LRS target
  • Save several images in each filter g,r,i, for the ACAM.
  • Save several deeper images as well.
  • Run Steve's software to determine the orientation (or ask Steve to run his software).

Determine the Center of the BIB:

  • Select a 14th mag star in a reasonably rich field with shuffle for the BIB
  • Setup on the very center of the BIB field of view and save an image note any differences from the wiki center position.
  • Guide on one of the guide probes
  • Put in the ACAM and save an shallow image with the target star not saturated.

Measure the star position on the acam: ds9_imstats 20190401T115437.0_acm_sci.fits Y

Determine the Center of LRS2-B

  • Select a 14th mag star in a reasonably rich field with shuffle for the LRS2-B
  • Setup on LRS2-B and start guiding on one of the guiders
  • Take LRS2-B spectrum, probably 60 seconds.
  • Adjust the position so that the star is at the center of LRS2-B IFU using lmap until the offsets are less than 0.3"

syscmd -T 'Guider1_offset_fiducial ( dx_asec=-0.01,dy_asec=0.55,compensate="false")'

  • Confirm the star is at the center of the IFU by taking a spectrum.
  • Once it is as the center of the IFU put in the ACAM and take a shallow image so that the star is not saturated.
  • Report on the position of the LRS2-B in the night report and on NightOperations/Commissioning/Results
  • Take a deeper image so that there are large number of stars.

Determine the Center of LRS2-R

  • Select a 14th mag star in a reasonably rich field with shuffle for the LRS2-R
  • Setup on LRS2-R and start guiding on one of the guiders
  • Take LRS2-R spectrum, probably 60 seconds.
  • Adjust the position so that the star is at the center of LRS2-R IFU using lmap until the offsets are less than 0.3"
  • Confirm the star is at the center of the IFU by taking a spectrum.
  • Once it is as the center of the IFU put in the ACAM and take a shallow image so that the star is not saturated.
  • Report on the position of the LRS2-R in the night report and on NightOperations/Commissioning/Results
  • Take a deeper image so that there are large number of stars.

Determine the Center of the HPFACQ IFU on the ACQ:

  • Select a 9-10th mag star with shuffle for the regular setup (600)
  • Setup on the very center of the HPFACQ field of view and save an image.
  • Guide on one of the guide probes and make sure that the star is still at the center of the HPFACQ
  • Put in the ACAM and save an shallow image with the target star not saturated.
  • Report on the position of the HPFACQ regular setup in the night report, on the markers wiki page and on NightOperations/Commissioning/Results

Determine the Center of the side HPFACQ IFU on the ACQ:

  • Select a 9-10th mag star with shuffle for the side setup (610)
  • NOTE that you probably will not be able to guide on the side CB because the orientation is different than the center IFU (600).
  • Make telescope offsets with the TCS hand paddle to get it close to the center of the side CB.
  • Guide on one of the guide probes and make sure that you use the PID loop.
  • Adjust the fiducial position on the active guider to get the star centered well on the side CB.
  • Put in the ACAM and save an shallow image with the target star not saturated.
  • Report on the position of the HPFACQ regular setup in the night report, on the markers wiki page and on NightOperations/Commissioning/Results

These tests need to be done at least 5 times to get a very good average.

Data reduction

The ACAM image orientation on the sky should come directly from Steve's ACAM orientation analysis. His code is rotated by 90 degrees so subtract 90 from the value that comes from Steve's software. This goes into the Shuffle cfg file as "acam". Follow the instructions for updating the shuffle.cfg file: HetProcedures/RA/Shuffle

On any ACAM image set a circular marker at the LRS2-B and LRS2-R positions and make the radius 158.1 arcseconds in size (as set by the fplane file). The intersection of these two cicles is the new value for the IHMP. Update the wiki and the shuffle.cfg file (acam_x_origin and acam_y_origin; Follow the instructions for updating the shuffle.cfg file: HetProcedures/RA/Shuffle). This is also the center of the TCS pointing should be the CRPIX values for the ACAM, ask the software team to update this for the ACAM. Next take one of the ACAM images from the LRS2-B position test and run the shuffle for this object's setup with the new shuffle.cfg file. Adjust the acam angle in shuffle.cfg until the stellar positions in the fake ACAM match the real ACAM. The for the same object run shuffle but for the LRS2-R position. If the object does not fall at the previously determined value of the LRS2-R then adjust the fplane value in the shuffle.cfg file and rerun shuffle until it does. Wtih these positions now locked in ask Greg to submit the new shuffle.cfg file to svn. Once it is updated download the new version and make sure that Sergey downloads the shuffle.cfg file to the correct location and re-run shuffle for shuffle for all active targets, and standards.

We also need to update the position of the HPFACQ on the ACQ. Update the wiki and change the regularhpfsetup script and check into svn.

We also need to update the position of the directHPF on the ACQ. We have need to get the script to do this from Joe.. The value goes on the wiki and in the directhpfsetup script.

In theory the fplane should not need updating but the offset from from HPFACQ to directsetup might. Place this new value in the regularhpfsetup script and check into svn.

check the offset from LRS2-B to LRS2-R

Purpose: See what the offset is to get accurately from LRS2-B to LRS2-R position on the ACAM. This need not involve the LRS2 instrument at all but does require that we have the new updated LRS2-B and LRS2-R ACAM positions.

Procedure:

  • Setup on LRS2-B ACAM position
  • Take a final ACAM position to confirm we are in the right place.
  • offset from B to R using mgp
  • Take an image with ACAM and see if we are in the right place.
  • Have the TO offset from the current star position to the ideal position and take note of the offset size.
  • move back to LRS2 B
  • try a modified mgp poff command with the old offset + correction.
  • repeat until it works
  • try the oposite offset and see that it works from R to B.

Try this with another star to confirm.

Once you have a new value give it to Sergey to be installed in mgp and also update the wiki.

Measure the guider zero points

In order for the guiders to hit the correct stars once shuffle is updated you need to adjust the probe zero points in TCS.

Procedure:

  • Setup on LRS2-B on the ACAM for a 14th mag star
  • Measure the offset needed to center the guide star at the center of the guider IFU
  • Measure the total offsets needed to center the WFS stars (can use the offsets from the guiders as a first best guess)
  • For this setup save the offsets for all of the probes

Do this procedure at least 10 times and then median the results for each probe. Enter these values into the spreadsheet on this page. In a new date/worksheet. Confirm that the current values are correct by looking at TCS code. Update these values with the new values.

Testing the Guider orientation

Purpose: We would like to nail down the Guider orientation angles before the FPA. This is not critical but this is a test we will be doing after so having a baseline would be helpful. The goal is to have 2 or more stars (even if faint) in a guider. It is ok if the guider only one guider gets this per track. The goal is to get at least 10 different images on sky with 2+ stars.

Procedure:

  • Go to a very rich field
  • Setup on stars selected by shuffle or LRSstars
  • Saves 10 images with the guider that has 2+ stars in the field of view.
  • Report this in the time in the RA report and in an e-mail to Gary and Matthew.

Repeat until you get 10 fields on both GC1 and GC2.

Notes on Software updates

Zero points of various camera can be changed in the configuration files <camera>Camera.conf (eg. Guider1Camera.conf). The wcs-reference-pixel keyword is the X/Y pixel for the zero point of the field in unbinned pixel coordinates. The binned values are what you see as CRPIXx in the image header.

Plate Scale and Rotation of the cameras are both contained in ./het_lib/common/include/tcs_definitions.h under the particular camera name space. Scale is in units of arcseconds per pixel and angles are in radians. Modifying these values requires a recompile of the source code.

Last modified 6 months ago Last modified on Oct 23, 2023 3:24:43 AM

Attachments (15)

Download all attachments as: .zip