A compression method, compression device and monitoring system for encoded video data

By re-encoding the encoded video data and triggering intelligent event detection, the problem of sacrificing quality in existing video data compression methods is solved, achieving the effect of reducing video data size without reducing video quality, and is suitable for video data processing in monitoring systems.

CN115708352BActive Publication Date: 2026-07-24HANGZHOU EZVIZ SOFTWARE CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
HANGZHOU EZVIZ SOFTWARE CO LTD
Filing Date
2021-08-18
Publication Date
2026-07-24

Smart Images

  • Figure CN115708352B_ABST
    Figure CN115708352B_ABST
Patent Text Reader

Abstract

The application discloses a compression method of encoded video data, which comprises the following steps: extracting at least one first enhancement layer video frame from first encoded video data; re-encoding the first enhancement layer video frame to obtain a second enhancement layer video frame; and taking the second enhancement layer video frame and a base layer video frame in the first video data as second compressed video data, wherein the first video data is scalable video coding data. The compression method of the application does not change the structure of the video data before and after compression, retains the real-time and continuity of the video data, is compatible with the frame rate stability requirements of various players, and reduces the capacity of the video data without losing the video data information.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of video data processing, and in particular, to a method for compressing encoded video data. Background Technology

[0002] To reduce the size of video data, raw video data from image acquisition devices usually needs to be encoded to form encoded video data.

[0003] Take the internationally recognized H.264 and H.265 standards as examples. Both H.264 and H.265 employ a combination of intra-frame coding and inter-frame coding.

[0004] During intra-frame coding, the input video frame is divided into multiple macroblocks according to texture complexity. The intra-frame predicted nearest neighbor macroblock is searched for each macroblock. The difference between this macroblock and the searched macroblock is then converted to the frequency domain, followed by quantization and entropy coding to form the compressed video frame format data, i.e., an I-frame. Higher image texture complexity results in finer macroblock division, thus generating more difference data, leading to a relatively larger amount of video data after quantization and compression.

[0005] During inter-frame coding, the input video frame is divided into multiple macroblocks according to certain principles. For each macroblock, similar macroblocks are searched in the region near the reference frame. The coordinates of the searched macroblocks are mapped to motion vectors in the horizontal and vertical directions. The motion vectors are then converted into frequency domain data. After quantization and entropy coding, the data in the format of the predicted frame after video compression, i.e., P-frame, is formed.

[0006] Even after encoding, video data still consumes a lot of hardware resources during subsequent storage and / or transmission. For example, video data in surveillance applications needs to be stored for later retrieval, which requires a lot of storage space. Therefore, compressing the encoded video data becomes a necessity.

[0007] Existing technologies for compressing video data fall into two main categories:

[0008] One type involves dynamically adjusting parameters such as video frame bitrate, frame rate, and refresh frame interval based on the degree of motion of the target in the video frame, in order to reduce the image quality data during non-motion periods and thus compress the video data.

[0009] Another approach involves spatially increasing the quantization step size factor in non-moving regions of a video frame to reduce the image quality data in these regions, thereby compressing the video data.

[0010] Both of the above-mentioned video data compression methods achieve video data compression at the cost of sacrificing image quality unrelated to motion content. This compression method results in the loss of information in the video data and is not suitable for application scenarios with high requirements for video data quality. Summary of the Invention

[0011] This invention provides a method for compressing encoded video data to reduce video data size while maintaining video data quality.

[0012] The method for compressing encoded video data provided by this invention is implemented as follows:

[0013] Extract at least one first enhancement layer video frame from the encoded first video data.

[0014] The first enhancement layer video frames are re-encoded to obtain the second enhancement layer video frames.

[0015] The second enhancement layer video frames and the base layer video frames from the first video data are used as the compressed second video data.

[0016] in,

[0017] The first video data is scalable video encoded data.

[0018] Preferably, the re-encoding of the first enhancement layer video frame includes,

[0019] After stripping macroblock data and syntax data from the video frames of the first enhancement layer,

[0020] The macroblock data in the first enhancement layer video frame is encoded in copy mode.

