Encoding method and apparatus suitable for spatial image

By generating sampling points based on spatial angles to construct a spatial picture matrix, and dividing sub-matrices according to the degree of change of adjacent pictures, using key frame and predicted frame encoding, it solves the problem of being unable to encode spatial images with existing technology, and achieves efficient spatial images. Encoding and decoding.

WO2024222936A1PCT designated stage expired Publication Date: 2024-10-31BEIJING WODONG TIANJUN INFORMATION TECH CO LTD +1
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2024/090279
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2023-04-28
Filing Date
2024-04-28
Publication Date
2024-10-31

AI Technical Summary

Technical Problem

Existing video encoding and decoding technology is based on timing and cannot effectively encode spatial images because it assumes that frame data is temporally continuous and cannot be applied to spatial images.

Method used

Construct a spatial picture matrix by generating the longitude and latitude of sampling points based on different spatial angles, determine the target size of the submatrix according to the degree of change between adjacent spatial pictures, and divide it into picture groups, use key frames and predicted frames for encoding, and generate Encoded file.

Benefits of technology

It achieves efficient encoding of spatial images, reorganizes the spatial image matrix, uses spatial distribution characteristics to improve encoding and decoding efficiency, and reduces memory usage.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2024090279_31102024_PF_FP_ABST
    Figure CN2024090279_31102024_PF_FP_ABST
Patent Text Reader

Abstract

The present disclosure discloses an encoding method and apparatus suitable for a spatial image. A specific embodiment of the method comprises: according to longitudes and latitudes corresponding to a plurality of sampling points under different spatial angles, generating a spatial picture matrix comprising a plurality of spatial pictures acquired by means of the plurality of sampling points; according to the degree of change between adjacent spatial pictures in the spatial picture matrix, determining target sizes of sub-matrices corresponding to different regions in the spatial picture matrix; dividing the spatial picture matrix by using the sub-matrices corresponding to different regions in the spatial picture matrix, and obtaining a plurality of picture groups; and according to respective key frames and prediction frames comprised in the plurality of picture groups, encoding a spatial picture in the spatial picture matrix, and generating an encoded file.
Need to check novelty before this filing date? Find Prior Art

Description

Coding method and device for spatial images

[0001] CROSS-REFERENCE TO RELATED APPLICATIONS

[0002] This patent application claims priority to the Chinese patent application filed on April 28, 2023, with application number 202310485016.5 and invention name “Encoding method and device for spatial images”. The full text of the application is incorporated into the application by reference. Technical Field

[0003] The embodiments of the present disclosure relate to the field of computer technology, specifically to coding technology, and more particularly to a coding method, device, computer-readable medium, and electronic device applicable to spatial images. Background Art

[0004] Current mainstream video encoding and decoding technologies are all based on time sequence, meaning that the data of the previous and next frames in the bitstream are temporally continuous. This is a very strong a priori condition, meaning that the encoding process can safely utilize this information. Existing video encoding technologies can be applied to time-sequential images, but not to spatial images.

[0005] Summary of the Invention

[0006] The embodiments of the present disclosure provide a coding method, device, computer-readable medium, and electronic device applicable to spatial images.

[0007] In one or more embodiments, a coding method suitable for spatial images is provided, including: generating a spatial picture matrix including multiple spatial pictures collected by multiple sampling points according to the longitude and latitude corresponding to multiple sampling points at different spatial angles; determining the target size of the sub-matrix corresponding to different areas in the spatial picture matrix according to the degree of change between adjacent spatial pictures in the spatial picture matrix; dividing the spatial picture matrix according to the sub-matrices corresponding to different areas in the spatial picture matrix to obtain multiple picture groups; encoding the spatial pictures in the spatial picture matrix according to the key frames and predicted frames included in each of the multiple picture groups to generate a coded file.

[0008] In one or more embodiments, the above-mentioned determination of the target size of the submatrix corresponding to different areas in the spatial picture matrix based on the degree of change between adjacent spatial pictures in the spatial picture matrix includes: determining the target size of the submatrix corresponding to different areas in the spatial picture matrix based on the negative correlation between the degree of change between adjacent spatial pictures in the spatial picture matrix and the target size of the submatrix.

[0009] In one or more embodiments, adjacent sampling points among the above-mentioned multiple sampling points are arranged at preset degree intervals in the longitude direction and the latitude direction, and the above-mentioned determination of the target size of the sub-matrix corresponding to different areas in the spatial picture matrix based on the degree of change between adjacent spatial pictures in the spatial picture matrix and the negative correlation between the target size of the sub-matrix includes: in response to determining that the degree of change between adjacent spatial pictures in the latitude direction in the spatial picture matrix is ​​greater than the degree of change between adjacent spatial pictures in the longitude direction, determining that the length of the sub-matrix is ​​greater than the width, wherein the length direction of the sub-matrix corresponds to the longitude direction of the sampling point, and the width direction of the sub-matrix corresponds to the latitude direction of the sampling point; in response to determining that the degree of change between adjacent spatial pictures in the longitude direction in the spatial picture matrix is ​​negatively correlated with the latitude value, determining that the length of the sub-matrix is ​​positively correlated with the latitude value; based on the length of the sub-matrix being greater than the width, and the positive correlation between the length of the sub-matrix and the latitude value, determining the target size of the sub-matrix in different areas of the spatial picture matrix.

[0010] In one or more embodiments, the above-mentioned generation of a spatial picture matrix including multiple spatial pictures collected by multiple sampling points based on the longitudes and latitudes corresponding to multiple sampling points at different spatial angles includes: arranging multiple spatial pictures with the longitudes of the sampling points corresponding to the spatial pictures as the horizontal axis and the latitudes of the sampling points corresponding to the spatial pictures as the vertical axis to generate a spatial picture matrix.

[0011] In one or more embodiments, the above-mentioned encoding of spatial pictures in the spatial picture matrix according to the key frames and predicted frames included in each of the multiple picture groups to generate an encoding file includes: arranging the picture groups corresponding to the sampling points at the same latitude in the multiple picture groups in order from small to large according to the longitudes of the sampling points corresponding to the picture groups, to generate multiple picture group subsequences; arranging the multiple picture group subsequences according to the latitudes of the sampling points corresponding to the picture groups in order from small to large, determining the picture group identifiers corresponding to the multiple picture groups, to generate a picture group sequence; arranging the spatial pictures in each picture group in the picture group sequence in the order of key frames first and predicted frames later, determining the picture identifiers of the spatial pictures in each picture group in the multiple picture groups, to generate a spatial picture sequence; encoding the spatial picture sequence according to the key frames and predicted frames included in each of the multiple picture groups to generate an encoding file.

[0012] In one or more embodiments, the above-mentioned arrangement of the spatial pictures in each picture group in the picture group sequence in the order of key frames first and predicted frames later, determining the picture identifier of the spatial pictures in each picture group in the multiple picture groups, and generating the spatial picture sequence includes: determining the spatial picture at the center position in the submatrix corresponding to each of the multiple picture groups as the initial key frame; for each picture group in the multiple picture groups, based on the initial key frame of the picture group, determining the key frame of the picture group in the direction in which the sampling points corresponding to the spatial pictures in the picture group are sparser, and determining the predicted frame adjacent to the key frame; arranging the spatial pictures in each picture group in the picture group sequence in the order of key frames first and predicted frames later, determining the picture identifier of the spatial pictures in each picture group in the multiple picture groups, and generating the spatial picture sequence.

[0013] In one or more embodiments, the above-mentioned encoding of the spatial picture sequence according to the key frames and prediction frames included in each of the multiple picture groups to generate a coded file includes: for each picture group in the multiple picture groups, using a reference method in which the prediction frame in the picture group uniquely refers to the key frame in the picture group to encode the spatial picture sequence and generate a coded file.

[0014] In one or more embodiments, a coding device suitable for spatial images is provided, including: a first generation unit, configured to generate a spatial picture matrix including multiple spatial pictures collected by multiple sampling points according to the longitude and latitude corresponding to the multiple sampling points at different spatial angles; a determination unit, configured to determine the target size of the sub-matrix corresponding to different areas in the spatial picture matrix according to the degree of change between adjacent spatial pictures in the spatial picture matrix; a division unit, configured to divide the spatial picture matrix with the sub-matrices corresponding to different areas in the spatial picture matrix to obtain multiple picture groups; a second generation unit, configured to encode the spatial pictures in the spatial picture matrix according to the key frames and prediction frames included in each of the multiple picture groups to generate a coded file.

