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

enhancements to PartitionIndexer.observations_to_indices #2

Open
cchris28 opened this issue Jul 18, 2023 · 0 comments
Open

enhancements to PartitionIndexer.observations_to_indices #2

cchris28 opened this issue Jul 18, 2023 · 0 comments

Comments

@cchris28
Copy link
Collaborator

  • Use "radius" instead of "fov" as it is more conventional
  • SkyCoord.separation is the haversine angle speed colud be improved. Benchmark. Consider dot product and see Dino comment below.
  • ephemeris.set requires internet connection. Consider alternative (ask Dino).

Dino on SkyCoord.separation
You want to transform to cartesian system and then search a box because .separation is the Haversine distance and is very costly. See how I did it in the example implementation. This is why this same approach works for 80 mil rows for CADC, you round all that down to integers, execute a fast select on indexed integers in the DB, and then you prune on finer shapes. Or in our case, we can skip the integers because there's no slow and fast np.where. You might not intending for this function to do that so this might be fine, or not, but if you were this won't be fast if there are many pointings.

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

1 participant