  Medical anomaly detection is a critical research area aimed at recognizing
abnormal images to aid in diagnosis.Most existing methods adopt synthetic
anomalies and image restoration on normal samples to detect anomaly. The
unlabeled data consisting of both normal and abnormal data is not well
explored. We introduce a novel Spatial-aware Attention Generative Adversarial
Network (SAGAN) for one-class semi-supervised generation of health images.Our
core insight is the utilization of position encoding and attention to
accurately focus on restoring abnormal regions and preserving normal regions.
To fully utilize the unlabelled data, SAGAN relaxes the cyclic consistency
requirement of the existing unpaired image-to-image conversion methods, and
generates high-quality health images corresponding to unlabeled data, guided by
the reconstruction of normal images and restoration of pseudo-anomaly
images.Subsequently, the discrepancy between the generated healthy image and
the original image is utilized as an anomaly score.Extensive experiments on
three medical datasets demonstrate that the proposed SAGAN outperforms the
state-of-the-art methods.
