Conversion from Latitude, Longitude, Altitude to ICRS #1067
-
Is there a way to convert a location from Latitude, Longitude, Altitude to ICRS? Thank you. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
ICRS uses coordinates with right ascension and declination, so it needs latitude, longitude, altitude, and azimuth at a specified date and time. |
Beta Was this translation helpful? Give feedback.
-
Happily, yes! If you build a geographic location object, its
Could you suggest how the documentation of Skyfield might be expanded or improved to make this easier to discover? That would guide me in getting this better explained, for other folks who might have the same question. |
Beta Was this translation helpful? Give feedback.
Oh, drat, I forgot the altitude in my example code! The
latlon()
method lets you specify a distance above the geoid:https://rhodesmill.org/skyfield/api-topos.html#skyfield.toposlib.Geoid.latlon
latlon(latitude_degrees, longitude_degrees, elevation_m=0.0)
So providing that third argument should give you the position you need.