vector calculations for apparent().altaz()
See original GitHub issueHi Brandon, recently I heavily used the new panda approach for hipparchus catalogue. As I run through your examples they worked fine. Is used the same filter approach like in your documentation.
For getting an AltAz picture of the selected stars I would replace
ra, dec, distance = astrometric.radec()
straight forward with
alt, az, d = astrometric.apparent().altaz()
but this approach throws some errors:
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/skyfield/positionlib.py", line 413, in apparent
position_au, gcrs_position)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/skyfield/earthlib.py", line 115, in compute_limb_angle
coszd = dots(position_au, observer_au) / (disobj * disobs)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/skyfield/functions.py", line 15, in dots
return (v * u).sum(axis=0)
ValueError: operands could not be broadcast together with shapes (3,93) (3,)
From my point of view that might be related to absence of vector capabilities in apparent and altaz module. If you could confirm that, I would change my code to get a list of Stars out of the datagram like:
bright_stars = list()
for index, row in df.iterrows():
bright_stars.append(Star.from_dataframe(row)
to get a list, which is appropriate. Any thoughts about my doing ? Many thanks in advance and merry christmas !
Michel
Issue Analytics
- State:
- Created 5 years ago
- Comments:21 (8 by maintainers)
Top Results From Across the Web
Positions — Skyfield documentation - Rhodes Mill
Skyfield stores the locations of celestial bodies as (x,y,z) vectors that ... An Apparent position is computed by calling the Astrometric.apparent() method.
Read more >Horizontal coordinates - PyAstronomy
Convert hour angle and declination into horizon (alt/az) coordinates. Parameters. hafloat or array. Local apparent hour angle in DEGREES. decfloat or array.
Read more >HOR2EQ - L3HarrisGeospatial.com
This is a nice code to calculate equatorial (ra,dec) coordinates from horizon (alt,az) coords. It is typically accurate to about 1 arcsecond
Read more >eq2hor.pro
... and uses vector arithmetic in every calculation except ; when calculating ... N_params() LT 4 then begin print,'Syntax - EQ2HOR, ra, dec,...
Read more >Convert from Alt/Az coordinates w.r.t. point on surface to (x,y,z ...
In order to calculate a new point from an origin, you will also need a distance from the origin to the point in...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@brandon-rhodes,
Sorry for the late answer, I’m on a business trip, but got a quick test and with 1.14 is works nicely. Thanks for fixing !
Michel
Great! I’ll see about getting a release out this week, if things don’t get too busy.