Repository navigation
Firefly-2138: microscope 'at row' searches use the cutout center - #2073
aventura121 wants to merge 2 commits into
Conversation
| const {subsize, scanId, coaddId, refSourceId} = table?.request ?? {}; | ||
| // use the frame center (the row's position) if there's no cutout (subsize) or an ID is set (WiseRequestList.js:79) | ||
| if (!(Number(subsize) > 0) || scanId || coaddId || refSourceId) return rowWp; | ||
| const ra = getCellValue(table, table.highlightedRow, 'in_ra'); | ||
| const dec = getCellValue(table, table.highlightedRow, 'in_dec'); | ||
| if (!isNumeric(ra) || !isNumeric(dec)) return rowWp; | ||
| return makeWorldPt(Number(ra), Number(dec), CoordinateSys.EQ_J2000); |
There was a problem hiding this comment.
We need to rethink this. This is wise specific code and not general. The function name looks general but is looks at wise search parameters and table columns.
We need to avoid having mission specific code in the general functions. I will think about what is the best way to proceed.
robyww
left a comment
There was a problem hiding this comment.
After doing some research it appears that wise is using in_ra and in_dec to make cutouts.
for example
firefly/src/firefly/js/metaConvert/missions/WiseRequestList.js
Lines 68 to 71 in cde0644
However the real problem it the table metadata is set wrong (at least in the wise case) by the IBE search processor.
firefly/src/firefly/java/edu/caltech/ipac/astro/ibe/BaseIbeDataSource.java
Lines 174 to 176 in cde0644
That is where the real problem is and needs to be fixed. You should look at the other missions in metaConvert/missions and see it that applies to them as well. so I don't think we need the getCutoutAwareWorldPtFromTableRow function the code should keep using getWorldPtFromTableRow. It should work if the the meta data is set correctly.
firefly/src/firefly/js/data/MetaConst.js
Lines 11 to 18 in cde0644
crval1 and crval2 are related to pixels that are the projection base for the original FITS file. They come from the FITS header. For cutouts they could be off the image.
Thanks, @robyww. I see what you mean about the mission specific code. I tried changing CENTER_COLUMN but it breaks its other readers like the chart and seems to cause other issues. It looks like we don't need to make a change to the server though because the converters you're pointing to already work out the position for us. We can have them report that position and then have the microscope ask its table's converter. That keeps it agnostic. Does that sound good? |
|
I think Your right, we could also do something like makeDataProductsConverter(table).getImageCenterColumns()Why don't you take another look at |
FIREFLY-2138 "WISE: use microscope: search at row uses field center"
Description:
The microscope menu's "at row" searches aren't starting from the search position for the cutouts. They start from the center of the full image the cutout was taken from.
Fix:
"At row" searches start from the search position when the table shows cutouts.
Builds:
irsa-ife: https://firefly-2138-wise-search.irsakubedev.ipac.caltech.edu/applications/wise
firefly: https://firefly-2138-wise-search.irsakubedev.ipac.caltech.edu/firefly
Validation:
Microscope readout
TAP menu readout
By comparison, on the deployed WISE app, we can see the wrong values are shown (e.g. 183.93094, -16.65889).