[0021] The macroblock data encoded in copy mode is fused with the syntax data to form a video frame, resulting in a second enhancement layer video frame.

[0022] Preferably, the method further includes,

[0023] Detect trigger events,

[0024] When a trigger event is detected and is valid, the current first video data is stored and / or transmitted until the trigger event becomes invalid.

[0025] When no triggering event is detected or the triggering event is invalid, the step of extracting at least one first enhancement layer video frame from the encoded first video data is performed, and the second enhancement layer video frame and the basic layer video frame in the first video data are stored and / or transmitted.

[0026] Preferably, the encoded first video data is surveillance video data, and the encoded first video data is cached according to a video caching mechanism.

[0027] When a triggering event is detected and is valid, the current first video data is stored and / or transmitted until the triggering event becomes invalid, including:

[0028] When a first triggering event is detected to identify the start of the triggering event, the first video data cached within the time range set before the current first triggering event, as well as the currently cached first video data, are stored and / or transmitted until a second triggering event is detected to identify the end of the triggering event.

[0029] The step of extracting at least one first enhancement layer video frame from the encoded first video data when no trigger event is detected or the trigger event is invalid includes:

[0030] If no first triggering event is detected to identify the start of the triggering event or a second triggering event is detected to identify the end of the triggering event, then for all cached first video data, the step of extracting at least one first enhancement layer video frame from the encoded first video data is performed.

[0031] Preferably, the detection trigger event includes,

[0032] Using an intelligent detection mechanism, it is determined whether the target in the current first video data meets the set expectations;

[0033] in,

[0034] The set expectations include the target's movement, trajectory, posture, behavior, time, events, space, or any combination thereof.

[0035] Preferably, the extraction of at least one first enhancement layer video frame from the encoded first video data includes,

[0036] The reference markers in the syntax data of the first video data are analyzed. Based on the reference markers, the predictive coding relationship of the current video frame is generated. Based on this relationship, it is determined whether the current video frame is a first enhancement layer video frame.

[0037] If so, then extract the video frame of the first enhancement layer.

[0038] Otherwise, it is determined to be a basic layer video frame.

[0039] Preferably, the stripping of macroblock data and syntactic data from the first enhancement layer video frame includes,

[0040] According to the grammatical standard of the video standard conforming to the first video data, macroblock data and grammatical data are extracted from the first enhancement layer video frames to obtain macroblock data and grammatical data respectively.

[0041] The copy mode encoding of macroblock data in the first enhancement layer video frame includes,

[0042] If the first video data conforms to the H.264 standard, then it is encoded in block copy mode on a macroblock basis.

[0043] If the first video data conforms to the H.265 standard, then copy mode encoding is performed on a unit-by-unit basis.

[0044] This application also provides a compression apparatus for encoded video data, the compression apparatus including a memory and a processor, the memory storing a computer program, the processor being configured to execute the computer program to implement the steps of any of the compression methods for encoded video data as described in claims 1 to 7.

[0045] This application further provides a monitoring system, which includes an image acquisition device and a background device for processing encoded first video data from the image acquisition device. The background device includes a processor and a memory, the memory storing a computer program, and the processor being configured to execute the steps of the computer program to implement any of the compression methods for the encoded video data.

[0046] This application also provides an image acquisition device, which includes a memory and a processor. The memory stores a computer program, and the processor is configured to execute the computer program to implement any of the compression methods for the encoded first video data from the image acquisition device.

[0047] This application provides a method for compressing encoded video data. By re-encoding at least one frame of the first enhancement layer video data, the real-time performance and continuity of the video data are preserved since the video data structure remains unchanged before and after compression. This method is compatible with the frame rate stability requirements of various players and reduces the video data size without losing video data information. Furthermore, by using intelligent detection to generate trigger events, the video data is divided into trigger time periods and non-trigger time periods. Video data in non-trigger time periods is re-encoded, while video data in trigger time periods is not re-encoded. This ensures that the video data information required by the business is preserved, thus reducing the video data size while maintaining video data quality. Attached Figure Description

[0048] Figure 1A schematic diagram of the compression method for encoded video data in this application.

[0049] Figure 2 This is a schematic diagram illustrating the storage of the first video data encoded in Example 1.

