with other state-of-the-art methods. The baseline is a ResNet-50 Mask R-CNN with a 5-level feature pyramid [@fpn]. Figure \[fig:net\] illustrates the architecture. The backbones initialize from ImageNet pretrainings. All other modules use random initialization. All models trained for 24 epochs on 32 NVIDIA GTX 1080 Ti GPUs. The batch size is 64. The learning rate is 1.25e-4 at the beginning of training and drops by a factor of 10 at the start of the 18th and 21st epochs. All experiments used softmax normalization and $d_k = 64$.

![**Architecture of the Mask R-CNN FPN baseline.** Red dots are potential locations for the insertion of efficient attention or non-local modules.[]{data-label="fig:net"}](figures/net.png){width="\linewidth"}

Table \[tab:vs-ca\] reports the comparison against the non-local module. As rows res3 and fpn3 show, inserting an efficient attention module or a non-local module at the same location in a network has nearly identical effects on the performance. However, at layers where the input is large, inserting a non-local module leads to out-of-memory errors, while inserting an efficient attention module improved performance significantly and consumed little additional resources. Consequently, using the best insertion schemes for each module, the efficient attention module outperforms the non-local module by 0.9 box AP and 0.8 mask 