MNRAS 000 , 1-7 (2019)

## Deep learning dark matter map reconstructions from DES SV weak lensing data

Niall Jeffrey, 1 ? Fran¸ cois Lanusse , Ofer Lahav , Jean-Luc Starck 2 1 3

- 1 Department of Physics &amp; Astronomy, University College London, Gower Street, London, WC1E 6BT, UK
- 2
- Berkeley Center for Cosmological Physics and Department of Physics, University of California, Berkeley, CA 94720
- 3 AIM, CEA, CNRS, Universit´ e Paris-Saclay, Universit´ Paris Diderot, Sorbonne Paris Cit´, F-91191 Gif-sur-Yvette, France e e

Accepted XXX. Received YYY; in original form ZZZ

## ABSTRACT

We present the first reconstruction of dark matter maps from weak lensing observational data using deep learning. We train a convolution neural network (CNN) with a Unet based architecture on over 3 6 : GLYPH&lt;2&gt; 10 5 simulated data realizations with non-Gaussian shape noise and with cosmological parameters varying over a broad prior distribution. We interpret our newly created DES SV map as an approximation of the posterior mean P ' GLYPH&lt;20&gt; j GLYPH&lt;13&gt; ' of the convergence given observed shear. Our DeepMass y method is substantially more accurate than existing mass-mapping methods. With a validation set of 8000 simulated DES SV data realizations, compared to Wiener filtering with a fixed power spectrum, the DeepMass method improved the mean-square-error (MSE) by 11 per cent. With N-body simulated MICE mock data, we show that Wiener filtering with the optimal known power spectrum still gives a worse MSE than our generalized method with no input cosmological parameters; we show that the improvement is driven by the non-linear structures in the convergence. With higher galaxy density in future weak lensing data unveiling more non-linear scales, it is likely that deep learning will be a leading approach for mass mapping with Euclid and LSST.

Key words: gravitational lensing: weak - large-scale structure of Universe- methods: statistical

## 1 INTRODUCTION

The evolving cosmological density field is rich in information about the cosmological model of the Universe, its unknown parameters, and cosmic web-dependent astrophysics. Though the largest fraction of the density is invisible dark matter, the gravitational lensing effect of galaxies can be used to infer fluctuations in the total foreground matter distribution. Accurate mass maps will be essential for the science goals of the upcoming LSST survey and the ESA Euclid mission.

accurate mass maps in the presence of noisy, masked shear data is to use physically motivated priors. In Jeffrey et al. (2018b) it was shown that using either Gaussian priors or 'halo model' sparsity priors for GLYPH&lt;20&gt; improved the accuracy of the reconstructions with Dark Energy Survey Science Verification (DES SV) data. Implemented methods include using log-normal (B¨ ohm et al. 2017) priors or E-mode priors (Mawdsley et al. 2019).

The maps considered in this paper are of the twodimensional convergence, GLYPH&lt;20&gt; , a weighted projection of the matter density field in the foreground of the observed galaxies. Recovering the convergence from the measured galaxy shapes, known as observed shear GLYPH&lt;13&gt; obs in the weak lensing regime, is an ill-posed inverse problem, troubled by survey masks (missing data) and galaxy 'shape noise'.

A typical principled approach to reconstructing more

- ? E-mail: niall.jeffrey.15@ucl.ac.uk
- y github.com/NiallJeffrey/DeepMass

However, all of these priors take functional forms that only approximate the true object of interest, the prior on the convergence field P ' GLYPH&lt;20&gt; jM' (with model assumptions M ). These approximations are necessary because we cannot represent the probability distribution of the non-linear density field in closed form. For example, we cannot characterise it uniquely in terms of its moments (Carron &amp; Szapudi 2017). Even if the true, unapproximated prior were available, evaluation via direct calculation would likely be intractable.

Fortunately we can still draw realizations of convergence maps from the prior distribution P ' GLYPH&lt;20&gt; ' in the form of simulations, which provides opportunity to a new generation of methods based on deep learning. Such an approach has been simultaneously proposed by Shirasaki et al. (2018), where a

conditional adversarial network was used to learn a mapping from noisy convergence maps to an estimate of the noise-free convergence.

In this work, we propose a deep learning method to estimate the posterior mean of the convergence map from observed weak lensing shear measurements. In section 4 we demonstrate our method on simulations and DES SV data.

## 2 WEAK GRAVITATIONAL LENSING