[0050] Figure 3 This is a schematic diagram of a format for real-time SVC video data.

[0051] Figure 4 This is a schematic diagram of a first video data format and a second video data format.

[0052] Figure 5 This is a schematic diagram illustrating how encoded video data is compressed and transmitted on the image acquisition device side in Embodiment 2.

[0053] Figure 6 This is a schematic diagram illustrating, in Embodiment 3, the compressed encoded video data on the image acquisition device side for storage and / or transmission.

[0054] Figure 7 This is a schematic diagram of a monitoring system.

[0055] Figure 8 This is a schematic diagram of an image acquisition device.

[0056] Figure 9 This is a schematic diagram of an image acquisition device or a back-end device in a monitoring system. Detailed Implementation

[0057] To make the objectives, technical means, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings.

[0058] This application reduces the size of the video data by re-encoding the enhancement layer video frames in the encoded video data and using the re-encoded enhancement layer video frames and the base layer video frames in the encoded video data as compressed video data, without losing any information in the video data.

[0059] See Figure 1 As shown, Figure 1 This is a schematic diagram of a compression method for the encoded video data described in this application. The method includes:

[0060] Step 101: Extract at least one first enhancement layer video frame from the encoded first video data.

[0061] Preferably, all first enhancement layer video frames in the first video data are extracted.

[0062] The first video data is Scalable video coding (SVC) data.

[0063] Step 102: Re-encode the first enhancement layer video frame to obtain the second enhancement layer video frame.

[0064] Re-encoding includes:

[0065] After stripping macroblock data and syntax data from the video frames of the first enhancement layer,

[0066] The macroblock data in the first enhancement layer video frame is encoded in copy mode.

[0067] The macroblock data encoded in copy mode is fused with the syntax data to form a video frame, resulting in a second enhancement layer video frame.

[0068] Step 103: Use the second enhancement layer video frames and the base layer video frames from the first video data as the compressed second video data.

[0069] When the re-encoded video data is used for local storage, this invention helps to increase the video duration per unit storage space, significantly reduce the total storage space for video duration, and substantially reduce local storage, thus saving storage costs and meeting the selective compression requirements of the surveillance industry for video storage. When applied to network storage, it can reduce the transmission bandwidth pressure for uploading, storage, and playback, enhance the stability of network video data, and reduce network storage space.

[0070] Example 1

[0071] To facilitate understanding of this application, the following explanation uses the storage of surveillance video data as an example. See [link to relevant documentation]. Figure 2 As shown, Figure 2 A schematic diagram illustrating the storage of the encoded first video data.

[0072] Step 201: The encoded first video data from the image acquisition device is buffered in real time.

[0073] Since surveillance video data typically needs to provide information within a set time range prior to a triggered event, such as information within 4-10 seconds before a trigger event, in order to form a complete information chain of the event, a video buffering mechanism is adopted for delayed storage and processing of the video.

[0074] Furthermore, by utilizing the triggering events of the intelligent detection mechanism, the pre-recording function of the triggered events can be realized. By using the cached first video data, the integrity of the pre-recording of the triggered events can be effectively guaranteed.

[0075] in,

[0076] The first video data is SVC video data, which can be transmitted from a local image acquisition device via an intranet such as a local area network, or it can be transmitted from a network image acquisition device via an external network.

[0077] See Figure 3 As shown, Figure 3 This is a schematic diagram of a format for real-time SVC video data. Each video frame consists of two parts: a base layer video frame (B) and an enhancement layer video frame (S). These two parts combine to generate a full-resolution image. The enhancement layer video frame is typically 1.5 or 2 times the base resolution in both the horizontal and vertical directions. This facilitates spatially scalable encoding of videos with different resolutions, such as VGA and QVGA (ratio 2) and 1080p and 720p (ratio 1.5), both of which can be spatially scalable encoded. Spatial scalability can be combined with temporal scalability (and SNR) in a completely independent manner.

[0078] Step 202: Determine whether a triggering event has been detected and whether the triggering event is valid.