[0015] In one or more embodiments, the above-mentioned determination unit is further configured to: determine the target size of the sub-matrix corresponding to different areas in the spatial picture matrix based on the negative correlation between the degree of change between adjacent spatial pictures in the spatial picture matrix and the target size of the sub-matrix.

[0016] In one or more embodiments, adjacent sampling points among the above-mentioned multiple sampling points are arranged at preset degree intervals in the longitude direction and the latitude direction, and the above-mentioned determination unit is further configured to: in response to determining that the degree of change between adjacent spatial pictures in the latitude direction in the spatial picture matrix is ​​greater than the degree of change between adjacent spatial pictures in the longitude direction, determine that the length of the submatrix is ​​greater than the width, wherein the length direction of the submatrix corresponds to the longitude direction of the sampling point, and the width direction of the submatrix corresponds to the latitude direction of the sampling point; in response to determining that the degree of change between adjacent spatial pictures in the longitude direction in the spatial picture matrix is ​​negatively correlated with the latitude value, determine that the length of the submatrix is ​​positively correlated with the latitude value; based on the fact that the length of the submatrix is ​​greater than the width, and the positive correlation between the length of the submatrix and the latitude value, determine the target size of the submatrix in different areas of the spatial picture matrix.

[0017] In one or more embodiments, the first generating unit is further configured to: arrange multiple spatial images with the longitude of the sampling point corresponding to the spatial image as the horizontal axis and the latitude of the sampling point corresponding to the spatial image as the vertical axis to generate a spatial image matrix.

[0018] In one or more embodiments, the above-mentioned second generation unit is further configured to: arrange the picture groups corresponding to the sampling points at the same latitude in multiple picture groups in order of the longitudes of the sampling points corresponding to the picture groups from small to large, and generate multiple picture group subsequences; arrange the multiple picture group subsequences in order of the latitudes of the sampling points corresponding to the picture groups from small to large, determine the picture group identifiers corresponding to each of the multiple picture groups, and generate a picture group sequence; arrange the spatial pictures in each picture group in the picture group sequence in the order of key frames first and predicted frames later, determine the picture identifiers of the spatial pictures in each picture group in the multiple picture groups, and generate a spatial picture sequence; encode the spatial picture sequence according to the key frames and predicted frames included in each of the multiple picture groups to generate an encoded file.

[0019] In one or more embodiments, the above-mentioned second generation unit is further configured to: determine the spatial picture at the center position in the submatrix corresponding to each of the multiple picture groups as the initial key frame; for each picture group in the multiple picture groups, based on the initial key frame of the picture group, determine the key frame of the picture group from the direction in which the sampling points corresponding to the spatial picture in the picture group are sparser, and determine the predicted frame adjacent to the key frame; arrange the spatial pictures in each picture group in the picture group sequence in the order of key frame first and predicted frame later, determine the picture identifier of the spatial picture in each picture group in the multiple picture groups, and generate a spatial picture sequence.

[0020] In one or more embodiments, the above-mentioned second generation unit is further configured to: for each picture group in a plurality of picture groups, encode the spatial picture sequence using a reference method in which the predicted frame in the picture group uniquely refers to the key frame in the picture group to generate a coded file.

[0021] In one or more embodiments, a computer-readable medium is provided, on which a computer program is stored, wherein when the program is executed by a processor, the method described in any of the above implementations is implemented.

[0022] In one or more embodiments, an electronic device is provided, comprising: one or more processors; a storage device having one or more programs stored thereon, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement the method described in any of the above implementations.

[0023] It should be understood that the content described in this section is not intended to identify the key or important features of the embodiments of the present disclosure, nor is it intended to limit the scope of the present disclosure. Other features of the present disclosure will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS

[0024] Other features, objects and advantages of the present disclosure will become more apparent from a reading of the detailed description of non-limiting embodiments made with reference to the following drawings:

[0025] FIG1 is a diagram of an exemplary system architecture in which an embodiment of the present disclosure may be applied;

[0026] FIG2 is a flow chart of an embodiment of a coding method applicable to spatial images according to the present disclosure;

[0027] FIG3 is a schematic diagram of the spatial layout of sampling points according to the latitude and longitude sampling method of this embodiment;

[0028] FIG4 is a schematic diagram of a spatial picture matrix according to this embodiment;

[0029] FIG5 is a schematic diagram of sub-matrices in different regions of a spatial picture matrix according to this embodiment;

[0030] FIG6 is a schematic diagram showing a spatial picture sequence according to this embodiment;

[0031] FIG7 is a schematic diagram of a reference method between a predicted frame and a key frame in a picture group according to this embodiment;

[0032] FIG8 is a schematic diagram of an application scenario of the coding method applicable to spatial images according to this embodiment;

[0033] FIG9 is a flowchart of another embodiment of a coding method applicable to spatial images according to the present disclosure;

[0034] FIG10 is a schematic diagram of a decoding trajectory according to this embodiment;

[0035] FIG11 is a schematic diagram of a screen sliding trajectory according to this embodiment;

[0036] FIG12 is a structural diagram of an embodiment of a coding apparatus applicable to spatial images according to the present disclosure;

[0037] FIG13 is a schematic diagram of the structure of a computer system suitable for implementing the embodiments of the present disclosure. DETAILED DESCRIPTION

[0038] The present disclosure will be further described in detail below with reference to the accompanying drawings and examples. It should be understood that the specific embodiments described herein are intended only to illustrate the relevant invention and are not intended to limit the invention. It should also be noted that, for ease of description, only portions relevant to the relevant invention are shown in the accompanying drawings.

[0039] It should be noted that, in the absence of conflict, the embodiments and features of the embodiments in the present disclosure may be combined with each other. The present disclosure will be described in detail below with reference to the accompanying drawings and in combination with the embodiments.

[0040] It should be noted that the collection, collection, updating, analysis, processing, use, transmission, and storage of user personal information involved in the technical solutions disclosed herein all comply with relevant laws and regulations, are used for legitimate purposes, and do not violate public order and good morals. Necessary measures are taken with respect to user personal information to prevent unauthorized access to user personal information data and to safeguard the security of user personal information, network security, and national security.

[0041] FIG. 1 shows an exemplary architecture 100 to which the method and apparatus for encoding spatial images of the present disclosure may be applied.

[0042] As shown in Figure 1, system architecture 100 may include terminal devices 101, 102, and 103, a network 104, and a server 105. The communication connections between terminal devices 101, 102, and 103 constitute a topological network, and network 104 is used to provide a medium for communication links between terminal devices 101, 102, and 103 and server 105. Network 104 may include various connection types, such as wired or wireless communication links or fiber optic cables.

[0043] Users can use terminal devices 101, 102, 103 to interact with server 105 via network 104 to receive or send messages, etc. Terminal devices 101, 102, 103 can be hardware devices or software that support network connection for data interaction and data processing. When terminal devices 101, 102, 103 are hardware, they can be various electronic devices that support network connection, information acquisition, interaction, display, processing and other functions, including but not limited to smart phones, image acquisition devices, tablet computers, e-book readers, laptop computers and desktop computers, etc. When terminal devices 101, 102, 103 are software, they can be installed in the electronic devices listed above. They can be implemented as multiple software or software modules for providing distributed services, for example, or as a single software or software module. No specific limitation is made here.

[0044] Server 105 can be a server that provides various services, such as a backend processing server that receives spatial images provided by terminal devices 101, 102, and 103, utilizes the spatial distribution characteristics of the spatial images, determines a coding structure for a group of images, and then encodes the image to generate an encoded file. As an example, server 105 can be a cloud server.

[0045] It should be noted that the server can be either hardware or software. When the server is hardware, it can be implemented as a distributed server cluster consisting of multiple servers, or as a single server. When the server is software, it can be implemented as multiple software or software modules (e.g., software or software modules for providing distributed services), or as a single software or software module. No specific limitations are given here.

[0046] It should also be noted that the spatial image encoding method provided in the embodiments of the present disclosure can be executed by a server, a terminal device, or a server and a terminal device in cooperation with each other. Accordingly, the various components (e.g., various units) included in the spatial image encoding apparatus can be entirely located in the server, entirely located in the terminal device, or separately located in the server and the terminal device.

[0047] It should be understood that the number of terminal devices, networks, and servers in Figure 1 is merely illustrative. Any number of terminal devices, networks, and servers may be provided as needed. When the electronic device on which the method for encoding aerial images is running does not need to transmit data with other electronic devices, the system architecture may include only the electronic device (e.g., a server or terminal device) on which the method for encoding aerial images is running.

[0048] 2 , a process 200 of an embodiment of a method for encoding a spatial image is shown, including the following steps:

[0049] Step 201 : generating a spatial picture matrix including a plurality of spatial pictures collected by a plurality of sampling points according to the longitudes and latitudes corresponding to the plurality of sampling points at different spatial angles.

[0050] In this embodiment, an entity executing the spatial image encoding method (e.g., the terminal device or server in Figure 1 ) generates a spatial image matrix comprising multiple spatial images captured at multiple sampling points based on the longitudes and latitudes corresponding to the multiple sampling points at different spatial angles. The spatial images represent images of target objects obtained at different spatial angles. The target objects can be various objects, such as people and objects.

[0051] As an example, multiple sampling points may be uniformly set at different spatial angles to capture spatial images of the target object at different spatial angles, that is, a uniform sampling method.

[0052] As another example, multiple sampling points can be non-uniformly set at different spatial angles around the target object with preset intervals of longitude and latitude to capture spatial images of the target object at different spatial angles, that is, longitude and latitude sampling.

[0053] Figure 3 shows a schematic diagram 300 of the spatial layout of sampling points for a longitude-latitude sampling method. For the upper hemisphere of the target object, sampling is performed at 10° intervals. Thus, there are 36 sampling points in the longitude direction and 9 sampling points in the latitude direction, resulting in a total of 324 (36×99) sampling points in the upper hemisphere of the target object. The left sub-image in Figure 3 is a top view of the spatial layout of the sampling points, while the right sub-image is a front view of the spatial layout of the sampling points.

[0054] The sampling points at different spatial angles correspond to different longitudes and latitudes, thereby sampling and obtaining spatial images at different spatial angles. By arranging the spatial images at different spatial angles in a certain order, a spatial image matrix can be obtained. As an example, for each spatial image, the spatial image is named according to the longitude and latitude of the sampling point corresponding to the spatial image; then, according to the naming information of each spatial image, multiple spatial images are arranged to generate a spatial image matrix. For example, if the longitude and latitude of the sampling point corresponding to the spatial image is (10°, 20°), the spatial image can be named "10-20.jpg".

[0055] In some optional implementations of this embodiment, the above-mentioned execution entity can perform the above-mentioned step 201 in the following manner: arrange multiple spatial images with the longitude of the sampling point corresponding to the spatial image as the horizontal axis and the latitude of the sampling point corresponding to the spatial image as the vertical axis to generate a spatial image matrix.

[0056] Specifically, with the longitude of the sampling point corresponding to the spatial image as the horizontal axis and the latitude of the sampling point corresponding to the spatial image as the vertical axis, multiple spatial images are arranged in the order of longitude from small to large and latitude from small to large to obtain a spatial image matrix.

[0057] Continuing with the sampling points shown in FIG3 as an example, the generated spatial picture matrix is ​​shown in FIG4. The latitude range in the spatial picture matrix is ​​0°9-80°, and the longitude range is 0°-350°.

[0058] In this implementation, based on the latitude and longitude of the sampling points, an arrangement method that is more consistent with the spatial correlation between multiple spatial pictures is provided, so that the generated spatial picture matrix is ​​more conducive to spatial coding, thereby improving spatial coding efficiency.

[0059] Step 202 : Determine target sizes of sub-matrices corresponding to different regions in the spatial picture matrix according to the degree of change between adjacent spatial pictures in the spatial picture matrix.

[0060] In this embodiment, the execution entity may determine the target sizes of the sub-matrices corresponding to different regions in the spatial picture matrix according to the degree of change between adjacent spatial pictures in the spatial picture matrix.

[0061] Characterization of the degree of change between adjacent spatial images, the degree of change between the image contents represented by adjacent spatial images, or the degree of change in the positions between adjacent sampling points corresponding to each of the adjacent spatial images. Regarding the degree of change between image contents, for example, the image features of each of the adjacent spatial images can be extracted through a feature extraction network, and the image features represent the image content of the spatial images; then, by calculating the similarity between the image features of the adjacent spatial images (for example, cosine similarity or Euclidean distance), the degree of change between the adjacent spatial images is determined. Among them, the similarity between adjacent spatial images is negatively correlated with the degree of change between adjacent spatial images. For another example, the histograms corresponding to each of the adjacent spatial images can be determined, and then the degree of change between the adjacent spatial images can be determined by the distance between the histograms.

[0062] Regarding the degree of positional variation between adjacent sampling points, when the distance between the sampling points corresponding to adjacent spatial images in longitude and latitude is greater, the degree of variation between adjacent images is greater; when the distance between the sampling points corresponding to adjacent spatial images in longitude and latitude is closer, the degree of variation between adjacent images is smaller. It can be understood that the degree of variation between the image content of adjacent spatial images collected by adjacent sampling points is often positively correlated with the degree of positional variation between adjacent sampling points.

[0063] As an example, the above-mentioned execution body is provided with a correspondence table that represents the correspondence between the degree of change between adjacent spatial pictures in the spatial picture matrix and the target size of the sub-matrix corresponding to different areas in the spatial picture matrix, so as to determine the target size of the sub-matrix corresponding to different areas corresponding to adjacent spatial pictures in the spatial picture matrix based on the correspondence table and the degree of change between adjacent spatial pictures in the spatial picture matrix.

[0064] As another example, based on the change data of the pre-set target size of the sub-matrix with the degree of change between adjacent spatial pictures, linear fitting is performed to determine a function model between the target size of the sub-matrix and the degree of change between adjacent spatial pictures; then, based on the determined function model and the degree of change between adjacent spatial pictures in the spatial picture matrix, the target sizes of the sub-matrices corresponding to different areas in the spatial picture matrix are determined.

[0065] In some optional implementations of this embodiment, the above-mentioned execution entity can perform the above-mentioned step 202 in the following manner: based on the degree of change between adjacent spatial pictures in the spatial picture matrix and the negative correlation between the target size of the sub-matrix, determine the target size of the sub-matrix corresponding to different areas in the spatial picture matrix.

[0066] Under the longitude and latitude sampling method shown in FIG3 , the degree of change between adjacent spatial images is not the same. Specifically, the degree of change between adjacent spatial images in the longitude direction decreases as the latitude increases.

[0067] The principle that the degree of change between adjacent spatial pictures in the spatial picture matrix is ​​negatively correlated with the target size of the submatrix is ​​adopted. The smaller the degree of change between adjacent spatial pictures, the larger the target size of the submatrix of the area where the adjacent spatial pictures are located in the spatial picture matrix; the greater the degree of change between adjacent spatial pictures, the smaller the target size of the submatrix of the area where the adjacent spatial pictures are located in the spatial picture matrix.

[0068] The submatrix is ​​used to partition the spatial image matrix in subsequent steps to obtain image groups. For spatial images with less variation, a larger image group is set to include more spatial images; for spatial images with greater variation, a smaller image group is set to include fewer spatial images, which improves data compression efficiency during the encoding process.

[0069] In some optional implementations of this embodiment, adjacent sampling points among the plurality of sampling points are arranged at intervals of a preset number of degrees in the longitude and latitude directions. The preset number of degrees can be set based on actual conditions. As an example, referring again to FIG. 3 , the plurality of sampling points are arranged at intervals of 10° in the longitude and latitude directions.

[0070] In this implementation, the execution entity can determine the target size of the submatrix by:

[0071] First, in response to determining that the degree of change between adjacent spatial pictures in the latitude direction in the spatial picture matrix is ​​greater than the degree of change between adjacent spatial pictures in the longitude direction, it is determined that the length of the submatrix is ​​greater than the width, wherein the length direction of the submatrix corresponds to the longitude direction of the sampling point, and the width direction of the submatrix corresponds to the latitude direction of the sampling point; then, in response to determining that the degree of change between adjacent spatial pictures in the longitude direction in the spatial picture matrix is ​​negatively correlated with the latitude value, it is determined that the length of the submatrix is ​​positively correlated with the latitude value; finally, based on the fact that the length of the submatrix is ​​greater than the width, and the positive correlation between the length of the submatrix and the latitude value, the target size of the submatrix in different areas of the spatial picture matrix is ​​determined.

[0072] Continuing with FIG5 , a schematic diagram 500 of submatrices for different regions in a spatial image matrix is ​​shown. Based on the first principle that the length of the submatrix is ​​greater than the width and the second principle that the length of the submatrix is ​​positively correlated with the latitude value, the target sizes of the submatrices are 9×4 and 36×1, respectively. The target size of the submatrix corresponding to the region where the low-latitude spatial image is located is 9×4, and the target size of the submatrix corresponding to the region where the high-latitude spatial image is located is 36×1.

