  In this paper, HeadPosr is proposed to predict the head poses using a single
RGB image. \textit{HeadPosr} uses a novel architecture which includes a
transformer encoder. In concrete, it consists of: (1) backbone; (2) connector;
(3) transformer encoder; (4) prediction head. The significance of using a
transformer encoder for HPE is studied. An extensive ablation study is
performed on varying the (1) number of encoders; (2) number of heads; (3)
different position embeddings; (4) different activations; (5) input channel
size, in a transformer used in HeadPosr. Further studies on using: (1)
different backbones, (2) using different learning rates are also shown. The
elaborated experiments and ablations studies are conducted using three
different open-source widely used datasets for HPE, i.e., 300W-LP, AFLW2000,
and BIWI datasets. Experiments illustrate that \textit{HeadPosr} outperforms
all the state-of-art methods including both the landmark-free and the others
based on using landmark or depth estimation on the AFLW2000 dataset and BIWI
datasets when trained with 300W-LP. It also outperforms when averaging the
results from the compared datasets, hence setting a benchmark for the problem
of HPE, also demonstrating the effectiveness of using transformers over the
state-of-the-art.
