CN112383676B - Video file processing method and device, electronic equipment and storage medium - Google Patents

Video file processing method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN112383676B
CN112383676B CN202011211201.8A CN202011211201A CN112383676B CN 112383676 B CN112383676 B CN 112383676B CN 202011211201 A CN202011211201 A CN 202011211201A CN 112383676 B CN112383676 B CN 112383676B
Authority
CN
China
Prior art keywords
video
processed
frame
video file
video frames
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202011211201.8A
Other languages
Chinese (zh)
Other versions
CN112383676A (en
Inventor
王伟
李光
刘一卓
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Baidu Netcom Science and Technology Co Ltd
Original Assignee
Beijing Baidu Netcom Science and Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Baidu Netcom Science and Technology Co Ltd filed Critical Beijing Baidu Netcom Science and Technology Co Ltd
Priority to CN202011211201.8A priority Critical patent/CN112383676B/en
Publication of CN112383676A publication Critical patent/CN112383676A/en
Application granted granted Critical
Publication of CN112383676B publication Critical patent/CN112383676B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N5/00Details of television systems
    • H04N5/14Picture signal circuitry for video frequency region

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Television Signal Processing For Recording (AREA)

Abstract

The application discloses a video file processing method, a video file processing device, electronic equipment and a storage medium, and relates to the technical field of Internet. The specific implementation scheme is as follows: selecting a video frame to be processed from video frames of a video file to be processed according to user selection operation; and carrying out mutation processing on the video frames to be processed in the video file to be processed to obtain an abnormal video file. A flexible implementation is provided for the processing of video files.

Description

Video file processing method and device, electronic equipment and storage medium
Technical Field
The present disclosure relates to the field of internet technologies, and in particular, to a video file processing method, apparatus, electronic device, and storage medium.
Background
The internet content is iterated from text, pictures to video, and video applications are growing in bursts. When using video applications, users often encounter video jams. In live broadcast, as a result of network jitter and the like, a video stream pulled by a user watching live broadcast is blocked at a watching end.
The playing end can be tested through scene reproduction of the cartoon video so as to determine the experience condition of a user on playing the cartoon. However, the current scene reproduction scheme determines that the cartoon video has randomness, and cannot include all cases of actually generating the cartoon video, so that the test result of the playing end has one-sided property.
Disclosure of Invention
The disclosure provides a video file processing method, a video file processing device, electronic equipment and a storage medium.
According to an aspect of the present disclosure, there is provided a video file processing method, including:
selecting a video frame to be processed from video frames of a video file to be processed according to user selection operation;
and carrying out mutation processing on the video frames to be processed in the video file to be processed to obtain an abnormal video file.
According to another aspect of the present disclosure, there is provided a video file processing apparatus including:
the selection module is used for selecting the video frames to be processed from the video frames of the video files to be processed according to the selection operation of the user;
and the processing module is used for carrying out mutation processing on the video frames to be processed in the video file to be processed to obtain an abnormal video file.
According to another aspect of the present disclosure, there is provided an electronic device including:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the video file processing method of any one of the embodiments of the present application.
According to another aspect of the present disclosure, there is provided a non-transitory computer-readable storage medium storing computer instructions for causing a computer to execute the video file processing method according to any of the embodiments of the present application.
According to the method and the device, the problem that the construction of the cartoon video reproduction has randomness and cannot include all conditions of actually generating the cartoon video is solved, abnormal video files under various conditions can be generated, the abnormal video files are closer to the generation conditions of the cartoon video in an actual scene, and a rich sample set is provided for a playing end test.
It should be understood that the description in this section is not intended to identify key or critical features of the embodiments of the disclosure, nor is it intended to be used to limit the scope of the disclosure. Other features of the present disclosure will become apparent from the following specification.
Drawings
The drawings are for better understanding of the present solution and do not constitute a limitation of the present application. Wherein:
FIG. 1 is a flowchart of a video file processing method according to an embodiment of the present application;
FIG. 2 is a schematic diagram of a video file processing procedure provided according to an embodiment of the present application;
FIG. 3 is a flowchart of another video file processing method provided in accordance with an embodiment of the present application;
FIG. 4 is a flow chart of yet another video file processing method provided in accordance with an embodiment of the present application;
FIG. 5 is a flow chart of yet another video file processing method provided in accordance with an embodiment of the present application;
fig. 6 is a schematic structural diagram of a video file processing apparatus according to an embodiment of the present application;
fig. 7 is a block diagram of an electronic device for implementing the video file processing method of the embodiment of the present application.
Detailed Description
Exemplary embodiments of the present application are described below in conjunction with the accompanying drawings, which include various details of the embodiments of the present application to facilitate understanding, and should be considered as merely exemplary. Accordingly, one of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the present application. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
Fig. 1 is a flowchart of a video file processing method according to an embodiment of the present application. The method and the device are suitable for the situation that the video file to be processed is processed to obtain the abnormal video file. The abnormal video file can be used for, but not limited to, processing and playing performance of the abnormal video file by the test playing end, and experience condition of a user after the abnormal video file is played by the test playing end. The embodiment may be performed by a video file processing apparatus, which may be implemented in software and/or hardware and may be integrated in an electronic device carrying video file processing functions. As shown in fig. 1, the method includes:
s101, selecting a video frame to be processed from video frames of a video file to be processed according to a user selection operation.
In this embodiment, the video file to be processed is composed of video frames, and the video frames of the video file to be processed can be obtained after decoding the video file to be processed in MP4, MKV, AVI and other formats, for example, the video frames can be in YUV format. The video file to be processed can be a network streaming media video file or a local video file. The video frame to be processed is an object to be processed selected from video frames of the video file to be processed, and optionally, the video frame to be processed may be at least one frame of the video frames of the video file to be processed.
When a player is tested, the scheme for simulating and reproducing the cartoon video generally transmits video streams and constructs frame loss video under the condition that a playing end uses a weak network environment. However, the time in the switching process of the scheme is uncontrollable, has randomness, and cannot adaptively and controllably construct the cartoon video under various conditions. In addition, the scheme of continuously starting and stopping a firewall or disabling a network card at a playing end by adopting a timing script can influence the transmission of the video stream, and the frame loss video can be constructed. However, the scheme also has randomness, can not effectively control frame loss, and can not construct the cartoon video under various conditions. In addition, neither of the above schemes can be configured to form repeated frames of a stuck video.
In this embodiment, when constructing an abnormal video file, first, according to a user selection operation, a to-be-processed video frame is selected from video frames of the to-be-processed video file, and parameters such as the number and types of the to-be-processed video frames may be selected according to actual situations, so that there are a plurality of abundant to-be-processed video frame selection situations.
Optionally, the user selection operation in the embodiment of the present application may be an operation specified by the user, for example, specifying a frame number by the user; a random framing operation selected by the user is also possible. Further, the frame number designated by the user may be used as the video frame to be processed, or the video frame to be processed may be randomly selected from among the video frames of the video file to be processed.
S102, mutation processing is carried out on the video frames to be processed in the video files to be processed, and abnormal video files are obtained.
In this embodiment, the mutation processing of the video frame to be processed includes, but is not limited to, frame loss processing and/or repeated frame processing. As shown in fig. 2. The frame loss processing may be performed by a frame loss processor and the repeated frame processing may be performed by a repeated frame processor. The frame loss processing may be deleting each frame of video in the video frames to be processed from the video file to be processed, so as to obtain an abnormal video file. The method may be to randomly discard a single frame, randomly discard a plurality of frames, discard a designated single frame (video frame number), discard a designated plurality of frames (video frame numbers), discard a designated section (start video frame number, end video frame number), or select a video frame discard from the designated sections. Optionally, the number of processed video files (i.e. abnormal video files) obtained after processing the video frames to be processed may be at least one, and may be consistent with the number of video frames to be processed or may not be consistent with the number of video frames to be processed.
For example, the abnormal video file obtained by the single frame loss processing may be at least one. Specifically, the to-be-processed video frames 1, 2 and 3 are deleted from the to-be-processed video file, and three files of the to-be-processed video frame 1, the to-be-processed video frame 2 and the to-be-processed video frame 3 are obtained.
The repeated frame processing is to add the video frame to be processed into the video file to be processed, so that the situation that the video frame to be processed is repeated is caused. Such as random single frame repetition, random multi-frame repetition, specified single frame (video frame number) repetition, specified multi-frame (multiple video frame numbers) repetition, specified interval (start video frame number, end video frame number) repetition, or selection of video frame repetition from specified intervals, etc. The repeated position, the repeated times and the like of the video frames to be processed in the video file to be processed can be set according to actual conditions. For example, the repeated processing of the video frames 1, 2 and 3 to be processed may be performed to obtain an abnormal video file including the repeated video frames to be processed arranged in 1, 2, 3, or an abnormal video file including the repeated video frames to be processed arranged in 1, 2, 3, an abnormal video file including the video frames to be processed arranged as 1, an abnormal video file of the video frames to be processed arranged as 2, an abnormal video file of the video frames to be processed arranged as 3, and the like can also be obtained. The above is merely an example of the number and form of the abnormal video files, and other abnormal video files may be generated, where the number and form of the generated abnormal video files may be determined according to the actual situation, and are not exhaustive herein. The cartoon video file in fig. 2 is the abnormal video file in the present embodiment.
According to the technical scheme, the video frames to be processed are flexibly selected from the video frames of the video files to be processed, so that the selected video frames to be processed are more comprehensive; and then, carrying out mutation processing on the video frames to be processed in the video files to be processed to obtain abnormal video files, solving the problems that the existing cartoon video reproduction construction has randomness and cannot comprise all the situations of actually generating the cartoon video, generating the abnormal video files under various conditions, being closer to the generation situation of the cartoon video in an actual scene, and providing a rich sample set for a playing end test.
As an alternative manner of this embodiment, after obtaining the abnormal video file, the method further includes: determining the number of video frames to be processed; the number is taken as the mutation degree of the abnormal video file.
In this embodiment, the mutation degree of the abnormal video file may be determined according to the number of the video frames to be processed, so as to quantitatively reflect the play clamping degree of the abnormal video file, so that in the subsequent test, the play end clamping degree which can be accepted by the user is clear. For example, the mutation degree of the abnormal video file may be proportional to the number of the video frames to be processed, that is, the greater the number of the video frames to be processed, the higher the mutation degree of the abnormal video file. For example, when the number of video frames to be processed is 10, the degree of variance of the abnormal video file is 1 level, when the number of video frames to be processed is 20, the degree of variance of the abnormal video file is 2 level, when the number of video frames to be processed is 30, the degree of variance of the abnormal video file is 3 level, and so on. And determining the linear relation between the mutation degree of the abnormal video file and the number of the video frames to be processed according to the data, thereby determining the mutation degree of the abnormal video file corresponding to the number of other video frames to be processed. In addition, the number of the video frames to be processed can be directly determined as the mutation degree of the abnormal video file. For example, when the number of video frames to be processed is 1, the degree of variance of the abnormal video file is 1 level, when the number of video frames to be processed is 2, the degree of variance of the abnormal video file is 2 level, when the number of video frames to be processed is 3, the degree of variance of the abnormal video file is 3 level, and so on.
The method has the beneficial effects that the variation degree of the abnormal video files can be quantitatively represented according to the number of the video frames to be processed, so that the variation degree of the abnormal video files obtained by different variation processes can be clearly determined, and the corresponding relation between the variation degree of each abnormal video file and the playing performance of the player and the degree of the click-on which can be accepted by a user can be clearly determined in the subsequent player test.
Fig. 3 is a flowchart of another video file processing method according to an embodiment of the present application. The present embodiment further explains selection of a video frame to be processed from among video frames of a video file to be processed on the basis of the above embodiment. As shown in fig. 3, the method includes:
s201, determining the frame type of the video frame in the video file to be processed.
The frame types may include key frames (I frames), difference frames (P frames), and bi-directional difference frames (B frames), among others. In video compression, each frame represents a still image. While in actual compression, various algorithms are adopted to reduce the data capacity, wherein the IPB is one algorithm for reducing the data capacity. The I frame represents a key frame, and the complete reservation of the key frame picture can be completed only by key frame data during decoding. The P-frame represents the difference between this frame and a previous key frame (or P-frame), and the difference defined by this frame needs to be overlapped with the previously buffered picture when decoding, so as to generate the final picture. The B frame is a bi-directional difference frame, that is, the B frame records the difference between the present frame and the previous and subsequent frames. To decode a B frame, not only a previous buffer picture but also a subsequent picture is obtained, and a final picture is obtained by superimposing the previous and subsequent pictures with the present frame data. In this embodiment, for the decoded video file to be processed, the frame type of the video frame may be determined, and it is clear which of the I frame, the P frame, or the B frame is the video frame.
S202, displaying the video frames and the frame types of the video frames to a user.
In order to enable the user to freely select the video frames to be processed so as to obtain various selection conditions of the video frames to be processed, in this embodiment, the video frames in the video file to be processed and the frame types of the video frames are displayed to the user, so that the user can select the video frames to be processed according to the actual conditions and requirements according to the displayed video frames and the frame type adaptability of the video frames. The video frames and frame types of the video frames may be presented to the user through a visual interface, and the specific presentation form may be in a graphic form or a list form, which is not limited herein.
S203, selecting the video frames to be processed from the video frames of the video files to be processed according to the user selection operation.
In this embodiment, the selection operation by the user may be an option selection operation or an input operation acting on the visual interface. The option selection operation or the input operation may be a manual operation or a voice operation. The user can be prompted to select the video frame to be processed on the visual interface, and the video frame selected by the user can be used as the video frame to be processed after the selection operation of the user is obtained. The user can be prompted on the visual interface to select the video frames which are not processed, and after the selection operation of the user is obtained, all video frames in the video file to be processed except the video frames selected by the user can be used as the video frames to be processed. Other setting forms can be set in the visual interface to determine the video frames to be processed according to the selection operation of the user.
S204, mutation processing is carried out on the video frames to be processed in the video files to be processed, and abnormal video files are obtained.
In this embodiment, after determining the video frame to be processed according to the selection operation of the user, the mutation operation may be performed on the video frame to be processed. Illustratively, depending on the user selection, the frame type of the resulting video frame to be processed may include one of a P frame, an I frame, a B frame, a P frame and an I frame, a P frame and a B frame, an I frame and a B frame, a P frame and an I frame, and a B frame. For the case that the video frame to be processed is a single frame, that is, the case that the video frame to be processed is one frame of a P frame, an I frame or a B frame, the mutation processing may include frame loss processing and/or repeated frame processing. Taking the frame type of the video frame to be processed as a P frame as an example, at least one frame with the frame type of the P frame can be discarded from the video frames of the file to be processed, so as to obtain the abnormal video file. And repeating at least one frame with the frame type of P frames in the video frames of the file to be processed to obtain the abnormal video file. And repeating the frame operation on at least one frame with the frame type of P frame, and discarding at least one frame with the frame type of P frame to obtain the abnormal video file. For the case that the video frame to be processed is two frames or more, the mutation processing can be performed including frame loss processing and/or repeated frame processing. Taking the case that the frame type of the video frame to be processed is a P frame and an I frame as an example, at least one frame of which the frame type is a P frame and at least one frame of which the repeating frame type is an I frame may be discarded from the video frames of the video file to be processed; or at least one frame with the frame type of I frame can be discarded from video frames of the video file to be processed, and at least one frame with the repeated frame type of P frame can be discarded; or at least one frame with the frame type of P frame and at least one frame with the frame type of I frame can be discarded from the video frames of the video file to be processed, or the at least one frame with the frame type of P frame and the at least one frame with the frame type of I frame can be repeated in the video frames of the video file to be processed. The mutation process may be performed in at least one item to obtain at least one abnormal video file. Specifically, the processing of the video frames to be processed can be set according to actual conditions so as to meet the requirements of player testing. In order to be able to test the performance of the player against a variety of situations, the type of mutation processing performed on the video frames to be processed may be made as many as possible to obtain a rich sample set.
It should be noted that the foregoing is merely an example of exception handling, and is not exhaustive, and any scheme that performs frame loss and/or repeated frame processing on a video frame to be processed is within the scope of protection of the present application.
According to the technical scheme, the frame type of the video frame in the video file to be processed is determined; displaying the video frames and the frame types of the video frames to a user; according to the selection operation of the user, the video frames to be processed are selected from the video frames of the video files to be processed, so that the video frames to be processed are adaptively determined according to the requirements of the user, the problem that the construction of the cartoon video reproduction has randomness and cannot include all the situations of actually generating the cartoon video is solved, the video frames to be processed in various situations are obtained according to the selection of the user to be processed, and the sample set tested by the player is enriched.
As an alternative manner of this embodiment, selecting a video frame to be processed from video frames of a video file to be processed according to a user selection operation may include: and selecting the video frames to be processed from the video frames of the video file to be processed according to the frame numbers specified by the user.
For example, the user may not select a video frame to be processed for the type of video frame, but rather refer to the type of video frame, designate the frame number of the video frame, and determine the video frame to be processed according to the frame number. The user can be prompted to select the frame number of the video frame to be processed, and the video frame corresponding to the frame number selected by the user is used as the video frame to be processed. The user can be prompted to select the frame number of the video frame which is not processed, and the frame number which is selected by the user is used as the frame to be processed except the frame number which corresponds to the frame number in all the video frames of the video file to be processed. The user may be prompted to select a start frame number and a stop frame number of the designated number interval, and the video frame to be processed is selected from the designated number interval determined by the start frame number and the stop frame number. The selection of the video frames to be processed from the designated number interval may be a random selection or a designated selection for the user. The scheme further enriches the forms and types of the video frames to be processed, so that the subsequent mutation processing is facilitated, and a rich player test sample set is obtained.
Fig. 4 is a flowchart of yet another video file processing method according to an embodiment of the present application. The present embodiment further explains selection of a video frame to be processed from among video frames of a video file to be processed on the basis of the above embodiment. As shown in fig. 4, the method includes:
s301, carrying out random full arrangement on the numbers of video frames of the video file to be processed.
Illustratively, the total number n of frames of the video frames in the video file to be processed is determined, including the number 0- (n-1). The numbers of n video frames are randomly and fully arranged to obtain a digital queue with the disordered numbers, for example, digital queues with the numbers of 4, 7, 0, 8, 3, 15 and … … can be obtained.
S302, selecting a video frame to be processed from video frames of the video file to be processed according to the arrangement result and the user selection operation.
In this embodiment, if the user selection operation is the user-specified operation, the arrangement result may be displayed to the user, and the user selects the video frame to be processed, for example, the user may select to determine the video frame to be processed from the video frames arranged in front, may select to determine the video frame to be processed from the video frames arranged in rear, and may select to determine the video frame to be processed from the video frames arranged in the middle. The number of selected video frames to be processed may also be determined based on a user selection operation.
If the user selection operation is the random frame selection operation, randomly selecting a preset number of video frames from the digital queue to serve as the video frames to be processed. For example, a preset number of video frames arranged in front of the digital queue may be randomly selected as the video frames to be processed, a preset number of video frames arranged at the end of the digital queue may be randomly selected as the video frames to be processed, and a preset number of video frames may be randomly selected from the middle position of the digital queue as the video frames to be processed. The preset number can be set according to actual conditions. For example, for the number queues of numbers 4, 7, 0, 8, 3, 15, … …, the video frames corresponding to the first 5 numbers arranged can be selected as the video frames to be processed, and the video frames of numbers 4, 7, 0, 8, 3 can be selected as the video frames to be processed.
S303, mutation processing is carried out on the video frames to be processed in the video files to be processed, and abnormal video files are obtained.
In this embodiment, the mutation processing of the video frames to be processed is the same as that of the above embodiment, that is, a single video frame to be processed may be selected to perform frame loss and/or frame repetition operations according to actual needs, or a plurality of video frames to be processed may be selected to perform frame loss and/or frame repetition operations, so long as a scheme of performing frame loss and/or frame repetition processing on the video frames to be processed is within the protection scope of the present application.
According to the technical scheme, the numbers of the video frames of the video file to be processed are randomly and fully arranged, and the video frames to be processed are selected from the video frames of the video file to be processed according to the arrangement result, so that various selectable combination forms of the video frames to be processed are provided, variation processing is carried out on the combination forms of the video frames to be processed to obtain abnormal video files under various conditions, and a sample set tested by a player is enriched.
Fig. 5 is a flowchart of still another video file processing method according to an embodiment of the present application. The present embodiment further explains selection of a video frame to be processed from among video frames of a video file to be processed on the basis of the above embodiment. As shown in fig. 5, the method includes:
s401, determining a single variation frame number.
In this embodiment, the number of single variance frames may be less than or equal to the total number of frames of the video frames in the video file to be processed. The specific number can be determined according to the actual situation.
S402, selecting a video frame to be processed from video frames of a video file to be processed according to a single variation frame number and user selection operation; wherein, the continuous video frame number in the video frame to be processed is a single variation frame number.
In this embodiment, after determining the number of single mutation frames, a continuous video frame satisfying the number of single mutation frames is selected from the video frames of the video file to be processed as the video frame to be processed. For example, if the number of single mutation frames is 2, 2 consecutive frames are selected from the video file to be processed as the video frames to be processed. If the number of the single compiling frames is 10 frames, selecting continuous 10 frames from the video file to be processed as the video frames to be processed. The positions of the selected continuous video frames in the video file to be processed can be set according to actual conditions, and the positions can be designated by a user or randomly selected after a random operation mode is selected for the user.
S403, mutation processing is carried out on the video frames to be processed in the video files to be processed, and abnormal video files are obtained.
In this embodiment, the abnormal video file obtained by performing mutation processing on the video frame to be processed in the file to be processed may be at least one. For example, if the number of single mutation frames is 3, 3 consecutive video frames are selected from the video file to be processed as video frames to be processed, which may be, for example, the 5 th frame, the 6 th frame, and the 7 th frame. The number of abnormal video files obtained after the mutation processing is not particularly limited as long as it is ensured that the mutation processing is performed once for each of the 5 th, 6 th and 7 th frames. The method includes the steps of copying video files to be processed to obtain 3 identical video files to be processed, performing frame loss processing on a 5 th frame in a 1 st video file to be processed to obtain a 1 st abnormal video file, performing frame loss processing on a 6 th frame in a 2 nd video file to be processed to obtain a 2 nd abnormal video file, and performing frame loss processing on a 7 th frame in a 3 rd video file to be processed to obtain a 3 rd abnormal video file. Or, copying the video files to be processed to obtain 2 identical video files to be processed, and performing frame loss processing on the 5 th frame and the 6 th frame in the 1 st video file to be processed to obtain the 1 st abnormal video file. And carrying out frame loss processing on the 7 th frame in the 2 nd video file to be processed to obtain the 2 nd abnormal video file. The foregoing is not exhaustive, and other abnormal video files may be obtained for other situations, where the frame loss process may also be a repeated frame process.
According to the technical scheme, the number of single variation frames is determined; according to the single mutation frame number, the video frames to be processed are selected from the video frames of the video files to be processed, so that selectable combination forms of various video frames to be processed and mutation processing conditions are provided, abnormal video files under various conditions are obtained, and a sample set tested by a player is enriched.
Fig. 6 is a schematic structural diagram of a video file processing apparatus according to an embodiment of the present application. The method and the device are suitable for the situation that the video file to be processed is processed to obtain the abnormal video file. The device can realize the video file processing method of any embodiment of the application. The apparatus may be integrated in an electronic device that carries video file processing functionality. The video file processing apparatus 500 specifically includes:
a selection module 501, configured to select a video frame to be processed from video frames of a video file to be processed according to a user selection operation;
the processing module 502 is configured to perform mutation processing on a video frame to be processed in the video file to be processed, so as to obtain an abnormal video file.
According to the technical scheme, the video frames to be processed are selected from the video frames of the video files to be processed; the video frame to be processed in the video file to be processed is subjected to mutation processing to obtain an abnormal video file, so that the problem that the construction of the video reproduction of the cartoon is random and cannot include all conditions of actually generating the cartoon is solved, the abnormal video file under various conditions can be generated, the abnormal video file is closer to the generation condition of the cartoon in an actual scene, and a rich sample set is provided for the test of a playing end.
Illustratively, the selection module 501 may include:
a frame type determining unit, configured to determine a frame type of a video frame in a video file to be processed;
the display unit is used for displaying the video frames and the frame types of the video frames to a user;
and the first video frame selection unit is used for selecting the video frames to be processed from the video frames of the video file to be processed according to the user selection operation.
The first video frame selection unit is specifically configured to:
and selecting the video frames to be processed from the video frames of the video file to be processed according to the frame numbers specified by the user.
Illustratively, the selection module 501 may include:
the full arrangement unit is used for carrying out random full arrangement on the numbers of the video frames of the video file to be processed;
and the second video frame selection unit is used for selecting the video frames to be processed from the video frames of the video file to be processed according to the arrangement result and the user selection operation.
Illustratively, the selection module 501 may include:
a single variation frame number determining unit for determining a single variation frame number;
the third video frame selection unit is used for selecting a video frame to be processed from the video frames of the video file to be processed according to the single variation frame number and the user selection operation; wherein, the continuous video frame number in the video frame to be processed is a single variation frame number.
Illustratively, the apparatus may further include:
the number determining module is used for determining the number of the video frames to be processed;
and the variation degree determining module is used for taking the number as the variation degree of the abnormal video file.
According to embodiments of the present application, an electronic device and a readable storage medium are also provided.
As shown in fig. 7, a block diagram of an electronic device according to a video file processing method according to an embodiment of the present application is shown. Electronic devices are intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. The electronic device may also represent various forms of mobile devices, such as personal digital processing, cellular telephones, smartphones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be exemplary only, and are not meant to limit implementations of the application described and/or claimed herein.
As shown in fig. 7, the electronic device includes: one or more processors 601, memory 602, and interfaces for connecting the components, including high-speed interfaces and low-speed interfaces. The various components are interconnected using different buses and may be mounted on a common motherboard or in other manners as desired. The processor may process instructions executing within the electronic device, including instructions stored in or on memory to display graphical information of the GUI on an external input/output device, such as a display device coupled to the interface. In other embodiments, multiple processors and/or multiple buses may be used, if desired, along with multiple memories and multiple memories. Also, multiple electronic devices may be connected, each providing a portion of the necessary operations (e.g., as a server array, a set of blade servers, or a multiprocessor system). One processor 601 is illustrated in fig. 7.
Memory 602 is a non-transitory computer-readable storage medium provided herein. The memory stores instructions executable by the at least one processor to cause the at least one processor to perform the video file processing method provided herein. The non-transitory computer readable storage medium of the present application stores computer instructions for causing a computer to execute the video file processing method provided by the present application.
The memory 602 is used as a non-transitory computer readable storage medium for storing non-transitory software programs, non-transitory computer executable programs, and modules, such as program instructions/modules (e.g., the selection module 501 and the processing module 502 shown in fig. 6) corresponding to the video file processing method in the embodiments of the present application. The processor 601 executes various functional applications of the server and data processing, i.e., implements the video file processing method in the above-described method embodiments, by running non-transitory software programs, instructions, and modules stored in the memory 602.
The memory 602 may include a storage program area and a storage data area, wherein the storage program area may store an operating system, at least one application program required for a function; the storage data area may store data created according to the use of the electronic device of the video file processing method, and the like. In addition, the memory 602 may include high-speed random access memory, and may also include non-transitory memory, such as at least one magnetic disk storage device, flash memory device, or other non-transitory solid-state storage device. In some embodiments, memory 602 may optionally include memory remotely located relative to processor 601, which may be connected to the electronic device of the video file processing method via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The electronic device of the video file processing method may further include: an input device 603 and an output device 604. The processor 601, memory 602, input device 603 and output device 604 may be connected by a bus or otherwise, for example in fig. 7.
The input device 603 may receive input numeric or character information and generate key signal inputs related to user settings and function control of the electronic device of the video file processing method, such as a touch screen, a keypad, a mouse, a track pad, a touch pad, a pointer stick, one or more mouse buttons, a track ball, a joystick, and the like. The output devices 504 may include a display device, auxiliary lighting devices (e.g., LEDs), and haptic feedback devices (e.g., vibration motors), among others. The display device may include, but is not limited to, a Liquid Crystal Display (LCD), a Light Emitting Diode (LED) display, and a plasma display. In some implementations, the display device may be a touch screen.
Various implementations of the systems and techniques described here can be realized in digital electronic circuitry, integrated circuitry, application specific ASIC (application specific integrated circuit), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include: implemented in one or more computer programs, the one or more computer programs may be executed and/or interpreted on a programmable system including at least one programmable processor, which may be a special purpose or general-purpose programmable processor, that may receive data and instructions from, and transmit data and instructions to, a storage system, at least one input device, and at least one output device.
These computing programs (also referred to as programs, software applications, or code) include machine instructions for a programmable processor, and may be implemented in a high-level procedural and/or object-oriented programming language, and/or in assembly/machine language. As used herein, the terms "machine-readable medium" and "computer-readable medium" refer to any computer program product, apparatus, and/or device (e.g., magnetic discs, optical disks, memory, programmable Logic Devices (PLDs)) used to provide machine instructions and/or data to a programmable processor, including a machine-readable medium that receives machine instructions as a machine-readable signal. The term "machine-readable signal" refers to any signal used to provide machine instructions and/or data to a programmable processor.
To provide for interaction with a user, the systems and techniques described here can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and pointing device (e.g., a mouse or trackball) by which a user can provide input to the computer. Other kinds of devices may also be used to provide for interaction with a user; for example, feedback provided to the user may be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form, including acoustic input, speech input, or tactile input.
The systems and techniques described here can be implemented in a computing system that includes a background component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such background, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local Area Networks (LANs), wide Area Networks (WANs), the internet, and blockchain networks.
The computer system may include a client and a server. The client and server are typically remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other. The server can be a cloud server, also called a cloud computing server or a cloud host, and is a host product in a cloud computing service system, so that the defects of high management difficulty and weak service expansibility in the traditional physical hosts and VPS service are overcome.
According to the technical scheme of the embodiment of the application, the video frames to be processed are selected from the video frames of the video file to be processed; the video frame to be processed in the video file to be processed is subjected to mutation processing to obtain an abnormal video file, so that the problem that the construction of the video reproduction of the cartoon is random and cannot include all conditions of actually generating the cartoon is solved, the abnormal video file under various conditions can be generated, the abnormal video file is closer to the generation condition of the cartoon in an actual scene, and a rich sample set is provided for the test of a playing end.
The method and the device can be applied to the technical field of the Internet and the fields of video processing and the like.
It should be appreciated that various forms of the flows shown above may be used to reorder, add, or delete steps. For example, the steps described in the present application may be performed in parallel, sequentially, or in a different order, provided that the desired results of the technical solutions disclosed in the present application can be achieved, and are not limited herein.
The above embodiments do not limit the scope of the application. It will be apparent to those skilled in the art that various modifications, combinations, sub-combinations and alternatives are possible, depending on design requirements and other factors. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present application are intended to be included within the scope of the present application.

Claims (10)

1. A video file processing method, comprising:
selecting a video frame to be processed from video frames of a video file to be processed according to user selection operation;
performing mutation processing on the video frames to be processed in the video file to be processed to obtain an abnormal video file;
wherein selecting the video frame to be processed from the video frames of the video file to be processed according to the user selection operation includes:
determining the frame type of a video frame in a video file to be processed;
displaying the video frames and the frame types of the video frames to a user so that the user can select the video frames to be processed according to the actual conditions and requirements according to the displayed video frames and the frame type adaptability of the video frames, wherein the user selection operation is user-specified operation comprising user-specified frame numbers or user-selected random frame selection operation.
2. The method of claim 1, wherein selecting a video frame to be processed from among video frames of a video file to be processed according to a user selection operation comprises:
the numbers of the video frames of the video file to be processed are arranged randomly;
and selecting the video frames to be processed from the video frames of the video file to be processed according to the arrangement result and the user selection operation.
3. The method of claim 1, wherein selecting a video frame to be processed from among video frames of a video file to be processed according to a user selection operation comprises:
determining a single variation frame number;
selecting a video frame to be processed from the video frames of the video file to be processed according to the single variation frame number and the user selection operation; wherein, the continuous video frame number in the video frame to be processed is the single variation frame number.
4. The method of claim 1, further comprising, after obtaining the abnormal video file:
determining the number of the video frames to be processed;
and taking the number as the mutation degree of the abnormal video file.
5. A video file processing apparatus comprising:
the selection module is used for selecting the video frames to be processed from the video frames of the video files to be processed according to the selection operation of the user;
the processing module is used for carrying out mutation processing on the video frames to be processed in the video file to be processed to obtain an abnormal video file;
wherein the selection module comprises:
a frame type determining unit, configured to determine a frame type of a video frame in a video file to be processed;
the display unit is used for displaying the video frames and the frame types of the video frames to a user so that the user can select the video frames to be processed according to the actual situation and the requirements according to the displayed video frames and the frame types of the video frames, wherein the user selection operation is a user designated operation comprising a user designated frame number or a user selected random frame selection operation.
6. The apparatus of claim 5, wherein the selection module comprises:
the full arrangement unit is used for carrying out random full arrangement on the numbers of the video frames of the video file to be processed;
and the second video frame selection unit is used for selecting the video frames to be processed from the video frames of the video file to be processed according to the arrangement result and the user selection operation.
7. The apparatus of claim 5, the selection module comprising:
a single variation frame number determining unit for determining a single variation frame number;
the third video frame selection unit is used for selecting a video frame to be processed from video frames of the video file to be processed according to the single variation frame number and the user selection operation; wherein, the continuous video frame number in the video frame to be processed is the single variation frame number.
8. The apparatus of claim 5, further comprising:
the quantity determining module is used for determining the quantity of the video frames to be processed;
and the mutation degree determining module is used for taking the number as the mutation degree of the abnormal video file.
9. An electronic device, comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the video file processing method of any one of claims 1-4.
10. A non-transitory computer-readable storage medium storing computer instructions for causing the computer to perform the video file processing method of any one of claims 1-4.
CN202011211201.8A 2020-11-03 2020-11-03 Video file processing method and device, electronic equipment and storage medium Active CN112383676B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011211201.8A CN112383676B (en) 2020-11-03 2020-11-03 Video file processing method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011211201.8A CN112383676B (en) 2020-11-03 2020-11-03 Video file processing method and device, electronic equipment and storage medium

Publications (2)

Publication Number Publication Date
CN112383676A CN112383676A (en) 2021-02-19
CN112383676B true CN112383676B (en) 2024-02-09

Family

ID=74579055

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011211201.8A Active CN112383676B (en) 2020-11-03 2020-11-03 Video file processing method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN112383676B (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101079993A (en) * 2006-05-23 2007-11-28 中国科学院声学研究所 Static frame loss method in video playing
CN101159862A (en) * 2007-11-29 2008-04-09 北京中星微电子有限公司 Frame rate control method and device
CN105357592A (en) * 2015-10-26 2016-02-24 山东大学苏州研究院 Selective frame dropping method for streaming media adaptive transmission
CN108777788A (en) * 2018-08-01 2018-11-09 深圳市捷视飞通科技股份有限公司 Video quality test method, computer equipment and storage medium
CN110177308A (en) * 2019-04-15 2019-08-27 广州虎牙信息科技有限公司 Mobile terminal and its audio-video frame losing method in record screen, computer storage medium
CN110958491A (en) * 2018-09-27 2020-04-03 中兴通讯股份有限公司 Video Kanton model training method, video Kanton model prediction method, server and storage medium

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20170006281A1 (en) * 2014-05-08 2017-01-05 Huawei Device Co., Ltd. Video Quality Detection Method and Apparatus

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101079993A (en) * 2006-05-23 2007-11-28 中国科学院声学研究所 Static frame loss method in video playing
CN101159862A (en) * 2007-11-29 2008-04-09 北京中星微电子有限公司 Frame rate control method and device
CN105357592A (en) * 2015-10-26 2016-02-24 山东大学苏州研究院 Selective frame dropping method for streaming media adaptive transmission
CN108777788A (en) * 2018-08-01 2018-11-09 深圳市捷视飞通科技股份有限公司 Video quality test method, computer equipment and storage medium
CN110958491A (en) * 2018-09-27 2020-04-03 中兴通讯股份有限公司 Video Kanton model training method, video Kanton model prediction method, server and storage medium
CN110177308A (en) * 2019-04-15 2019-08-27 广州虎牙信息科技有限公司 Mobile terminal and its audio-video frame losing method in record screen, computer storage medium

Also Published As

Publication number Publication date
CN112383676A (en) 2021-02-19

Similar Documents

Publication Publication Date Title
CN109640188B (en) Video preview method and device, electronic equipment and computer readable storage medium
US10061467B2 (en) Presenting a message in a communication session
CN111277861B (en) Method and device for extracting hot spot segments in video
CN103747362A (en) Method and device for cutting out video clip
US20210243145A1 (en) Methods, systems, and media for generating a notification in connection with a video content item
CN108174280B (en) Audio and video online playing method and system
CN113424553B (en) Method and system for playback of media items
US11528513B2 (en) Preemptively altering advertising content
CN111866550A (en) Method and device for shielding video clip
EP3024223B1 (en) Videoconference terminal, secondary-stream data accessing method, and computer storage medium
CN111095939A (en) Identifying previously streamed portions of a media item to avoid repeated playback
CN111935502A (en) Video processing method, video processing device, electronic equipment and storage medium
CN111601150A (en) Video processing method and device
CN113825020B (en) Video definition switching method, device, equipment, storage medium and program product
CN111654736A (en) Method and device for determining audio and video synchronization error, electronic equipment and storage medium
CN110855557A (en) Video sharing method and device and storage medium
CN110636338A (en) Video definition switching method and device, electronic equipment and storage medium
CN112383825B (en) Video recommendation method and device, electronic equipment and medium
WO2024109706A1 (en) Media content display method and apparatus, and device, readable storage medium and product
CN112383676B (en) Video file processing method and device, electronic equipment and storage medium
CN111541905B (en) Live broadcast method and device, computer equipment and storage medium
CN113542802B (en) Video transition method and device
CN105487769A (en) Media file display method and device and electronic equipment
CN109144354B (en) Method and equipment for rotating player view layer
CN113038237B (en) Live broadcast information processing method, device, equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant