osa logo
OSA Home
Start Here
Data Overview
Known Issues
the Surveys
Coverage Maps
Schema browser
Data access
Login
Archive Listing
GetImage
MultiGetImage
Region
Freeform SQL
CrossID
SQL Cookbook
Q&A
Glossary
Release History
Gallery
Publications
Monitor
Downtime
Links
osa logo bottom
IFA     ROE
Home | Overview | Browser | Access | Login | Cookbook 
  OSA logo

OSA - Known Issues

General problems:


Please pay particular attention to the following outstanding problems: Unpaired sources in the atlasSource table

Source merging, i.e. taking the detections in various wavebands and combining them for a given source object, is performed on a frameset basis. Currently for ATLAS a frameset is based on a single detector (one of 32) that is the result of stacking two dither offsets (to fill the gaps).

It has been discovered that some pointings in ATLAS in the various wavebands are offset from each other. As this offset increases the number of unmerged/unpaired sources increases. In previous surveys archived by WFAU this effect has been negated by the large overlaps between pointings (eg UKIDSS) and the seamless catalogues extracted (using the priorOrSec flag) do not really suffer from the these edge effects.

Unfortunately overlap between pointings with ATLAS is small and the offsets between wavebands can be quite large compared to the framesets themselves. The effect is compounded by the fact that spurious sources are more commonly found around the detector edges due to issues of scattered light and single exposure coverage. An investigation based on looking at g and r sources in DR1 showed that around 1.5 percent of real pairings are missed. However all detections are stored in atlasDetection and every detection appears in a source in atlasSource it's just that the source merging is sub-optimnal resulting in unmatched sources in the primary selection because their match appears on a different frameset.

To visualize the issue we can look at multiframeIDs 34350 (g band) and 34575 (r band). The field centres for these two multiframes are some 40 arcsec apart. The following query finds all primary sources with g or r mags brighter than 20th.

select s.ra as raDeg,s.dec as decDeg, gApermag3, rApermag3 
from atlasSource as s, atlasmergelog as m
where m.framesetid=s.framesetid 
and (priOrSec=0 or priOrSec=s.framesetid) /* seamless primary sources*/
and (gmfid=34350 or rmfid=34575)
and (gApermag3 between 0 and 20  or rapermag3 between 0 and 20)
This query reurns 3437 sources, of these 349 have either no g or no r magnitude (gapermga3 <0 or rapermag3 <0) i.e. have no match in the other band. The plot below shows all the sources (red) and unpaired (blue), the unpaired mostly follow the detector/frameset edges.

We can recover matches by selecting secondary sources in the region of interest

select ra as raDeg,dec as decDeg,gApermag3,rApermag3 
from atlasSource
where(priOrSec !=0 and priOrsec != framesetid) /* secondary */
and (gApermag3 >0 or rApermag3 >0)
and ra between 192.5 and 193.9 and
dec between -7.15 and -6.05
Pairing up the 349 unmatched sources from the first query with the results of the second query, we find that 168 have matches. The recovered mags are plotted below showing that 163 of the matches show reasonable agreement and are likely real. The unrecovered mags will mostly be crud detectiions around detector/frameset edges. So for these particular two observations around 5% of real potential g/r pairs are missing in the primary source catalogue but can be recovered.

Contamination from unmatched sources can be reduced by excluding the dither region surrounding a framesset, this is done using the ppErrBit flags, so the first query above becomes

select s.ra as raDeg,s.dec as decDeg, gApermag3, rApermag3
from atlasSource as s, atlasmergelog as m
where m.framesetid=s.framesetid
and (priOrSec=0 or priOrSec=s.framesetid) /* seamless primary sources*/
and (gmfid=34350 or rmfid=34575)
and (gApermag3 between 0 and 20  or rapermag3 between 0 and 20)
and rppErrbits & 0x00400000 = 0
and gppErrbits & 0x00400000 = 0
This query now returns some 2619 sources, with 165 unpaired. Some 129 of these are recovered by pairing with the secondary sources in this region. Although fewer unpaired sources are returned using the ppErrBit flag the downside is gaps in coverage.

If you have questions of the issue or need help with recovering matches please contact osa-support.

r-band observations arranged by time rather than OB in vphasSource table