[0073] In this implementation, a specific method for determining the target size of the submatrix is ​​provided. Based on the first principle that the length of the submatrix is ​​greater than the width and the second principle that the length of the submatrix is ​​positively correlated with the latitude value, the adaptability of the determined submatrix to the spatial distribution characteristics of the spatial image is improved, which helps to further improve the coding efficiency.

[0074] Step 203 : Divide the spatial picture matrix into sub-matrices corresponding to different regions in the spatial picture matrix to obtain a plurality of picture groups.

[0075] In this embodiment, the execution entity may divide the spatial picture matrix into sub-matrices corresponding to different regions in the spatial picture matrix to obtain multiple picture groups.

[0076] 5 , the spatial picture matrix is ​​divided by the sub-matrices corresponding to different regions, resulting in nine picture groups GOP1 to GOP9. The sub-matrices corresponding to picture groups GOP1 to GOP8 are 9×4, and the sub-matrix corresponding to GOP9 is 36×1.

[0077] Step 204 : Encode the spatial pictures in the spatial picture matrix according to the key frames and predicted frames included in each of the plurality of picture groups to generate an encoded file.

[0078] In this embodiment, the execution entity may encode the spatial pictures in the spatial picture matrix according to the key frames and predicted frames respectively included in the plurality of picture groups to generate an encoded file.

[0079] During the compression encoding process, each spatial image frame represents a still image. During actual compression, various compression algorithms are employed to reduce data capacity, with IPB frames being the most common. The I-frame within an IPB frame is also known as a key frame or intra-frame coded frame. A key frame is typically the first frame in each picture group. After appropriate compression, it serves as a reference point for random access, generating a static image. A key frame can be considered the product of image compression, which removes redundant information from the video. A P-frame, also known as a predicted frame or forward predictive coded frame, is used to generate the encoded data corresponding to the predicted frame by removing any redundant information from the compressed data corresponding to the key frame in the same picture group. A predicted frame represents the difference between the predicted frame and the corresponding key frame. During decoding, the decoded data corresponding to the key frame and the predicted frame are referenced to generate the spatial image corresponding to the predicted frame.

[0080] In this embodiment, a determination method can be preset to determine the key frames and prediction frames in the picture group; then, based on the key frames and prediction frames included in each of the multiple picture groups, the spatial pictures in the spatial picture matrix are encoded to generate an encoded file.

[0081] For example, for each picture group in multiple picture groups, the spatial picture corresponding to the sampling point with the smallest longitude and latitude in the picture group is used as the key frame, and the remaining spatial pictures in the picture group are used as prediction frames. The spatial pictures in the spatial picture matrix are encoded to generate an encoded file.

[0082] In some optional implementations of this embodiment, the execution entity may perform step 204 as follows:

[0083] First, the picture groups corresponding to the sampling points at the same latitude in the multiple picture groups are arranged in ascending order of the longitudes of the sampling points corresponding to the picture groups to generate multiple picture group subsequences.

[0084] 5 , the multiple GOP subsequences include a first GOP subsequence, a second GOP subsequence, and a third GOP subsequence. The first GOP subsequence is "GOP1->GOP2->9GOP3->GOP4," the second GOP subsequence is "GOP5->GOP6->9GOP7->GOP8," and the third GOP subsequence is GOP9.

[0085] Second, multiple picture group subsequences are arranged in ascending order of the latitudes of the sampling points corresponding to the picture groups, and picture group identifiers corresponding to the multiple picture groups are determined to generate a picture group sequence.

[0086] 5 , the sequence of groups of pictures is “GOP1—>GOP2—>9GOP3…—>GOP8—>9GOP9”.

[0087] Third, the spatial pictures in each picture group in the picture group sequence are arranged in the order of key frames first and predicted frames later, and the picture identifiers of the spatial pictures in each picture group in the plurality of picture groups are determined to generate a spatial picture sequence.

[0088] Specifically, based on the determined picture group sequence, for the spatial pictures in each picture group, the picture sequence within the picture group is determined in the order of key frames first and predicted frames later. Thus, according to the picture sequence corresponding to the picture group, the picture identifier of the spatial picture in each picture group is determined, and finally the spatial picture sequence is obtained.

[0089] For the multiple prediction frames in each picture group, the arrangement order of the multiple prediction frames can be determined according to a preset determination method. For example, the multiple prediction frames are arranged in the order of latitude and longitude of the sampling points corresponding to the spatial pictures from small to large.

[0090] 6, which shows a schematic diagram of a spatial picture sequence. In each picture group, the key corresponding to the identifier is "0", and the predicted frame corresponding to the identifier is "1-35".

[0091] Fourth, the spatial picture sequence is encoded according to the key frames and predicted frames included in each of the plurality of picture groups to generate an encoded file.

[0092] In this implementation, the spatial picture matrix is ​​first arranged to obtain a spatial picture sequence, and then encoding is performed according to the arrangement order of the spatial pictures in the spatial picture sequence, as well as the key frames and predicted frames in each picture group, further improving the efficiency and accuracy of the encoding process.

[0093] In some optional implementations of this embodiment, the above-mentioned execution entity can perform the above-mentioned third step in the following manner: first, determine the spatial picture at the center position in the submatrix corresponding to each of the multiple picture groups as the initial key frame; then, for each picture group in the multiple picture groups, based on the initial key frame of the picture group, determine the key frame of the picture group from the direction in which the sampling points corresponding to the spatial picture in the picture group are sparser, and determine the predicted frame adjacent to the key frame; finally, arrange the spatial pictures in each picture group in the picture group sequence in the order of key frame first and predicted frame later, determine the picture identifier of the spatial picture in each picture group in the multiple picture groups, and generate a spatial picture sequence.

[0094] Continuing with the 9×4 submatrix shown in FIG5 as an example, for the 36 spatial pictures in the divided picture group, based on the initial key frame at the center position, the key frame is determined from the direction in which the sampling points corresponding to the spatial pictures in the picture group are sparser, that is, in the direction with smaller latitude, specifically at the position (40, 10). Then, for the predicted frames around the key frame, the sorting information of the multiple predicted frames is determined in a left-right symmetrical manner, and the spatial pictures in each picture group in the picture group sequence are arranged to determine the picture identifier of the spatial picture in the picture group. As an example, for the picture group corresponding to the 9×4 submatrix, the picture identifier of the spatial picture in the picture group can be determined with reference to the encoding order in GOP1 in FIG5.

[0095] For the picture group corresponding to the 36×1 submatrix, since the degree of change between adjacent spatial pictures is very small, any one of the spatial pictures can be determined as a key frame. For example, the first spatial picture in the picture group is determined as the key frame. Then, the spatial pictures in the picture group are arranged in order of longitude from small to large, and the picture identifiers of the spatial pictures in the picture group corresponding to the 36×1 submatrix are determined.

[0096] Based on the initial key frame at the center position, the key frame is determined from the direction of sparser sampling points corresponding to the spatial pictures in the picture group, so that the degree of change between the key frame in the picture group and the surrounding predicted frames is small, which further helps the encoding efficiency of the encoding process and reduces the data volume of the encoded file.

[0097] In some optional implementations of this embodiment, the above-mentioned execution entity can perform the above-mentioned fourth step in the following manner: for each picture group in multiple picture groups, the spatial picture sequence is encoded using a reference method in which the predicted frame in the picture group uniquely refers to the key frame in the picture group to generate an encoded file.

[0098] 7, a schematic diagram of a reference method between a predicted frame and a key frame in a group of pictures is shown 700. For each predicted frame in a group of pictures, a key frame in the group of pictures is uniquely referenced to obtain an encoded file.

[0099] In this implementation, the spatial picture sequence is encoded by adopting a reference method in which the predicted frame in the picture group uniquely references the key frame in the picture group, which reduces the complexity of the relationship between the predicted frame and the key frame in the encoded file and helps to improve the data determination speed and decoding efficiency during the decoding process.

[0100] Continuing with FIG8 , FIG8 is a schematic diagram 800 of an application scenario of a spatial image encoding method according to this embodiment. In the application scenario of FIG8 , first, an image acquisition device is used to obtain multiple spatial images of a target object from multiple sampling points at different spatial angles. The spatial layout of the multiple sampling points is shown in 801 . For the upper hemisphere of the target object, sampling is performed at intervals of 10°. Thus, there are 36 sampling points in the longitude direction and 9 sampling points in the latitude direction, resulting in 324 (36×9) sampling points in the upper hemisphere of the target object. Then, based on the degree of change between adjacent spatial images in the spatial image matrix, the target size of the submatrix corresponding to different regions in the spatial image matrix is ​​determined; then, the spatial image matrix 802 is divided by the submatrices 8021 corresponding to different regions in the spatial image matrix to obtain multiple image groups; finally, based on the key frames and predicted frames included in each of the multiple image groups, the spatial images in the spatial image matrix are encoded to generate an encoded file.

