Patent attributes
Provided is a method of encoding an image, the method including: determining a subjective quality of the image when the image is compressed; determining at least one degree of compression that changes the subjective quality and is from among degrees of compression indicating how much the image is compressed; and encoding the image by compressing a residual signal of the image, based on compression information according to the determined degree of compression, wherein the subjective quality is determined for each frame by using a Deep Neural Network (DNN). Provided are an image decoding method and an image decoding apparatus for performing the image decoding method for decoding an image by using information encoded according to an image encoding method.