[0079] When a trigger event is detected and the trigger event is valid, the first video data currently cached is directly written to the storage medium, such as a hard drive or memory card, until the trigger event becomes invalid.

[0080] To meet the business requirements for monitoring data and form a complete chain of event information, it is preferable to search for the first video data within a set time range before the first video data currently cached in the cache area, and then directly write the first video data into the storage medium.

[0081] If no triggering event is detected or the triggering event is invalid, proceed to step 203 to process the cached first video data.

[0082] in,

[0083] The triggering event is the result of the intelligent target trigger judgment, which can be obtained through the intelligent detection mechanism. Intelligent detection uses computer image vision analysis technology to detect whether the target in the current first video data meets the set expectations, thereby automatically filtering out various invalid and interfering images, such as swaying leaves and random noise from the sensor;

[0084] The set expectations can be determined according to business needs, including target movement, trajectory, posture, behavior, time, event, space associated with the target, or any combination thereof. Thus, trigger events can be diverse, such as alarm start and alarm end events obtained from video content analysis, or target movement start and target movement end events obtained from motion recognition of video content. Specifically, for example, the appearance of a pedestrian or vehicle crossing a certain area in the frame can be set as a trigger event. More specifically, when a pedestrian or vehicle enters a certain area in the frame, it is a target movement start event; when the pedestrian or vehicle leaves that area in the frame, it is a target movement end event.

[0085] The validity of a trigger event can be marked by a first trigger event that identifies the start of the trigger event and a first trigger event that identifies the end of the trigger event. Using the validity of trigger events, the currently cached video data can be distinguished between trigger time periods and non-trigger time periods. For example, using alarm start and alarm end events, the valid time period for the duration of an alarm event can be determined; this time period is the trigger time period.

[0086] Step 203: Re-encode the cached first video data.

[0087] Since the original video frames from the image acquisition device have already undergone one encoding process, the re-encoding of the first video data at this point is equivalent to a second encoding.

[0088] In a single video frame, the moving area typically does not occupy the entire frame relative to the reference frame, especially in scenarios where the image acquisition device is fixed and the background information is usually static. Factors causing changes in the image usually include sensor random noise, leaves swaying in place, etc., which manifest as slight motion changes in parts of the video frame. Therefore, the static areas of the image in each video frame contain a large amount of identical information.

[0089] In typical video coding modes, motion residual information between two video frames is written into the bitstream. During decoding, the decoder regenerates the current macroblock based on the reference frame and the motion vector prediction residual to form the current motion video frame. This residual data is often the largest component of inter-frame coding storage. However, copy mode coding does not include inter-frame motion vector prediction residual data. Instead, it uses the corresponding macroblock of the reference frame as the motion vector prediction for the video frame. In copy mode coding, the macroblock corresponding to the reference macroblock in the reference frame is marked to indicate that the inter-frame motion prediction residual is zero. In this way, storing the marking information that indicates the reference macroblock can significantly reduce the data size after frame compression.

[0090] Therefore, when re-encoding, the video frames of the enhancement layer are encoded in copy mode.

[0091] The specific re-encoding process is as follows:

[0092] To determine whether a video frame is an enhancement layer video frame, for example, the reference markers in the syntax data of the first video data are analyzed. Based on the reference markers, a predictive coding relation for the current video frame is generated (this relation is also used for decoding). Based on this relation, it is determined whether the current video frame is an enhancement layer video frame.

[0093] If it is an enhancement layer video frame, then

[0094] According to the syntax standard of the video standard (e.g., H.264 or H.265) that the first video data conforms to, the payload data in the video frame is stripped to obtain the payload data and syntax data respectively, wherein the payload data is macroblock data;

[0095] All payload data of the video frame is encoded in copy mode. That is, macroblocks in the macroblock data that are consistent with macroblock data in the reference frame are identified to obtain macroblock data after copy mode encoding. If the first video data is H264 standard, copy mode encoding is performed on a macroblock basis. If the first video data is H265 standard, copy mode encoding is performed on a coding unit basis.

[0096] The macroblock data and syntax data encoded in copy mode are merged into a video frame, thus forming a new enhancement layer video frame, resulting in a second enhancement layer video frame, which is then written to the storage medium.