[0101] The method provided by the above-mentioned embodiments of the present disclosure generates a spatial picture matrix including multiple spatial pictures collected by multiple sampling points according to the longitude and latitude corresponding to multiple sampling points at different spatial angles; determines the target size of the sub-matrix corresponding to different areas in the spatial picture matrix according to the degree of change between adjacent spatial pictures in the spatial picture matrix; divides the spatial picture matrix with the sub-matrices corresponding to different areas in the spatial picture matrix to obtain multiple picture groups; encodes the spatial pictures in the spatial picture matrix according to the key frames and prediction frames included in each of the multiple picture groups to generate an encoding file, thereby providing a coding method suitable for spatial pictures. During the encoding process, the spatial pictures are reorganized to obtain the spatial picture matrix, and the picture groups in the spatial picture matrix are specified to manage the spatial pictures in the picture groups and realize the temporal decoupling of the spatial pictures; and, the spatial distribution characteristics of the spatial pictures are utilized to determine the picture group coding structure, thereby improving the compression efficiency of the encoding process, helping to improve the decoding efficiency, and reducing the memory usage of the decoding process.

[0102] 9 , a schematic flow chart 900 of an embodiment of a coding method applicable to spatial images according to the present disclosure is shown, including the following steps:

[0103] Step 901 , arranging multiple spatial images with the longitude of the sampling point corresponding to the spatial image as the horizontal axis and the latitude of the sampling point corresponding to the spatial image as the vertical axis to generate a spatial image matrix.

[0104] Step 902 : In response to determining that the degree of change between adjacent spatial pictures in the latitudinal direction in the spatial picture matrix is ​​greater than the degree of change between adjacent spatial pictures in the longitudinal direction, determine that the length of the submatrix is ​​greater than the width.

[0105] The length direction of the submatrix corresponds to the longitude direction of the sampling point, and the width direction of the submatrix corresponds to the latitude direction of the sampling point.

[0106] Step 903 : In response to determining that the degree of change between adjacent spatial pictures in the longitudinal direction of the spatial picture matrix is ​​negatively correlated with the latitude value, determine that the length of the submatrix is ​​positively correlated with the latitude value.

[0107] Step 904 : Determine target sizes of submatrices in different regions of the spatial picture matrix based on the fact that the length of the submatrix is ​​greater than the width and the positive correlation between the length of the submatrix and the latitude value.

[0108] Step 905 : Divide the spatial picture matrix into sub-matrices corresponding to different regions in the spatial picture matrix to obtain multiple picture groups.

[0109] Step 906 , arranging the picture groups corresponding to the sampling points at the same latitude in the plurality of picture groups in ascending order of the longitudes of the sampling points corresponding to the picture groups, to generate a plurality of picture group subsequences.

[0110] Step 907 , arranging the plurality of picture group subsequences in ascending order of the latitudes of the sampling points corresponding to the picture groups, determining the picture group identifiers corresponding to the plurality of picture groups, and generating a picture group sequence.

[0111] Step 908: Determine the spatial picture at the center position in the sub-matrix corresponding to each of the multiple picture groups as the initial key frame.

[0112] Step 909 : For each picture group in the plurality of picture groups, based on the initial key frame of the picture group, determine the key frame of the picture group in a direction where the sampling points corresponding to the spatial pictures in the picture group are sparser, and determine the predicted frame adjacent to the key frame.

[0113] Step 910 , arrange the spatial pictures in each picture group in the picture group sequence in the order of key frames first and predicted frames later, determine the picture identifier of the spatial picture in each picture group in the plurality of picture groups, and generate a spatial picture sequence.

[0114] Step 911 : Encode the spatial picture sequence according to the key frames and predicted frames included in each of the plurality of picture groups to generate an encoded file.

[0115] It can be seen from this embodiment that, compared with the embodiment corresponding to Figure 2, the process 900 of the encoding method applicable to spatial images in this embodiment specifically illustrates the generation process of the spatial picture matrix, the process of determining the target size of the submatrix, the process of determining the spatial picture sequence, and the process of determining the key frames in the picture group. It fully utilizes the spatial distribution characteristics of the spatial pictures to determine the picture group encoding structure, further improves the compression efficiency of the encoding process, helps to improve the decoding efficiency, and reduces the memory usage of the decoding process.

[0116] For the encoded files obtained in the above embodiments 200 and 900, a schematic flow chart of an embodiment of a decoding method applicable to spatial images is provided, including the following steps:

[0117] The first step is to determine the target longitude and latitude corresponding to the target space image desired by the user according to the acquired operation information.

[0118] In this embodiment, the execution entity of the decoding method applicable to spatial images (for example, the terminal device or server in FIG1 ) can determine the target longitude and latitude corresponding to the target spatial image desired by the user based on the acquired operation information.

[0119] The operation information can be an action instruction corresponding to a user's sliding operation or a voice instruction corresponding to voice information. Continuing with Figure 10, it shows the user's operation trajectory within the spatial image matrix. Following the operation trajectory, the execution entity decodes the spatial image data at the corresponding location and obtains and displays the user's desired target spatial image.

[0120] As an example, the execution entity can pre-establish a correspondence between the user's operation position on the screen and the target longitude and latitude corresponding to the user's desired target space image, thereby determining the target longitude and latitude corresponding to the user's desired target space image in real time during the user's operation. The target longitude and latitude corresponding to the target space image are the longitude and latitude corresponding to the sampling point corresponding to the target space image.

[0121] The second step is to determine the position information of the target space picture and the key frames in the target picture group to which the target space picture belongs in the encoded file according to the target longitude and latitude.

[0122] In this embodiment, the execution entity may determine the position information of the target space picture and the key frames in the target picture group to which the target space picture belongs in the encoded file according to the target longitude and latitude.

[0123] The position information includes position information of the target spatial picture in the encoded file and position information of key frames in the target picture group to which the target spatial picture belongs in the encoded file.

[0124] As an example, the execution entity can pre-establish a correspondence between the longitude and latitude corresponding to each spatial image in the encoded file and the spatial image's position information within the encoded file. Thus, the position information of the target spatial image within the encoded file is determined based on the target longitude and latitude. Based on the target longitude and latitude, the key frame longitude and latitude of the key frame within the target image group to which the target spatial image belongs are determined, thereby further determining the key frame's position information within the encoded file.

[0125] In some optional implementations of this embodiment, the execution entity may perform the second step in the following manner:

[0126] First, the target picture group identifier and the target picture identifier of the target spatial picture are determined according to the target longitude and latitude and the key frame longitude and latitude of the key frames in each picture group in the encoded file.

[0127] As an example, the above-mentioned execution entity can determine the key frame longitude and latitude of the key frames in each picture group in the encoded file to generate a key frame longitude and longitude set; then, compare the target longitude and latitude with the key frame longitude and longitude in the key frame longitude and longitude set, and determine the target picture group to which the target spatial picture belongs based on the comparison result between the target longitude and longitude and the longitude and longitude of each key frame in the key frame longitude and longitude set; then, determine the target picture group identifier of the target picture group and the target picture identifier of the target spatial picture.

[0128] Continuing to refer to Figure 5, the corresponding key frame latitude and longitude set is:

[0129] Then, the position information is determined according to the target picture group identifier and the target picture identifier.

[0130] During the encoding process to obtain an encoded file, the spatial picture identifier and the picture group identifier of the picture group to which the spatial picture belongs are generally encoded. After determining the target picture group identifier and the target picture identifier, the position information of the target spatial picture in the encoded file and the position information of the key frames in the target picture group to which the target spatial picture belongs can be determined in the encoded file.

[0131] In this implementation, a specific implementation method is provided for determining the position information of the target spatial picture in the encoded file and the position information of the key frames in the target picture group to which the target spatial picture belongs in the encoded file, which improves the determination efficiency and accuracy of the position information determination process.

[0132] In some optional implementations of this embodiment, the above-mentioned execution entity can determine the target picture group identifier and the target picture identifier in the following manner: first, the picture group to which the key frame corresponding to the key frame longitude and latitude closest to the target longitude and latitude in the key frame of each picture group in the encoded file belongs is taken as the target picture group, and the target picture group identifier is determined; then, the target picture identifier is determined based on the offset between the target longitude and latitude and the key frame longitude and latitude corresponding to the key frame in the target picture group.

