In this paper we present a Double mha pooling layer for speaker verification. The use of this layer is inspired by [1]}, where Double mha is presented as a double self attention block which captures feature statistics and makes adaptive feature
assignment over images. In this work this mechanism is used as a combination of two self attention pooling layers to create utterance-level speaker embeddings. Given a sequence of encoded representations from a cnn, Self mha first concatenates the context vector from \(K\)  head attentions applied over a \(K\)  sub-embedding sequences. An additional self attention mechanism is then applied over the multi-head context vector. This attention based pooling summarizes the set of head context vectors into a global speaker representation. This representation is pooled through a weighted average of the head context vectors, where the head weights are produced with the self attention mechanism. On the one hand, this approach allows the model to attend to different parts of the sequence, capturing at the same time different subsets of encoded representations. On the other hand, the pooling layer allows to select which head context vectors are the most relevant to produce the global context vector. In comparison with [1]}, the second pooling layer operates over the head context vectors produced by a mha instead of the global descriptors produced by a self multi attention mechanism applied over an image.
