Using Astropy/Python/Juypter

Whilst trying to process my limited data on M101 I noticed the Pixinsight AnnotateImage Script had an option to output the solved objects to a text file.

What I decided I wanted to know was the distance for each of the identified objects so it was time to break out Python Jupyter Notebook and connect to SIMBAD via the very useful Astropy module.

First we need to iterate over the contents of the solved objects text file and push them into a Python list data object (objects).

Now we have a list of object names we can send this to the SIMBAD data service via the query_objects function to retrieve information on each of the objects in the list. However, for the purpose of this exercise I’m only really interested in the Z_value (RedShift) and maybe the Radial Velocity, using the Hubble Constant I could calculate the light year distance. Instead of calculating it myself I use the Planck13 class to return the value for the lookback_time function. This returns a value in Gyrs where 1,000,000,000 light years = 1 Gyr.

I really need to read up more on the Astropy API so I can deal with the errors shown above and look to perform inline sorting for the highest Z value. Regardless of the errors most of the objects were returned and based on the Z value the furthest object returned was PGC2489445 at some 3.04 billion light years.