[0097] In this way, the stored enhancement layer video frame data only contains syntax data, while the payload data uses a copy-skip mode to reference the reference frame.

[0098] If it is a base layer video frame, then the base layer video frame is written directly to the storage medium.

[0099] Thus, the compressed first video data includes the second enhancement layer video frames and the base layer video frames, which are referred to as the second video data for ease of description.

[0100] See Figure 4 As shown in the figure, a represents the first video data format, and b represents the second video data format.

[0101] This embodiment performs real-time secondary processing on video data without disrupting the existing storage mechanism. Since the video data structure remains unchanged before and after compression, it preserves the real-time nature and continuity of the video data while retaining the advantages of SVC data, thus meeting the frame rate stability requirements of various players. By using trigger events to distinguish real-time video data into trigger time periods and non-trigger time periods, different strategies are adopted to process the cached video data in different time periods. This approach avoids losing information in the video data while significantly reducing storage space. Simultaneously, it achieves the function of pre-recording video while reducing the cache space used for delayed storage.

[0102] Example 2

[0103] In this embodiment, the encoded video data from the image acquisition device is compressed for transmission.

[0104] See Figure 5 As shown, Figure 5 This is a schematic diagram illustrating how encoded video data is compressed and transmitted on the image acquisition device side in this second embodiment.

[0105] Step 501: The image acquisition device acquires the raw video data and encodes it to obtain the encoded first video data.

[0106] The first video data is an SVC format video stream, including base layer video frames and enhancement layer video frames;

[0107] Step 502: Determine whether a trigger event has been detected.

[0108] If a trigger event is detected and remains valid, the current first video data will be passed through continuously until the trigger event becomes invalid, for example, when the trigger event ends.

[0109] If no triggering event is detected or the triggering event is invalid, proceed to step 503.

[0110] Step 503: Extract all enhancement layer video frames from the current first video data.

[0111] In this step, the reference markers in the syntax data of the first video data are analyzed, and the predictive coding relationship of the current video frame is generated based on the reference markers. The enhancement layer video frame is then determined based on this relationship.

[0112] Step 504: For each extracted enhancement layer video frame, extract the macroblock data from that enhancement layer video frame.

[0113] In this step, according to the syntax standard of the video standard (e.g., H.264 or H.265) conforming to the first video data, the payload data in the video frame is stripped to obtain the payload data and syntax data respectively. The payload data is macroblock data.

[0114] Step 505: Perform replication mode encoding on the macroblock data to obtain replication mode encoded macroblock data.

[0115] Step 506: The macroblock data encoded in copy mode is fused with the syntax data of the video frame to form a video frame, resulting in the second enhancement layer video frame.

[0116] Step 507: Repeat steps 504-506 until every video frame of the enhancement layer has been re-encoded.

[0117] Step 508: Encapsulate the current base layer video frame and the second enhancement layer video frame into second video data and transmit it.

[0118] Step 509: Repeat steps 503-508 until a trigger condition is detected.

[0119] This embodiment significantly reduces the size of the first video data through re-encoding, while not losing video data information, reducing the bandwidth occupied by video data transmission, and improving the real-time performance and transmission efficiency.

[0120] Example 3

[0121] See Figure 6 As shown, Figure 6 This is a schematic diagram illustrating how the encoded video data is compressed on the image acquisition device side for storage and / or transmission in this embodiment three.

[0122] Step 601: The image acquisition device acquires the raw video data and encodes it to obtain the encoded first video data.

[0123] The first video data is an SVC format video stream, including base layer video frames and enhancement layer video frames;

[0124] Step 602: Extract all enhancement layer video frames from the current first video data.

[0125] In this step, the reference markers in the syntax portion of the first video data are analyzed, and the predictive coding relationship of the current video frame is generated based on the reference markers. The enhancement layer video frame is then determined based on this relationship.

[0126] Step 603: For each extracted enhancement layer video frame, extract the macroblock data from that enhancement layer video frame.

[0127] In this step, according to the syntax standard of the video standard (e.g., H.264 or H.265) conforming to the first video data, the payload data in the video frame is stripped to obtain the payload data and syntax data respectively. The payload data is macroblock data.

