Astrokit for Scientists

Astrokit is an open-source web-based application for asteroid lightcurve photometry. It supports the discovery and analysis of asteroids in astrophotography by providing services that determine astrometry, photometry, and lightcurves of asteroids.

Astrokit is supported by a NASA ROSES research grant (C.21 Citizen science Asteroid Data, Education, and Tools - CADET).

The software is built to address the most pressing challenges facing research scientists and amateur astronomers seeking to create lightcurves:

User challenges

  • Proprietary software requires purchase and installation
  • Existing solutions require extensive prior understanding of photometry and reduction processes
  • Most solutions require spreadsheets and manual checks
  • Software becomes outdated as technology and techniques improve
  • Barriers to collaboration and sharing

Astrokit solutions

  • Free web application accessible from any browser
  • Open-source development approach
  • Guided checklists for non-professionals
  • Automate parameter tuning for photometry, comparison stars, and reductions
  • Automate checks of inputs and results
  • Integrate with other web databases, eg. MPC, VizieR
  • Disseminate results using open formats such as ALCDEF

Capabilities and Methodology

Astrokit supports the discovery and analysis of asteroids in astrophotography by providing services that determine astrometry, photometry, and lightcurves of asteroids. This section walks the reader through specific capabilities of the platform.

Refer to the Astrokit user flow diagram below for a summary of the guided process through which users conduct astrometry, photometry, and create corrected standard lightcurves.


Images are automatically analyzed for their astrometry immediately upon upload. If applicable, the software reads FITS headers and corresponding metadata is filled in the lightcurve or image models within Astrokit.

Astrometric solutions are later used to identify targets, select reference and comparison stars, and retrieve known magnitudes from catalogs.

After a group of images has been uploaded, the web server stores these images security on Amazon Web Services S3 cloud. A background astrometry job dispatches the images for analysis by the solver. The analyses are monitored and the results are retrieved by Astrkoit when complete.


Astrokit computes photometry by extracting a point-spread function (PSF) model from stars in observations.

We chose this technique because parameter tuning can be mostly automated, reducing the learning curve for beginners. The tedium of drawing apertures over an image is removed entirely, which saves time and opportunity for error.

The alternate approach, aperture photometry, assumes a linearly-varying background in the aperture’s vicinity and is sometimes preferred for its mathematical simplicity. PSF photometry excels in crowded star fields but is not strictly necessary for asteroid photometry. However, because the process is fully automated by Astrokit, we having the liberty of selecting the more advanced method. This is an example of how improved automation can enable more advanced models and reduce error.


The photometry process is implemented using the SExtractor and PSFex software packages. Both are popular open-source packages developed by Astromatic. When evaluating photometry packages, we first determined that SExtractor and PSFEx exhibit performance similar to that of the popular IRAF photometry package and the DAOPHOT algorithm. We then selected the package with the least tuning required without trading off accuracy.

Although Astrokit selects intelligent defaults, we stress the importance of performing checks and invite the user to review the work in progress. Ultimately, the entire process is transparent to a user interested in detail. It is interactive, allowing the user to tune parameters until they are satisfied with outputs.

As a result, the Astrokit photometry page includes the ability to tune photometry and review extracted point sources, instrumental magnitudes, flux, and SNR. A residual image is displayed to the user to allow visual verification of the accuracy of the PSF model. This section is accompanied by guidance on how to recognize successful photometry and residuals.

Astrokit uses the latest free sextractor and psfex binaries available via Debian and Ubuntu Linux package managers. SExtractor is a program that builds catalogs of objects from an astronomical image. PSFEx extracts models of the point-spread functions from images processed by SExtractor. In order to compute a catalog with accurate PSF photometry, the process via the Astromatic toolchain requires the creation of an initial catalog with SExtractor, transfer of this catalog to PSFEx in order to fit a PSF model, and a repeat use of SExtractor with the new model.

This processing is started by a photometry job and completed on the backend machine. Results are stored on S3 and can be downloaded by the user.

Tuning photometry parameters for an image.

Reference and Comparison Stars

Now that the astrometry and photometry steps have completed, we must reconcile their outputs and merge their data together. This allows us to match instrumental magnitudes from PSF photometry with known standard catalog magnitudes of reference stars.

In order to perform this join, we use an r-tree data structure to match results from astrometry to our own photometric results.

The VizieR service API (University of Strasbourg) is used to query these results using the URAT1 catalog, which is maintained by the U.S. Naval Observatory.

The user can then review a table of reference stars and associated data, including instrumental magnitudes, SNR, and standard magnitudes in a variety of bands. At this point, Astrokit also performs some checks at this point to ensure the basic sanity of the data, eg. by ensuring a roughly linear relationship between instrumental magnitudes and catalog magnitudes, and by highlighting stars within an acceptable SNR range. The user is shown guidance on choosing specific comparison stars (for example, by selecting stars that match the color of the asteroid).

At the lightcurve level, Astrokit looks at reference stars across all observations and selects common stars. From these stars, the software selects comparison stars for use in photometric reduction. Afterwards, the user can review and modify the list of comparison stars.

Reviewing reference stars.


At a high level, photometric reduction on Astrokit is split into two steps.

