Metamaterial perfect absorbers (MPAs) typically have regularly-shaped unit structures owing to constraints on conventional analysis methods, limiting their absorption properties. We propose an MPA structure with a general polygon-shaped meta-atom. Its irregular unit structure provides multiple degrees-of-freedom, enabling flexible properties, such as dual-band absorption. We constructed a deep neural network to predict the parameters of the corresponding MPA structure with a given absorptivity as input, and vice versa. The mean-square error was as low as 0.0017 on the validation set. This study provides a basis for the design of complicated artificial electromagnetic structures for application in metamaterials and metasurfaces.