[0128] Step 604: Perform replication mode encoding on the macroblock data to obtain replication mode encoded macroblock data.

[0129] Step 605: The macroblock data encoded in copy mode is fused with the syntax data of the video frame to form a video frame, resulting in the second enhancement layer video frame.

[0130] Step 606, repeat steps 603-605 until every video frame of the enhancement layer has been re-encoded.

[0131] Step 607: Encapsulate the current base layer video frame and the second enhancement layer video frame into second video data, and store and / or transmit them.

[0132] In this embodiment, the first video data is re-encoded on the image acquisition device side, which greatly reduces the storage space and transmission bandwidth of the first video data.

[0133] See Figure 7 As shown, Figure 7 This is a schematic diagram of a monitoring system. The system includes an image acquisition device and backend equipment for processing encoded first video data from the image acquisition device.

[0134] The backend equipment includes,

[0135] The video caching module is used to cache the encoded first video data from the image acquisition device.

[0136] The intelligent detection module performs video analysis on the current first video data to detect whether the target meets the set expectations. When the result of the target video analysis meets the set expectations, a trigger event is output.

[0137] The video re-encoding module is used to extract at least one first enhancement layer video frame from the first video data when a trigger event from the intelligent detection module occurs or the trigger event is invalid. The first enhancement layer video frame is then re-encoded to obtain a second enhancement layer video frame. The second enhancement layer video frame and the base layer video frames from the first video data are used as the compressed second video data.

[0138] The storage module is used to store the current first video data when the event is triggered and the event is valid, until the event is invalidated, and to store the second video data.

[0139] And / or,

[0140] The transmission module is used to transmit the current first video data when a trigger event is detected and the trigger event is valid, until the trigger event becomes invalid, and to transmit the second video data.

[0141] See Figure 8 As shown, Figure 8 This is a schematic diagram of an image acquisition device. The image acquisition device includes,

[0142] The imaging module is used to acquire and encode current video images in real time to obtain the first video data.

[0143] The video re-encoding module is used to extract at least one first enhancement layer video frame from the first video data, re-encode the first enhancement layer video frame to obtain a second enhancement layer video frame, and use the second enhancement layer video frame and the base layer video frame from the first video data as the compressed second video data.

[0144] Storage module, used to store the second video data.

[0145] And / or,

[0146] The transmission module is used to transmit the second video data.

[0147] Preferably, the device also includes,

[0148] The intelligent detection module performs video analysis on the current first video data to detect whether the target meets the set expectations. When the result of the target video analysis meets the set expectations, a trigger event is output.

[0149] The video re-encoding module further includes, when a trigger event from the intelligent detection module or when the trigger event is invalid, extracting at least one first enhancement layer video frame from the first video data, re-encoding the first enhancement layer video frame to obtain a second enhancement layer video frame, and using the second enhancement layer video frame and the base layer video frame from the first video data as compressed second video data.

[0150] See Figure 9 As shown, Figure 9 This is a schematic diagram of an image acquisition device or a backend device in a monitoring system. The image acquisition device includes a memory and a processor. The memory stores a computer program, and the processor is configured to execute the computer program to implement a method for compressing encoded video data from encoded first video data received from the image acquisition device.

[0151] The backend device includes a processor and a memory, the memory storing a computer program, and the processor being configured to execute the steps of the computer program to implement any of the compression methods for the encoded video data.

[0152] The memory may include random access memory (RAM) or non-volatile memory (NVM), such as at least one disk storage device. Optionally, the memory may also be at least one storage device located remotely from the aforementioned processor.

[0153] The processors mentioned above can be general-purpose processors, including central processing units (CPUs), network processors (NPs), etc.; they can also be digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components.

[0154] This invention also provides a computer-readable storage medium storing a computer program, which, when executed by a processor, implements the steps of any of the compression methods for the encoded video data.

[0155] For the device / network-side equipment / storage medium embodiments, since they are basically similar to the method embodiments, the description is relatively simple, and relevant parts can be referred to in the description of the method embodiments.

