The invention relates to a method for realizing GIF (
Graphics Interchange Format) adaptive
steganography based on a spatio-temporal policy network and cross-frame optimization, which comprises the following steps of: inputting continuous multi-frame images serving as frame fragments into a pre-trained spatio-temporal policy network to generate policy information; determining the embedding capacity of secret information for the target image in the frame segment through a cross-frame optimization module; based on the determined embedding capacity and embedding
cost distribution contained in the strategy information, embedding secret information into the target image; and the
steganography GIF is analyzed, and the secret information is recovered. According to the method and the device for realizing the GIF adaptive
steganography based on the space-time strategy network and the cross-frame optimization, the processor and the computer readable storage medium thereof, the space-time characteristics of the GIF are automatically learned by utilizing the strategy network obtained by deep
reinforcement learning training, so that an optimal embedding strategy and a cross-frame
load distribution scheme are generated, and the self-adaptive steganography of the GIF is realized. Therefore, the high embedding capacity is ensured, and meanwhile, the anti-detection safety of steganography is remarkably improved.