Medical video image live broadcast all-in-one
Technical Field
The invention relates to the technical field of video image transmission for remote medical treatment, in particular to a medical video image live broadcast all-in-one machine.
Background
In China, the application of video acquisition devices such as various video acquisition cards, hard disk recorders and the like greatly improves the remote medical efficiency. Many medical research and development teams seek various technical means without losing time. In order to realize high-efficiency transmission of various medical signals such as medical images and videos, compatibility and high efficiency of various video acquisition devices are focused on.
In practical applications, we will find that the video output formats of various medical devices are five-in-eight, and that conventional video acquisition devices tend to be more non-standard. When the medical equipment is used for various medical equipment with various brands in hospitals, the engineers of the manufacturer are queried to know the video output interface, signal format, parameters and the like of the equipment. Special acquisition equipment is required for the device. Whereas when a hospital needs to receive signals from other devices, the previous devices are likely to be unmatched. This requires repeating the previous operation again and re-purchasing a new device. The result is that the capital is wasted, and the equipment can be scattered and arranged beside the butt joint equipment due to the fact that the equipment is not produced in a customized mode, the equipment cannot be fixedly installed, space is occupied, and the damage possibility is greatly improved.
In addition, in practical application, we also find that the video image used in telemedicine has the characteristics of fixed field (back) view and small picture dynamic, and also has the requirements of high definition, high stability and low delay. At present, a live broadcast system facing a consumer market and an encoding and decoding method thereof cannot well adapt to the demand characteristics of telemedicine. The transmission and conversion formats have a plurality of factors such as poor definition, incompatibility, easy attenuation and the like, so that the use is greatly influenced by blurring, jitter and the like of images and video quality after the signals are transmitted in a long distance. Especially when transmitting under the harsher communication environment such as wireless network, often cause the picture to block or blur because of losing packet etc. can not reach the level that the telemedicine needs.
Disclosure of Invention
The invention aims to solve the technical problems that: the medical video image live broadcast all-in-one machine is based on high-definition video signal processing and solves the compatibility problem of various video acquisition equipment.
The technical scheme provided by the invention for solving the technical problems is as follows: the medical video image live broadcast all-in-one machine comprises a cabinet, wherein a main board, a power module for supplying power and a video management server positioned outside the cabinet are arranged in the cabinet;
the mainboard is sequentially provided with a video acquisition unit, a video processing unit and a video compression coding unit which are connected through an I/O bus;
the video acquisition unit is provided with a plurality of video signal access ports and is used for being connected to the video output ends of various existing medical equipment and acquiring multiple paths of instant original video signals;
the video processing unit comprises a video preprocessing module and an HD-SDI transcoding module, and is suitable for converting the multipath instant original video signals into high-definition standard video signals in an HD-SDI format after preprocessing;
the video compression and encoding unit comprises a video compression arithmetic unit and a video encoder, the video compression and encoding unit is suitable for compressing and encoding the high-definition standard video signal in the HD-SDI format processed by the video processing unit, and the encoding standard of the video compression and encoding unit is H.265;
the video management server is adapted to respond to the access needs of the user and to send the encoded video streaming media to the client.
Further, the video preprocessing module comprises a video resolution adjustment sub-module, a video frame rate adjustment sub-module and a code rate adjustment sub-module which are sequentially connected with each other through signals.
Further, the video management server comprises an access control management module, a cache module, a streaming media network sending module and a local display module.
In order to provide a more stable and higher definition video under a severe communication environment, the video compression arithmetic unit further comprises an original frame storage module, a reference frame grabbing module, a reference frame buffer module, a block buckling module, a block buffer module, a block inter-frame motion trend buffer module, a current frame reconstruction module, a second current frame reconstruction module, a block motion compensation calculation module, a block inter-frame deformation prediction module and a block deformation compensation calculation module.
Further, the original frame storage module pre-stores an original frame image under a pure background scene;
the reference frame grabbing module is used for grabbing a frame of image as a reference frame after N frames are arranged at each interval, and the value range of N is 0-60;
the block buckling module is used for buckling and taking out a block image with actual content from the reference frame image and inputting information of the block pattern into the block cache module for temporary storage;
the block mass inter-frame motion prediction module is used for acquiring images positioned behind the reference frame, searching block mass patterns which accord with the block mass pattern characteristics in the reference frame, further calculating motion vectors of the block mass patterns relative to the block mass patterns in the reference frame, and sending the motion vectors to the current frame reconstruction module to be used as block mass motion prediction vectors;
the current frame reconstruction module is used for constructing a virtual current frame image, wherein the virtual current frame image contains a virtual block mass pattern;
the block mass motion compensation calculation module is used for collecting an actual current frame image, comparing and checking the actual current frame image with a virtual current frame image, calculating the position difference between the virtual block mass pattern and the block mass pattern in the actual current frame image, and calculating a block mass motion compensation difference value by combining a block mass motion prediction vector;
the block mass inter-frame deformation prediction module is used for acquiring images positioned behind a reference frame, searching block mass patterns which accord with the characteristics of the block mass patterns in the reference frame, further calculating block mass deformation trend parameters of the block mass patterns relative to the block mass deformation trend parameters in the reference frame, and outputting the block mass deformation trend parameters to the second current frame reconstruction module, wherein the second current frame reconstruction module is used for constructing a virtual current frame image, the virtual current frame image contains a virtual block mass pattern, and the block mass deformation compensation calculation module acquires an actual current frame image and compares the actual current frame image with the block mass patterns in the virtual current frame image to calculate a block mass deformation compensation residual value related to the block mass patterns.
Further, the block pattern information, the block motion compensation difference value and the block deformation compensation residual value are encoded by the video encoder and then sent to a buffer module in the streaming media server, and the original frame image is also sent to the buffer module by the original frame storage module.
The beneficial effects of the invention are as follows:
the medical video image live broadcast all-in-one machine solves the technical problem of how to collect and process various standard or nonstandard videos output by various medical equipment in a hospital for live broadcast, so that a user can receive multiple paths of video pictures with different contents at one terminal. The user can watch in a mobile phone terminal through a 4G network in a mobile mode at any time, and user experience is improved.
The invention also solves the technical problems of how to meet the transmission stability requirement of medical video and still transmit high-quality video under the condition of a harsher network communication environment, and the medical video signal acquisition and transcoding system originally develops a compression coding unit which utilizes the characteristics of fixed scene and smaller dynamic state of the medical video, and achieves the purpose of reducing the video transmission data volume by intercepting moving 'lumps' firstly and then superposing the means of the lump pattern on a clean background frame.
The other is that: the same motion prediction and deformation prediction module is adopted at the local end and the decoding end, and the adjustment parameters are transmitted to the decoding end after the prediction result is adjusted to conform to the actual image at the local end. The decoding end adjusts the prediction result through the adjustment parameters, so that the finally displayed image is the same as the acquired image of the local end. The video transmission data volume (only the transmission adjustment parameters are needed) is further reduced on the premise of ensuring the video quality.
Drawings
The medical video image live broadcast all-in-one machine is further described below with reference to the accompanying drawings.
FIG. 1 is a block diagram of a medical video image live broadcast all-in-one machine according to the present invention;
FIG. 2 is a workflow diagram of a medical video live video all-in-one machine in accordance with the present invention;
FIG. 3 is a schematic diagram of the logic structure and operation principle of the video compression operator;
FIG. 4 is an exploded view of the blob clipping module for a reference frame image;
fig. 5 is a schematic diagram of the logical structure and video restoration principle of the client.
Detailed Description
Examples
According to the video live broadcasting all-in-one machine shown in fig. 1, 2 and 3, the video live broadcasting all-in-one machine comprises a cabinet, wherein a main board and a power module for supplying power are arranged in the cabinet, and the video live broadcasting all-in-one machine further comprises a video management server positioned outside the cabinet.
The video management server comprises an access control management module, a cache module, a streaming media network sending module and a local display module. The video management server is adapted to respond to the access needs of the user and to send the encoded video streaming media to the client.
The main board is sequentially provided with a video acquisition unit, a video processing unit and a video compression coding unit which are connected through an I/O bus.
The video acquisition unit is provided with a plurality of video signal access ports and is used for being connected to the video output ends of various existing medical equipment and acquiring multiple paths of instant original video signals. The video acquisition unit comprises an acquisition module and an output module. In this embodiment, the acquisition module is a purchased hardware acquisition card, and the hardware acquisition card is provided with multiple input interfaces, and is connected to video output ends of various medical devices through coaxial cables, optical fiber wires or other wired cables, so as to perform multiple instant video signal acquisition. The output module is a processing chip arranged on the hardware acquisition card and an output port connected with the processing chip, and is used for transmitting each path of original video signal acquired in real time by the acquisition module to the video processing unit after time sequence arrangement, and each path of original video signal is a continuous frame during transmission.
The video processing unit comprises a video preprocessing module and an HD-SDI transcoding module, and is suitable for converting the multipath instant original video signals into high-definition standard video signals in an HD-SDI format after preprocessing. It may be preferable that: the video preprocessing module comprises a video resolution adjustment sub-module, a video frame rate adjustment sub-module and a code rate adjustment sub-module which are connected in sequence. The video resolution adjustment module adjusts the resolution of each frame image of each path of original video signal to 1280 pixels by 720 pixels. When the resolution of the frame image of the original signal is smaller than the resolution, interpolation calculation is performed to expand the frame image to 1280 pixels by 720 pixels, and when the resolution of the frame image of the original signal is larger than the resolution, resolution compression is performed to reduce the frame image of the original signal to 1280 pixels by 720 pixels. The video frame rate adjusting module is used for adjusting the frame rate of the original video signal after resolution adjustment to enable the frame rate to be 50-60 HZ, and the code rate adjusting module is used for adjusting the code rate parameter of the whole original video signal to a preset value of 1Mps-2 Mps.
The video compression and encoding unit comprises a video compression arithmetic unit and a video encoder, the video compression and encoding unit is suitable for compressing and encoding the high definition standard video signal in the HD-SDI format processed by the video processing unit, and the encoding standard of the video compression and encoding unit is H.265.
In order to provide a more stable and higher definition video under a severe communication environment, the video compression arithmetic unit comprises an original frame storage module, a reference frame grabbing module, a reference frame buffering module, a block buckling module, a block buffering module, a block inter-frame motion trend buffering module, a current frame reconstruction module, a second current frame reconstruction module, a block motion compensation calculation module, a block inter-frame deformation prediction module and a block deformation compensation calculation module.
The original frame storage module pre-stores an original frame image under a pure background scene.
The reference frame grabbing module is used for grabbing a frame of image after every interval N frames to serve as a reference frame, the value range of N is 0-60, the reference frame grabbing module can be preset to grab after every interval N frames, can also be preset to grab continuously, and can be set to grab continuously or the value of N is smaller when the network environment is good or the video quality requirement is high. In this embodiment, the reference frame capturing module captures a second frame image ("second frame" is merely for convenience of description with reference to the drawings, in a specific application, "second frame" is actually an x+1 frame, and the same applies below) as a reference frame, in this embodiment, a captured reference frame is preset to include a substantial image (such as a parameter curve in an electrocardiograph indicator or an actual scene in an operating room) other than a background, and the captured reference frame is stored in the reference frame buffer module for standby according to a network transmission environment and a requirement of video quality.
The block buckling module is used for buckling out a block image with actual content in the reference frame image and inputting information of the block pattern into the block caching module for temporary storage. When in buckling, as shown in fig. 4, the reference frame image and the original frame image are firstly decomposed into a plurality of macro blocks and a plurality of micro blocks at different levels according to the chromaticity and the brightness of the image, then overlapping and comparing are carried out to remove repeated blocks, the difference blocks are reserved, the reserved set of the difference blocks is defined as a block mass, and the block mass pattern information comprises the related parameters of the coordinates, the chromaticity, the brightness and the like of the difference blocks in the reference frame. And temporarily storing the pattern information of the block mass in a block mass cache module for calling. As shown in fig. 4, the agglomerate in this embodiment is a five-pointed star pattern.
The block mass inter-frame motion prediction module acquires a third frame image and searches a block mass pattern which accords with the block mass pattern information characteristics, further calculates a motion vector of the block mass in the third frame relative to the block mass in the second frame, and sends the motion vector to the current frame reconstruction module to serve as a block mass motion prediction vector for constructing a virtual current frame image (fourth frame), wherein the virtual current frame image contains virtual blocks.
The block motion compensation calculation module acquires an actual current frame image, compares and checks the actual current frame image with a virtual current frame image, calculates the position difference between the virtual block and the block in the actual current frame image, and calculates a block motion compensation difference value by combining a block motion prediction vector.
The inter-block deformation prediction module acquires a third frame of image and searches for block patterns which accord with the information characteristics of the block patterns, calculates block deformation trend parameters of the block patterns in the third frame relative to the block pattern information in the block cache module, and examines deformation parameters of the block pattern edge contour and chromaticity brightness parameters of each micro block in the block pattern when calculating the block deformation trend parameters.
The second current frame reconstruction module is used for constructing a virtual current frame image, and the second current frame reconstruction module predicts and reconstructs the shape, chromaticity and brightness of the block mass pattern in the current frame according to the deformation trend parameters. The block deformation compensation calculation module acquires an actual current frame image and compares the actual current frame image with the block patterns in the virtual current frame image, and calculates a block deformation compensation residual value related to the block patterns.
The block pattern information, the block motion compensation difference value and the block deformation compensation residual value are coded by a video coder and then sent to a buffer memory module in a streaming media server, and the original frame image is also sent to the buffer memory module by an original frame storage module.
The access control management module in the video management server is used for responding to the access request of the terminal user and judging whether the authority of the user is matched with the request, if so, the video data cached in the cache module is further sent to the user through the streaming media network sending module.
The local display module in the video management server includes a liquid crystal display, a buffer unit and a decoding unit. The video image information can be previewed locally through the local display module. The same display device, buffer unit and decoding unit are also present in the client located on the other side of the network.
As shown in fig. 5, the decoding unit includes a decoding module, a second original frame storage module, a second blob buffer module, a blob motion compensation feedback module, a blob deformation compensation feedback module, a second blob inter-frame motion prediction module, a blob inter-frame motion trend buffer module, a second blob inter-frame deformation prediction module, a blob inter-frame deformation trend buffer module, and a third current frame reconstruction module.
The second original frame storage module reads an original frame image from the buffer unit and takes the original frame image as a first frame image when the video is played, and the decoding module reads the block mass pattern information, the block mass motion compensation difference value and the block mass deformation compensation residual value from the buffer unit and sends the block mass pattern information, the block mass motion compensation difference value and the block mass deformation compensation residual value to the block mass buffer module, the block mass motion compensation feedback module and the block mass deformation compensation feedback module respectively after decoding.
The second block buffer module, the block motion compensation feedback module and the block deformation compensation feedback module load the received block pattern information, the block motion compensation difference value and the block deformation compensation residual value to the current frame reconstruction module respectively for reconstructing the current frame image.
And the calculation results of the block motion prediction vector and the block deformation trend parameter of the second block inter-block motion prediction module and the second block inter-block deformation prediction module are also respectively loaded to a third current frame reconstruction module for reconstructing the current frame image. The second block inter-frame motion prediction module and the second block inter-frame deformation prediction module also respectively input block motion prediction vectors and block deformation trend parameters into the block inter-frame motion trend caching module and the block inter-frame deformation trend caching module so as to enable the trend of the previous frame to continue reconstructing an image when packet loss and frame loss occur.
The second block inter-frame motion prediction module and the second block inter-frame deformation prediction module also continuously collect the reconstructed frame images, and output the frame images to be empty when the motion or deformation trend cannot be calculated after the original frame images and the second frame images are collected by the original light.
And a third current frame reconstruction module in the decoding unit firstly reads the original frame image in the second original frame storage module when reconstructing, then reads the block mass pattern information in the second block mass buffer module, and carries out picture reconstruction of the current frame by combining the block mass motion prediction vector, the block mass deformation trend, the block mass motion compensation difference value and the block mass deformation compensation residual value and outputting the picture reconstruction.
The technical solutions of the above embodiments of the present invention can be cross-combined with each other to form a new technical solution, and in addition, all technical solutions formed by equivalent substitution fall within the scope of protection claimed by the present invention.