[0156] In this document, relational terms such as "first" and "second" are used merely to distinguish one entity or operation from another, without necessarily requiring or implying any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

[0157] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.

Claims

1. A method for compressing encoded video data, characterized in that, The method includes, Extract at least one first enhancement layer video frame from the encoded first video data. The first enhancement layer video frames are re-encoded to obtain the second enhancement layer video frames. The second enhancement layer video frames and the base layer video frames from the first video data are used as the compressed second video data. in, The first video data is scalable video encoded data, and the re-encoding of the first enhancement layer video frames includes, After stripping macroblock data and syntax data from the video frames of the first enhancement layer, The macroblock data in the first enhancement layer video frame is encoded in copy mode. The macroblock data encoded in copy mode is fused with the syntax data to form a video frame, resulting in a second enhancement layer video frame.

2. The compression method as described in claim 1, characterized in that, The method further includes, Detect trigger events, When a trigger event is detected and is valid, the current first video data is stored and / or transmitted until the trigger event becomes invalid. When no triggering event is detected or the triggering event is invalid, the step of extracting at least one first enhancement layer video frame from the encoded first video data is performed, and the second enhancement layer video frame and the basic layer video frame in the first video data are stored and / or transmitted.

3. The compression method as described in claim 2, characterized in that, The encoded first video data is surveillance video data, and the encoded first video data is cached according to a video caching mechanism. When a triggering event is detected and is valid, the current first video data is stored and / or transmitted until the triggering event becomes invalid. include, When a first triggering event is detected to identify the start of the triggering event, the first video data cached within the time range set before the current first triggering event, as well as the currently cached first video data, are stored and / or transmitted until a second triggering event is detected to identify the end of the triggering event. The step of extracting at least one first enhancement layer video frame from the encoded first video data when no trigger event is detected or the trigger event is invalid includes: If no first triggering event is detected to identify the start of the triggering event or a second triggering event is detected to identify the end of the triggering event, then for all cached first video data, the step of extracting at least one first enhancement layer video frame from the encoded first video data is performed.

4. The compression method as described in claim 2 or 3, characterized in that, The detection trigger events include, Using an intelligent detection mechanism, it is determined whether the target in the current first video data meets the set expectations; in, The set expectations include the target's movement, trajectory, posture, behavior, time, events, space, or any combination thereof.

5. The compression method as described in claim 1, characterized in that, The extraction of at least one first enhancement layer video frame from the encoded first video data includes, The reference markers in the syntax data of the first video data are analyzed. Based on the reference markers, the predictive coding relationship of the current video frame is generated. Based on this relationship, it is determined whether the current video frame is a first enhancement layer video frame. If so, then extract the video frame of the first enhancement layer. Otherwise, it is determined to be a basic layer video frame.

6. The compression method as described in claim 1, characterized in that, The process of stripping macroblock data and syntactic data from the first enhancement layer video frame includes, According to the grammatical standard of the video standard conforming to the first video data, macroblock data and grammatical data are extracted from the first enhancement layer video frames to obtain macroblock data and grammatical data respectively. The macroblock data in the first enhancement layer video frame is encoded in copy mode. include, If the first video data conforms to the H.264 standard, then it is encoded in block copy mode on a macroblock basis. If the first video data conforms to the H.265 standard, then copy mode encoding is performed on a unit-by-unit basis.

7. A compression device for encoded video data, characterized in that, The compression device includes a memory and a processor, the memory storing a computer program, and the processor being configured to execute the computer program to implement the steps of any of the compression methods for encoded video data as described in claims 1 to 6.

8. A monitoring system, characterized in that, The system includes an image acquisition device and a back-end device for processing encoded first video data from the image acquisition device. The back-end device includes a processor and a memory, the memory storing a computer program, and the processor is configured to execute the computer program to implement the steps of any of the compression methods for the encoded video data as described in claims 1 to 6.

9. An image acquisition device, characterized in that, The image acquisition device includes a memory and a processor. The memory stores a computer program, and the processor is configured to execute the computer program to implement the steps of any of the compression methods for encoded video data as described in claims 1 to 6 on the encoded first video data from the image acquisition device.