iCompare: A Package for Automated Comparison of Solar System Integrators

We present a tool for the comparison and validation of the integration packages suitable for Solar System dynamics. iCompare, written in Python, compares the ephemeris prediction accuracy of a suite of commonly-used integration packages (JPL/HORIZONS, OpenOrb, OrbFit at present). It integrates a set of test particles with orbits picked to explore both usual and unusual regions in Solar System phase space and compares the computed to reference ephemerides. The results are visualized in an intuitive dashboard. This allows for the assessment of integrator suitability as a function of population, as well as monitoring their performance from version to version (a capability needed for the Rubin Observatory's software pipeline construction efforts). We provide the code on GitHub with a readily runnable version in Binder (https://github.com/dirac-institute/iCompare).


INTRODUCTION
Accurate computation of positions and velocities of Solar System objects (ephemerides) is a challenging problem solved by special-purpose numerical integration software packages (integrators). A number of these are in use by the dynamics community: JPL/HORIZONS 1 , OpenOrb 2 (Granvik et al. 2015), and OrbFit 3 to name a few. JPL/HORI-ZONS is generally regarded as the "gold standard" for highprecision short-term computation, while others may excel for different purposes (e.g., longer-term integration). However, we have found no easy way to compare their performance and select the best tool for any given job. Ideally, one would like a tool that can automatically compute and compare the ephemerides produced by a suite of integrators, and visually present the results. For example, the Rubin Observatory's Data Management system (Jurić et al. 2017) for the Legacy Survey of Space and Time (LSST) (Ivezić et al. 2019) is required to accurately predict the positions of known moving objects to enable association and monitoring thereof.
In this note we present iCompare, a software package for comparison and validation of Solar System integrators. Written in Python, it compares the ephemerides prediction accu-Corresponding author: Maria Chernyavskaya maria8ch@uw.edu racies of a suite of commonly-used integrators, and displays the results in a color-coded table.

Overview and Architecture
iCompare is a pure-Python package that automatically runs a suite of orbit integrators with identical inputs and comparable dynamical models; compares their outputs and produces a color-coded table representing the closeness of predicted ephemerides to a reference integrator ( Figure 1).
The package is built to be modular and extensible. The main driver and the output visualization functions are all in a single file (icompare/__init__.py, at present). Code for each supported integrator is implemented in its own file (e.g. icompare/openorb.py), with the requirement that such modules must export a function with the signature def get_ephem(elements, start, stop, obscode) where elements are the orbital elements in cometary format, start and stop are the start and stop times of integration, and obscode is the MPC Observatory Code. This architecture makes it easy to enhance iCompare with support for new integrators 4 .

Supported Integrators and their Configuration
iCompare supports three integrators at present: the JPL/HORIZONS (the reference integrator), OpenOrb, and OrbFit. These support different options for tuning the dynamical model and integration method. All have been con-figured to use the DE430 ephemerides, except for JPL/HORI-ZONS which has recently switched to DE441 5 . The details are as follows: • JPL/HORIZONS is a web service that offers few user-tunable options. We use it in its default configuration with astroquery.jplhorizons (Ginsburg et al. 2019).
• OpenOrb uses the default dynamical model of OpenOrb's python bindings, pyoorb, which is the typical of the way most users would run it. This includes the DE430 ephemerides, N-body integration, a 5-day integration step, and no asteroid perturbers.
• OrbFit exposes the ability to adjust the dynamical model through numerous settings. Per advice by the OrbFit team (F. Spoto, priv. comm.), we've used the settings listed in the icompare/orbfit.py file 6 . We caution the reader that these choices may change as the software evolves; the most recent settings can always be found in icompare/orbfit.py.

Reference Integrator
At present, the reference integrator is fixed to JPL/HORI-ZONS; a future version will allow it to be user-selectable. All computed ephemerides are compared to JPL/HORIZONS outputs, and the comparisons are displayed in the visual dashboard.

Ephemerides comparison
In the default configuration, iCompare computes the predicted positions of given objects over a 10yr timespan, January 1, 2010 -January 1, 2020, with step size of one day. The default obscode is I11, the standard stand-in for the Rubin Observatory, Gemini South Telescope.
Once the positions of the propagated objects have been computed, we compute the great circle distances between the predictions of each integrator and the reference integrator 7 . These results are passed to icompare.table stats(), which computes a median, mean and the maximum ephemeris difference over the integrated periods. The chosen summary statistics give the user a sense of the typical differences, as well as the maximum differences in predicted positions over the integration period. 5 Strictly speaking, the integrators would all use the same dynamical model, or at least the state vectors derived for their particular model. This is not what occurs in common every-day use. 6 https://github.com/dirac-institute/iCompare/blob/ a823cbfeb86bedd40bf4480382e17974f5066827/icompare/orbfit.py#L78 7 See Section 2.3

Test Objects
We have selected 22 objects to represent different populations for orbit propagation. Our set includes Main Belt Asteroids (MBAs), Potentially Hazardous Asteroids (PHAs), Near Earth Objects (NEOs), Trans-Neptunian Objects (TNOs), and representatives of Mars Trojans, Jupiter Trojans, Centaurs, Impactors, a "Vatira" asteroid (2020 AV2), and an Interstellar Object ('Oumuamua). These were chosen with LSST applications in mind, but iCompare allows the user to modify the list as necessary.

Binder support
We provide the ability to directly launch and test a Jupyter notebook with iCompare using mybinder.org, an "online service for building and sharing reproducible and interactive computational environments from online repositories" 8 . This makes it possible to try and run iCompare without installing any software locally.
3. RESULTS Figure 1 shows an example run of iCompare, using the default settings and test objects as described in preceding sections. The columns contain integrator and statistical value labels, and the rows show the asteroids, grouped by object type. All values in the table are expressed in arcseconds. The data is color-coded as follows: if the difference between ephemerides is less than 0.05 arcseconds, no color is applied. If the difference up to 0.2" (roughly a single LSST-Cam pixel), the cell is blue to denote a small but statistically detectable difference. A difference up to 0.6" (comparable to Rubin Observatory median PSF width of 0.8") is marked orange. Finally, the cells shaded red indicate significant differences between integrators that are likely to be observable even in single-epoch observations. As can be inferred from the previous paragraphs, the default color map has been selected for Rubin Observatory development purposes. The user can override it via an argument to the icompare. plot() function.
Much of the table has no color flags, showing close agreement of all tested integrators. As expected, the rows towards the bottom -impactors, NEOs, and an ISO with cometary behavior -show the largest deviations. These are particularly difficult objects to integrate, especially with default settings. While individual object accuracy could be improved on via hand-tuning the settings, we intentionally avoid doing so since the LSST is meant to be an automated survey. Instead, we hope to encourage the integrator writers to add functionality to auto-select the appropriate defaults based on the object being integrated. Figure 1. A screenshot of an iCompare-generated table of differences between ephemerides (in arcseconds), color-coded with the following schema: red > 1"; orange > 0.6"; blue > 0.2"; transparent > 0.05"

CONCLUSIONS AND FUTURE WORK
This note introduces iCompare, a Python package for the comparison of the most popular integrators in Solar System dynamics to JPL/HORIZONS. It enables a rapid visual comparison of ephemerides prediction accuracy of Solar System integrators across a range of orbits and object types. It is modular and extensible to new integrators by additions of a single Python wrapper. We hope iCompare will be useful to both integration package authors and users selecting an integrator for their specific application. We would especially encourage improvements towards automation of the integration packages such that they require less per-object handtuning; this is crucial for applications in automated surveys such as LSST.
iCompare is available at https://github.com/ dirac-institute/iCompare; feedback, feature suggestion, and pull requests are welcome and we invite collaboration on future improvements.