diff --git a/views.py b/views.py index 5ec9eeb..e626adc 100644 --- a/views.py +++ b/views.py @@ -395,13 +395,13 @@ class UpperLimitView(APIView): # refine belt to circular region using astropy separation for catsrc in belt_sources: catsrc_coord = SkyCoord(catsrc.ra_deg, catsrc.dec_deg, unit="deg") - separation = center_coord.separation(catsrc_coord).deg - if separation > radius_deg: + separation = center_coord.separation(catsrc_coord) + if separation.deg > radius_deg: continue f = catsrc.flux or 0.0 for lb in reversed(sorted_bounds): if f >= lb: - mask_radius = radius_map[lb] + mask_radius = radius_map[lb] * 3600 break nearby_sources.append( @@ -417,8 +417,8 @@ class UpperLimitView(APIView): "catalog_name": catsrc.catalog_name, "new_xray": catsrc.new_xray, "source_type": catsrc.source_type, - "mask_radius_deg": mask_radius, - "separation_deg": separation, + "mask_radius_as": mask_radius, + "separation_as": separation.arcsecond, } )