// This code is generated by generate_code.py, do not modify it manually.
//! This module contains all the known columns in the gaiaedr3_distance table.
use crate::traits::{Column, Table};
/// Estimating distances from parallaxes: Geometric and photogeometric distances to 1.47 billion stars in Gaia EDR3. The table contains stellar distance estimates to sources in Gaia EDR3 that have parallaxes. Provided are two types of distance estimates, together with their corresponding asymmetric uncertainties, using Bayesian posterior density functions that are sampled for each source. The prior is based on a detailed model of the 3D spatial, colour, and magnitude distribution of stars in our Galaxy that includes a 3D map of interstellar extinction. The first type of distance estimate is purely geometric, in that it only makes use of the Gaia parallax and parallax uncertainty. The second type is photogeometric: in addition to the parallax, it also uses the source's G-band magnitude and BP-RP colour. The distance estimate and uncertainties are quantiles, so are invariant under logarithmic transformations. This means that the median estimate of the distance can be used to give the median estimate of the distance modulus, and likewise for the uncertainties. Data replicated from gedr3dist.main table at GAVO Data Center TAP service https://dc.g-vo.org/tap and TAP metadata as of December 2020. Reference paper: https://ui.adsabs.harvard.edu/abs/2021AJ....161..147B/abstract (DOI: 10.3847/1538-3881/abd806)
#[allow(non_camel_case_types)]
pub struct gaiaedr3_distance;
impl Table for gaiaedr3_distance {
fn string(&self) -> String {
"gaiaedr3_distance".to_string()
}
}
/// The columns in the gaiaedr3_distance table.
#[allow(non_camel_case_types)]
#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, strum::Display)]
pub enum Col {
/// Unique source identifier. Note that this *cannot* be matched against the DR1 or DR2 source_ids.
source_id,
/// The median of the geometric distance posterior. The geometric distance estimate.
r_med_geo,
/// The 16th percentile of the geometric distance posterior. The lower 1-sigma-like bound on the confidence interval.
r_lo_geo,
/// The 84th percentile of the geometric distance posterior. The upper 1-sigma-like bound on the confidence interval.
r_hi_geo,
/// The median of the photogeometric distance posterior. The photogeometric distance estimate.
r_med_photogeo,
/// The 16th percentile of the photogeometric distance posterior. The lower 1-sigma-like bound on the confidence interval.
r_lo_photogeo,
/// The 84th percentile of the photogeometric distance posterior. The upper 1-sigma-like bound on the confidence interval.
r_hi_photogeo,
/// Additional information on the solution. Do not use for filtering (see table note in the reference URL).
flag,
}
impl Column for Col {}
#[cfg(test)]
/// Collects all the known columns in the gaiaedr3_distance table.
pub fn collect_known(map: &mut std::collections::HashMap<String, Vec<String>>) {
let mut col_strings = Vec::new();
col_strings.push(Col::source_id.to_string());
col_strings.push(Col::r_med_geo.to_string());
col_strings.push(Col::r_lo_geo.to_string());
col_strings.push(Col::r_hi_geo.to_string());
col_strings.push(Col::r_med_photogeo.to_string());
col_strings.push(Col::r_lo_photogeo.to_string());
col_strings.push(Col::r_hi_photogeo.to_string());
col_strings.push(Col::flag.to_string());
map.insert(gaiaedr3_distance.string(), col_strings);
}