  Learned image compression methods have exhibited superior rate-distortion
performance than classical image compression standards. Most existing learned
image compression models are based on Convolutional Neural Networks (CNNs).
Despite great contributions, a main drawback of CNN based model is that its
structure is not designed for capturing local redundancy, especially the
non-repetitive textures, which severely affects the reconstruction quality.
Therefore, how to make full use of both global structure and local texture
becomes the core problem for learning-based image compression. Inspired by
recent progresses of Vision Transformer (ViT) and Swin Transformer, we found
that combining the local-aware attention mechanism with the global-related
feature learning could meet the expectation in image compression. In this
paper, we first extensively study the effects of multiple kinds of attention
mechanisms for local features learning, then introduce a more straightforward
yet effective window-based local attention block. The proposed window-based
attention is very flexible which could work as a plug-and-play component to
enhance CNN and Transformer models. Moreover, we propose a novel Symmetrical
TransFormer (STF) framework with absolute transformer blocks in the
down-sampling encoder and up-sampling decoder. Extensive experimental
evaluations have shown that the proposed method is effective and outperforms
the state-of-the-art methods. The code is publicly available at
https://github.com/Googolxx/STF.
