Dear Dustin,
I have some follow-up questions/remarks, as I'm trying to do essentially the same thing and my attempts might be useful for other people.
I want to get the photo-z for sources in a given cone (ra,dec,radius) from a python script.
1) Your example uses the Datalab interface, if I've understood correctly, to perform the same query from a python script one would need to use the
datalab client
2) The query does not work in your example, I think because the ls_dr9.photo_z table does not contain the ra,dec columns. My approach to solving this would be to query the ls_dr9.tractor table with the ra,dec,radius and get the release,brickid,objid for each object in the table to make a unique identifier hash as suggested, and then use this hash to query the ls_dr9.photo_z. Are you aware of a simpler way than this?
3) In general, is there a scriptable way to get the photo-z information for sources in the legacy survey Tractor or Sweep tables?
Cheers,
Jesse
PS: Thank you for all the work you've done for the community over the
years, I particularly appreciate the
astrometry.net service.