Are DPDAs accepting on final state equivalent to DPDAs accepting on empty stack equivalent?


Say I have a string x that is accepted by some DPDA P that accepts empty stack. Intuitively it’s seems impossible for P to accept any string x.y for any y != epsilon. The below DPDA accepts on final states all strings the language {a,b}* having an equal number of a’s and b’s.

DPDA

Is it possible to transform this to a DPDA accepting on empty stack, i.e. are DPDAs accepting on final states and DPDAs accepting on empty stack equivalent?