First, depending on the reduction, there are coefficients that must be derived across all observations. We refer to these generally as “lightcurve-level” reductions because the results are stored with the lightcurve and are shared among all image observations. Sometimes these specific coefficients are referred to as transforms or extinctions.

After lightcurve-level coefficients are determined, they are used to perform image-level reductions and obtain standard magnitudes for target objects.

The reduction methodology employed by Astrokit is outlined in astronomer Brian Warner’s book, A Practical Guide to Lightcurve Photometry and Analysis.

The full reduction equation is:

M_t = (m_t - comp_t) + T(CI_t - CI_c) + k"X(CI_t - CI_c) + M_c


M_t = sky (catalog) magnitude of target
m_t = instrumental mag of target
m_c = instrumental mag of comp
T = transform for given color index (e.g., B-V)
CI_t = color index of target
CI_c = color index of comp
k" = second order extinction (mag/air mass)
X = air mass
M_c = catalog magnitude of comp

Some reduction outputs, such as graphs of transforms, are produced on the backend using matplotlib. Others outputs, such as linearity check graphs, are interactive on the page. The results of image reductions are stored made available to the user.

Reduction details: Lightcurve level

Lightcurve level reductions are needed only if the user wants to perform a more accurate reduction that uses second-order extinction, a filter transformation coefficient, and the hidden transform. The ability to compute transforms and correct for extinction is dictated in part by the type of data the user has uploaded. If applicable, we determine these values by running calculations across all observations and combining them into a final result that is used in the reduction formula above.

Before reductions can be performed, the user is asked to specify the color index bands of their observation (for example, V-R or B-V). The user is also asked to pair images in these respective bands. A handful of image pairs is sufficient for the software to determine the coefficients necessary to perform a reduction.

Note that the use of transforms and multi-filter observations is optional. The user may also opt for simple differential photometry per the following equation:

M_target = (m_target - m_comp) + M_comp

This makes Astrokit suitable for a wide variety of differential photometry use cases beyond asteroid observations.

Transformation Coefficient

The transformation coefficient Tf converts raw instrumental magnitudes to standard magnitudes. The software uses the following equation:

M_f - m_f = T_f * CI + ZP_f


M_f = standard magnitude in color band of filter f
m_f = raw instrumental magnitude in band of f
T_f = converts instrumental mag to standard mag in band of f
CI = standard color index
Z_f = nightly zero oint in band of f

Using the comparison stars chosen by the software and confirmed by the user, the software determines Tf by running a linear regression on a plot of apparent magnitudes versus standard magnitudes in two color bands in order to determine slope of the equation above.

Hidden Transform

The "hidden transform" is the equation that allows us to compute the color index the target object in an observation. The derivation is similar to that of the transformation coefficient, although it is not used directly in the final photometry reduction (hence its name).

The coefficient for the hidden transform is calculated by a linear regression between standard color indexes and instrumental color indexes. Once determined, the transform is used to convert instrumental color indexes to standard color indexes for all observations.

Other values

Second-order extinction can be calculated by the backend, but because it does not change very often we give users the option of inputting a constant so that full derivation of second-order extinction is not required for each set of observations. Astokit provides guidance for when to use second-order extinction, including default values for certain CI bands.

Selecting image pairs at the lightcurve level.

Reduction details: Image level

Once the user is satisfied with computed transforms, they can perform a reduction for each image.

The software solves for the full photometry formula (from above):

M_t = (m_t - comp_t) + T(CI_t - CI_c) + k"X(CI_t - CI_c) + M_c

This reduction applies the transforms computed in the previous step and computes magnitudes for each (target + comparison) pair. The software calculates airmass on the observation's astrometry and metadata.

By repeating this calculation for each comparison star, we obtain multiple estimates for standard magnitude. The final standard magnitude is the mean of these estimates and the standard deviation is the error.

This entire process is then repeated for each comparison star by treating that star as an unknown target. As a result, every comparison star behaves as a “check star” that allows the user to compare the Astrokit reduction with an expected catalog magnitude. The software also displays a check graph that measures correlation between computed standard magnitudes and known standard magnitudes.

Image reductions are typically triggered en masse at the lightcurve level, with the entire process happening automatically for every uploaded image. Afterwards, the user is invited to review each observation, where they can review final results, intermediate steps, and the checks performed. Users may also run reductions on individual images if desired.


Astrokit is able to apply a variety of corrections, such as light-time and unity distance.

Image-level reduction, checks, and corrections.

Light Curves


Once reductions have been performed, the user can view a lightcurve of standard magnitudes plotted over time. The lightcurve includes JD, standard magnitudes, error, and is suitable for scientific publication. A full table of values is also shown below the lightcurve plot. The lightcurves can be phase-folded interactively, with the plot updating according to user input. The user can tweak the style and other settings of the chart. The final image can be downloaded for external sharing.

There are additional options to plot a lightcurve of instrumental magnitudes over time, plot a graph of magnitude error over time, export the lightcurve data to CSV/Excel format, and export the lightcurve data to ALCDEF Standard format.

A lightcurve in the making.


That's all for now! We hope this shows you why Astrokit may be a good tool to add to your workflow. Don't hesitate to Contact Us directly if you have any questions.