In current VPHAS+ releases, VPHASDR3 (VPHASv20170222) and earlier, a mistake in the processing meant that band-merging was not done with the expected OB constraints. This means that r_1 is the earliest r frame in a pointing, not the one associated with the ugr epoch and r_2 is the latest, not the one associated with the riHa epoch. To select data such that colours are from contemporaneous bands and the band order is as expected, use the following type of query:

SELECT s.sourceID,umgPnt,umgPntErr,gmr_1Pnt as gmrPnt,gmr_1PntErr as
          gmrPntErr,r_2miPnt as rmiPnt,r_2miPntErr as rmiPntErr,CASE WHEN
          r_2AperMag3>0. AND havphasAperMag3>0. THEN (r_2AperMag3-havphasAperMag3)
          ELSE-9.99995E8 END AS rmhavphasPnt,CASE WHEN r_2AperMag3Err>0. AND
          havphasAperMag3Err>0. THEN SQRT(r_2AperMag3Err*r_2AperMag3Err+havphasAperMag3Err*havphasAperMag3Err)
          ELSE-9.99995E8 END AS rmhavphasPntErr,u.mjdObs as uMjd,g.mjdObs  as
          gMjd,r_1.mjdObs as r_1Mjd,r_2.mjdObs  as r_2Mjd,i.mjdObs as iMjd,ha.mjdObs as havphasMjd,
          uAperMag3,uAperMag3Err,gAperMag3,gAperMag3Err,r_1AperMag3,r_1AperMag3Err,r_2AperMag3,
          r_2AperMag3Err,iAperMag3,iAperMag3Err,havphasAperMag3,havphasAperMag3Err
          FROM vphasMergeLog as l,vphasSource as s,Multiframe as u,Multiframe as g,
                Multiframe as r_1,Multiframe as r_2,Multiframe as i,Multiframe as ha
            WHERE s.frameSetID=l.frameSetID and l.umfID=u.multiframeID and
            l.gmfID=g.multiframeID and l.r_1mfID=r_1.multiframeID and
            l.r_2mfID=r_2.multiframeID and l.imfID=i.multiframeID and
            l.havphasmfID=ha.multiframeID and l.frameSetID BETWEEN 816043786241 AND
            816043786337 and
            ((u.mjdObs>0 and r_1.mjdObs>0 and abs(u.mjdObs-r_1.mjdObs)<0.3) or
            (g.mjdObs>0 and r_1.mjdObs>0 and abs(g.mjdObs-r_1.mjdObs)<0.3)
            or (i.mjdObs>0 and r_2.mjdObs>0 and abs(i.mjdObs-r_2.mjdObs)<0.3)
            or (ha.mjdObs>0 and r_2.mjdObs>0 and abs(ha.mjdObs-r_2.mjdObs)<0.3))
            UNION
            SELECT s.sourceID,umgPnt,umgPntErr,gmr_2Pnt as gmrPnt,gmr_2PntErr as
            gmrPntErr,r_1miPnt as rmiPnt,r_1miPntErr as rmiPntErr,CASE WHEN
            r_1AperMag3>0. AND havphasAperMag3>0. THEN (r_1AperMag3-havphasAperMag3)
            ELSE-9.99995E8 END AS rmhavphasPnt,CASE WHEN r_1AperMag3Err>0. AND
            havphasAperMag3Err>0. THEN
            SQRT(r_1AperMag3Err*r_1AperMag3Err+havphasAperMag3Err*havphasAperMag3Err)
            ELSE-9.99995E8 END AS rmhavphasPntErr,u.mjdObs as uMjd,g.mjdObs  as
            gMjd,r_2.mjdObs as r_1Mjd,r_1.mjdObs  as r_2Mjd,i.mjdObs as iMjd,ha.mjdObs
            as havphasMjd, uAperMag3,uAperMag3Err,gAperMag3,gAperMag3Err,r_2AperMag3 as
            r_1AperMag3,r_2AperMag3Err as r_1AperMag3Err, r_1AperMag3 as
            r_2AperMag3,r_1AperMag3Err as
            r_2AperMag3Err,iAperMag3,iAperMag3Err,havphasAperMag3,havphasAperMag3Err
            FROM vphasMergeLog as l,vphasSource as s,Multiframe as u,Multiframe as
            g,Multiframe as r_1,Multiframe as r_2,Multiframe as i,Multiframe as ha<
            WHERE s.frameSetID=l.frameSetID and l.umfID=u.multiframeID and
            l.gmfID=g.multiframeID and l.r_1mfID=r_1.multiframeID and
            l.r_2mfID=r_2.multiframeID and l.imfID=i.multiframeID and
            l.havphasmfID=ha.multiframeID and l.frameSetID BETWEEN 816043786241 AND
            816043786337 and
            ((u.mjdObs>0 and r_2.mjdObs>0 and abs(u.mjdObs-r_2.mjdObs)<0.3) or
            (g.mjdObs>0 and r_2.mjdObs>0 and abs(g.mjdObs-r_2.mjdObs)<0.3)
            or (i.mjdObs>0 and r_1.mjdObs>0 and abs(i.mjdObs-r_1.mjdObs)<0.3)
            or (ha.mjdObs>0 and r_1.mjdObs>0 and abs(ha.mjdObs-r_1.mjdObs)<0.3))
            UNION
            SELECT s.sourceID,umgPnt,umgPntErr,gmr_1Pnt as gmrPnt,gmr_1PntErr as
            gmrPntErr,r_2miPnt as rmiPnt,r_2miPntErr as rmiPntErr,CASE WHEN
            r_2AperMag3>0. AND havphasAperMag3>0. THEN (r_2AperMag3-havphasAperMag3)
            ELSE-9.99995E8 END AS rmhavphasPnt,CASE WHEN r_2AperMag3Err>0. AND
            havphasAperMag3Err>0. THEN
            SQRT(r_2AperMag3Err*r_2AperMag3Err+havphasAperMag3Err*havphasAperMag3Err)
            ELSE-9.99995E8 END AS rmhavphasPntErr,u.mjdObs as uMjd,g.mjdObs  as
            gMjd,r_1.mjdObs as r_1Mjd,r_2.mjdObs  as r_2Mjd,i.mjdObs as iMjd,ha.mjdObs
            as havphasMjd,
            uAperMag3,uAperMag3Err,gAperMag3,gAperMag3Err,r_1AperMag3,r_1AperMag3Err,r_2
            AperMag3,r_2AperMag3Err,iAperMag3,iAperMag3Err,havphasAperMag3,havphasAperMag3Err
            FROM vphasMergeLog as l,vphasSource as s,Multiframe as u,Multiframe as
            g,Multiframe as r_1,Multiframe as r_2,Multiframe as i,Multiframe as ha
            WHERE s.frameSetID=l.frameSetID and l.umfID=u.multiframeID and
            l.gmfID=g.multiframeID and l.r_1mfID=r_1.multiframeID and
            l.r_2mfID=r_2.multiframeID and l.imfID=i.multiframeID and
            l.havphasmfID=ha.multiframeID and l.frameSetID BETWEEN 816043786241 AND 816043786337
            and ((g.mjdObs<0 and i.mjdObs<0) or (r_1.mjdObs<0 and r_2.mjdObs<0))

