  Developments in the description of the masses of atomic nuclei have led to
various nuclear mass models that provide predictions for masses across the
whole chart of nuclides. These mass models play an important role in
understanding the synthesis of heavy elements in the rapid neutron capture
($r$-) process. However, it is still a challenging task to estimate the size of
uncertainty associated with the predictions of each mass model. In this work, a
method to quantify the mass uncertainty using \textit{ensemble Bayesian model
averaging} (EBMA) is introduced. This Bayesian method provides a natural way to
perform model averaging, selection, calibration, and uncertainty
quantification, by combining the mass models as a mixture of normal
distributions, whose parameters are optimized against the experimental data,
employing the Markov chain Monte Carlo (MCMC) method using the No-U-Turn
sampler (NUTS). The average size of our best uncertainty estimates of neutron
separation energies based on the AME2003 data is 0.48 MeV and covers 95% of new
data in the AME2020. The uncertainty estimates can also be used to detect
outliers with respect to the trend of experimental data and theoretical
predictions.
