Skip to main content

Astrometry.net solver interface

Project description

Astrometry

Astrometry turns a list of star positions into a pixel-to-sky transformation (WCS) by calling C functions from the Astrometry.net library (https://astrometry.net).

Astrometry.net star index files ("series") are automatically downloaded when required.

This package is useful for solving plates from a Python script, comparing star extraction methods, or hosting a simple local version of Astrometry.net with minimal dependencies. See https://github.com/dam90/astrometry for a more complete self-hosting solution.

Unlike Astrometry.net, Astrometry does not include FITS parsing or image pre-processing algorithms. Stars must be provided as a list of pixel positions.

This library works on Linux and macOS but it requires WSL on Windows.

We are not the authors of the Astrometry.net library. You should cite works from https://astrometry.net/biblio.html if you use the Astrometry.net algorithm via this package.

Get started

python3 -m venv .venv
source .venv/bin/activate
pip install astrometry
import astrometry

with astrometry.Solver(
    astrometry.series_5200.index_files(
        cache_directory="astrometry_cache",
        scales={6},
    )
) as solver:

    stars = [
        [388.9140568247906, 656.5003281719216],
        [732.9210858972549, 473.66395545775106],
        [401.03459504299843, 253.788113189415],
        [312.6591868096163, 624.7527729425295],
        [694.6844564647456, 606.8371776658344],
        [741.7233477959561, 344.41284826261443],
        [867.3574610200455, 672.014835980283],
        [1063.546651153479, 593.7844603550848],
        [286.69070190952704, 422.170016812049],
        [401.12779619355155, 16.13543616977013],
        [205.12103484692776, 698.1847350789413],
        [202.88444768690894, 111.24830187635557],
        [339.1627757703069, 86.60739435924549],
    ]

    solution = solver.solve(
        stars=stars,
        size_hint=None,
        position_hint=None,
        solution_parameters=astrometry.SolutionParameters(),
    )

    if solution.has_match():
        print(f"{solution.best_match().center_ra_deg=}")
        print(f"{solution.best_match().center_dec_deg=}")
        print(f"{solution.best_match().scale_arcsec_per_pixel=}")

solve is thread-safe. It can be called any number of times from the same Solver object.

Examples

Use the solver without with

import astrometry

solver = astrometry.Solver(...)
solver.solve(...) # solve can be called multiple times
solver.close() # close the index files used by the solver

Provide size and position hints

import astrometry

with astrometry.Solver(...) as solver:
    solution = solver.solve(
        stars=...,
        size_hint=astrometry.SizeHint(
            lower_arcsec_per_pixel=1.0,
            upper_arcsec_per_pixel=2.0,
        ),
        position_hint=astrometry.PositionHint(
            ra_deg=65.7,
            dec_deg=36.2,
            radius_deg=1.0,
        ),
        solution_parameters=...
    )

Print progress information (download and solve)

import astrometry
import logging

logging.getLogger().setLevel(logging.INFO)

with astrometry.Solver(...) as solver:
    solution = solver.solve(...)

Print field stars metadata

Astrometry extracts metadata from the star index ("series"). See Choosing series for a description of the available data.

import astrometry

with astrometry.Solver(...) as solver:
    solution = solver.solve(...)

    if solution.has_match():
        for star in solution.best_match().stars:
            print(f"{star.ra_deg}º, {star.dec_deg}º:", star.metadata)

Calculate field stars pixel positions with astropy

import astrometry

with astrometry.Solver(...) as solver:
    solution = solver.solve(...)

    if solution.has_match():
        wcs = solution.best_match().astropy_wcs()
        pixels = wcs.all_world2pix(
            [[star.ra_deg, star.dec_deg] for star in solution.best_match().stars],
            0,
        )
        # pixels is a len(solution.best_match().stars) x 2 numpy array of float values

astropy.wcs.WCS provides many more functions to probe the transformation properties and convert from and to pixel coordinates. See https://docs.astropy.org/en/stable/api/astropy.wcs.WCS.html for details. Astropy (https://pypi.org/project/astropy/) must be installed to use this method.

Print series description and size (without downloading them)

import astrometry

print(astrometry.series_5200_heavy.description)
print(astrometry.series_5200_heavy.size_as_string({2, 3, 4}))

See Choosing Series for a list of available series.

Disable tune-up and distortion

import astrometry

with astrometry.Solver(...) as solver:
    solution = solver.solve(
        stars=...,
        size_hint=...,
        position_hint=...,
        solution_parameters=astrometry.SolutionParameters(
            sip_order=0,
            tune_up_logodds_threshold=None,
        ),
    )

Stop the solver early using the log-odds callback

Return after the first match

import astrometry

with astrometry.Solver(...) as solver:
    solution = solver.solve(
        stars=...,
        size_hint=...,
        position_hint=...,
        solution_parameters=astrometry.SolutionParameters(
            logodds_callback=lambda logodds_list: astrometry.Action.STOP,
        ),
    )

Return early if the best log-odds are larger than 100.0

import astrometry

with astrometry.Solver(...) as solver:
    solution = solver.solve(
        stars=...,
        size_hint=...,
        position_hint=...,
        solution_parameters=astrometry.SolutionParameters(
            logodds_callback=lambda logodds_list: (
                astrometry.Action.STOP
                if logodds_list[0] > 100.0
                else astrometry.Action.CONTINUE
            ),
        ),
    )

Return early if there are at least ten matches

import astrometry

with astrometry.Solver(...) as solver:
    solution = solver.solve(
        stars=...,
        size_hint=...,
        position_hint=...,
        solution_parameters=astrometry.SolutionParameters(
            logodds_callback=lambda logodds_list: (
                astrometry.Action.STOP
                if len(logodds_list) >= 10.0
                else astrometry.Action.CONTINUE
            ),
        ),
    )

Return early if the three best matches are similar

import astrometry

def logodds_callback(logodds_list: list[float]) -> astrometry.Action:
    if len(logodds_list) < 3:
        return astrometry.Action.CONTINUE
    if logodds_list[1] > logodds_list[0] - 10 and logodds_list[2] > logodds_list[0] - 10:
        return astrometry.Action.STOP
    return astrometry.Action.CONTINUE


with astrometry.Solver(...) as solver:
    solution = solver.solve(
        stars=...,
        size_hint=...,
        position_hint=...,
        solution_parameters=astrometry.SolutionParameters(
            logodds_callback=logodds_callback,
        ),
    )

Choosing series

This library downloads series from http://data.astrometry.net. A solver can be instantiated with multiple series and scales as follows:

import astrometry

with astrometry.Solver(
    astrometry.series_5200.index_files(
        cache_directory="astrometry_cache",
        scales={4, 5, 6},
    )
    + astrometry.series_4200.index_files(
        cache_directory="astrometry_cache",
        scales={6, 7, 12},
    )
) as solver:
    ...

Astrometry.net gives the following recommendations to choose a scale:

Each index file contains a large number of “skymarks” (landmarks for the sky) that allow our solver to identify your images. The skymarks contained in each index file have sizes (diameters) within a narrow range. You probably want to download index files whose quads are, say, 10% to 100% of the sizes of the images you want to solve.

For example, let’s say you have some 1-degree square images. You should grab index files that contain skymarks of size 0.1 to 1 degree, or 6 to 60 arcminutes. Referring to the table below, you should [try index files with scales 3 to 9]. You might find that the same number of fields solve, and faster, using just one or two of the index files in the middle of that range - in our example you might try [5, 6 and 7].

-- http://astrometry.net/doc/readme.html

Scale 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
Skymark diameter (arcmin) [2.0, 2.8] [2.8, 4.0] [4.0, 5.6] [5.6, 8.0] [8, 11] [11, 16] [16, 22] [22, 30] [30, 42] [42, 60] [60, 85] [85, 120] [120, 170] [170, 240] [240, 340] [340, 480] [480, 680] [680, 1000] [1000, 1400] [1400, 2000]

The table below lists series sizes and properties (we copied the descriptions from http://data.astrometry.net). You can access a series' object with astrometry.series_{name} (for example astrometry.series_4200).

Name Total size Scales Description Metadata
4100 0.36 GB [7, 19] built from the Tycho-2 catalog, good for images wider than 1 degree, recommended MAG_BT: float
MAG_VT: float
MAG_HP: float
MAG: float
4200 33.78 GB [0, 19] built from the near-infared 2MASS survey, runs out of stars at the low end, most users will probably prefer 4100 or 5200 j_mag: float
5000 76.24 GB [0, 7] an older version from Gaia-DR2 but without Tycho-2 stars merged in, our belief is that series_5200 will work better than this one source_id: int
phot_g_mean_mag: float
phot_bp_mean_mag: float
phot_rp_mean_mag: float
parallax: float
parallax_error: float
pmra: float
pmra_error: float
pmdec: float
pmdec_error: float
ra: float
dec: float
ref_epoch: float
5200 36.14 GB [0, 6] LIGHT version built from Tycho-2 + Gaia-DR2, good for images narrower than 1 degree, combine with 4100-series for broader scale coverage, the LIGHT version contains smaller files with no additional Gaia-DR2 information tagged along, recommended -
5200_heavy 79.67 GB [0, 6] HEAVY version same as 5200, but with additional Gaia-DR2 information (magnitude in G, BP, RP, proper motions and parallaxes), handy if you want that extra Gaia information for matched stars ra: float
dec: float
mag: float
ref_cat: str
ref_id: int
pmra: float
pmdec: float
parallax: float
ra_ivar: float
dec_ivar: float
pmra_ivar: float
pmdec_ivar: float
parallax_ivar: float
phot_bp_mean_mag: float
phot_rp_mean_mag: float
6000 1.20 GB [4, 6] very specialized, uses GALEX Near-UV measurements, and only a narrow range of scales fuv_mag: float
nuv_mag: float
6100 1.58 GB [4, 6] very specialized, uses GALEX Far-UV measurements, and only a narrow range of scales fuv_mag: float
nuv_mag: float

The table below indicates the total file size for each scale (most series have multiple index files per scale).

Name 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
4100 - - - - - - - 165.00 MB 94.55 MB 49.77 MB 24.87 MB 10.21 MB 5.30 MB 2.73 MB 1.38 MB 740.16 kB 408.96 kB 247.68 kB 187.20 kB 144.00 kB
4200 14.22 GB 9.25 GB 5.06 GB 2.63 GB 1.31 GB 659.09 MB 328.25 MB 165.44 MB 81.84 MB 41.18 MB 20.52 MB 8.02 MB 4.17 MB 2.16 MB 1.10 MB 596.16 kB 339.84 kB 213.12 kB 164.16 kB 132.48 kB
5000 34.79 GB 20.19 GB 10.74 GB 5.44 GB 2.71 GB 1.36 GB 676.79 MB 340.73 MB - - - - - - - - - - - -
5200 17.20 GB 9.49 GB 4.86 GB 2.45 GB 1.22 GB 614.89 MB 307.72 MB - - - - - - - - - - - - -
5200_heavy 36.46 GB 21.20 GB 11.29 GB 5.72 GB 2.85 GB 1.43 GB 714.56 MB - - - - - - - - - - - - -
6000 - - - - 892.55 MB 457.66 MB 233.23 MB - - - - - - - - - - - - -
6100 - - - - 599.33 MB 384.09 MB 214.79 MB - - - - - - - - - - - - -

Documentation

Solver

class Solver:
    def __init__(self, index_files: list[pathlib.Path]): ...

    def solve(
        self,
        stars: typing.Iterable[SupportsFloatMapping],
        size_hint: typing.Optional[SizeHint],
        position_hint: typing.Optional[PositionHint],
        solution_parameters: SolutionParameters,
    ) -> Solution: ...

    def __enter__(self) -> Solver: ...

    def __exit__(
        self,
        exception_type: typing.Optional[typing.Type[BaseException]],
        value: typing.Optional[BaseException],
        traceback: typing.Optional[types.TracebackType],
    ) -> bool: ...

solve is thread-safe and can be called any number of times.

  • index_files: List of index files to use for solving. The list need not come from a Series object. Series subsets and combinations are possible as well.
  • star: iterator over a list of pixel coordinates for the input stars.
  • size_hint: Optional angular pixel size range (SizeHint). Significantly speeds up solve when provided. If size_hint is None, the range [0.1, 1000.0] is used. This default range can be changed by setting astrometry.DEFAULT_LOWER_ARCSEC_PER_PIXEL and astrometry.DEFAULT_UPPER_ARCSEC_PER_PIXEL to other values.
  • position_hint: Optional field center Ra/Dec coordinates and error radius (PositionHint). Significantly speeds up solve when provided. If position_hint is None, the entire sky is used (radius_deg = 180.0).
  • solution_parameters: Advanced solver parameters (SolutionParameters)

SizeHint

@dataclasses.dataclass
class SizeHint:
    lower_arcsec_per_pixel: float
    upper_arcsec_per_pixel: float

lower_arcsec_per_pixel and upper_arcsec_per_pixel must be larger than 0 and upper_arcsec_per_pixel must be smaller than or equal to upper_arcsec_per_pixel.

PositionHint

@dataclasses.dataclass
class PositionHint:
    ra_deg: float
    dec_deg: float
    radius_deg: float
  • ra_deg must be in the range [0.0, 360.0[.
  • dec_deg must be in the range [-90.0, 90.0].
  • radius must be larger than or equal to zero.

All values are in degrees and must use the same frame of reference as the index files. Astrometry.net index files use J2000 FK5 (https://docs.astropy.org/en/stable/api/astropy.coordinates.FK5.html). ICRS and FK5 differ by less than 0.1 arcsec (https://www.iers.org/IERS/EN/Science/ICRS/ICRS.html).

Action

class Action(enum.Enum):
    STOP = 0
    CONTINUE = 1

Parity

class Parity(enum.IntEnum):
    NORMAL = 0
    FLIP = 1
    BOTH = 2

SolutionParameters

@dataclasses.dataclass
class SolutionParameters:
    solve_id: typing.Optional[str] = None
    uniformize_index: bool = True
    deduplicate: bool = True
    sip_order: int = 3
    sip_inverse_order: int = 0
    distance_from_quad_bonus: bool = True
    positional_noise_pixels: float = 1.0
    distractor_ratio: float = 0.25
    code_tolerance_l2_distance: float = 0.01
    minimum_quad_size_pixels: typing.Optional[float] = None
    minimum_quad_size_fraction: float = 0.1
    maximum_quad_size_pixels: float = 0.0
    maximum_quads: int = 0
    maximum_matches: int = 0
    parity: Parity = Parity.BOTH
    tune_up_logodds_threshold: typing.Optional[float] = 14.0
    output_logodds_threshold: float = 21.0
    slices_generator: typing.Callable[[int], typing.Iterable[tuple[int, int]]] = astrometry.batches_generator(25)
    logodds_callback: typing.Callable[[list[float]], Action] = lambda _: Action.CONTINUE
  • solve_id: Optional plate identifier used in logging messages. If solve_id is None, it is automatically assigned a unique integer. The value can be retrieved from the Solution object (solution.solve_id).
  • uniformize_index: Uniformize field stars at the matched index scale before verifying a match.
  • deduplicate: De-duplicate field stars before verifying a match.
  • sip_order: Polynomial order of the Simple Imaging Polynomial distortion (see https://irsa.ipac.caltech.edu/data/SPITZER/docs/files/spitzer/shupeADASS.pdf). 0 disables SIP distortion. tune_up_logodds_threshold must be None if sip_order is 0.
  • sip_inverse_order: Polynomial order of the inversee Simple Polynomial distortion. Usually equal to sip_order. 0 means "equal to sip_order".
  • distance_from_quad_bonus: Assume that stars far from the matched quad will have larger positional variance.
  • positional_noise_pixels: Expected error on the positions of stars.
  • distractor_ratio: Fraction of distractors in the range ]0, 1].
  • code_tolerance_l2_distance: Code tolerance in 4D codespace L2 distance.
  • minimum_quad_size_pixels: Minimum size of field quads to try, None calculates the size automatically as minimum_quad_size_fraction * min(Δx, Δy), where Δx (resp. Δy) is the maximum x distance (resp. y distance) between stars in the field.
  • minimum_quad_size_fraction: Only used if minimum_quad_size_pixels is None (see above).
  • maximum_quad_size_pixels: Maximum size of field quads to try, 0.0 means no limit.
  • maximum_quads: Number of field quads to try, 0 means no limit.
  • maximum_matches: Number of quad matches to try, 0 means no limit.
  • parity: Parity.NORMAL does not flip the axes, Parity.FLIP does, and Parity.BOTH tries flipped and non-flipped axes (at the cost of doubling computations).
  • tune_up_logodds_threshold: Matches whose log-odds are larger than this value are tuned-up (SIP distortion estimation) and accepted if their post-tune-up log-odds are larger than output_logodds_threshold. None disables tune-up and distortion estimation (SIP). The default Astrometry.net value is math.log(1e6).
  • output_logodds_threshold: Matches whose log-odds are larger than this value are immediately accepted (added to the solution matches). The default Astrometry.net value is math.log(1e9).
  • slices_generator: User-provided function that takes a number of stars as parameter and returns an iterable (such as list) of two-elements tuples representing ranges. The first tuple item (start) is included while the second tuple item (end) is not. The returned ranges can have a variable size and/or overlap. The algorithm compares each range with the star catalogue sequentially. Small ranges significantly speed up the algorithm but increase the odds of missing matches. astrometry.batches_generator(n) generates non-overlapping batches of n stars.
  • logodds_callback: User-provided function that takes a list of matches log-odds as parameter and returns an astrometry.Action object. astrometry.Action.CONTINUE tells the solver to keep searching for matches whereas astrometry.Action.STOP tells the solver to return the current matches immediately. The log-odds list is sorted from highest to lowest value and should not be modified by the callback function.

Accepted matches are always tuned up, even if they hit tune_up_logodds_threshold and were already tuned-up. Since log-odds are compared with the thresholds before the tune-up, the final log-odds are often significantly larger than output_logodds_threshold. Set tune_up_logodds_threshold to a value larger than or equal to output_logodds_threshold to disable the first tune-up, and None to disable tune-up altogether. Tune-up logic is equivalent to the following Python snippet:

# This (pseudo-code) snippet assumes the following definitions:
# match: candidate match object
# log_odds: current match log-odds
# add_to_solution: appends the match to the solution list
# tune_up: tunes up a match object and returns the new match and the new log-odds
if tune_up_logodds_threshold is None:
    if log_odds >= output_logodds_threshold:
        add_to_solution(match)
else:
    if log_odds >= output_logodds_threshold:
        tuned_up_match, tuned_up_loggods = tune_up(match)
        add_to_solution(tuned_up_match)
    elif log_odds >= tune_up_logodds_threshold:
        tuned_up_match, tuned_up_loggods = tune_up(match)
        if tuned_up_loggods >= output_logodds_threshold:
            tuned_up_twice_match, tuned_up_twice_loggods = tune_up(tuned_up_match)
            add_to_solution(tuned_up_twice_match)

Astrometry.net gives the following description of the tune-up algorithm. See tweak2 in astrometry.net/solver/tweak2.c for the implementation.

Given an initial WCS solution, compute SIP polynomial distortions using an annealing-like strategy. That is, it finds matches between image and reference catalog by searching within a radius, and that radius is small near a region of confidence, and grows as you move away. That makes it possible to pick up more distant matches, but they are downweighted in the fit. The annealing process reduces the slope of the growth of the matching radius with respect to the distance from the region of confidence.

-- astrometry.net/include/astrometry/tweak2.h

Solution

@dataclasses.dataclass
class Solution:
    solve_id: str
    matches: list[Match]

    def has_match(self) -> bool: ...

    def best_match(self) -> Match: ...

    def to_json(self) -> str: ...

    @classmethod
    def from_json(cls, solution_as_json: str) -> Solution: ...

matches are sorted in descending log-odds order. best_match returns the first match in the list. to_json and from_json may be used to save and load solutions.

Match

@dataclasses.dataclass
class Match:
    logodds: float
    center_ra_deg: float
    center_dec_deg: float
    scale_arcsec_per_pixel: float
    index_path: pathlib.Path
    stars: tuple[Star, ...]
    quad_stars: tuple[Star, ...]
    wcs_fields: dict[str, tuple[typing.Any, str]]

    def astropy_wcs(self) -> astropy.wcs.WCS: ...
  • logodds: Log-odds (https://en.wikipedia.org/wiki/Logit) of the match.
  • center_ra_deg: Right ascension of the stars bounding box's center, in degrees and in the frame of reference of the index (J200 FK5 for Astrometry.net series).
  • center_dec_deg: Declination of the stars bounding box's center in degrees and in the frame of reference of the index (J200 FK5 for Astrometry.net series).
  • scale_arcsec_per_pixel: Pixel scale in arcsec per pixel.
  • index_path: File system path of the index file used for this match.
  • stars: List of visible index stars. This list is almost certainly going to differ from the input stars list.
  • quad_stars: The index stars subset (usually 4 but can be 3 or 5) used in the hash code search step (see https://arxiv.org/pdf/0910.2233.pdf, 2. Methods).
  • wcs_fields: WCS fields describing the transformation between pixel coordinates and world coordinates. This dictionary can be passed directly to astropy.wcs.WCS.

astropy_wcs generates an Astropy WCS object. Astropy (https://pypi.org/project/astropy/) must be installed to use this method. See Calculate field stars pixel positions with astropy for details.

Star

@dataclasses.dataclass
class Star:
    ra_deg: float
    dec_deg: float
    metadata: dict[str, typing.Any]

ra_deg and dec_deg are in degrees and use the same frame of reference as the index files. Astrometry.net index files use J2000 FK5 (https://docs.astropy.org/en/stable/api/astropy.coordinates.FK5.html). ICRS and FK5 differ by less than 0.1 arcsec (https://www.iers.org/IERS/EN/Science/ICRS/ICRS.html).

The contents of metadata depend on the data available in index files. See Series for details.

Series

@dataclasses.dataclass
class Series:
    name: str
    description: str
    scale_to_sizes: dict[int, tuple[int, ...]]
    url_pattern: str

    def size(self, scales: typing.Optional[set[int]] = None): ...

    def size_as_string(self, scales: typing.Optional[set[int]] = None): ...

    def index_files(
        self,
        cache_directory: typing.Union[bytes, str, os.PathLike],
        scales: typing.Optional[set[int]] = None,
    ) -> list[pathlib.Path]: ...
  • name defines the cache subdirectory name.
  • description is a copy of the text description in http://data.astrometry.net.
  • scale_to_sizes maps each available HEALPix resolution to index files sizes in bytes. The smaller the scale, the larger the number of HEALPix subdivisions.
  • url_pattern is the base pattern used to generate file download links.
  • size returns the cumulative file sizes for the given scales in bytes. If scales is None, all the scales available for the series are used.
  • size_as_string returns a human-readable string representation of size.
  • index_files returns index files paths for the given scales (or all available scales if scales is None). This function downloads files that are not already in the cache directory. cache_directory is created if it does not exist. Download automatically resumes for partially downloaded files.

Change the constants astrometry.CHUNK_SIZE, astrometry.DOWNLOAD_SUFFIX and astrometry.TIMEOUT to configure the downloader parameters.

batches_generator

def batches_generator(
    batch_size: int,
) -> typing.Callable[[int], typing.Iterable[tuple[int, int]]]:
    ...
  • batch_size sets the size of the generated batches.

batches_generator returns a slices generator compatible with SolutionParameters.slices_generator. The slices are non-overlapping and non-full slices are ignored. For instance, a batch size of 25 over 83 stars would generate the slices (0, 25), (25, 50), and (50, 75).

SupportsFloatMapping

class SupportsFloatMapping(typing.Protocol):
    def __getitem__(self, index: typing.SupportsIndex, /) -> typing.SupportsFloat:
        ...

Contribute

Clone the repository

Clone this repository and pull its submodule:

git clone --recursive https://github.com/neuromorphicsystems/astrometry.git
cd astrometry
cd astrometry.net
git reset --hard 04e97d5365525ac429dca69b344f9f4d9070b739
git apply ../astrometry.net.patch
cd ..

or

git clone https://github.com/neuromorphicsystems/astrometry.git
cd astrometry
git submodule update --recursive
cd astrometry.net
git reset --hard 04e97d5365525ac429dca69b344f9f4d9070b739
git apply ../astrometry.net.patch
cd ..

After building, reset the patch changes to keep the submodule in a clean state

git reset --hard 04e97d5365525ac429dca69b344f9f4d9070b739

Format and lint

clang-format -i astrometry_extension/astrometry_extension.c astrometry_extension/astrometry_extension_utilities.h
pip install '.[lint]'
isort .; black .; pyright .

Build a local version

pip install -e . # use 'CC="ccache clang" pip install -e .' to speed up incremental builds

Publish

  1. Bump the version number in setup.py.

  2. Create a new release on GitHub.

MSVC compatibility (work in progress)

  • fitsbin.c, kdtree_internal.c, kdtree_internal_fits.c, solver.c: replace Variable Length Arrays (VAL) with _alloca (type name[size] -> type* name = _alloca(size))
  • fitsbin.c, fitsioutils.c, fitstable.c: cast void* to char* to enable pointer arithmetic
  • anqfits.c, verify.c: #define debug(args...) -> #define debug(...)
  • qfits_time.c: remove #include <pwd.h>
  • log.h, keywords.h: remove __attribute__ directives
  • bl.c: remove redundant bl.inc and bl_nl.c includes
  • replace all POSIX calls (file IO, network, select...). This requires significant effort when targeting the entire Astrometry.net library. It might be less complicated with Astrometry, which uses only a subset of Astrometry.net.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

astrometry-4.3.0.tar.gz (529.6 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

astrometry-4.3.0-cp313-cp313-musllinux_1_2_x86_64.whl (2.1 MB view details)

Uploaded CPython 3.13musllinux: musl 1.2+ x86-64

astrometry-4.3.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl (2.1 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.17+ x86-64manylinux: glibc 2.28+ x86-64

astrometry-4.3.0-cp313-cp313-macosx_11_0_arm64.whl (529.9 kB view details)

Uploaded CPython 3.13macOS 11.0+ ARM64

astrometry-4.3.0-cp313-cp313-macosx_10_13_x86_64.whl (631.6 kB view details)

Uploaded CPython 3.13macOS 10.13+ x86-64

astrometry-4.3.0-cp312-cp312-musllinux_1_2_x86_64.whl (2.1 MB view details)

Uploaded CPython 3.12musllinux: musl 1.2+ x86-64

astrometry-4.3.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl (2.1 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ x86-64manylinux: glibc 2.28+ x86-64

astrometry-4.3.0-cp312-cp312-macosx_11_0_arm64.whl (529.9 kB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

astrometry-4.3.0-cp312-cp312-macosx_10_13_x86_64.whl (631.6 kB view details)

Uploaded CPython 3.12macOS 10.13+ x86-64

astrometry-4.3.0-cp311-cp311-musllinux_1_2_x86_64.whl (2.1 MB view details)

Uploaded CPython 3.11musllinux: musl 1.2+ x86-64

astrometry-4.3.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl (2.1 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64manylinux: glibc 2.28+ x86-64

astrometry-4.3.0-cp311-cp311-macosx_11_0_arm64.whl (529.8 kB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

astrometry-4.3.0-cp311-cp311-macosx_10_9_x86_64.whl (631.4 kB view details)

Uploaded CPython 3.11macOS 10.9+ x86-64

astrometry-4.3.0-cp310-cp310-musllinux_1_2_x86_64.whl (2.1 MB view details)

Uploaded CPython 3.10musllinux: musl 1.2+ x86-64

astrometry-4.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl (2.1 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ x86-64manylinux: glibc 2.28+ x86-64

astrometry-4.3.0-cp310-cp310-macosx_11_0_arm64.whl (529.8 kB view details)

Uploaded CPython 3.10macOS 11.0+ ARM64

astrometry-4.3.0-cp310-cp310-macosx_10_9_x86_64.whl (631.4 kB view details)

Uploaded CPython 3.10macOS 10.9+ x86-64

astrometry-4.3.0-cp39-cp39-musllinux_1_2_x86_64.whl (2.1 MB view details)

Uploaded CPython 3.9musllinux: musl 1.2+ x86-64

astrometry-4.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl (2.1 MB view details)

Uploaded CPython 3.9manylinux: glibc 2.17+ x86-64manylinux: glibc 2.28+ x86-64

astrometry-4.3.0-cp39-cp39-macosx_11_0_arm64.whl (529.8 kB view details)

Uploaded CPython 3.9macOS 11.0+ ARM64

astrometry-4.3.0-cp39-cp39-macosx_10_9_x86_64.whl (631.4 kB view details)

Uploaded CPython 3.9macOS 10.9+ x86-64

File details

Details for the file astrometry-4.3.0.tar.gz.

File metadata

  • Download URL: astrometry-4.3.0.tar.gz
  • Upload date:
  • Size: 529.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.12.9

File hashes

Hashes for astrometry-4.3.0.tar.gz
Algorithm Hash digest
SHA256 54de35b9247471fe7dc6e5b5da2374d627631e9c6229f5d4dcf230a581e9be22
MD5 a0d727f9c0c7b3b48169d0049755cc24
BLAKE2b-256 a782f7494cd074c90e0feef4d2c25d8ea737c202e035f1f72c96d4d3d35b104d

See more details on using hashes here.

File details

Details for the file astrometry-4.3.0-cp313-cp313-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for astrometry-4.3.0-cp313-cp313-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 add1911972dbb205635a76c9bfb67984be4fdb656bf6bb79eaeae8012a0a5c08
MD5 f1269a1c8f64ab5b83266cb2ce951316
BLAKE2b-256 0783263355b60e3795b1668c52148395b7eee42f355f06299667638871eba30f

See more details on using hashes here.

File details

Details for the file astrometry-4.3.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for astrometry-4.3.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 ecd623b988b074d42ee0be58e1710a4989e4119cb4acba382d9ca35179a6024d
MD5 95216b1d1e5ceb9b0f7c57cb7c1a49c9
BLAKE2b-256 08ff7570100f2fc8c5bbd3381085f07c4f2095fe3ababa068237cdff5ac7bc1e

See more details on using hashes here.

File details

Details for the file astrometry-4.3.0-cp313-cp313-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for astrometry-4.3.0-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 8f7efa67e4c630df852ca060489d63056142ea73dcf26686c1890522f1ee9027
MD5 833f2d1ac4e1c4c194262fc9ccd5b4d3
BLAKE2b-256 b27c8100540eb1fe391ee62afb9ba63d332506f8e05626d6e59e8fd6d7bf98ea

See more details on using hashes here.

File details

Details for the file astrometry-4.3.0-cp313-cp313-macosx_10_13_x86_64.whl.

File metadata

File hashes

Hashes for astrometry-4.3.0-cp313-cp313-macosx_10_13_x86_64.whl
Algorithm Hash digest
SHA256 a9722582fec0fe63791df89c1c77e63609cbc6262ffd634e7e398687ba9f4f90
MD5 5594576c711f2991aee092e9559c1700
BLAKE2b-256 f8e054fde453444d920ae25ed44c90f7335c3801515ebac08d2236ff18a79bea

See more details on using hashes here.

File details

Details for the file astrometry-4.3.0-cp312-cp312-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for astrometry-4.3.0-cp312-cp312-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 6700c17ecc30b31274b35a7a8ad8fbc79d78e0bcbcfd9a0dd24d66072d2d1100
MD5 b1f7b0a0042b480b852bd0ca25d0f2b3
BLAKE2b-256 5c407fa7ef210ae8f8bd3180e3990326314c7812a93d67185a2ba1d266273290

See more details on using hashes here.

File details

Details for the file astrometry-4.3.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for astrometry-4.3.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 f0ca141e9d5ba233a991745318fad25e1cdf5c7b5e88cabe763f1d1575655cd1
MD5 4eb5469b4dcd3f414a249522cdcc2a26
BLAKE2b-256 370a326d0f52eda90bc31d1aaf26948590de33aa790e27aeffb87c9a6d6930fc

See more details on using hashes here.

File details

Details for the file astrometry-4.3.0-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for astrometry-4.3.0-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 3ded93ca8e3b4f3fd998e2034fc9b5506aa42840a3fdd3e21db52ed6a10ea1d3
MD5 fb56b8d3bc15150e7757a5c504ba0f2f
BLAKE2b-256 ecb5b7cef5a8985a5fba5242128fa47e60af3b26d8f39d8c50c8341dba87105b

See more details on using hashes here.

File details

Details for the file astrometry-4.3.0-cp312-cp312-macosx_10_13_x86_64.whl.

File metadata

File hashes

Hashes for astrometry-4.3.0-cp312-cp312-macosx_10_13_x86_64.whl
Algorithm Hash digest
SHA256 cead9ca3fc46d1952fa2e155b5de6939b6f0368dc8bdee26f7dab2448949d956
MD5 33ec364f658cbd4480ab15ae6e609636
BLAKE2b-256 b865664eda3010d14173a9f9010c306691cd305fa85f87f82d4f33e1b04e1f64

See more details on using hashes here.

File details

Details for the file astrometry-4.3.0-cp311-cp311-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for astrometry-4.3.0-cp311-cp311-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 1cefad7811017915ae8dd45fbedd1155f36923c7ef6eaf557bc3fab8fb76a878
MD5 41e4a7704f8a07d138bb54210caa8198
BLAKE2b-256 d38b35110d6b215b990351c168a2ceededb9109c99f82bd68f8f6ae4bb6d294b

See more details on using hashes here.

File details

Details for the file astrometry-4.3.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for astrometry-4.3.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 f0f4c9c3e551b5b65de51c766089a53fed1cf772108d0f141f3cd22d8d96ba0a
MD5 ab2259fe2b07173ad6d678f1d98f3e62
BLAKE2b-256 605bc1c8269fb8ac3b75676bc5aec24b13ace0296c77c12b36ad480ba433f8c8

See more details on using hashes here.

File details

Details for the file astrometry-4.3.0-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for astrometry-4.3.0-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 ddaacf0545f76fb623a7da3f2205d626291292d3d098324e1db9d7e0527d1cae
MD5 9a50cb58c36ebbdd0fe5e470fc7df56e
BLAKE2b-256 a2c353ab8390a18dc0f7b5296a1ce219f3494330821f22ab46d955efbebd6432

See more details on using hashes here.

File details

Details for the file astrometry-4.3.0-cp311-cp311-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for astrometry-4.3.0-cp311-cp311-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 4f84a64e4a59a2400a3091a54cb889bf91628e51ec0468e7385457c47cd92059
MD5 8da6cd6fc2c3e2fb1c988615a13feb8c
BLAKE2b-256 427afc63e285aafd0d4b536db30c8e20f1a9ab507636d004e8b3b2473557daf7

See more details on using hashes here.

File details

Details for the file astrometry-4.3.0-cp310-cp310-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for astrometry-4.3.0-cp310-cp310-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 8269a2f8e65d2f6da848629c90e57b8eea55fdcfd50c7265e2ebc257b5943b34
MD5 22cdbee6a5c32f1d8777b5173c0999e6
BLAKE2b-256 76463fa4d8a9c86af7a64957afc843bf77270a489571c74c6624e585b9b6c6da

See more details on using hashes here.

File details

Details for the file astrometry-4.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for astrometry-4.3.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 edeb38d7d2e25acadbeb8706f57aefa03de54f5696a88eb9b758c907f2cfa23d
MD5 3d577c6f349843535d00a3cf3d1308b3
BLAKE2b-256 9b0aa9c9267e6f5a1958ad46af63d37845646abaa7439f974ffd5bffd8f458f9

See more details on using hashes here.

File details

Details for the file astrometry-4.3.0-cp310-cp310-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for astrometry-4.3.0-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 896577c1501eae7b3cfef70f14ae3c2d7c98d38ceed7a63156e64cfc3fc92a8d
MD5 df9e4e9aa37a0ba1a6a6596dc21745a9
BLAKE2b-256 5538a888c6b2fbf8178a862e748d01fe4b5e3e0466dd1f6e0b2e02fe0346ed5b

See more details on using hashes here.

File details

Details for the file astrometry-4.3.0-cp310-cp310-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for astrometry-4.3.0-cp310-cp310-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 c74dfc82760883e52190ffaef49ecd28a16cab8fe1d3b6952fd1ec25bf2339e7
MD5 370092ed38fd565524c1e68bc8719838
BLAKE2b-256 ed8f02cee7f069e814ea5990335c4e250cee8ccaaefd7bc43d1cc18e9984bec8

See more details on using hashes here.

File details

Details for the file astrometry-4.3.0-cp39-cp39-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for astrometry-4.3.0-cp39-cp39-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 9591f0a8795871990a5e439b960e7ed07d24363ebe5876fbe461340c4b05afcc
MD5 017ae5f6c1628e2a561e1b3fea97b9ef
BLAKE2b-256 64cca6cb9f0acc2970bb3d7cc7eb4fe39ce0f7c756ad520043c5bf2b503527ca

See more details on using hashes here.

File details

Details for the file astrometry-4.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for astrometry-4.3.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 3a70bd25989369d56c843828958570b7905f0e13b086f2dc6d6c4701d87b9c9a
MD5 933e91426a4718752c185e252d16aa9b
BLAKE2b-256 b58b4d5e7c3ab2fc1e3f89835cbdd6c79034ecde0268d8589ef673eff9fe562f

See more details on using hashes here.

File details

Details for the file astrometry-4.3.0-cp39-cp39-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for astrometry-4.3.0-cp39-cp39-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 0d1d169c583d7484f41662b0a306ee731157a01bc6d913b6e746b9d57cf70cf6
MD5 405fae102cb87f9897315fe6e8dce0e0
BLAKE2b-256 8a3561d9fdeb4f8076115232d09882833ce871076d8aa1c22182ab61a32f8b98

See more details on using hashes here.

File details

Details for the file astrometry-4.3.0-cp39-cp39-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for astrometry-4.3.0-cp39-cp39-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 d5a51caafff877dabb33bccd59a1cc7845f59e37c57d15a021a34796efdfb1c1
MD5 c1d8f8f9cf7e3c9bb4bbecc38f899802
BLAKE2b-256 867a00e2285ebbe61b4e06c113dd01bc5d7d4560b3496fb809addef2844ba47b

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page