## 2.1 Shear and convergence

Given a distribution of source galaxies n in radial comoving distance ! , the convergence at position # GLYPH&lt;20&gt; GLYPH&lt;30&gt; on the sky is given by a weighted integral of the density

$$\kappa ( \vec { \phi } ) = \frac { 3 H _ { 0 } ^ { 2 } \Omega _ { m } } { 2 } \int _ { 0 } ^ { \infty } \left [ \int _ { 0 } ^ { \omega } d \omega ^ { \prime } \frac { \omega ^ { \prime } ( \omega - \omega ^ { \prime } ) } { \omega } \frac { \delta ( \vec { \phi }, \omega ^ { \prime } ) } { a ( \omega ^ { \prime } ) } \right ] n ( \omega ) d \omega \,, \quad \text{Figu} \\ ( 1 ) \quad \text{the t}$$

where H 0 is the present value of the Hubble parameter, a is the cosmological scale factor, GLYPH&lt;10&gt; m is the matter density parameter, and GLYPH&lt;14&gt; is the overdensity.

We express the linear data model in matrix notation,

$$\gamma & = A \kappa + n \,, & ( 2 ) & \quad \text{- would}$$

where n is a vector of noise per pixel. The matrix operator acting on the convergence A GLYPH&lt;20&gt; is the shear contribution due to lensing (Bartelmann &amp; Schneider 2001). In this formulation, the elements GLYPH&lt;13&gt; are the complex shear measurements binned into angular pixels in a two-dimensional image format.

We do not take into account the second order effects of reduced shear (Schneider &amp; Seitz 1995), flexion (Bacon et al. 2006) or intrinsic alignments (Kirk et al. 2015). However, the deep learning approach taken in this paper is extremely flexible; as long as an effect can be modelled and included in the training data, it will be taken into account in the mass map reconstruction. This is not generally true of other methods. For example, flexion requires reformulations of methods (e.g. Lanusse et al. 2016). Additionally, noise per pixel is invariably approximated as Gaussian, which we do not assume in our deep learning approach.

## 2.2 Previous mapping approaches

The original mass mapping approach by Kaiser &amp; Squires (1993) was a direct deconvolution. In practice Kaiser-Squires (KS) inverts the matrix A in Fourier space, where the matrix is diagonal. As this deconvolution is across a finite space, the edges of the data and internal masks introduce artefacts. KS is further troubled by the noise term in equation 2, which it does not take into account.

In a Bayesian framework we may wish to consider the posterior distribution of the convergence GLYPH&lt;20&gt; conditional on the observed shear GLYPH&lt;13&gt;

$$P ( \kappa | \gamma, \mathcal { M } ) = \frac { P ( \gamma | \kappa, \mathcal { M } ) \ P ( \kappa | \mathcal { M } ) } { P ( \gamma | \mathcal { M } ) } \, & & ( 3 ) & & \\ & & \quad \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \$$

The denominator P ' GLYPH&lt;13&gt; ' is a Bayesian evidence term conditional on model M . The first factor of the numerator is the

Figure 1. Prior range of cosmological parameters GLYPH&lt;10&gt; m and GLYPH&lt;27&gt; 8 of the training data. Simulations were run at the marked points.