This query has several important features: UNION to combine 3 selections: i) where the observed time of the r_1 frame matches the u or g frame or the observed time of the r_2 frame matches the i or H-alpha frame; ii) where the observed time of the r_2 frame matches the u or g frame or the observed time of the r_1 frame matches the i or H-alpha frame; iii) where there is not a corresponding g and i frame or r_1 and r_2.

Use of aliasing to rename columns: r_1AperMag3 is aliased to r_2AperMag3 in the cases where the r_1 frame matches the observed time of the i frame or Ha frame.

Use of CASE WHEN THEN ELSE to create rmHavphas colours on the fly, with the correct defaults.

The frameset selection in this case selected 96 frameSets. Each frameset covers a matching set of detectors, and there are 32 detectors in the focal plane. Moreover in VPHAS+ there are typically 3 pointings each separated by 0.2 degrees, 2 which have ugr-riHa observations and a third which have g-Ha observations. In future releases we hope to stack these while still giving photometry that has been correctly illumination corrected, but in VPHAS+ DR3 and earlier releases a typical tile consists of 96 frameSets.



Home | Overview | Browser | Access | Login | Cookbook
Listing | FreeSQL
Links | Credits

WFAU, Institute for Astronomy,
Royal Observatory, Blackford Hill
Edinburgh, EH9 3HJ, UK

osa-support@roe.ac.uk
25/9/2023