[go: up one dir, main page]

CN109951737B - Video processing method, video processing device, electronic equipment and computer-readable storage medium - Google Patents

Video processing method, video processing device, electronic equipment and computer-readable storage medium Download PDF

Info

Publication number
CN109951737B
CN109951737B CN201910143598.2A CN201910143598A CN109951737B CN 109951737 B CN109951737 B CN 109951737B CN 201910143598 A CN201910143598 A CN 201910143598A CN 109951737 B CN109951737 B CN 109951737B
Authority
CN
China
Prior art keywords
video processing
video
video file
processing subsystems
subsystems
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
CN201910143598.2A
Other languages
Chinese (zh)
Other versions
CN109951737A (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.)
Douyin Vision Co Ltd
Douyin Vision Beijing Co Ltd
Original Assignee
Beijing ByteDance Network 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 ByteDance Network Technology Co Ltd filed Critical Beijing ByteDance Network Technology Co Ltd
Priority to CN201910143598.2A priority Critical patent/CN109951737B/en
Publication of CN109951737A publication Critical patent/CN109951737A/en
Application granted granted Critical
Publication of CN109951737B publication Critical patent/CN109951737B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)

Abstract

The present disclosure discloses a video processing method, which includes: receiving a video file; determining a video processing task corresponding to the video file; determining N video processing subsystems from M video processing subsystems, wherein M and N are positive integers, and M > 1; and executing the video processing task through the N video processing subsystems. The video processing method, the video processing device, the electronic equipment and the computer readable storage medium can efficiently process video files through a plurality of video processing subsystems.

Description

Video processing method, video processing device, electronic equipment and computer-readable storage medium
Technical Field
The present disclosure relates to the field of information processing, and in particular, to a video processing method and apparatus, an electronic device, and a computer-readable storage medium.
Background
With the progress of internet related technologies, video applications are becoming a main interactive means, for example, a user may publish a shot video to a video sharing platform, and other users may browse videos published by others through the video sharing platform.
In the above application scenario, terminal devices operated by different users often have different brands, functions, and hardware, so that videos shot by the users through operating the terminal devices also have different parameters, for example, videos shot by different terminal devices have different resolutions, bit rates, and/or formats, which may cause many technical problems, taking the example that different terminal devices generate videos with different resolutions: when other users browse the high-resolution video, if terminal equipment of the other users only supports lower resolution, the high-resolution video can be played at the lower resolution, so that not only is bandwidth wasted, but also a large amount of resources are occupied by the processing of decoding and encoding the video and poor playing experience is caused; or, the user issues the video with the low resolution to the video sharing platform, and when other users browse the video with the low resolution, if the terminal devices of the other users support higher resolution, poor playing experience may also be caused. Similarly, the above technical problem also exists because different terminal devices often generate videos with different code rates.
Disclosure of Invention
The disclosed embodiments provide a video processing method, apparatus, electronic device, and computer-readable storage medium, which efficiently process a video file through a dedicated video processing system, thereby facilitating the terminal device to play the video file.
In a first aspect, an embodiment of the present disclosure provides a video processing method, including: receiving a video file; determining a video processing task corresponding to the video file; determining N video processing subsystems from M video processing subsystems, wherein M and N are positive integers, and M > 1; and executing the video processing task through the N video processing subsystems.
Further, determining a video processing task corresponding to the video file includes: determining attributes of the video file; determining the video processing task according to the attribute of the video file; wherein the attributes of the video file include at least one of: a resolution of the video file; a code rate of the video file; the size of the video file; the format of the video file.
Further, the video processing task includes at least one of: converting the video file to a first video file having a first resolution; the video file is converted to a second video file having a second resolution.
Further, the resolution of the video file is greater than the first resolution, and the resolution of the video file is less than the second resolution.
Further, determining N video processing subsystems from the M video processing subsystems comprises: determining the running states of the M video processing subsystems; determining the N video processing subsystems from the M video processing subsystems based on the operating state.
Further, the M video processing subsystems include a first group of video processing subsystems and a second group of video processing subsystems; determining the N video processing subsystems from the first group of video processing subsystems when the video file meets a first preset condition; determining the N video processing subsystems from the second set of video processing subsystems when the video file does not satisfy the first preset condition; wherein the first preset condition comprises one or more of the following preset conditions: the resolution of the video file is higher than a preset resolution; the code rate of the video file is greater than a preset code rate; the size of the video file is higher than a preset size; the format of the video file belongs to a preset format.
Further, the method further comprises: determining a target video processing subsystem of the M video processing subsystems, wherein the running state of the target video processing subsystem meets a second preset condition; control the target video processing subsystem to perform a first operation, the first operation comprising one or more of: restarting operation, maintaining operation, sleeping operation, shutting down operation and updating operation.
Further, the operating state includes at least one of: operating temperature, operating duration, idle duration; the second preset condition includes at least one of: the operating temperature reaches a preset temperature; the operation time reaches a preset operation time; the idle time reaches a preset idle time.
Further, the M video processing subsystems comprise a system on chip.
Further, the M video processing subsystems include an ARM processor.
Further, after the video processing task is executed by the N video processing subsystems, the method further includes: receiving a playing request of terminal equipment, wherein the playing request is used for requesting to play the video file; and determining parameters of the terminal equipment, and sending the first video file or the second video file according to the parameters of the terminal equipment. In a second aspect, an embodiment of the present disclosure provides a video processing apparatus, including: the receiving module is used for receiving the video file; the video processing task determining module is used for determining a video processing task corresponding to the video file; the video processing subsystem determining module is used for determining N video processing subsystems from M video processing subsystems, wherein M and N are positive integers, and M is larger than 1; and the N video processing subsystems are used for executing the video processing tasks.
Further, the video processing task determining module is further configured to determine an attribute of the video file; determining the video processing task according to the attribute of the video file; wherein the attributes of the video file include at least one of: a resolution of the video file; a code rate of the video file; the size of the video file; the format of the video file.
Further, the video processing task includes at least one of: converting the video file to a first video file having a first resolution; the video file is converted to a second video file having a second resolution.
Further, the resolution of the video file is greater than the first resolution, and the resolution of the video file is less than the second resolution.
Further, the video processing subsystem determining module is further configured to determine the operating states of the M video processing subsystems; determining the N video processing subsystems from the M video processing subsystems based on the operating state.
Further, the M video processing subsystems include a first group of video processing subsystems and a second group of video processing subsystems; when the video file meets a first preset condition, the video processing subsystem determining module determines the N video processing subsystems from the first group of video processing subsystems; when the video file does not meet the first preset condition, a video processing subsystem determining module determines the N video processing subsystems from the second group of video processing subsystems; wherein the first preset condition comprises one or more of the following preset conditions: the resolution of the video file is higher than a preset resolution; the code rate of the video file is greater than a preset code rate; the size of the video file is higher than a preset size; the format of the video file belongs to a preset format.
Furthermore, the video processing device further comprises a control module, wherein the control module is used for determining a target video processing subsystem of the M video processing subsystems, the running state of which meets a second preset condition; control the target video processing subsystem to perform a first operation, the first operation comprising one or more of: restarting operation, maintaining operation, sleeping operation, shutting down operation and updating operation.
Further, the operating state includes at least one of: operating temperature, operating duration, idle duration; the second preset condition includes at least one of: the operating temperature reaches a preset temperature; the operation time reaches a preset operation time; the idle time reaches a preset idle time.
Further, the M video processing subsystems comprise a system on chip.
Further, the M video processing subsystems include an ARM processor.
Further, the receiving module is further configured to receive a play request of the terminal device, where the play request is used to request to play the video file; the video processing device further comprises a terminal device parameter determining module and a sending module, wherein the terminal device parameter determining module is used for determining the parameters of the terminal device, and the sending module is used for sending the first video file or the second video file according to the parameters of the terminal device.
In a third aspect, an embodiment of the present disclosure provides an electronic device, including: a memory for storing computer readable instructions; and one or more processors coupled with the memory for executing the computer readable instructions, such that the processors when executed implement the video processing method of any of the preceding first aspects.
In a fourth aspect, the present disclosure provides a non-transitory computer-readable storage medium, wherein the non-transitory computer-readable storage medium stores computer instructions, which when executed by a computer, cause the computer to perform the video processing method of any one of the foregoing first aspects.
The disclosure discloses a video processing method, a video processing device, an electronic device and a computer readable storage medium. The video processing method is characterized by comprising the following steps: receiving a video file; determining a video processing task corresponding to the video file; determining N video processing subsystems from M video processing subsystems, wherein M and N are positive integers, and M > 1; and executing the video processing task through the N video processing subsystems. The video processing method, the video processing device, the electronic equipment and the computer readable storage medium provided by the embodiment of the disclosure can be used for efficiently processing the video file through the special video processing system, so that the terminal equipment can conveniently play the video file.
The foregoing is a summary of the present disclosure, and for the purposes of promoting a clear understanding of the technical means of the present disclosure, the present disclosure may be embodied in other specific forms without departing from the spirit or essential attributes thereof.
Drawings
In order to more clearly illustrate the embodiments of the present disclosure or the technical solutions in the prior art, the drawings needed to be used in the description of the embodiments or the prior art will be briefly introduced below, and it is obvious that the drawings in the following description are some embodiments of the present disclosure, and other drawings can be obtained according to the drawings without creative efforts for those skilled in the art.
Fig. 1 is a schematic view of an application scenario to which a video processing method provided in the embodiment of the present disclosure is applied;
fig. 2 is a flowchart of a first embodiment of a video processing method according to an embodiment of the present disclosure;
fig. 3 is a flowchart of a second embodiment of a video processing method according to the present disclosure;
fig. 4 is a schematic structural diagram of an embodiment of a video processing apparatus according to the present disclosure;
fig. 5 is a schematic structural diagram of an electronic device provided according to an embodiment of the present disclosure.
Detailed Description
The embodiments of the present disclosure are described below with specific examples, and other advantages and effects of the present disclosure will be readily apparent to those skilled in the art from the disclosure in the specification. It is to be understood that the described embodiments are merely illustrative of some, and not restrictive, of the embodiments of the disclosure. The disclosure may be embodied or carried out in various other specific embodiments, and various modifications and changes may be made in the details within the description without departing from the spirit of the disclosure. It is to be noted that the features in the following embodiments and examples may be combined with each other without conflict. All other embodiments, which can be derived by a person skilled in the art from the embodiments disclosed herein without making any creative effort, shall fall within the protection scope of the present disclosure.
It is noted that various aspects of the embodiments are described below within the scope of the appended claims. It should be apparent that the aspects described herein may be embodied in a wide variety of forms and that any specific structure and/or function described herein is merely illustrative. Based on the disclosure, one skilled in the art should appreciate that one aspect described herein may be implemented independently of any other aspects and that two or more of these aspects may be combined in various ways. For example, an apparatus may be implemented and/or a method practiced using any number of the aspects set forth herein. Additionally, such an apparatus may be implemented and/or such a method may be practiced using other structure and/or functionality in addition to one or more of the aspects set forth herein.
It should be further noted that the drawings provided in the following embodiments are only for illustrating the basic idea of the present disclosure, and the drawings only show the components related to the present disclosure rather than being drawn according to the number, shape and size of the components in actual implementation, and the type, number and proportion of the components in actual implementation may be changed arbitrarily, and the layout of the components may be more complicated.
In addition, in the following description, specific details are provided to facilitate a thorough understanding of the examples. However, it will be understood by those skilled in the art that the aspects may be practiced without these specific details.
The video processing method provided in this embodiment may be executed by a video processing apparatus, which may be implemented as software, as hardware, or as a combination of software and hardware, for example, the video processing apparatus includes a computer device, so that the video processing method provided in this embodiment is executed by the computer device, and for example, the video processing apparatus includes a computer system, and optionally, the computer system includes a plurality of subsystems (for example, includes M video processing subsystems), so that the video processing method provided in this embodiment is executed by the computer system.
Fig. 1 is a schematic view of an application scenario to which the video processing method provided by the embodiment of the present disclosure is applied, and it should be noted that the application scenario shown in fig. 1 is taken as an example and is not limited to the application scenario of the embodiment of the present disclosure, and the embodiment of the present disclosure may also be applied to various appropriate application scenarios. As shown in fig. 1, a video processing apparatus 101 on the network side (for example, the video processing apparatus 101 serves as a server) receives information, for example, a video file from a terminal apparatus 102, the video processing apparatus 101 on the network side can process the video file, and further, a terminal device 103 can request and receive the processed video file from the video processing apparatus 101 and then play the processed video file. For the sake of clear and concise introduction to the embodiments of the present disclosure, a description will be given based on an application scenario of interaction between the video processing apparatus and the terminal device, and it will be understood by those skilled in the art that the embodiments of the present disclosure may also be applied to various appropriate scenarios. In the embodiment of the present disclosure, the terminal device belongs to a computer device, for example, the terminal device may be a mobile terminal device or a desktop terminal device, and the form, the category, and the like of the video processing apparatus and the terminal device are not limited in the embodiment of the present disclosure.
Fig. 2 is a flowchart of a first embodiment of a video processing method provided in the embodiments of the present disclosure, such as
As shown in fig. 2, the video processing method according to the embodiment of the present disclosure includes the following steps:
step S201, receiving a video file;
in step S201, the video processing apparatus may receive a video file from a terminal device through a network. For example, when a user operates a terminal device to shoot a video and wants to share the video through a video sharing platform, the user may send a video file corresponding to the video to a video processing device of the video sharing platform, and the video processing device may process the video file after receiving the video file.
Step S202, determining a video processing task corresponding to the video file.
As described in the background of the present disclosure, video files generated by different terminal devices may have different resolutions, bit rates, sizes, and/or formats, so that the video files generated by the terminal devices need to be processed so as to be played by other terminal devices. Therefore, in step S202, a video processing task corresponding to the video file is determined, so that executing the video processing task realizes processing of the video file.
In an optional embodiment, determining a video processing task corresponding to the video file includes: determining the attribute of the video file, and determining the video processing task according to the attribute of the video file, wherein the attribute of the video file comprises at least one of the following items: resolution of the video file, code rate of the video file, size of the video file, format of the video file. As will be understood by those skilled in the art, with the continuous update of the technology, the terminal devices used by most users support the conventional video file resolution and bitrate, and support the mainstream video file format, so that the video sharing platform can process the video file to conform to the conventional and mainstream video file resolution, bitrate, size, and/or video file format, so that the video file shared by the video sharing platform can be well supported by the terminal devices used by most users, and therefore the video processing apparatus can determine the video processing task according to the attributes (e.g., resolution, bitrate, size, and/or format) of the video file received in step S201. Optionally, if the resolution of the video file does not belong to the preset resolution range, the video processing task determined in step S202 includes processing the video file into a video file whose resolution belongs to the preset resolution range; optionally, if the bitrate of the video file does not belong to the preset bitrate range, the video processing task determined in step S202 includes processing the video file into a video file whose bitrate belongs to the preset bitrate range; optionally, if the size of the video file does not belong to the preset size range, the video processing task determined in step S202 includes processing the video file into a video file belonging to the preset size range; optionally, if the format of the video file does not belong to the preset format, the video processing task determined in step S202 includes processing the video file into a video file of the preset format; optionally, the video processing task determined in step S202 includes processing the video file into a video file in a preset format, in this embodiment, the video processing task includes a plurality of video processing tasks, for example, the preset format includes an rmvb format, an mpeg4 format, a wmv format, and a flv format, the video file received by the video processing apparatus in step S201 is in an mpeg4 format, then according to the format of the video file, the determined video processing task includes processing the video file into three video processing tasks, namely, an rmvb format, a wmv format, and a flv format, and the determined video processing task does not include processing the video file into a video processing task in an mpeg4 format because the format of the received video file is already in an mpeg4 format. It should be noted that the preset format includes one or more of various video formats known to those skilled in the art.
In another optional embodiment, the video processing task comprises at least one of: converting the video file to a first video file having a first resolution; the video file is converted to a second video file having a second resolution. Optionally, the first resolution is different from the second resolution. As understood by those skilled in the art, the terminal device used by the user may mainly support one resolution or can optimally support one resolution according to the screen size and the computing power thereof, so that in order to enable the terminal device used by the user to achieve a better playing effect when playing the video, the video processing task determined in step S202 may include converting the video file into a video processing task having the resolution that can be optimally supported by the terminal device, that is, converting the video file into a first video file having a first resolution, for example, the resolution that is optimally supported by the terminal device. Since the resolutions that can be optimally supported by different terminal devices may be different, optionally, the video processing task determined in step S202 may further include converting the video file into a second video file having a second resolution, for example, the resolution that is optimally supported by the different terminal devices, where the second resolution is different from the first resolution. With the above-described embodiment, after receiving the video file in step S201, the video processing task determined in step S202 includes processing the video file into video files with different resolutions, thereby enabling the video files to be well supported by different terminal devices. Optionally, the resolution of the video file is greater than the first resolution, and/or the resolution of the video file is less than the second resolution. That is, the video processing task determined in step S202 may include converting the video file to have a lower first resolution and/or converting the video file to have a higher second resolution. For example, according to the prior art, for an image of each frame of the video file, the resolution may be reduced or increased through an image processing algorithm, so as to obtain a video file with a lower or higher resolution, further, in the above process, the processing process for the video file may include steps of decoding, scaling, processing and encoding through the image algorithm, and the like, which is not described in detail in this disclosure. Moreover, in the above optional embodiment, the resolution, the first resolution, and the second resolution may also be replaced by a bitrate, a first bitrate, and a second bitrate, respectively, that is, the video processing task includes: converting the video file into a first video file with a first bitrate; and/or converting the video file into a second video file with a second bitrate, optionally, the bitrate of the video file is greater than the first bitrate, and/or the bitrate of the video file is less than the second bitrate, and the same or corresponding description refers to the above optional embodiment, which is not repeated herein.
Step S203: determining N video processing subsystems from M video processing subsystems, wherein M and N are positive integers, and M > 1;
as mentioned above, the video processing task determined in step S202 may include multiple video processing tasks, and the video sharing platform may receive multiple video files from the terminal devices of multiple users in the same period, so that more video processing tasks are determined for the multiple video files, and therefore in the embodiment of the present disclosure, M video processing subsystems for performing the video processing tasks are provided, where M is a positive integer and M >1, that is, the embodiment of the present disclosure may perform the video processing tasks in parallel and efficiently through the M video processing subsystems, in one embodiment, the video processing apparatus includes the M video processing subsystems, and in another embodiment, the video processing apparatus does not include the M video processing subsystems. For the video task corresponding to the video file received in step S201, in step S203, N video processing subsystems may be determined from M video processing subsystems to process the video task corresponding to the video file, where N is a positive integer and N is less than or equal to M.
In an alternative embodiment, determining N video processing subsystems from among the M video processing subsystems comprises: determining the operating states of the M video processing subsystems, and determining the N video processing subsystems from the M video processing subsystems based on the operating states. For example, the video processing apparatus may monitor the operating states of the M video processing subsystems at regular time, in real time, or before executing step S203, where the operating states include, but are not limited to, an operating duration, an idle duration, an operating temperature, an occupied memory, an idle memory, a processing performance, and the like of the video processing subsystems, so as to determine the N video processing subsystems according to the operating states of the M video processing subsystems, for example, determine the N video processing subsystems with the highest processing performance from the M video processing subsystems, so as to enable the video processing apparatus to exert the strongest performance to process the video processing task corresponding to the video file; or determining N video processing subsystems with the longest idle time from the M video processing subsystems so as to balance the load of the M video processing subsystems. Of course, other strategies may also be adopted to determine the N video processing subsystems according to the operating states of the M video processing subsystems, which is not limited in the embodiment of the present disclosure.
In another alternative embodiment, the M video processing subsystems include a first set of video processing subsystems and a second set of video processing subsystems; determining the N video processing subsystems from the first group of video processing subsystems when the video file meets a first preset condition; wherein the first preset condition comprises one or more of the following preset conditions: the resolution of the video file is higher than a preset resolution; the code rate of the video file is greater than a preset code rate; the size of the video file is higher than a preset size; the format of the video file belongs to a preset format. Optionally, when the video file does not satisfy the first preset condition, the N video processing subsystems are determined from the second group of video processing subsystems. For example, a first group of video processing subsystems of the M video processing subsystems is configured with a dedicated image processor (e.g., GPU) so as to be able to process a video file with high resolution and/or high bitrate more efficiently, and thus when the resolution of the video file is higher than a preset resolution and/or the bitrate of the video file is higher than a preset bitrate, the N video processing subsystems are determined from the first group of video processing subsystems, otherwise, the N video processing subsystems are determined from the second group of video processing subsystems; also for example, a first group of video processing subsystems among the M video processing subsystems has a low power consumption characteristic, so that less power can be consumed in processing a large file and/or a video file of a preset format, and thus when the size of the video file is higher than the preset size and/or the format of the video file belongs to the preset format, the N video processing subsystems are determined from the first group of video processing subsystems, otherwise, the N video processing subsystems are determined from the second group of video processing subsystems. Of course, when the N video processing subsystems are determined from the first group or the second group of video processing subsystems, the N video processing subsystems may also be determined according to the operating state of each video processing subsystem in the first group or the second group of video processing subsystems, and the specific implementation manner refers to the foregoing embodiments and is not described herein again.
Step S204: and executing the video processing task through the N video processing subsystems.
In step S204, by executing the video processing tasks through the N video processing subsystems determined in step S203, optionally, the video processing tasks may be equally distributed to the N video processing subsystems, for example, the video processing tasks determined in step S202 include processing the video file into four video processing tasks of rmvb format, mpeg4 format, wmv format, and flv format, and if four video processing subsystems are determined to execute the video processing tasks (i.e., N-4) in step S203, then one of the four video processing tasks may be executed by each of the four video processing subsystems; of course, the video processing tasks may also be distributed to the N video processing subsystems non-uniformly, for example, in step S203, it is determined that two video processing subsystems execute the video processing tasks (i.e., N ═ 2), and for the above four video processing tasks, one video processing subsystem of the two video processing subsystems may process one video processing task, and the other video processing subsystem may process the remaining three video processing tasks.
In an alternative embodiment, the M video processing subsystems comprise a system on chip. In yet another alternative embodiment, the M video processing subsystems include an arm (advanced RISC machine) processor. For example, one, a plurality of or all of the M video processing subsystems comprise a system on chip, and for example, one, a plurality of or all of the M video processing subsystems comprise one or a plurality of ARM processors, and may further comprise one or a plurality of GPUs, APUs, and/or codec hard-core processors, thereby having the characteristics of high-speed computing capability and low energy consumption. Optionally, the M video processing subsystems are independent, that is, the M video processing subsystems do not communicate directly or do not communicate with each other, so that the video processing tasks can be executed independently, and high reliability is achieved.
According to the embodiment of the disclosure, after receiving a video file from a terminal device, a video processing device determines a video processing task corresponding to the video file, and determines N video processing subsystems from M video processing subsystems to execute the video processing task in parallel, so that the video file can be efficiently processed, and a plurality of video files corresponding to the video file and suitable for different terminal devices are generated, thereby facilitating the different terminal devices to play the video file.
As shown in fig. 3, in the second embodiment of the video processing method of the present disclosure, in step S204: after the video processing tasks are executed by the N video processing subsystems, the method further includes step S205 and step S206, where the step S205 includes: receiving a playing request of terminal equipment, wherein the playing request is used for requesting to play the video file; the step S206 includes: and determining parameters of the terminal equipment, and sending the first video file or the second video file according to the parameters of the terminal equipment. As an example, the parameter of the terminal device includes an optimal resolution supported by the terminal device, a screen size of the terminal device, a screen parameter of the terminal device, and/or a processor parameter of the terminal device, and so on, so that in step S206, the video processing apparatus sends a first video file or a second video file to the terminal device according to the parameter of the terminal device, for example, the parameter of the terminal device includes the screen size of the terminal device, when the screen size of the terminal device is smaller than (or equal to) a preset size, the first video file is sent to the terminal device, when the screen size of the terminal device is larger than (or equal to) the preset size, the second video file is sent to the terminal device, wherein the resolution of the first video file is smaller than the resolution of the second video file, and if the screen size of the terminal equipment is smaller than (or equal to) the preset size, sending the video file with high resolution to the terminal equipment so as to send the video file more suitable for the terminal equipment to the terminal equipment, thereby facilitating the terminal equipment to play the video file.
In an optional embodiment, the video processing method further includes: determining a target video processing subsystem of the M video processing subsystems, wherein the running state of the target video processing subsystem meets a second preset condition; control the target video processing subsystem to perform a first operation, the first operation comprising one or more of: restarting operation, maintaining operation, sleeping operation, shutting down operation and updating operation. Wherein the target video processing subsystem may comprise one or more of the M video processing subsystems. Optionally, the operating state includes at least one of the following: operating temperature, operating duration, idle duration; the second preset condition includes at least one of: the operating temperature reaches a preset temperature; the operation time reaches a preset operation time; the idle time reaches a preset idle time. In this embodiment, the video processing apparatus may monitor, in a timed manner or in real time, the operating states of the M video processing subsystems, where the operating states include, but are not limited to, an operating duration, an idle duration, an operating temperature, an occupied memory, an idle memory, a processing performance, and the like of the video processing subsystems, so as to control a target video processing subsystem of the M video processing subsystems to execute the first operation according to the operating states of the M video processing subsystems. As an example, the video processing apparatus monitors the running states of the M video processing subsystems at regular time, and finds that the idle duration of a target video processing subsystem among the M video processing subsystems reaches a preset idle duration, that is, the current video processing tasks needing to be processed are fewer, and the target video processing subsystem is already in an idle state for a long time, so the video processing apparatus may control the target video processing subsystem to perform a sleep operation or a shutdown operation to save electric energy. As another example, the video processing apparatus monitors the operating states of the M video processing subsystems at regular time, finds that the system version of a target video processing subsystem of the M video processing subsystems is older, and then the video processing apparatus may control the target video processing subsystem to perform an update operation to update the system version or control the target video processing subsystem to perform a maintenance operation to maintain the target video processing subsystem in a better operating state. By the mode, the video device can realize the unified management and scheduling of the M video processing subsystems, and efficiently and reliably control the M video processing subsystems to execute video processing tasks.
Fig. 4 is a schematic structural diagram of an embodiment of a video processing apparatus 400 according to an embodiment of the present disclosure, and as shown in fig. 4, the apparatus includes a receiving module 401, a video processing task determining module 402, and a video processing subsystem determining module 403.
The receiving module 401 is configured to receive a video file;
the video processing task determining module 402 is configured to determine a video processing task corresponding to the video file;
the video processing subsystem determining module 403 is configured to determine N video processing subsystems from M video processing subsystems, where M and N are positive integers, and M > 1;
the N video processing subsystems are used for executing the video processing tasks.
In an optional embodiment, the video processing apparatus 400 further includes a terminal device parameter determining module 404 and a sending module 405, and in this optional embodiment, the receiving module 401 of the video processing apparatus 400 is further configured to receive a play request of a terminal device, where the play request is used to request to play the video file; the terminal device parameter determining module 404 is configured to determine a parameter of the terminal device; the sending module 405 is configured to send the first video file or the second video file to the terminal device according to the parameter of the terminal device.
The apparatus shown in fig. 4 may perform the method of the embodiment shown in fig. 2 and/or fig. 3, and a part not described in detail in this embodiment may refer to the related description of the embodiment shown in fig. 2 and/or fig. 3. The implementation process and technical effect of the technical solution refer to the description in the embodiment shown in fig. 2 and/or fig. 3, and are not described herein again.
Referring now to FIG. 5, a block diagram of an electronic device 500 suitable for use in implementing embodiments of the present disclosure is shown. The electronic devices in the embodiments of the present disclosure may include, but are not limited to, mobile terminals such as mobile phones, notebook computers, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablet computers), PMPs (portable multimedia players), in-vehicle terminals (e.g., car navigation terminals), and the like, and fixed terminals such as digital TVs, desktop computers, and the like. The electronic device shown in fig. 5 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present disclosure.
As shown in fig. 5, electronic device 500 may include a processing means (e.g., central processing unit, graphics processor, etc.) 501 that may perform various appropriate actions and processes in accordance with a program stored in a Read Only Memory (ROM)502 or a program loaded from a storage means 508 into a Random Access Memory (RAM) 503. In the RAM 503, various programs and data necessary for the operation of the electronic apparatus 500 are also stored. The processing device 501, the ROM 502, and the RAM 503 are connected to each other through a bus or a communication line 504. An input/output (I/O) interface 505 is also connected to the bus or communication line 504.
Generally, the following devices may be connected to the I/O interface 505: input devices 506 including, for example, a touch screen, touch pad, keyboard, mouse, image sensor, microphone, accelerometer, gyroscope, etc.; output devices 507 including, for example, a Liquid Crystal Display (LCD), speakers, vibrators, and the like; storage devices 508 including, for example, magnetic tape, hard disk, etc.; and a communication device 509. The communication means 509 may allow the electronic device 500 to communicate with other devices wirelessly or by wire to exchange data. While fig. 5 illustrates an electronic device 500 having various means, it is to be understood that not all illustrated means are required to be implemented or provided. More or fewer devices may alternatively be implemented or provided.
In particular, according to an embodiment of the present disclosure, the processes described above with reference to the flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code for performing the method illustrated in the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network via the communication means 509, or installed from the storage means 508, or installed from the ROM 502. The computer program performs the above-described functions defined in the methods of the embodiments of the present disclosure when executed by the processing device 501.
It should be noted that the computer readable medium in the present disclosure can be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may include, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present disclosure, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In contrast, in the present disclosure, a computer readable signal medium may comprise a propagated data signal with computer readable program code embodied therein, either in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: electrical wires, optical cables, RF (radio frequency), etc., or any suitable combination of the foregoing.
The computer readable medium may be embodied in the electronic device; or may exist separately without being assembled into the electronic device.
The computer readable medium carries one or more programs which, when executed by the electronic device, cause the electronic device to perform the video processing method in the above embodiments.
Alternatively, the computer readable medium carries one or more programs, which when executed by the electronic device, cause the electronic device to perform the video processing method in the above embodiments.
Computer program code for carrying out operations for aspects of the present disclosure may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, Smalltalk, C + +, and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or the connection may be made to an external computer (for example, through the Internet using an Internet service provider).
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The units described in the embodiments of the present disclosure may be implemented by software or hardware. Where the name of an element does not in some cases constitute a limitation on the element itself.
The foregoing description is only exemplary of the preferred embodiments of the disclosure and is illustrative of the principles of the technology employed. It will be appreciated by those skilled in the art that the scope of the disclosure herein is not limited to the particular combination of features described above, but also encompasses other embodiments in which any combination of the features described above or their equivalents does not depart from the spirit of the disclosure. For example, the above features and (but not limited to) the features disclosed in this disclosure having similar functions are replaced with each other to form the technical solution.

Claims (11)

1. A video processing method, comprising:
receiving a video file;
determining a video processing task corresponding to the video file;
determining N video processing subsystems from M video processing subsystems, wherein M and N are positive integers, and M > 1;
executing the video processing tasks by the N video processing subsystems;
wherein the M video processing subsystems comprise a first set of video processing subsystems and a second set of video processing subsystems;
the determining N video processing subsystems from among the M video processing subsystems comprises:
determining the N video processing subsystems from the first group of video processing subsystems when the video file meets a first preset condition;
determining the N video processing subsystems from the second set of video processing subsystems when the video file does not satisfy the first preset condition;
wherein the first preset condition comprises one or more of the following preset conditions:
the resolution of the video file is higher than a preset resolution;
the code rate of the video file is greater than a preset code rate;
the size of the video file is higher than a preset size;
the format of the video file belongs to a preset format;
determining a target video processing subsystem of the M video processing subsystems, wherein the running state of the target video processing subsystem meets a second preset condition;
control the target video processing subsystem to perform a first operation, the first operation comprising one or more of: restarting operation, maintaining operation, dormancy operation, shutdown operation and updating operation;
wherein the operating state comprises at least one of:
operating temperature, operating duration, idle duration;
the second preset condition includes at least one of:
the operating temperature reaches a preset temperature;
the operation time reaches a preset operation time;
the idle time reaches a preset idle time.
2. The video processing method of claim 1, wherein determining the video processing task corresponding to the video file comprises:
determining attributes of the video file;
determining the video processing task according to the attribute of the video file; wherein,
the attributes of the video file include at least one of:
a resolution of the video file;
a code rate of the video file;
the size of the video file;
the format of the video file.
3. The video processing method according to claim 1 or 2, wherein the video processing task comprises at least one of:
converting the video file to a first video file having a first resolution;
the video file is converted to a second video file having a second resolution.
4. The video processing method of claim 3, wherein the video file has a resolution greater than the first resolution and a resolution less than the second resolution.
5. The video processing method of claim 1, wherein determining N video processing subsystems from among the M video processing subsystems comprises:
determining the running states of the M video processing subsystems;
determining the N video processing subsystems from the M video processing subsystems based on the operating state.
6. The video processing method of claim 1, wherein the M video processing subsystems comprise a system-on-chip.
7. The video processing method of claim 1, wherein the M video processing subsystems comprise ARM processors.
8. The video processing method of claim 3, further comprising, after performing the video processing task by the N video processing subsystems:
receiving a playing request of terminal equipment, wherein the playing request is used for requesting to play the video file;
and determining parameters of the terminal equipment, and sending the first video file or the second video file according to the parameters of the terminal equipment.
9. A video processing apparatus, comprising:
the receiving module is used for receiving the video file;
the video processing task determining module is used for determining a video processing task corresponding to the video file;
a video processing subsystem determining module for determining N video processing subsystems from M video processing subsystems, wherein M and N are positive integers, and M > 1;
the N video processing subsystems are used for executing the video processing tasks;
wherein the M video processing subsystems comprise a first set of video processing subsystems and a second set of video processing subsystems;
the determining N video processing subsystems from among the M video processing subsystems comprises:
determining the N video processing subsystems from the first group of video processing subsystems when the video file meets a first preset condition; determining the N video processing subsystems from the second set of video processing subsystems when the video file does not satisfy the first preset condition; wherein the first preset condition comprises one or more of the following preset conditions: the resolution of the video file is higher than a preset resolution; the code rate of the video file is greater than a preset code rate; the size of the video file is higher than a preset size; the format of the video file belongs to a preset format;
the control module is used for determining a target video processing subsystem of the M video processing subsystems, wherein the running state of the target video processing subsystem meets a second preset condition; control the target video processing subsystem to perform a first operation, the first operation comprising one or more of: restarting operation, maintaining operation, dormancy operation, shutdown operation and updating operation; wherein the operating state comprises at least one of: operating temperature, operating duration, idle duration; the second preset condition includes at least one of: the operating temperature reaches a preset temperature; the operation time reaches a preset operation time; the idle time reaches a preset idle time.
10. An electronic device, comprising:
a memory for storing computer readable instructions; and
a processor coupled to the memory for executing the computer readable instructions such that the processor when executed implements the video processing method of any of claims 1-8.
11. A non-transitory computer-readable storage medium storing computer-readable instructions that, when executed by a computer, cause the computer to perform the video processing method of any one of claims 1-8.
CN201910143598.2A 2019-02-26 2019-02-26 Video processing method, video processing device, electronic equipment and computer-readable storage medium Active CN109951737B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910143598.2A CN109951737B (en) 2019-02-26 2019-02-26 Video processing method, video processing device, electronic equipment and computer-readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910143598.2A CN109951737B (en) 2019-02-26 2019-02-26 Video processing method, video processing device, electronic equipment and computer-readable storage medium

Publications (2)

Publication Number Publication Date
CN109951737A CN109951737A (en) 2019-06-28
CN109951737B true CN109951737B (en) 2022-02-25

Family

ID=67007725

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910143598.2A Active CN109951737B (en) 2019-02-26 2019-02-26 Video processing method, video processing device, electronic equipment and computer-readable storage medium

Country Status (1)

Country Link
CN (1) CN109951737B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111901620B (en) * 2020-07-24 2022-07-29 北京达佳互联信息技术有限公司 Live playback video generation method and device, electronic equipment and storage medium
CN114866808A (en) * 2022-06-10 2022-08-05 深圳市瑞驰信息技术有限公司 High-performance video processing system and method and electronic equipment

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101945278A (en) * 2010-09-15 2011-01-12 中国科学院深圳先进技术研究院 Video self-adaptive transcoding method and system
CN103686209A (en) * 2013-12-13 2014-03-26 乐视网信息技术(北京)股份有限公司 Transcoding and processing method and system with diverse mechanisms
CN104363463A (en) * 2014-11-10 2015-02-18 能力天空科技(北京)有限公司 Video processing method, device and system

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7617515B1 (en) * 2001-05-24 2009-11-10 Vixs Systems, Inc. Method and apparatus for managing resources in a multimedia system
US9137497B2 (en) * 2007-04-11 2015-09-15 At&T Intellectual Property I, Lp Method and system for video stream personalization
KR20130068091A (en) * 2011-12-15 2013-06-25 삼성전자주식회사 Method for providing video and display apparatus thereof
CN103220577B (en) * 2012-01-18 2015-07-29 腾讯科技(深圳)有限公司 A kind of video broadcasting method, device and system
CN103702139B (en) * 2013-12-13 2017-02-01 华中科技大学 Video-on-demand system based on scalable coding under mobile environment
CN106961628B (en) * 2017-03-24 2020-04-28 北京金山安全软件有限公司 Video playing method and device and electronic equipment

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101945278A (en) * 2010-09-15 2011-01-12 中国科学院深圳先进技术研究院 Video self-adaptive transcoding method and system
CN103686209A (en) * 2013-12-13 2014-03-26 乐视网信息技术(北京)股份有限公司 Transcoding and processing method and system with diverse mechanisms
CN104363463A (en) * 2014-11-10 2015-02-18 能力天空科技(北京)有限公司 Video processing method, device and system

Also Published As

Publication number Publication date
CN109951737A (en) 2019-06-28

Similar Documents

Publication Publication Date Title
CN109582310B (en) Data processing method and device, electronic equipment and computer readable storage medium
CN112954354B (en) Video transcoding method, device, equipment and medium
CN112379982B (en) Task processing method, device, electronic equipment and computer readable storage medium
CN114979762B (en) Video downloading, transmission method, device, terminal equipment, server and medium
CN110764892A (en) Task processing method, device and computer readable storage medium
US20190114989A1 (en) Systems and methods for image optimization
CN113521728A (en) Cloud application implementation method and device, electronic equipment and storage medium
CN110290398B (en) Video issuing method and device, storage medium and electronic equipment
CN109951737B (en) Video processing method, video processing device, electronic equipment and computer-readable storage medium
CN116541174A (en) Storage device capacity processing method, device, equipment and storage medium
CN118201116B (en) Communication resource allocation method, device, equipment and storage medium
CN111290861A (en) Message processing method and device and electronic equipment
CN117014590A (en) Image processing method, device, terminal and storage medium
CN113850055B (en) Data processing method, device, storage medium and product
CN115314718B (en) Live broadcast data processing method, device, equipment and medium
KR20160084215A (en) Method for dynamic processing application for cloud streaming service and apparatus for the same
CN111258670B (en) Method and device for managing component data, electronic equipment and storage medium
CN114528110A (en) Task processing method, device and system
CN115775290A (en) Animation frame rate processing method, device, equipment and storage medium
CN112163176A (en) Data storage method and device, electronic equipment and computer readable medium
CN112148448A (en) Resource allocation method, device, equipment and computer readable medium
CN114647472B (en) Picture processing method, apparatus, device, storage medium, and program product
CN114928862B (en) System overhead reduction method and system based on task unloading and service caching
CN112578897B (en) Control method, device, terminal and storage medium of electronic device
CN114153620B (en) Optimal allocation method and device for Hudi operating environment resources

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
CP01 Change in the name or title of a patent holder
CP01 Change in the name or title of a patent holder

Address after: 100041 B-0035, 2 floor, 3 building, 30 Shixing street, Shijingshan District, Beijing.

Patentee after: Douyin Vision Co.,Ltd.

Address before: 100041 B-0035, 2 floor, 3 building, 30 Shixing street, Shijingshan District, Beijing.

Patentee before: Tiktok vision (Beijing) Co.,Ltd.

Address after: 100041 B-0035, 2 floor, 3 building, 30 Shixing street, Shijingshan District, Beijing.

Patentee after: Tiktok vision (Beijing) Co.,Ltd.

Address before: 100041 B-0035, 2 floor, 3 building, 30 Shixing street, Shijingshan District, Beijing.

Patentee before: BEIJING BYTEDANCE NETWORK TECHNOLOGY Co.,Ltd.