[INSTRM-1573] Implement the function to filter out unstable FFs in FPS actor Created: 08/Apr/22 Updated: 12/May/23 Resolved: 12/May/23 |
|
| Status: | Done |
| Project: | Instrument control development |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Task | Priority: | Normal |
| Reporter: | chyan | Assignee: | chyan |
| Resolution: | Done | Votes: | 0 |
| Labels: | CanBeClosed | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||
| Description |
|
It is demonstrated filter out unstable FFs do helps the accuracy of transformations. This function should be also implemented in FPS actor. |
| Comments |
| Comment by chyan [ 12/May/23 ] |
def readFiducialMasks(fids):
"""
read good/bad/outer ring fiducial information from yaml file
"""
instPath = os.path.join(os.environ['PFS_INSTDATA_DIR'])
fidFile = os.path.join(instPath,"data/pfi/fiducials/fiducialFiberFlags.yaml")
with open(fidFile, 'r') as inFile:
fiducialFlags = yaml.safe_load(inFile)
fidsOuterRing = fids[fids.fiducialId.isin(fiducialFlags['outerRingIds'])]
badFids = fiducialFlags['badFidIds']
goodFids = list(set(fids['fiducialId'].values)-set(badFids))
fidsGood = fids[fids.fiducialId.isin(goodFids)]
return fidsOuterRing, fidsGood
|