This paper presents a fault diagnosis method for a vacuum contactor using the generalized Stockwell transform (GST) of vibration signals. The objective is to solve the problem of low diagnostic performance efficiency caused by the inadequate feature extraction capability and the redundant pixels in the graph background. The proposed method is based on the time-frequency graph optimization technique and ShuffleNetV2 network. Firstly, vibration signals in different states are collected and converted into GST time-frequency graphs. Secondly, multi-resolution GST time-frequency graphs are generated to cover signal characteristics in all frequency bands by adjusting the GST Gaussian window width factor λ. The OTSU algorithm is then combined to crop the energy concentration area, and the size of these time-frequency graphs is optimized by 68.86%. Finally, considering the advantages of the channel split and channel shuffle methods, the ShuffleNetV2 network is adopted to improve the feature learning ability and identify fault categories. In this paper, the CKJ5-400/1140 vacuum contactor is taken as the test object. The fault recognition accuracy reaches 99.74%, and the single iteration time of model training is reduced by 19.42%.