In traditional multiple-input multiple-output (MIMO) communication systems, the antenna spacing is often no smaller than half a wavelength. However, by exploiting the coupling between more closely-spaced antennas, a superdirective array may achieve a much higher beamforming gain than traditional MIMO. In this paper, we present a novel utilization of neural networks in the context of superdirective arrays. Specifically, a new model called MultiTransUNet-GAN is proposed, which aims to forecast the excitation coefficients to achieve ``superdirectivity" or ``super-gain" in the compact uniform linear or planar antenna arrays. In this model, we integrate a multi-level guided attention and a multi-scale skip connection. Furthermore, generative adversarial networks are integrated into our model. To improve the prediction accuracy and convergence speed of our model, we introduce the warm up aided cosine learning rate (LR) schedule during the model training, and the objective function is improved by incorporating the normalized mean squared error (NMSE) between the generated value and the actual value. Simulations demonstrate that the array directivity and array gain achieved by our model exhibit a strong agreement with the theoretical values. Overall, it shows the advantage of enhanced precision over the existing models, and a reduced requirement for measurement and the computation of the excitation coefficients.