![image](https://ac.marcodsn.me/arxiv-markdown-images/1908.00543v2-figure-82af0656-e2f9-474f-b293-a4ecab20f285.jpg)

likelihood P ' GLYPH&lt;13&gt; j GLYPH&lt;20&gt; ; M' , which encodes our noise model. The second term is the prior P ' GLYPH&lt;20&gt; jM' , a possible selection of which was discussed in section 1.

If we believe a realization of the convergence GLYPH&lt;20&gt; is a realization of Gaussian random field, then the form of P ' GLYPH&lt;20&gt; ' would be Gaussian. If the noise per pixel is Gaussian then the likelihood is also Gaussian, which results in a posterior distribution with both the mean and maximum given by the Wiener filter:

$$\hat { \kappa } _ { w } = W \gamma = S _ { \kappa } A ^ { \dagger } \left [ A S _ { \kappa } A ^ { \dagger } + N \right ] ^ { - 1 } \gamma$$

where S GLYPH&lt;20&gt; = h GLYPH&lt;20&gt; GLYPH&lt;20&gt; y i and N = h nn y i are the signal and noise covariance matrices respectively (Wiener 1949, Zaroubi et al. 1995, Jeffrey et al. 2018a). The signal covariance in harmonic space is diagonal for isotropic fields. On the sphere, its elements are given by the GLYPH&lt;20&gt; power spectrum, C GLYPH&lt;20&gt; ' ' ' .

This Gaussian distribution is only approximately true for large scales where Gaussianity persists from the early Universe. On smaller scales, non-Gaussianity grows due to non-linear structure formation, which results in the cosmic web of the late Universe.

## 3 DEEP LEARNING MAPS

## 3.1 Convolution neural networks

We take a standard deep learning approach. We seek an approximation F GLYPH&lt;2&gt; to the function that maps the pixelized shear to the convergence map

$$r \text{ the } \quad \hat { \kappa } = \mathcal { F } _ { \Theta } ( \gamma )$$

where the parameters of the function GLYPH&lt;2&gt; are to be learned (Goodfellow et al. 2016). We learn these parameters by minimising a mean-square-error (MSE) cost function

$$J ( \Theta ) = | | \mathcal { F } _ { \Theta } ( \gamma ) - \kappa _ { \text{true} } | | _ { 2 } ^ { 2 }$$

evaluated on a set of training data which consists of pairs of

Figure 2. Convergence GLYPH&lt;20&gt; reconstruction from DES SV observational data with: KS, Wiener filtering, and DeepMass.

![image](https://ac.marcodsn.me/arxiv-markdown-images/1908.00543v2-figure-e892e441-c94a-406d-a4fc-2e1dca88717e.jpg)

realistic shear and 'truth' (noise-free) convergence maps. If the training data'truth'maps are drawn from a prior distribution P ' GLYPH&lt;20&gt; ' , and the corresponding noisy shear map is drawn from the likelihood P ' GLYPH&lt;13&gt; j GLYPH&lt;20&gt; ' , this MSE cost function corresponds to F ' GLYPH&lt;2&gt; GLYPH&lt;13&gt; ' being a mean 1 posterior estimate (Jaynes 2003), such that ˆ GLYPH&lt;20&gt; is approximating:

## 3.2 DeepMass architecture

$$\hat { \kappa } = \mathcal { F } _ { \Theta } ( \gamma ) = \int \kappa \ P ( \kappa | \gamma ) \, \mathrm d \kappa \. & \quad ( 7 ) \quad \text{ each} \\ & \text{oluti}.$$

We use a deep convolution neural network (CNN) to approximate the function F GLYPH&lt;2&gt; , where the parameters GLYPH&lt;2&gt; are primarily elements of learned filters in convolutional layers. CNNs are particularly suited for two-dimensional image or onedimensional time series data with translation invariant features in the underlying signal.

The CNN is a series of iteratively computed layers. At a given layer j the signal x j is computed from the previous layer

$$x _ { j } & = \rho \mathbf M _ { j } x _ { j - 1 } & ( 8 ) & = \stackrel { \dots } { 2 0 1 8 }$$

with linear operator (e.g. convolution) M j and nonlinear activation function GLYPH&lt;26&gt; (LeCun et al. 1990, Mallat 2016). The output of a layer is sometimes called a feature map .

Due to their additional layers, deep architectures are often able to learn features with greater complexity than shallow architectures and therefore can better approximate the target function. For a general overview of deep learning and neural networks we recommend Goodfellow et al. (2016).

1 The mean posterior is not generally the maximum a posteriori

Our DeepMass architecture is based on the Unet (Ronneberger et al. 2015), which has a so-called expanding path and contracting path . The DeepMass contracting path differs from the original Unet: usually convolutions and activation are followed by a max pooling operation to downsample the images, whereas we use average pooling (G´ eron 2017). With each downsampling operation, the images decrease in resolution, but the 3 GLYPH&lt;2&gt; 3 filters cover more angular size of the image. The convolution after a pooling operation therefore has a receptive field that covers larger physical features in the convergence GLYPH&lt;20&gt; map.

There are similarities between Unet architectures and sparse recovery methods. These consider representations where the solution is sparse and employ transforms which are fixed (e.g. Fourier, wavelets) or learned from data, and optimization is solved using proximal theory (Starck et al. 2015). The Unet expanding and contracting path are very similar to synthesis and analysis concepts in sparse representations. This has motivated the use of wavelets to implement the Unet average pooling and the expanding path (Ye et al. 2018; Han &amp; Ye 2018). There are nevertheless significant differences: Unets can learn rich sets of features (corresponding to sparse dictionaries) from large training data sets, and the CNN implementation of non-linearity.

We differ from the original Unet by not using padding in the convolutional layers, as the edge of our data mask is already many pixels away from the edge of the square image. This choice means that output of a convolution has the same image dimensions as the input.

The full architecture and code can be seen online: DeepMass . y We have added Batch Normalization layers (Ioffe &amp; Szegedy 2015) after each convolutional layer; without this, training often became stuck in local minima of the cost function with respect to the parameters GLYPH&lt;2&gt; . For all

Figure 3. Example l-picola validation simulation ( centre ) and the corresponding Wiener ( left ) and DeepMass ( right ) reconstructions. The colour scale for the truth (target) is larger to accommodate the larger dynamic range and make comparison easier by eye.

![image](https://ac.marcodsn.me/arxiv-markdown-images/1908.00543v2-figure-34a334a5-b070-45ad-924f-c4fa069241c7.jpg)

layers, except for the final, we use the rectified linear unit (ReLU) activation. In the final layer we use a sigmoid function, which forces the output to be between 0 and 1 (inputs and outputs are correspondingly rescaled).

For simplicity and memory efficiency, we aimed to work with real (32-bit) numbers, thus necessitating an initial operation acting on the complex shear GLYPH&lt;13&gt; . The best results came from using a fixed Wiener filter operation before the first convolution (rather than KS, as might be expected). This is equivalent to the first layer having M j = 0 = W and GLYPH&lt;26&gt; = 1 , with no free parameters. We could also interpret the Unet after the initial Wiener operation as G GLYPH&lt;2&gt; where F ' GLYPH&lt;2&gt; GLYPH&lt;13&gt; ' = G ' GLYPH&lt;2&gt; W ' GLYPH&lt;13&gt; '' . The Wiener filter used a power spectrum with cosmological parameters GLYPH&lt;27&gt; 8 and GLYPH&lt;10&gt; m fixed at the mean of the marginal posterior distributions from DES Y1 analysis (Abbott et al. 2018). The flat sky power spectrum was an average of 102 power spectra of projected patches.

matter particles were binned using the healp ix (G´rski et al. o 2005) pixelisation of the sphere with nside =2048 in comoving radial shells of 50 Mpc h GLYPH&lt;157&gt; . The density GLYPH&lt;26&gt; map in a given redshift was converted into an overdensity GLYPH&lt;14&gt; = GLYPH&lt;26&gt; GLYPH&lt;157&gt; ¯ GLYPH&lt;26&gt; GLYPH&lt;0&gt; 1 using the average density in the shell ¯ GLYPH&lt;26&gt; . The convergence was calculated per pixel using equation 1. We wish to have the n z ' ' in the lensing kernel match the DES SV data (section 4.1), which we approximate by summing the individual posterior redshift distributions per galaxy from the BPZ photometric redshift code (Coe et al. 2006). The convergence maps were downgraded to nside =1024.

## 3.3 Training data

## 3.3.1 l-picola simulations

The training data is derived from 74 independent dark matter simulations, with each simulation covering an octant of the sky. The simulations used a standard flat GLYPH&lt;3&gt; CDM cosmological model with H 0 = 70 km Mpc GLYPH&lt;0&gt; 1 s GLYPH&lt;0&gt; 1 . The scalar spectral index and baryon density were fixed at n s = 0 95 : and GLYPH&lt;10&gt; b = 0 044 : respectively. The values of GLYPH&lt;10&gt; m and the amplitude parameter GLYPH&lt;27&gt; 8 are distributed on a non-Euclidean grid with distances between points giving a density according to our prior P ' GLYPH&lt;27&gt; 8 , GLYPH&lt;10&gt; m ' as shown in figure 1. Weak lensing constraints are most sensitive to combinations of this pair of parameters, so we avoid overfitting to a single cosmology by varying them in the training data.

To generate a convergence map from a simulation, the

The dark matter simulations are generated using the l-picola code (Howlett et al. 2015), which is based on the cola (Tassev et al. 2013) algorithm. This uses a combination of second-order Lagrangian perturbation theory (2LPT) and a Particle-Mesh (PM) which requires fewer time steps than 'full' N-body (e.g. Gadget Springel 2005) and therefore can generate simulations more quickly. This allows more training data to be generated in a given amount of compute time.

We used a 1250 Mpc GLYPH&lt;157&gt; h comoving simulation box, 768 3 particles, and a 1536 3 grid. A z &lt; 1 6 : lightcone was generated with up to four box replicates, using 30 time steps from z = 20 . The initial conditions used Eisenstein &amp; Hu 1999 for the linear matter power spectrum.

The drawback of this approach is the accuracy of the dark matter distribution. The finite spatial resolution and fewer timesteps used by the cola method particularly affects small distance scales. Our experiments have shown a suppression of the l-picola power spectrum at scales of ' &gt; 700 of order 10 per cent (relative to nicaea 2 (Kilbinger et al. 2009) theory), as is expected with cola methods. We correct the power of the l-picola convergence by estimating

2 nicaea.readthedocs.io

the smooth part of the C GLYPH&lt;20&gt; ' ' ' using a polynomial order 1 Savgol filter with window size 91 for each convergence map and reweighting spherical harmonics. Using the ratio of nicaea and only the smooth part of the measured simulation power spectrum ensures that the natural fluctuations inherent in C GLYPH&lt;20&gt; ' ' ' for a given realization are preserved.

## 3.3.2 Training images

From the 74 independent healp ix convergence maps over an octant of the sky, we generate 376,684 DES SV mock data realizations. A given realization is generated from the healp ix convergence map by randomly choosing a position on the sphere, applying a uniform random rotation between 0 and 360 deg, and extracting a square patch using a gnomonic projection with 256 2 pixels of size 4 5 2 : arcmin 2 . If the generated image has pixels outside the octant, it is rejected. The rotation step is not to make the reconstruction rotation invariant, which happens naturally as P ' GLYPH&lt;20&gt; ' is isotropic by the cosmological principle, but it is to augment the training data and learn F GLYPH&lt;2&gt; better.

From the projected square GLYPH&lt;20&gt; convergence map, the complex noise-free shear map is generated using the A matrix from equation 2. The mask is applied and a random shape noise map is added. The noise map is generated by randomly shuffling the positions of galaxies in the original catalogue; this keeps the density of galaxies the same, but destroys the coherent lensing signal. This way we forward model the nonGaussian noise inherent in the data (something that other methods do not do).

## 4 RESULTS

## 4.1 Dark Energy Survey SV data

DES is a ground-based photometric galaxy survey, observing in the southern sky from the 4m Blanco telescope in Chile with five photometric filters (Flaugher et al. 2015). The SV (A1) data 3 come from an initial run of 139 deg , but with 2 depth approximately that of the full 6 year survey (Chang et al. 2015). We make a redshift cut of 0 6 : &lt; z mean &lt; 1 2 : , where z mean is the mean of the z posterior for each galaxy. Data selection choices match Jeffrey et al. (2018b), although some maps appear different due to changes in pixel size and flat-sky projection.

In figure 2 we apply KS, Wiener filtering, and the trained DeepMass CNN. Kaiser-Squires uses a 10 arcmin Gaussian smoothing as in Jeffrey et al. (2018b). The Wiener filtering uses a power spectrum with GLYPH&lt;10&gt; m and GLYPH&lt;27&gt; 8 at the mean of their respective marginal posterior distributions from the Year 1 DES cosmology result (Abbott et al. 2018). The DeepMass CNN was trained using the Adam optimizer (Kingma &amp; Ba 2014) with a learning rate = 1 GLYPH&lt;2&gt; 10 GLYPH&lt;0&gt; 5 for 20 epochs (retraining over the full training set). The final Wiener and DeepMass maps were smoothed with a Gaussian

3 http://des.ncsa.illinois.edu

kernel of GLYPH&lt;27&gt; = 2 25 : arc min (half pixel size) to remove very small scale artefacts arising from the healp ix projection.

The DeepMass reconstruction clearly shows more nonlinear structure than the Wiener filter. Individual peaks, which are suppressed by Wiener filtering, are resolved by DeepMass. The accurate recovery of non-linear and peak structures using DeepMass is studied quantitatively in section 4.2.

## 4.2 Validation on simulations

Of the originally generated training images (section 3.3), 8000 were reserved for validation and not used for training. One such example can be seen in figure 3, with the corresponding Wiener filter and DeepMass reconstructions. As with the reconstruction from observational data, DeepMass can be seen to recover the non-linear (cosmic-web) structure better than Wiener filtering. Compared to Wiener filtering, the MSE over all 8000 maps is improved using DeepMass by 11 per cent.

As DeepMass is estimating the mean of a posterior probability distribution (equation 7) there are inevitably structures that appear in the map (figure 3) but do not appear in the truth and structures that appear in the truth but not in the reconstruction. Exploring the full posterior distribution, and thereby quantifying uncertainty, is a rich topic for future work.

To understand how DeepMass performs over different regimes, we can measure the MSE for a subset of pixels in the map with true value greater than some threshold, GLYPH&lt;20&gt; &gt; X . Figure 4 shows this for three different examples (labelled A, B and C), chosen from the validation sample for their different power spectra.

The bottom row of figure 4 shows the MSE difference between DeepMass and Wiener filtering ( MSEDeepMass GLYPH&lt;0&gt; MSEWiener ) for these three examples. In each case, the DeepMass improvement over Wiener filtering is shown to be driven by pixels with large true convergence GLYPH&lt;20&gt; truth . That is, DeepMass improves over Wiener filtering more for pixels with larger GLYPH&lt;20&gt; values (with increased improvement for those with GLYPH&lt;20&gt; truth &gt; 0 ). Compared to Wiener filtering, DeepMass is able to better reconstruct high GLYPH&lt;20&gt; value, non-linear structures in the convergence GLYPH&lt;20&gt; fields.

The error bars in the bottom row of figure 4 are given by q GLYPH&lt;27&gt; 2 MSE ; DeepMass + GLYPH&lt;27&gt; 2 MSE ; Wiener 'GLYPH&lt;157&gt; N GLYPH&lt;20&gt; &gt; X , where N GLYPH&lt;20&gt; &gt; X is the number of pixels in the sample above the threshold, and GLYPH&lt;27&gt; 2 MSE is the variance of the measured MSE over the sample for a given method.

The three map examples in figure 4 were chosen to demonstrate performance when the underlying true maps have different power spectra ( top row ). The map with the smallest power (example C) has the least improvement of DeepMass over Wiener filtering (though the improvement is still larger for high valued pixels). Example A, with a larger power spectrum, shows a much more significant improvement in MSE.

Figure 4 demonstrates that: (1) DeepMass improves over Wiener more for pixels with larger GLYPH&lt;20&gt; value, and (2) DeepMass improves over Wiener more when the underlying map has more structure (higher power).

In Jeffrey et al. (2018b), use of a 'halo-model' sparsity

Figure 4. The top row shows the power spectra of three example convergence GLYPH&lt;20&gt; truth maps (A, B and C) from the validation sample. The bottom row shows the corresponding change in MSE from Wiener filtering to DeepMass as a function of GLYPH&lt;20&gt; threshold of the pixels. This shows (1) DeepMass improves over Wiener mostly in the high GLYPH&lt;20&gt; regime, and (2) DeepMass improves over Wiener more when the underlying map has more structure (higher power).

![image](https://ac.marcodsn.me/arxiv-markdown-images/1908.00543v2-figure-30c747ca-af2a-42eb-8165-490fbf88f7f8.jpg)

prior did not outperform Wiener filtering in terms of MSE, and so we expect DeepMass MSE to outperform Glimpse . However, MSE minimisation relates just to the posterior mean, so alternative metrics (e.g. constraints from peak statistics) remain to be explored.

Using 18 non-overlapping mock DES SV data from the MICE (Fosalba et al. 2015) simulations we apply a Wiener filter with an optimal power spectrum calculated using the known cosmological parameters (not available in real data applications). Nevertheless, without using the known cosmological parameters as input, DeepMass still recovers maps with an average of 2 per cent better MSE.

Figure 5 shows the power spectrum P GLYPH&lt;1&gt; of the residual maps ˆ GLYPH&lt;20&gt; GLYPH&lt;0&gt; GLYPH&lt;20&gt; truth , normalized by dividing by the true power P truth , averaged across all the maps in the validation sample. The residual power shows no particular scale at which DeepMass performs better or worse than the Wiener filter; DeepMass outperforms Wiener filtering at all length scales.

The smaller improvement of DeepMass over Wiener with the MICE simulated data can be explained both by the fact that we have used the known cosmological parameters in the Wiener filter (whereas DeepMass uses no specified input cosmological parameters) and by the intrinsically low power of the MICE simulations. The MICE cosmological parameters (inc. GLYPH&lt;10&gt; m = 0 25 : , GLYPH&lt;27&gt; 8 = 0 8 : ) lead to a relatively low amplitude power spectrum, so DeepMass is in the regime demonstrated by example C in figure 4. The low power effectively means that there are fewer non-Gaussian structures above a detectable signal-to-noise level. The largest improvement over Wiener filtering comes when there are more non-linear (non-Gaussian) structures.

With the same MICE simulations, and restricting ourselves to pixels where the truth is greater than two standard deviations from the mean GLYPH&lt;20&gt; &gt; 2 GLYPH&lt;27&gt; (where GLYPH&lt;27&gt; is the standard deviation of pixels in the true map), compared to Wiener filtering, DeepMass improves the MSE by 8 per cent. As is to be expected, therefore, DeepMass improves over Wiener filtering due to its ability to reconstruct the non-linear structures in the cosmological signal.

At the smallest scales, the average P GLYPH&lt;1&gt; GLYPH&lt;157&gt; P truth for both methods tend towards one. This is evidence that both reconstruction methods are suppressing structure on the smallest scales, and the residual power is tending towards the power of the true map. On these smallest scales the signal-to-noise is so low that the minimum variance reconstructions damp fluctuations.

The Wiener filter uses the same fiducial power spectrum for each map included in the averaged result shown in figure 5. Although DeepMass has no input cosmology, it outperforms Wiener filtering on large scales which we may expect to be more approximately Gaussian. We can interpret this as DeepMass inferring power spectrum or cosmological parameter information from the data, information which is being used in the reconstruction.

In this work, we drew the cosmological parameters of the training data from broad priors (see figure 1) to generalize the DeepMass method for the realistic situation where the true underlying parameters are unknown. However, in future work it would be interesting to compare Wiener filtering with DeepMass trained at a single fiducial cosmology, to find whether DeepMass would outperform Wiener filtering only at small (presumably more non-Gaussian) scales.

1

Figure 5. Power spectrum of the residuals ( GLYPH&lt;20&gt; GLYPH&lt;1&gt; = ˆ GLYPH&lt;20&gt; GLYPH&lt;0&gt; GLYPH&lt;20&gt; truth ) normalized by the power spectrum of the truth P truth . The ratio P GLYPH&lt;1&gt; GLYPH&lt;157&gt; P truth is averaged over 8000 maps in the validation set with cosmological parameters drawn from the prior (figure 1).

![image](https://ac.marcodsn.me/arxiv-markdown-images/1908.00543v2-figure-fff2d1c0-f81a-426a-ba51-260753680706.jpg)

## 5 CONCLUSION

With DeepMass, we have presented a deep learning method to reconstruct convergence GLYPH&lt;20&gt; maps from shear measurements. With DES SV, we have shown the mass map reconstruction with deep learning from observational data.

By training with simulations over a broad prior distribution of cosmological parameters, we have a generalized method which needs no input cosmological parameters. This method has shown substantial improvement over Wiener filtering both qualitatively (by eye) and quantitatively (11 per cent MSE reduction on the validation data). The flexible approach also takes into account non-Gaussian noise in the weak lensing data. As our simulated training data are samples drawn from the prior P ' GLYPH&lt;20&gt; ' , the approach has a principled Bayesian interpretation, without the need for evaluation of closed-form priors.

The quality of the reconstruction with these initial experiments, and its flexibility, makes the deep learning approach a preeminent candidate for mass mapping with future weak lensing surveys.

## ACKNOWLEDGEMENTS

We thank Edd Edmondson (GPU-wrangler), Ben Wandelt for a useful discussion, and Lorne Whiteway for comments. NJ and OL acknowledge STFC Grant ST/R000476/1.

## REFERENCES

Abbott T. M. C., et al., 2018, Phys. Rev. D, 98, 043526

```
            Abbott T. M. C., et al., 2018, Phys. Rev. D, 98, 043526
            Bacon D. J., Goldberg D. M., Rowe B. T. P., Taylor A. N., 2006,
                MNRAS, 365, 414
            Bartelmann M., Schneider P., 2001, Phys. Rep., 340, 291
            Böhm V., Hilbert  S.,  Greiner  M.,  Enßlin  T.  A., 2017,  Phys.
                Rev. D, 96, 123510
            Carron J., Szapudi I., 2017, MNRAS, 469, 2855
            Chang C., et al., 2015, Physical Review Letters, 115, 051301
```

Coe D., Ben´ ıtez N., S´nchez S. F., Jee M., Bouwens R., Ford H., a 2006, AJ, 132, 926

Eisenstein D. J., Hu W., 1999, ApJ, 511, 5

Flaugher B., et al., 2015, AJ, 150, 150

Fosalba P., Gazta˜aga E., Castander F. J., Crocce M., 2015, MNn RAS, 447, 1319

G´ eron A., 2017, Hands-on machine learning with Scikit-Learn and TensorFlow. O'Reilly Media

Goodfellow I., Bengio Y., Courville A., 2016, Deep Learning. MIT G´ orski K. M., Hivon E., Banday A. J., Wandelt B. D., Hansen

F. K., Reinecke M., Bartelmann M., 2005, ApJ, 622, 759

Han Y., Ye J. C., 2018, IEEE transactions on medical imaging, 37, 1418

Howlett C., Manera M., Percival W. J., 2015, A&amp;C, 12, 109

Ioffe S., Szegedy C., 2015, arXiv preprint arXiv:1502.03167

Jaynes E. T., 2003, Probability theory: the logic of science. CUP

Jeffrey N., Heavens A., Fortio P., 2018a, A&amp;C, 25, 230

Jeffrey N., et al., 2018b, MNRAS, 479, 2871

Kaiser N., Squires G., 1993, ApJ, 404, 441

Kilbinger M., et al., 2009, A&amp;A, 497, 677

Kingma D. P., Ba J., 2014, arXiv preprint arXiv:1412.6980

Kirk D., et al., 2015, Space Sci. Rev., 193, 139

Lanusse F., Starck J.-L., Leonard A., Pires S., 2016, A&amp;A, 591,A2

LeCun Y., Boser B. E., Denker J. S., Henderson D., Howard R. E., Hubbard W. E., Jackel L. D., 1990, in Advances in neural information processing systems. pp 396-404

Mallat S., 2016, Philosophical Transactions of the Royal Society of London Series A, 374, 20150203

Mawdsley B., et al., 2019, arXiv e-prints, p. arXiv:1905.12682

- Ronneberger O., Fischer P., Brox T., 2015, CoRR, abs/1505.04597

Schneider P., Seitz C., 1995, A&amp;A, 294, 411

- Shirasaki M., Yoshida N., Ikeda S., 2018, arXiv e-prints, p. arXiv:1812.05781

Springel V., 2005, MNRAS, 364, 1105

Starck J.-L., Murtagh F., Fadili J., 2015, Sparse image and signal processing: Wavelets and related geometric multiscale analysis. CUP

Tassev S., Zaldarriaga M., Eisenstein D. J., 2013, J. Cosmology Astropart. Phys., 2013, 036

- Wiener N., 1949, Extrapolation, interpolation, and smoothing of stationary time series. Vol. 7, MIT
- Ye J. C., Han Y., Cha E., 2018, SIAM Journal on Imaging Sciences, 11, 991
- Zaroubi S., Hoffman Y., Fisher K. B., Lahav O., 1995, ApJ, 449,

446
Niall Jeffrey François Lanusse Ofer Lahav Jean-Luc Starck
Deep learning dark matter map reconstructions from DES SV weak lensing data
We present the first reconstruction of dark matter maps from weak lensing
observational data using deep learning. We train a convolution neural network
(CNN) with a Unet based architecture on over $3.6\times10^5$ simulated data
realizations with non-Gaussian shape noise and with cosmological parameters
varying over a broad prior distribution. We interpret our newly created DES SV
map as an approximation of the posterior mean $P(\kappa | \gamma)$ of the
convergence given observed shear. Our DeepMass method is substantially more
accurate than existing mass-mapping methods. With a validation set of 8000
simulated DES SV data realizations, compared to Wiener filtering with a fixed
power spectrum, the DeepMass method improved the mean-square-error (MSE) by 11
per cent. With N-body simulated MICE mock data, we show that Wiener filtering
with the optimal known power spectrum still gives a worse MSE than our
generalized method with no input cosmological parameters; we show that the
improvement is driven by the non-linear structures in the convergence. With
higher galaxy density in future weak lensing data unveiling more non-linear
scales, it is likely that deep learning will be a leading approach for mass
mapping with Euclid and LSST.