MACE: A Multi-pattern Accommodated and Efficient Anomaly Detection Method in the Frequency Domain