-
Notifications
You must be signed in to change notification settings - Fork 30
Description
When computing a MOC ts_map, the default pruning heuristic when refining the map is to refine only the k pixels with highest ts values. If there is a tie for the kth-highest ts value between two or more pixels, the set of pixels chosen for refinement will likely depend on the exact implementation of the heuristic.
For example, when computing maps with earth occlusion enabled, mapping returns many source pixels with ts = 0 (because the source would be totally occluded if it were at that pixel). If the kth-highest pixel is 0-valued, the set of pixels to be refined is unpredictable. In fact, I observed it to change based on the version of numpy used to implement top-k selection, which caused a test case failure on the server (numpy 1.26.4) that did not occur with my local installation (numpy 2.2.6).
While the case of ts = 0 can be handled specially (never refine such pixels), the top-k heuristic has potential issues with ties even if all ts values are > 0. I suggest that we deprecate the top-k heuristic and instead use the alternative ts threshold-based approach present in the MOC ts_map code, which is unaffected by ties.
Metadata
Metadata
Assignees
Labels
Type
Projects
Status