[0133] As an example, the target longitude and latitude is (60, 20), which is the closest to the key frame longitude and latitude (40, 10) in the key frame longitude and longitude set. Then the picture group GOP1 to which the key frame corresponding to the key frame longitude and longitude (40, 10) 9 belongs is taken as the target picture group, and the target picture group identifier is determined to be 1.

[0134] Then, the offset between the target longitude and latitude and the key frame longitude and latitude corresponding to the key frame in the target picture group is determined to be (20, 10), and the target picture identifier is determined to be 13.

[0135] Continuing with the submatrix shown in FIG5 as an example, the offset between the longitude and latitude corresponding to the spatial pictures in the picture groups GOP1-9 GOP8 and the longitude and latitude corresponding to the key frames is:

[0136] The offset between the latitude and longitude corresponding to the spatial picture in the picture group GOP9 and the key frame latitude and longitude corresponding to the key frame is:

[0137] According to the arrangement order of the spatial pictures in the picture sequence corresponding to the picture group during the encoding process, the above offset set is reordered to obtain a sorted offset sequence; based on the sorted offset sequence and the obtained offset, the target picture identifier corresponding to the target spatial picture can be determined.

[0138] In this implementation method, the target picture group identifier of the target picture group is determined based on the comparison results of the key frame longitude and latitude of each key frame involved in the encoded file and the target longitude and latitude of the target spatial picture expected by the user, and then the target picture identifier is determined, thereby improving the versatility and accuracy of the identification information determination process.

[0139] The third step is to decode the data at the location represented by the location information in the encoded file to obtain the target space image.

[0140] In this example, the execution entity may decode the data at the location represented by the location information in the encoded file to obtain the target space image.

[0141] After determining the location information of the target data to be decoded, the corresponding location coded data in the coded file can be decoded, and the target space image can be decoded and displayed.

[0142] In some optional implementations of this embodiment, the execution entity may perform the third step as follows:

[0143] First, according to the target picture identifier, it is determined whether the target spatial picture is a key frame in the target picture group or a predicted frame in the target picture group.

[0144] As an example, when it is determined that the target picture identifier is the same as the key frame identifier of the key frame in the target picture group, it is determined that the target spatial picture is the key frame in the target picture group; when it is determined that the target picture identifier is the same as the predicted frame identifier of the predicted frame in the target picture group, it is determined that the target spatial picture is the predicted frame in the target picture group.

[0145] Then, in response to determining that the target spatial picture is a predicted frame in the target picture group, the key frame in the target picture group at the position represented by the position information and the predicted frame corresponding to the target picture identifier are decoded to obtain the target spatial picture.

[0146] When the target spatial picture is a predicted frame in the target picture group, since the predicted frame refers to the key frame in the picture group, it is necessary to simultaneously decode the key frame in the target picture group at the position represented by the position information and the predicted frame corresponding to the target picture identifier to obtain the target spatial picture.

[0147] In some optional implementations of this embodiment, the above-mentioned execution entity can also perform the above-mentioned third step in the following manner: in response to determining that the target spatial picture is a key frame in the target picture group, decode the key frame in the target picture group at the position represented by the position information to obtain the target spatial picture.

[0148] When the target spatial picture is a key frame in the target picture group, the key frame in the target picture group at the position represented by the position information can be directly decoded to obtain the target spatial picture without referring to other spatial pictures.

[0149] Continuing with reference to Figure 11, a schematic diagram 1100 of a decoding trajectory of the operation trajectory corresponding to Figure 10 is shown. In this embodiment, the target longitude and latitude corresponding to the target spatial image desired by the user is determined based on the acquired operation information; the position information of the target spatial image and the key frames in the target image group to which the target spatial image belongs in the encoded file is determined based on the target longitude and latitude; the data at the position represented by the position information in the encoded file is decoded to obtain the target spatial image, thereby providing a decoding method suitable for spatial images. Since the spatial images in the encoded file are decoupled in time, the target longitude and latitude are mapped to the position of the corresponding data in the encoded file, thereby achieving decoding at any position and improving decoding flexibility.

[0150] With respect to the encoded files obtained in the above-mentioned embodiments 200 and 900, a schematic flow chart of another embodiment of a decoding method applicable to spatial images is provided, including the following steps:

[0151] The first step is to determine the target longitude and latitude corresponding to the target space image desired by the user according to the acquired operation information.

[0152] In the second step, the picture group to which the key frame corresponding to the key frame longitude and latitude closest to the target longitude and latitude in each picture group in the encoded file belongs is taken as the target picture group, and the target picture group identifier is determined.

[0153] The third step is to determine the target picture identifier according to the offset between the target longitude and latitude and the key frame longitude and latitude corresponding to the key frame in the target picture group.

[0154] The third step is to determine the target spatial picture and the key frames in the target picture group to which the target spatial picture belongs, and position information in the encoded file according to the target picture group identifier and the target picture identifier.

[0155] The fifth step is to determine, based on the target picture identifier, whether the target spatial picture is a key frame in the target picture group or a predicted frame in the target picture group.

[0156] In the sixth step, in response to determining that the target spatial picture is a predicted frame in the target picture group, the key frame in the target picture group at the position represented by the position information and the predicted frame corresponding to the target picture identifier are decoded to obtain the target spatial picture.

[0157] In the seventh step, in response to determining that the target spatial picture is a key frame in the target picture group, the key frame in the target picture group at the position represented by the position information is decoded to obtain the target spatial picture.

[0158] It can be seen from this embodiment that compared with the embodiment of the above-mentioned decoding method, the process of the decoding method applicable to spatial pictures in this embodiment specifically describes the process of determining the position information and the decoding process of the target spatial picture, further improving the efficiency and flexibility of the decoding process of the spatial picture.

[0159] Continuing to refer to FIG12 , as an implementation of the methods shown in the above figures, the present disclosure provides an embodiment of an encoding device suitable for spatial images. The device embodiment corresponds to the method embodiment shown in FIG2 , and the device can be specifically applied to various electronic devices.

[0160] As shown in Figure 12, the encoding device suitable for spatial images includes: a first generation unit 1201, configured to generate a spatial picture matrix including multiple spatial pictures collected by multiple sampling points according to the longitude and latitude corresponding to the multiple sampling points at different spatial angles; a determination unit 1202, configured to determine the target size of the sub-matrix corresponding to different areas in the spatial picture matrix according to the degree of change between adjacent spatial pictures in the spatial picture matrix; a division unit 1203, configured to divide the spatial picture matrix with the sub-matrices corresponding to different areas in the spatial picture matrix to obtain multiple picture groups; a second generation unit 1204, configured to encode the spatial pictures in the spatial picture matrix according to the key frames and prediction frames included in each of the multiple picture groups to generate an encoded file.

[0161] In some optional implementations of this embodiment, the above-mentioned determination unit 1202 is further configured to: determine the target size of the sub-matrix corresponding to different areas in the spatial picture matrix based on the negative correlation between the degree of change between adjacent spatial pictures in the spatial picture matrix and the target size of the sub-matrix.

[0162] In some optional implementations of this embodiment, adjacent sampling points among the above-mentioned multiple sampling points are arranged at preset degree intervals in the longitude direction and the latitude direction, and the above-mentioned determination unit 1202 is further configured to: in response to determining that the degree of change between adjacent spatial pictures in the latitude direction in the spatial picture matrix is ​​greater than the degree of change between adjacent spatial pictures in the longitude direction, determine that the length of the submatrix is ​​greater than the width, wherein the length direction of the submatrix corresponds to the longitude direction of the sampling point, and the width direction of the submatrix corresponds to the latitude direction of the sampling point; in response to determining that the degree of change between adjacent spatial pictures in the longitude direction in the spatial picture matrix is ​​negatively correlated with the latitude value, determine that the length of the submatrix is ​​positively correlated with the latitude value; based on the fact that the length of the submatrix is ​​greater than the width, and the positive correlation between the length of the submatrix and the latitude value, determine the target size of the submatrix in different areas of the spatial picture matrix.

[0163] In some optional implementations of this embodiment, the above-mentioned first generation unit is further configured to: arrange multiple spatial pictures with the longitude of the sampling point corresponding to the spatial picture as the horizontal axis and the latitude of the sampling point corresponding to the spatial picture as the vertical axis to generate a spatial picture matrix.

