Gaia measures the five astrometric parameters for stars in the Milky Way, but only four of them (positions and proper motion, but not distance) are well measured beyond a few kpc from the Sun. Modern spectroscopic surveys such as APOGEE cover a large area of the Milky Way disc and we can use the relation between spectra and luminosity to determine distances to stars beyond Gaia 's parallax reach. Here, we design a deep neural network trained on stars in common between Gaia and APOGEE that determines spectro-photometric distances to APOGEE stars, while including a flexible model to calibrate parallax zero-point biases in Gaia DR2. We determine the zero-point offset to be |$-52.3 \pm 2.0\, \mu \mathrm{as}$| when modelling it as a global constant, but also train a multivariate zero-point offset model that depends on G, G BP − G RP colour, and T eff and that can be applied to all ≈58 million stars in Gaia DR2 within APOGEE's colour–magnitude range and within APOGEE's sky footprint. Our spectro-photometric distances are more precise than Gaia at distances |${\gtrsim} 2\, \mathrm{kpc}$| from the Sun. We release a catalogue of spectro-photometric distances for the entire APOGEE DR14 data set which covers Galactocentric radii |$2\, \mathrm{kpc} \lesssim R \lesssim 19\, \mathrm{kpc}$| ; |${\approx} 150\, 000$| stars have |${\lt} 10{{\ \rm per\ cent}}$| uncertainty, making this a powerful sample to study the chemo-dynamical structure of the disc. We use this sample to map the mean [Fe/H] and 15 abundance ratios [X/Fe] from the Galactic Centre to the edge of the disc. Among many interesting trends, we find that the bulge and bar region at |$R \lesssim 5\, \mathrm{kpc}$| clearly stands out in [Fe/H] and most abundance ratios. [ABSTRACT FROM AUTHOR]