Likelihood-free Cosmological Constraints with Artificial Neural
  Networks: An Application on Hubble Parameters and SNe Ia
  The errors of cosmological data generated from complex processes, such as the
observational Hubble parameter data (OHD) and the Type Ia supernova (SN Ia)
data, cannot be accurately modeled by simple analytical probability
distributions, e.g. Gaussian distribution. To constrain cosmological parameters
from these data, likelihood-free inference is usually used to bypass the direct
calculation of the likelihood. In this paper, we propose a new procedure to
perform likelihood-free cosmological inference using two artificial neural
networks (ANN), the Masked Autoregressive Flow (MAF) and the denoising
autoencoder (DAE). Our procedure is the first to use DAE to extract features
from data, in order to simplify the structure of MAF needed to estimate the
posterior. Tested on simulated Hubble parameter data with a simple Gaussian
likelihood, the procedure shows the capability of extracting features from data
and estimating posterior distributions without the need of tractable
likelihood. We demonstrate that it can accurately approximate the real
posterior, achieve performance comparable to the traditional MCMC method, and
the MAF gets better training results for small number of simulation when the
DAE is added. We also discuss the application of the proposed procedure to OHD
and Pantheon SN Ia data, and use them to constrain cosmological parameters from
the non-flat $\Lambda$CDM model. For SNe Ia, we use fitted light curve
parameters to find constraints on $H_0,\Omega_m,\Omega_\Lambda$ similar to
relevant work, using less empirical distributions. In addition, this work is
also the first to use Gaussian process in the procedure of OHD simulation.
