rodluger / starry

Tools for mapping stars and planets.
https://starry.readthedocs.io
MIT License
138 stars 32 forks source link

Duplicate Longitude and Latitude from Pixel Transform #312

Open andrew-ayala opened 9 months ago

andrew-ayala commented 9 months ago

Describe the bug The latitude and longitude arrays produced by the "get_pixel_transforms" function include duplicate values of at (0 Lat, 180 Lon) and superfluous (0 Lat, -180 Lon).

To Reproduce

map = starry.Map(ydeg=2)
map[1,0] = 1.0
map.show()

lat, lon, Y2P, P2Y, Dx, Dy = map.get_pixel_transforms(oversample=2)
print(lat)
print(lon)

Output:

Lats = [-90. 0. 0. 0. 0. 0. 0. 0. 0. 90.] Lons = [ 0. -180. -108. -36. 0. 36. 108. 180. 180. 0.]

Expected behavior I believe latitude and longitude of the sampled points should be unique and evenly sampled across the sphere's surface.

Your setup (please complete the following information):

Additional context