  We develop a local model theory for moduli stacks of $2$-dimensional
non-scalar tame potentially Barsotti--Tate Galois representations of the Galois
group of an unramified extension of $\mathbb{Q}_p$. We derive from this
explicit presentations of potentially Barsotti--Tate deformation rings,
allowing us to prove structural results about them, and prove various
conjectures formulated by Caruso--David--M\'ezard.
