Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Review observatory coordinates #27

Open
dkirkby opened this issue Jan 6, 2016 · 3 comments
Open

Review observatory coordinates #27

dkirkby opened this issue Jan 6, 2016 · 3 comments

Comments

@dkirkby
Copy link
Member

dkirkby commented Jan 6, 2016

The specsim.transform.observatories dictionary gives astropy coordinates of APO, KPNO, LSST by name, as a convenience. This issue is to verify that these are correct and investigate if there is an alternative source of this info that should be used instead. This was prompted by my recent discovery that astropy has an extensive database that is accessible via EarthLocation.of_site() and stored in a json file.

However, taking the case of APO, it is not clear what the right answer should be since there are two different telescopes (2.5m and 3.5m). Are the differences between their locations negligible for all applications? The APO home page quotes:

Latitude 32° 46' 49" N, Longitude 105° 49' 13" W
Elevation 2788 meters

while the astropy db uses (from the IRAF Observatory Database):

"elevation": 2798,
"latitude": 32.78,
"longitude": 254.17999999999998,

and Don's nightly science plans assume:

Longitude:  105.820 degrees       Altitude:  2819.000 meters
 Latitude:    32.780 degrees      UT-Civil:     7.000 hours

Finally, the (e)BOSS plate design code uses:

if n_elements(lat) EQ 0 then lat = 32.7797556D
if n_elements(height) EQ 0 then height = 2797.D
@dmargala
Copy link

Currently, EarthLocation.of_site() requires an active internet connection to look up APO.

@dkirkby
Copy link
Member Author

dkirkby commented Jan 21, 2016

It looks like the download only happens the first time and then is cached:

https://github.com/astropy/astropy/blob/v1.1.x/astropy/coordinates/earth.py#L258

@dmargala
Copy link

Hmm, I can't reproduce the error now but this was the error I encountered a few days ago:

WARNING: Could not access the online site list. Falling back on the built-in version, which is rather limited. If you want to retry the download, do EarthLocation._get_site_registry(force_download=True) [astropy.coordinates.earth]
Traceback (most recent call last):
...
    self.where = astropy.coordinates.EarthLocation.of_site('apo')
  File "/Users/Daniel/anaconda/lib/python2.7/site-packages/astropy/coordinates/earth.py", line 220, in of_site
    raise UnknownSiteException(e.site, 'EarthLocation.get_site_names', close_names=e.close_names)
astropy.coordinates.errors.UnknownSiteException: u"Site 'apo' not in database. Use EarthLocation.get_site_names to see available sites."

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants