CN-122001862-A - Subway differentiated content playing method and device based on multichannel multicasting
Abstract
The embodiment of the disclosure discloses a subway differentiated content playing method and device based on multichannel multicasting, wherein the method comprises the steps of configuring a plurality of independent logic playing channels based on existing PIS of a subway, and constructing a video resource library with video source file parameter information. And establishing a playing plan and workflow comprising a default playing list and a plurality of timing playing lists associated with time windows for the logic playing channel based on the video resource library, matching the time windows according to a preset period to determine an active playing list to be played currently, and then pushing video files in the active playing list to UDP multicast addresses corresponding to the logic playing channel to realize the playing of different subway regions at the same or different times. The embodiment of the disclosure realizes multi-region and time-division accurate delivery of subway advertisement content, solves the problems of single content and inconvenient switching of the traditional PIS system, and remarkably improves the accuracy of advertisement delivery and the commercial value of the PIS system.
Inventors
- LING CHUNYUAN
- ZHANG YI
- XU JIE
- LIU XINLIN
- YANG SHILONG
Assignees
- 凌春源
Dates
- Publication Date
- 20260508
- Application Date
- 20260119
Claims (10)
- 1. The subway differentiated content playing method based on the multichannel multicasting is characterized by comprising the following steps of: Step S110, dividing a plurality of playing terminals into different playing areas based on a communication network and a multicast architecture of an existing passenger information system of the subway, and configuring a unique UDP multicast address for each playing area to generate independent logic playing channels; Step S120, extracting playing time lengths and coding format information of a plurality of video source files through a video information extraction tool, and storing the video source files under a preset directory to generate a video resource library; step S130, a playing plan is established for each logic playing channel based on the video resource library, wherein the playing plan comprises a default playing list and a plurality of timing playing lists associated with time windows; Step S140, a workflow is established for each logical playing channel, the workflow is matched with a time window according to a preset period, and is used for determining an active playing list to be played currently, and pushing video files in the active playing list to UDP multicast addresses corresponding to the logical playing channels, so as to realize the playing of different subway regions with different contents at the same or different times.
- 2. The method according to claim 1, wherein the workflow performs the following steps at preset cycles: Step S141, matching the current time with each time window in the playing plan, and if the time windows which are successfully matched exist, activating the corresponding timing play list; Step S142, invoking an FFmpeg transcoding tool to transcode the video file in the active playlist into a standard network stream format to generate a video stream; step S143, based on UDP multicast protocol, pushing the video stream to UDP multicast address corresponding to the logic playing channel, and receiving and decoding playing the video stream by playing terminal in corresponding UDP multicast address, to realize playing of different subway regions at the same or different time.
- 3. The method according to claim 2, wherein matching the current time with each of the time windows in the play plan in step S141 comprises: when the starting time of the time window is earlier than the ending time, judging whether the current time is between the starting time and the ending time, if so, matching is successful, and if not, matching is unsuccessful; when the starting time of the time window is later than the ending time, judging whether the current time is after the starting time or before the ending time, if so, matching is successful, and if not, matching is unsuccessful.
- 4. The method according to claim 2, wherein the workflow further performs a step S144 of status monitoring and fault self-healing at preset cycles, wherein: the state monitoring step is to monitor the survival state of the logic playing channel; And the fault self-healing step is that when the transcoding state is abnormal, the workflow executes an index-based back-off retry strategy on the FFmpeg transcoding tool to perform continuous retry, and when the number of continuous retry failures exceeds a preset threshold, the retry is stopped and an error alarm is triggered.
- 5. The method of claim 2, wherein transcoding the video files in the active playlist to a standard network streaming format in step S142 comprises: based on system load, the FFmpeg transcoding tool dynamically selects a CPU software encoder or a hardware encoder based on a display card; When the hardware encoder is selected, the CPU load is reduced by adding a hardware acceleration instruction to the parameters of the FFmpeg transcoding tool.
- 6. The method of claim 1, further comprising step S150 of logically playing a hot reload of the channel: Based on a configuration update request initiated by a user, receiving and analyzing an instruction in the configuration update request to obtain a play plan update configuration in a JSON format; writing the play plan updating configuration into a memory, and updating the play plan historical configuration in the memory into a play plan updating configuration; adding and deleting logical play channels through the play plan updating configuration and the play plan history configuration; terminating the pushing process of the video stream for the deleted logical play channel; and executing an initialization command of the newly added logic playing channel and starting a workflow of the newly added logic playing channel for the newly added logic playing channel.
- 7. The method of claim 1, further comprising step S160 of deploying the application step: In the deployment application stage, generating a test data set comprising a plurality of logic playing channels by simulating a target subway environment, wherein the logic playing channels are provided with workflows and playing plans of preset configuration templates; based on the test data set, performing parameter tuning and stability verification on the step executed by the workflow according to a preset period and the hot reload of the workflow; After parameter tuning and stability verification are completed, broadcasting contents are pushed to station areas with different functional attributes through the logic broadcasting channels in corresponding time windows, and different subway areas are used for broadcasting differentiated contents at the same time or at different times.
- 8. A subway differentiated content playing device based on multichannel multicasting, which is characterized by comprising: The logic playing channel construction module is used for dividing a plurality of playing terminals into different playing areas according to a communication network and a multicast architecture of an existing passenger information system of the subway, and configuring a unique UDP multicast address for each playing area to generate mutually independent logic playing channels; The video resource library construction module is used for extracting the playing time length and the coding format information of a plurality of video source files through the video information extraction tool, and storing the video source files under a preset directory to generate a video resource library; a play plan building module, configured to build a play plan for each of the logical play channels according to the video resource library, where the play plan includes a default play list and at least one timed play list associated with a time window; And the workflow execution module is used for establishing a workflow for each logic playing channel and executing a pushing step through the workflow according to a preset period.
- 9. An electronic device, comprising: a memory for storing a computer program product; A processor for executing a computer program product stored in said memory, which, when executed, implements the method of any of the preceding claims 1-7.
- 10. A computer readable storage medium having stored thereon computer program instructions, which when executed by a processor, implement the method of any of the preceding claims 1-7.
Description
Subway differentiated content playing method and device based on multichannel multicasting Technical Field The disclosure relates to the technical field of subway passenger information systems, in particular to a method and a device for playing subway differentiated contents based on multichannel multicasting. Background With the acceleration of the urban process and the popularization of digital media technology, a Passenger Information System (PIS) of a subway has gradually evolved from a basic information broadcasting platform to an integrated digital carrier for carrying public propaganda and business operation. The current mainstream technology mostly adopts a central broadcasting or local circulation playing mode, and although the stability of public information release is ensured, a significant bottleneck exists in the aspect of commercial value mining. With the increase of the requirements of advertisers on scenerization and accurate delivery, the core challenge faced by the system is how to realize differentiated and dynamic content distribution of massive terminals in space (different site attributes) and time (different time periods) dimensions under the existing communication network, so that the commercial potential of the system is fully activated while guaranteeing public functions. In response to this need, the prior art solutions all have significant limitations. Firstly, the unicast mode is adopted to independently push each terminal, which can cause exponential pressure of network bandwidth and server resources, and is difficult to deploy in large scale. And secondly, the scheme of local storage and preset scheduling of the terminal is relied on, and the real-time bandwidth is saved, but the content update is lagged, so that the requirements of flexible adjustment of advertisement scheduling and real-time inserting of emergency information cannot be met. Thirdly, the method of adding fixed broadcast channels can only realize limited 'one-out-of-many' broadcast control, and cannot adapt to site-level refined operation, and the system flexibility and the resource utilization rate are still low. These schemes have difficulty in achieving a compromise between efficiency, flexibility, real-time and cost. Accordingly, there is a need for one or more approaches to address the above-described problems. It should be noted that the information disclosed in the above background section is only for enhancing understanding of the background of the present disclosure and thus may include information that does not constitute prior art known to those of ordinary skill in the art. Disclosure of Invention The present disclosure is directed to a method, apparatus, device, and medium for playing subway differentiated content based on multi-channel multicast, which, in turn, at least partially overcome one or more of the problems due to the limitations and disadvantages of the related art. According to one aspect of the present disclosure, a method for playing subway differentiated contents based on multi-channel multicast is provided, which includes the steps of S110, dividing a plurality of playing terminals into different playing areas based on a communication network and a multicast architecture of an existing passenger information system of a subway, and configuring a unique UDP multicast address for each playing area to generate independent logic playing channels; Step S120, extracting playing time lengths and coding format information of a plurality of video source files through a video information extraction tool, and storing the video source files under a preset directory to generate a video resource library; step S130, a playing plan is established for each logic playing channel based on the video resource library, wherein the playing plan comprises a default playing list and a plurality of timing playing lists associated with time windows; Step S140, a workflow is established for each logical playing channel, the workflow is matched with a time window according to a preset period, and is used for determining an active playing list to be played currently, and pushing video files in the active playing list to UDP multicast addresses corresponding to the logical playing channels, so as to realize the playing of different subway regions with different contents at the same or different times. In an exemplary embodiment of the present disclosure, the workflow performs the following steps at a preset period: Step S141, matching the current time with each time window in the playing plan, and if the time windows which are successfully matched exist, activating the corresponding timing play list; Step S142, invoking an FFmpeg transcoding tool to transcode the video file in the active playlist into a standard network stream format to generate a video stream; step S143, based on UDP multicast protocol, pushing the video stream to UDP multicast address corresponding to the logic playing channel, and receiving a