[0164] In some optional implementations of this embodiment, the above-mentioned second generation unit 1201 is further configured to: arrange the picture groups corresponding to the sampling points at the same latitude in multiple picture groups in order of the longitudes of the sampling points corresponding to the picture groups from small to large, and generate multiple picture group subsequences; arrange the multiple picture group subsequences in order of the latitudes of the sampling points corresponding to the picture groups from small to large, determine the picture group identifiers corresponding to each of the multiple picture groups, and generate a picture group sequence; arrange the spatial pictures in each picture group in the picture group sequence in the order of key frames first and predicted frames later, determine the picture identifiers of the spatial pictures in each picture group in the multiple picture groups, and generate a spatial picture sequence; encode the spatial picture sequence according to the key frames and predicted frames included in each of the multiple picture groups to generate an encoded file.

[0165] In some optional implementations of this embodiment, the above-mentioned second generation unit 1204 is further configured to: determine the spatial picture at the center position in the submatrix corresponding to each of the multiple picture groups as the initial key frame; for each picture group in the multiple picture groups, based on the initial key frame of the picture group, determine the key frame of the picture group from the direction in which the sampling points corresponding to the spatial picture in the picture group are sparser, and determine the predicted frame adjacent to the key frame; arrange the spatial pictures in each picture group in the picture group sequence in the order of key frame first and predicted frame later, determine the picture identifier of the spatial picture in each picture group in the multiple picture groups, and generate a spatial picture sequence.

[0166] In some optional implementations of this embodiment, the above-mentioned second generation unit 1204 is further configured to: for each picture group in multiple picture groups, use a reference method in which the predicted frame in the picture group uniquely refers to the key frame in the picture group to encode the spatial picture sequence and generate an encoded file.

[0167] In this embodiment, a first generation unit in an encoding device suitable for spatial images generates a spatial picture matrix including multiple spatial pictures collected by multiple sampling points according to the longitude and latitude corresponding to multiple sampling points at different spatial angles; a determination unit determines the target size of the sub-matrix corresponding to different areas in the spatial picture matrix according to the degree of change between adjacent spatial pictures in the spatial picture matrix; a division unit divides the spatial picture matrix with the sub-matrices corresponding to different areas in the spatial picture matrix to obtain multiple picture groups; a second generation unit encodes the spatial pictures in the spatial picture matrix according to the key frames and prediction frames included in each of the multiple picture groups to generate an encoding file, thereby providing an encoding method suitable for spatial pictures. During the encoding process, the spatial pictures are reorganized to obtain the spatial picture matrix, and the picture groups in the spatial picture matrix are specified to manage the spatial pictures in the picture groups and realize the temporal decoupling of the spatial pictures; and the spatial distribution characteristics of the spatial pictures are utilized to determine the picture group encoding structure, thereby improving the compression efficiency of the encoding process, helping to improve the decoding efficiency, and reducing the memory usage of the decoding process.

[0168] Referring now to FIG13 , a schematic diagram illustrating the structure of a computer system 1300 suitable for implementing devices (e.g., devices 101, 102, 103, and 105 shown in FIG1 ) according to an embodiment of the present disclosure is shown. The device shown in FIG13 is merely an example and should not limit the functionality or scope of use of the embodiments of the present disclosure.

[0169] As shown in FIG13 , a computer system 1300 includes a processor (e.g., a CPU, central processing unit) 1301, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 1302 or a program loaded from a storage unit 1308 into a random access memory (RAM) 1303. Various programs and data required for the operation of the system 1300 are also stored in the RAM 1303. The processor 1301, the ROM 1302, and the RAM 1303 are connected to each other via a bus 1304. An input / output (I / O) interface 1305 is also connected to the bus 1304.

[0170] The following components are connected to the I / O interface 1305: an input section 1306 including a keyboard, a mouse, and the like; an output section 1307 including devices such as a cathode ray tube (CRT), a liquid crystal display (LCD), and speakers; a storage section 1308 including a hard disk; and a communication section 1309 including a network interface card such as a LAN card or a modem. The communication section 1309 performs communication processing via a network such as the Internet. A drive 1310 is also connected to the I / O interface 1305 as needed. Removable media 1311, such as a magnetic disk, an optical disk, a magneto-optical disk, or a semiconductor memory, is installed in the drive 1310 as needed, so that computer programs read therefrom can be installed into the storage section 1308 as needed.

[0171] In particular, according to an embodiment of the present disclosure, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present disclosure includes a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network via the communication section 1309 and / or installed from a removable medium 1311. When the computer program is executed by the processor 1301, the above-mentioned functions defined in the method of the present disclosure are performed.

[0172] It should be noted that the computer-readable medium of the present disclosure may be a computer-readable signal medium or a computer-readable storage medium, or any combination thereof. A computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or component, or any combination thereof. More specific examples of computer-readable storage media may include, but are not limited to, an electrical connection having one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination thereof. In the present disclosure, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, device, or component. In the present disclosure, a computer-readable signal medium may include a data signal propagated in baseband or as part of a carrier wave, which carries computer-readable program code. This propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. A computer-readable signal medium may also be any computer-readable medium other than a computer-readable storage medium that can transmit, propagate, or transport a program for use by or in conjunction with an instruction execution system, apparatus, or device. Program code embodied on a computer-readable medium may be transmitted using any suitable medium, including but not limited to wireless, wireline, optical fiber cable, RF, or any suitable combination thereof.

[0173] Computer program code for performing the operations of the present disclosure may be written in one or more programming languages, or a combination thereof, including object-oriented programming languages ​​such as Java, Smalltalk, C++, and conventional procedural programming languages ​​such as "C" or similar programming languages. The program code may be executed entirely on the client computer, partially on the client computer, as a stand-alone software package, partially on the client computer and partially on a remote computer, or entirely on the remote computer or server. In cases involving a remote computer, the remote computer may be connected to the client computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., through the Internet using an Internet service provider).

[0174] The flowcharts and block diagrams in the accompanying drawings illustrate the possible implementation architecture, functions and operations of the devices, methods and computer program products according to various embodiments of the present disclosure. In this regard, each box in the flowchart or block diagram can represent a module, program segment, or a part of code, and the module, program segment, or a part of code contains one or more executable instructions for implementing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order than that marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or flowchart, and the combination of the boxes in the block diagram and / or flowchart, can be implemented with a dedicated hardware-based system that performs the specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0175] The units involved in the embodiments described in the present disclosure may be implemented by software or by hardware. The described units may also be provided in a processor, for example, may be described as: a processor comprising a first generating unit, a determining unit, a dividing unit, and a second generating unit. Among them, the names of these units do not constitute a limitation on the unit itself under certain circumstances. For example, the determining unit may also be described as "a unit for determining the target size of the submatrix corresponding to different regions in the spatial picture matrix according to the degree of change between adjacent spatial pictures in the spatial picture matrix."

[0176] As another aspect, the present disclosure further provides a computer-readable medium, which may be included in the device described in the above embodiment; or it may exist independently and not be assembled into the device. The above computer-readable medium carries one or more programs. When the above one or more programs are executed by the device, the computer device: generates a spatial picture matrix including multiple spatial pictures collected by multiple sampling points according to the longitude and latitude corresponding to multiple sampling points at different spatial angles; determines the target size of the submatrix corresponding to different areas in the spatial picture matrix according to the degree of change between adjacent spatial pictures in the spatial picture matrix; divides the spatial picture matrix according to the submatrices corresponding to different areas in the spatial picture matrix to obtain multiple picture groups; encodes the spatial pictures in the spatial picture matrix according to the key frames and predicted frames included in each of the multiple picture groups to generate an encoded file.

[0177] The above description is merely a preferred embodiment of the present disclosure and an illustration of the technical principles employed. Those skilled in the art should understand that the scope of the invention involved in the present disclosure is not limited to the technical solutions formed by the specific combination of the above-mentioned technical features, but also encompasses other technical solutions formed by any combination of the above-mentioned technical features or their equivalents without departing from the above-mentioned inventive concept. For example, a technical solution formed by replacing the above-mentioned features with (but not limited to) technical features with similar functions disclosed in this disclosure.

Claims

1. A coding method applicable to a spatial image, comprising: Generate a spatial picture matrix including a plurality of spatial pictures collected by the plurality of sampling points according to the longitudes and latitudes corresponding to the plurality of sampling points at different spatial angles; Determining target sizes of sub-matrices corresponding to different regions in the spatial picture matrix according to a degree of change between adjacent spatial pictures in the spatial picture matrix; Dividing the spatial picture matrix by sub-matrices corresponding to different regions in the spatial picture matrix to obtain a plurality of picture groups; According to the key frames and the predicted frames respectively included in the multiple picture groups, the spatial pictures in the spatial picture matrix are encoded to generate an encoded file.

2. The method according to claim 1, wherein: The determining, according to the degree of change between adjacent spatial pictures in the spatial picture matrix, target sizes of sub-matrices corresponding to different regions in the spatial picture matrix includes: Based on the negative correlation between the degree of change between adjacent spatial pictures in the spatial picture matrix and the target size of the sub-matrix, the target size of the sub-matrix corresponding to different areas in the spatial picture matrix is ​​determined.

3. The method according to claim 2, wherein: Adjacent sampling points among the plurality of sampling points are arranged at preset intervals in the longitude direction and the latitude direction, and The determining, based on a negative correlation between a degree of change between adjacent spatial pictures in the spatial picture matrix and a target size of a submatrix, target sizes of submatrices corresponding to different regions in the spatial picture matrix comprises: In response to determining that the degree of change between adjacent spatial pictures in the latitude direction in the spatial picture matrix is ​​greater than the degree of change between adjacent spatial pictures in the longitude direction, determining that the length of the submatrix is ​​greater than the width, wherein the length direction of the submatrix corresponds to the longitude direction of the sampling point, and the width direction of the submatrix corresponds to the latitude direction of the sampling point; In response to determining that the degree of change between adjacent spatial images in the longitude direction in the spatial image matrix is ​​negatively correlated with the latitude value, determining the length of the submatrix and the latitude value. There is a positive correlation between Based on the fact that the length of the sub-matrix is ​​greater than the width and the positive correlation between the length of the sub-matrix and the latitude value, target sizes of the sub-matrices in different regions of the spatial picture matrix are determined.

4. The method according to claim 1, wherein: The step of generating a spatial picture matrix including a plurality of spatial pictures collected by the plurality of sampling points according to the longitudes and latitudes corresponding to the plurality of sampling points at different spatial angles comprises: The plurality of spatial pictures are arranged with the longitude of the sampling point corresponding to the spatial picture as the horizontal axis and the latitude of the sampling point corresponding to the spatial picture as the vertical axis to generate the spatial picture matrix.

5. The method according to claim 1, wherein: The step of encoding the spatial pictures in the spatial picture matrix according to the key frames and the predicted frames respectively included in the plurality of picture groups to generate a coded file comprises: Arrange the picture groups corresponding to the sampling points at the same latitude in the multiple picture groups in ascending order of the longitudes of the sampling points corresponding to the picture groups, to generate multiple picture group subsequences; Arrange the plurality of picture group subsequences in ascending order of latitudes of sampling points corresponding to the picture groups, determine picture group identifiers corresponding to the plurality of picture groups, and generate a picture group sequence; Arrange the spatial pictures in each picture group in the picture group sequence in the order of key frames first and predicted frames later, determine the picture identifier of the spatial picture in each picture group in the plurality of picture groups, and generate a spatial picture sequence; The spatial picture sequence is encoded according to the key frames and the predicted frames respectively included in the multiple picture groups to generate the encoded file.

6. The method according to claim 5, wherein: The step of arranging the spatial pictures in each picture group in the picture group sequence in the order of key frames first and predicted frames later, determining the picture identifier of the spatial pictures in each picture group in the plurality of picture groups, and generating the spatial picture sequence comprises: Determine a spatial picture at a center position in a submatrix corresponding to each of the plurality of picture groups as an initial key frame; For each of the plurality of picture groups, based on an initial key frame of the picture group, determining a key frame of the picture group in a direction in which sampling points corresponding to spatial pictures in the picture group are more sparse, and determining a prediction frame adjacent to the key frame; The spatial pictures in each picture group in the picture group sequence are arranged in the order of key frames first and predicted frames later, the picture identifiers of the spatial pictures in each picture group in the multiple picture groups are determined, and the spatial picture sequence is generated.

7. The method according to claim 5 or 6, wherein: The step of encoding the spatial picture sequence according to the key frames and the predicted frames respectively included in the plurality of picture groups to generate the encoded file comprises: For each picture group in the multiple picture groups, the spatial picture sequence is encoded in a reference manner in which a predicted frame in the picture group uniquely refers to a key frame in the picture group to generate the encoded file.

8. A coding device for a spatial image, comprising: A first generating unit is configured to generate a spatial picture matrix including a plurality of spatial pictures collected by the plurality of sampling points according to the longitudes and latitudes corresponding to the plurality of sampling points at different spatial angles; a determining unit configured to determine target sizes of sub-matrices corresponding to different regions in the spatial picture matrix according to a degree of change between adjacent spatial pictures in the spatial picture matrix; a dividing unit, configured to divide the spatial picture matrix into sub-matrices corresponding to different regions in the spatial picture matrix to obtain a plurality of picture groups; The second generating unit is configured to encode the spatial pictures in the spatial picture matrix according to the key frames and the predicted frames respectively included in the plurality of picture groups, and generate an encoded file.

9. The encoding device according to claim 8, wherein: The determining unit is further configured to: Based on the degree of change between adjacent spatial pictures in the spatial picture matrix, and the sub-matrix The negative correlation between the target sizes of the sub-matrices in the spatial picture matrix is ​​used to determine the target sizes of the sub-matrices corresponding to different areas in the spatial picture matrix.

10. The encoding device according to claim 8, wherein: Adjacent sampling points among the plurality of sampling points are arranged at preset intervals in the longitude direction and the latitude direction, and The determining unit is further configured to: in response to determining that the degree of change between adjacent spatial pictures in the latitude direction in the spatial picture matrix is ​​greater than the degree of change between adjacent spatial pictures in the longitude direction, determine that the length of the submatrix is ​​greater than the width, wherein the length direction of the submatrix corresponds to the longitude direction of the sampling point, and the width direction of the submatrix corresponds to the latitude direction of the sampling point; In response to determining that a degree of change between adjacent spatial images in the longitude direction in the spatial image matrix is ​​negatively correlated with the latitude value, determining that a length of the submatrix is ​​positively correlated with the latitude value; Based on the fact that the length of the sub-matrix is ​​greater than the width and the positive correlation between the length of the sub-matrix and the latitude value, target sizes of the sub-matrices in different regions of the spatial picture matrix are determined.

11. The encoding device according to claim 8, wherein: The first generating unit is further configured to: The plurality of spatial pictures are arranged with the longitude of the sampling point corresponding to the spatial picture as the horizontal axis and the latitude of the sampling point corresponding to the spatial picture as the vertical axis to generate the spatial picture matrix.

12. The encoding device according to claim 8, wherein: The second generating unit is further configured to: Arrange the picture groups corresponding to the sampling points at the same latitude in the multiple picture groups in ascending order of the longitudes of the sampling points corresponding to the picture groups, to generate multiple picture group subsequences; Arrange the plurality of picture group subsequences in ascending order of latitudes of sampling points corresponding to the picture groups, determine picture group identifiers corresponding to the plurality of picture groups, and generate a picture group sequence; Arrange the spatial pictures in each picture group in the picture group sequence in the order of key frames first and predicted frames later, and determine the spatial pictures in each picture group in the plurality of picture groups. Image identification of the film, generating a spatial image sequence; The spatial picture sequence is encoded according to the key frames and the predicted frames respectively included in the multiple picture groups to generate the encoded file.

13. The encoding device according to claim 12, wherein: The second generating unit is further configured to: Determine a spatial picture at a center position in a submatrix corresponding to each of the plurality of picture groups as an initial key frame; For each of the plurality of picture groups, based on an initial key frame of the picture group, determining a key frame of the picture group in a direction in which sampling points corresponding to spatial pictures in the picture group are more sparse, and determining a prediction frame adjacent to the key frame; The spatial pictures in each picture group in the picture group sequence are arranged in the order of key frames first and predicted frames later, the picture identifiers of the spatial pictures in each picture group in the multiple picture groups are determined, and the spatial picture sequence is generated.

14. The encoding device according to claim 12 or 13, wherein: The second generating unit is further configured to: For each picture group in the multiple picture groups, the spatial picture sequence is encoded in a reference manner in which a predicted frame in the picture group uniquely refers to a key frame in the picture group to generate the encoded file.

15. A non-transitory computer readable medium having a computer program stored thereon, wherein: When the program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.

16. An electronic device comprising: one or more processors; a storage device having one or more programs stored thereon, When the one or more programs are executed by the one or more processors, the one or more processors implement the method according to any one of claims 1 to 7.

Citation Information

Patent Citations

  • Virtual reality compression method based on positions

    CN107197285A

  • Video scene similarity analysis method and system and video coding and decoding method and system

    CN107657228A

  • Adaptive frame packing for 360-degree video coding

    CN111602401A

  • Coding method and device suitable for space image

    CN116527936A

  • Solid image compression device and solid image extension device

    JP2004336104A