CN111447253B - Buffer management method, system, device and storage medium - Google Patents

Buffer management method, system, device and storage medium Download PDF

Info

Publication number
CN111447253B
CN111447253B CN202010129868.7A CN202010129868A CN111447253B CN 111447253 B CN111447253 B CN 111447253B CN 202010129868 A CN202010129868 A CN 202010129868A CN 111447253 B CN111447253 B CN 111447253B
Authority
CN
China
Prior art keywords
data
sampling interval
current
state
new
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
CN202010129868.7A
Other languages
Chinese (zh)
Other versions
CN111447253A (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.)
Tsinghua University
Original Assignee
Tsinghua University
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 Tsinghua University filed Critical Tsinghua University
Priority to CN202010129868.7A priority Critical patent/CN111447253B/en
Publication of CN111447253A publication Critical patent/CN111447253A/en
Application granted granted Critical
Publication of CN111447253B publication Critical patent/CN111447253B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/56Provisioning of proxy services
    • H04L67/568Storing data temporarily at an intermediate stage, e.g. caching
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/56Provisioning of proxy services
    • H04L67/568Storing data temporarily at an intermediate stage, e.g. caching
    • H04L67/5682Policies or rules for updating, deleting or replacing the stored data
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W28/00Network traffic management; Network resource management
    • H04W28/02Traffic management, e.g. flow control or congestion control
    • H04W28/10Flow control between communication endpoints
    • H04W28/14Flow control between communication endpoints using intermediate storage

Abstract

The embodiment of the invention relates to the technical field of computer communication, and discloses a buffer area management method, a system, equipment and a storage medium, wherein the method comprises the steps of firstly acquiring the integral running state of a current buffer area; adjusting the numerical value of the current sampling interval according to the integral running state to obtain a new sampling interval; and determining the processing operation facing the data to be sent through the new sampling interval so as to process the data to be sent through the processing operation. Therefore, the embodiment of the invention considers the limitation of the capacity of the buffer area, can adjust the sampling interval based on the whole running state of the current buffer area, and uses the adjusted new sampling interval to actually process the buffering process, thereby improving the storage efficiency and better processing the communication condition of network interruption. Meanwhile, the uniform sampling of time sequence data is realized on the system level, the upper application program code does not need to be changed, the workload of upper application development is not increased, and the reliability of multi-machine communication is improved.

Description

Buffer management method, system, device and storage medium
Technical Field
The present invention relates to the field of computer communications technologies, and in particular, to a method, a system, a device, and a storage medium for buffer management.
Background
With the continuous development of communication technology, unstable network connection and limited bandwidth during communication cause a series of communication problems.
For example, if the robot is taken as an example, when the robot moves out of the range of the wireless network, switches between network source points, or is blocked by an obstacle, the network connection may be temporarily disconnected, so that important data is easily lost, and the transmission effect is affected.
It can be seen that a break in the network connection is a communication condition that often occurs.
For such communication conditions, buffering some data at the sender may be employed to resolve. Specifically, when the network connection is temporarily interrupted, new data may be placed directly into a buffer to await retransmission after network recovery.
However, the final effect is not good because the communication status of network interruption is solved by directly caching data at the sending end due to the limitation of the memory size and the capacity of the cache area.
Therefore, a new data management method is needed to handle the communication condition of network interruption.
Disclosure of Invention
In order to solve the foregoing technical problems, embodiments of the present invention provide a buffer management method, system, device, and storage medium.
In a first aspect, an embodiment of the present invention provides a buffer management method, including:
acquiring the integral running state of the current buffer area;
adjusting the value of the current sampling interval according to the integral running state to obtain a new sampling interval;
and determining the processing operation facing to the data to be sent through the new sampling interval so as to process the data to be sent through the processing operation.
Preferably, after determining the processing operation oriented to the data to be transmitted by the new sampling interval so as to process the data to be transmitted by the processing operation, the buffer management method further includes:
and if the processing operation is a retention operation, determining the data to be replaced in the current buffer area, and replacing the data to be replaced with the data to be sent.
Preferably, the overall operating state comprises a data fill state;
the adjusting the value of the current sampling interval according to the overall operation state to obtain a new sampling interval specifically includes:
if the data filling state of the current cache area is in a data filling state, performing amplification operation on the current sampling interval to obtain a first target sampling interval;
if the data filling state of the current cache region is in the data filling state, performing an amplification operation on the current sampling interval to obtain a first target sampling interval, where the buffer region management method further includes:
and performing data sampling operation through the first target sampling interval.
Preferably, before performing an amplification operation on the current sampling interval to obtain a first target sampling interval if the data filling state of the current buffer is in the data filling state, the buffer management method further includes:
acquiring a current discarding position;
deleting the data to be replaced pointed by the current discarding position in the current buffer area, and performing self-increment operation on the current discarding position to obtain a new discarding position;
and if the numerical value of the new discarded position is larger than the area capacity of the current buffer area, the data filling state of the current buffer area is regarded as a data filling state.
Preferably, the overall operating state comprises a current network state;
the adjusting the value of the current sampling interval according to the overall operation state to obtain a new sampling interval specifically includes:
if the current network state is changed from an abnormal transmission state to a normal transmission state, detecting the existing data volume in the current buffer area;
if the existing data volume is within a preset data volume range, reducing the current sampling interval to obtain a second target sampling interval;
after the reducing operation is performed on the current sampling interval to obtain a second target sampling interval if the existing data volume is within the preset data volume range, the buffer management method further includes:
and performing data sampling operation through the second target sampling interval.
Preferably, the determining, by the new sampling interval, a processing operation for data to be sent so as to process the data to be sent by the processing operation specifically includes:
if the data to be sent is obtained, performing self-increment operation on the state value of the current sampling state to obtain a new sampling state;
and if the new sampling state is equal to the new sampling interval, determining the processing operation facing the data to be sent as a retention operation, so as to process the data to be sent through the retention operation.
Preferably, after the obtaining of the data to be sent and performing a self-increment operation on the state value of the current sampling state to obtain a new sampling state, the buffer management method further includes:
and if the new sampling state is not equal to the new sampling interval, determining that the processing operation facing the data to be sent is a discarding operation, so as to process the data to be sent through the discarding operation.
In a second aspect, an embodiment of the present invention provides a buffer management system, including:
the state determining module is used for acquiring the integral operation state of the current buffer area;
the interval adjusting module is used for adjusting the numerical value of the current sampling interval according to the integral running state so as to obtain a new sampling interval;
and the data processing module is used for determining the processing operation facing to the data to be sent through the new sampling interval so as to process the data to be sent through the processing operation.
In a third aspect, an embodiment of the present invention provides an electronic device, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, where the processor implements the steps of the buffer management method provided in the first aspect of the present invention when executing the program.
In a fourth aspect, an embodiment of the present invention provides a non-transitory computer-readable storage medium, on which a computer program is stored, where the computer program, when executed by a processor, implements the steps of a buffer management method provided in the first aspect of the present invention.
According to the buffer area management method, the system, the equipment and the storage medium provided by the embodiment of the invention, the integral operation state of the current buffer area is firstly obtained; adjusting the numerical value of the current sampling interval according to the integral running state to obtain a new sampling interval; and determining the processing operation facing the data to be sent through the new sampling interval so as to process the data to be sent through the processing operation. Therefore, the embodiment of the invention considers the limitation of the capacity of the buffer area, does not adopt a mode of directly caching data at a sending end to solve the communication condition of network interruption, optimizes the mode of caching the data, specifically can adjust the sampling interval based on the whole running state of the current buffer area, and uses the adjusted new sampling interval to actually process the buffering process, thereby improving the storage efficiency and better processing the communication condition of network interruption.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and those skilled in the art can also obtain other drawings according to the drawings without creative efforts.
Fig. 1 is a flowchart of a buffer management method according to an embodiment of the present invention;
fig. 2 is a flowchart of a buffer management method according to another embodiment of the present invention;
FIG. 3 is a diagram of an exemplary buffer according to another embodiment of the present invention;
FIG. 4 is a flowchart illustrating a buffer management method according to yet another embodiment of the present invention;
FIG. 5 is a flowchart illustrating a buffer management method according to another embodiment of the present invention;
fig. 6 is a schematic diagram of a three-dimensional reconstruction architecture according to another embodiment of the present invention;
fig. 7 is a schematic structural diagram of a buffer management system according to an embodiment of the present invention;
fig. 8 is a schematic physical structure diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, but not all, embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Fig. 1 is a flowchart of a buffer management method according to an embodiment of the present invention, as shown in fig. 1, the method includes:
and S1, acquiring the overall operation state of the current buffer area.
It is understood that the buffer is an intermediate buffer area before data is transmitted or received, and the current buffer is a buffer area under a real-time state.
For convenience of understanding, the present embodiment may be described by taking an intermediate buffer area before data is transmitted as an example, that is, the buffer may be referred to as a transmission buffer. Of course, the buffer may also be a receive buffer, i.e. an intermediate buffer area before receiving the data.
Considering the limited capacity of the buffer area, the method of caching data is optimized instead of adopting a method of directly caching data at a sending end to solve the communication condition of network interruption, so that the storage efficiency is improved, and the aim of processing the communication condition of network interruption is fulfilled.
Specifically, as for the optimization strategy of the data caching method, the sampling interval may be adjusted based on the overall operating state of the current buffer, and the buffer process may be actually processed using the adjusted new sampling interval.
It can be seen that the sampling interval will adaptively change depending on the overall operating state of the current buffer.
And S2, adjusting the value of the current sampling interval according to the overall operation state to obtain a new sampling interval.
And S3, determining the processing operation facing the data to be sent through the new sampling interval so as to process the data to be sent through the processing operation.
The sampling interval refers to a sampling period for sampling data to be transmitted or data to be received, for example, if the data to be transmitted is taken as an example, and the sampling interval is 1, the interval between each two newly acquired data is 1, that is, the data is normally acquired, for example, if the data 1 is acquired for the first time, the data 2 is acquired for the second time, and so on.
The adjusted sampling interval may be increased or decreased.
For example, if the sampling interval is 2, the interval between each newly acquired data is 2, for example, if data 1 is acquired for the first time, data 3 will be acquired for the second time, and so on.
It can be seen that the processing operation on the subsequently newly acquired data is affected precisely because the sampling interval is adjusted. For example, data 2 is acquired when the sampling interval is 1, but data 2 is not acquired when the sampling interval is 2 but data 2 is skipped, which naturally causes the processing operation of newly acquired data, that is, the data to be transmitted mentioned here, to be different, and may be a discarding operation or a retaining operation.
Furthermore, the embodiment reduces the influence caused by data loss due to buffer overflow by automatically adjusting the sampling interval, realizes uniform sampling of time sequence data on the system level, does not need to change upper application program codes, does not increase the workload of upper application development, and improves the reliability of communication among multiple computers.
In addition, the embodiment also improves the communication robustness in the scene of unstable network.
On the basis of the foregoing embodiment, preferably, after determining, by a new sampling interval, a processing operation for data to be transmitted, so as to process the data to be transmitted by the processing operation, the buffer management method further includes:
and if the processing operation is a retention operation, determining the data to be replaced in the current buffer area, and replacing the data to be replaced with the data to be sent.
Specifically, as for the processing operation of data to be transmitted, the processing operation includes a retention operation and a discard operation.
If the current buffer area is a sending buffer area, in terms of the reserving operation, the newly acquired data, namely the data to be sent, can be reserved, and the data to be replaced is removed and replaced by the data to be sent if the data to be removed, namely the data to be replaced, is determined from the buffer area.
Further, as for the retention operation, after the data of the buffer is full, based on the assumption that the new data is more valuable than the old data, the buffer management may be performed in a manner of discarding the oldest data to make room for the new data.
On the basis of the foregoing embodiment, preferably, after determining, by a new sampling interval, a processing operation for data to be transmitted, so as to process the data to be transmitted by the processing operation, the buffer management method further includes:
and if the processing operation is a discarding operation, discarding the data to be sent.
For the discard operation, the data to be sent at this moment will be discarded and not stored in the current buffer.
The buffer management method provided by the embodiment of the invention comprises the steps of firstly obtaining the integral operation state of the current buffer; adjusting the numerical value of the current sampling interval according to the integral running state to obtain a new sampling interval; and determining the processing operation facing the data to be sent through the new sampling interval so as to process the data to be sent through the processing operation. Therefore, the embodiment of the invention considers the limitation of the capacity of the buffer area, does not adopt a mode of directly caching data at a sending end to solve the communication condition of network interruption, optimizes the mode of caching the data, specifically can adjust the sampling interval based on the whole running state of the current buffer area, and uses the adjusted new sampling interval to actually process the buffering process, thereby improving the storage efficiency and better processing the communication condition of network interruption.
Fig. 2 is a flowchart of a buffer management method according to another embodiment of the present invention, where the another embodiment of the present invention is based on the embodiment shown in fig. 1.
In this embodiment, the overall operating state includes a data filling state.
The S2 specifically includes:
and S21, if the data filling state of the current cache area is in a data filling state, performing augmentation operation on the current sampling interval to obtain a first target sampling interval.
It is understood that the data filling state may include a data filling state and a data not filling state, and as an example of the data filling state, refer to the exemplary diagram of the buffer shown in fig. 3.
Both times 15 and 30 in fig. 3 are data-filled states, i.e., states in which data fills the complete partial buffer in sequence.
In fig. 3, the buffers at 8 different times can be respectively recorded as left 1, left 2, left 3, left 4, right 1, right 2, right 3, and right 4.
Further, the buffer is a buffer queue, which can be denoted as buf _, and if fig. 3 is taken as an example, the buffer queue buf _ has 8 fields, and the field sequence numbers from left to right can be sequentially set to 0, 1, 2, 3, 4, 5, 6, and 7.
Specifically, if the time 15 is taken as an example, that is, the left 4 in fig. 3, it can be seen that the data filling state of the current buffer is in the data full state at this moment, the current sampling interval 1 may be expanded to be the first target sampling interval 2, and the current sampling interval is smaller than the first target sampling interval.
After S21, the buffer management method further includes:
and S22, performing data sampling operation through the first target sampling interval.
It can be understood that, since the first target sampling interval is 2, taking time 18 as an example, that is, taking right 2 in fig. 3 as an example, on the basis that the data to be transmitted obtained last is 16, the data to be transmitted obtained next will be subjected to data sampling operation according to the first target sampling interval 2, specifically 18.
And performing data sampling operation through the first target sampling interval to obtain data to be sent.
Of course, before the first target sampling interval is not adjusted, a data sampling operation is performed according to the current sampling interval to obtain data to be transmitted.
The buffer management method provided by the embodiment of the invention can be used for carrying out amplification operation on the sampling interval so as to reduce the data stored in the buffer within a specified time range, and flexibly and automatically respond to the real-time situation when the buffer is full.
On the basis of the foregoing embodiment, preferably, before performing an amplification operation on the current sampling interval to obtain a first target sampling interval if the data filling state of the current cache region is in a data full state, the buffer region management method further includes:
acquiring a current discarding position;
deleting the data to be replaced pointed by the current discarding position in the current buffer area, and performing self-increment operation on the current discarding position to obtain a new discarding position;
and if the numerical value of the new discarded position is larger than the area capacity of the current buffer area, the data filling state of the current buffer area is regarded as a data filling state.
It is understood that the present embodiment may also introduce a status description field, i.e., the current discard location, which may be denoted as pos _.
The current discarding position is a field sequence number pointing to the data to be replaced in the buffer, and the data to be replaced is data to be deleted if newly acquired data is reserved.
Specifically, if referring to fig. 3, the current discard position is the field shown in gray in fig. 3, and is distinguished from the remaining 7 fields shown in white in the buffer, so as to understand the following description text.
For example, if time 15 in fig. 3 is taken as an example, that is, left 4 in fig. 3 is taken as an example, the current discard position is field 7, that is, the last field in the current buffer, and the data to be filled is 15.
The padding data 15 may then be deleted and a selfjoin operation is then performed for the current discard location 7.
Wherein the incrementing operation may be an adding 1 operation, i.e., the new discard position may be 8.
Then, the area size of the current buffer area may be marked as buf.capacity, the area size may be set to be 7 by default, and obviously, if the new discard position 8 is greater than the area size 7, the current buffer area may be considered to be filled, and the data filling status is considered as the data filling status.
Further, the currently obtained data to be sent can be filled immediately while the data to be replaced is deleted.
For example, taking time 15 and time 16 in fig. 3 as an example, i.e., taking left 4 and right 1 in fig. 3 as an example, 15 in the last field is deleted and filled with the currently obtained data 16 to be sent.
Further, after the data filling status of the current buffer is regarded as the data filling status, a reset operation may be performed on the value of the new discard location, for example, a zero operation is performed on the new discard location 8 to obtain discard location 0.
Referring to left 4 and right 1 in fig. 3, the discard position will be changed from the last field to the first field.
Fig. 4 is a flowchart of a buffer management method according to yet another embodiment of the present invention, where yet another embodiment of the present invention is based on the embodiment shown in fig. 1.
In this embodiment, the overall operating state includes a current network state.
The S2 specifically includes:
s23, if the current network status changes from the abnormal transmission status to the normal transmission status, detecting the existing data amount in the current buffer.
It is understood that the current network state may include an abnormal transmission state and a normal transmission state, wherein the abnormal transmission state may be a communication condition in which the network is temporarily interrupted.
And when the abnormal transmission state is changed into the normal transmission state, the network is characterized by abnormal and sudden recovery.
It will be appreciated that, in view of the sudden recovery of the network anomaly, the network transmission will be stable, and the data to be transmitted filled in the transmission buffer will be quickly taken out and successfully transmitted, so the filled data in the transmission buffer will be reduced.
And S24, if the existing data volume is within the preset data volume range, performing a reduction operation on the current sampling interval to obtain a second target sampling interval.
The existing data amount is the amount of data still remaining in the buffer, and can be denoted as buf _.
It should be appreciated that if the amount of data still remaining is within a certain range, the sampling interval may be decreased and the current sampling interval will be greater than the second target sampling interval.
Specifically, the reduction operation may be a halving operation, for example, if the current sampling interval is 2, which would be halved from 2 to 1, the second target sampling interval is 1.
Further, as for the trigger manner for triggering the reduction operation, another trigger manner may also be provided.
For example, a ratio between the amount of existing data and a buffer queue capacity may be calculated, wherein the buffer queue capacity is the number of fields of all fields of the buffer, for example, the number of fields may be 8; and then, comparing the ratio with a preset threshold value R, and if the ratio is less than or equal to the preset threshold value R, reducing the current sampling interval to obtain a second target sampling interval.
After S24, the buffer management method further includes:
and S25, performing data sampling operation through the second target sampling interval.
It is understood that, in the subsequent process, the data sampling operation is performed through the reduced second target sampling interval to continuously obtain the data to be transmitted.
Therefore, when the network is abnormally and suddenly interrupted, the sampling interval can be increased so as to adaptively reduce the data filled in the buffer area; when the network exception is suddenly recovered, the sampling interval increased before can be reduced to adaptively increase the data filled in the buffer, because the data can be normally and stably sent out at the moment, and the existing data in the buffer accelerates the moving-out speed.
Further, the current sampling interval at this time may be greater than a preset interval value, and the preset interval value may be 1, so as to perform the reduction operation.
According to the buffer area management method provided by the embodiment of the invention, when the network abnormity is recovered suddenly, the sampling interval can be reduced, so that the data filled in the buffer area can be increased adaptively.
Fig. 5 is a flowchart of a buffer management method according to another embodiment of the present invention, and yet another embodiment of the present invention is based on the embodiment shown in fig. 1.
In this embodiment, the S3 specifically includes:
and S31, if the data to be sent is acquired, performing self-increment operation on the state value of the current sampling state to acquire a new sampling state.
It is understood that the present embodiment may also incorporate a state description field, i.e., the current sampling state, which may be denoted cur _.
The current sampling state is the data sequence number corresponding to the current sampling interval, for example, if the new sampling interval is 4, the current sampling state includes 0, 1, 2, and 3.
Specifically, if a new data to be sent is received, a self-increment operation is performed on the state value of the current sampling state. For example, if the current sample state is 3, an add 1 operation may be performed to obtain a new sample state of 4.
S32, if the new sampling state is equal to the new sampling interval, determining that the processing operation for the data to be sent is a reservation operation, so as to process the data to be sent through the reservation operation.
It should be appreciated that if the new sample state is 4 equals the new sample interval 4, then the new data to be transmitted acquired at this time may be retained.
Further, after the obtaining of the data to be sent and performing a self-increment operation on the state value of the current sampling state to obtain a new sampling state, the buffer management method further includes:
and if the new sampling state is not equal to the new sampling interval, determining that the processing operation facing the data to be sent is a discarding operation, so as to process the data to be sent through the discarding operation.
It should be appreciated that if the new sample state of 3 is not equal to the new sample interval of 4, the new data to be transmitted acquired at this point may be discarded.
Therefore, the purpose of setting the sampling state is to screen out newly acquired data to be transmitted according to the sampling interval, only newly acquired data to be transmitted at the moment when the new sampling state is equal to the new sampling interval is left, and other newly acquired data to be transmitted are all discarded, so that the application of the sampling interval is realized.
Further, if the new sampling state is equal to the new sampling interval and after the data to be transmitted is processed through the retention operation, then the reset operation may be performed on the new sampling state.
Specifically, a zero operation may be performed on a new sampling state, and then a new round of cyclic update of the sampling state is entered, i.e., increasing from 0 to 3, and resetting to 0 again when going to 4.
Further, in the initial stage, the current buffer area is empty, the current sampling interval is 1, the current sampling state is 0, and the current discard position is 0.
Further, if the data is output from the buffer area, self-subtraction operation can be performed on the real-time discarding position to obtain a new discarding position;
and if the new discarding position is smaller than the preset lower limit value, resetting the new discarding position.
Specifically, the self-decrement operation may be a decrement 1 operation. The preset lower limit value may be 0, the reset operation may be a zero operation,
the buffer management method provided by the embodiment of the invention can flexibly process newly acquired data to be transmitted by taking a sampling interval as a basis by introducing the sampling state.
As for fig. 1, fig. 2, fig. 4 and fig. 5 are flowcharts of a buffer management method according to an embodiment of the present invention, if a three-dimensional reconstruction technology is used as an implementation scene, a description will be given by taking an example that a camera sends image data to a three-dimensional reconstruction processing center during a three-dimensional reconstruction process.
See fig. 6 for a schematic diagram of a three-dimensional reconstruction architecture.
As can be seen, the implementation scenario involves the camera side and the three-dimensional reconstruction processing center side.
For example, the camera side can be used as an execution main body, the camera acquires image data, data obtained after preprocessing the image data can be marked as data to be sent, and the data to be sent passes through a sending buffer area; and the data flushed from the sending buffer area is transferred to a three-dimensional reconstruction processing center as a relay by the base station.
The three-dimensional reconstruction processing center side firstly passes the received data through the receiving buffer area, and the data flushed from the receiving buffer area is subjected to three-dimensional reconstruction operation.
In addition, the transmission data in the implementation scene is mainly picture data acquired by the camera side.
In conjunction with the above description, for other types of transmission data, it is also possible to achieve uniform sampling of the transmission data in case of network impairments.
Fig. 7 is a schematic structural diagram of a buffer management system according to an embodiment of the present invention, as shown in fig. 7, the system includes: a state determining module 301, an interval adjusting module 302 and a data processing module 303;
a state determining module 301, configured to obtain an overall operation state of a current buffer;
an interval adjusting module 302, configured to adjust a value of a current sampling interval according to the overall operation state to obtain a new sampling interval;
a data processing module 303, configured to determine, through a new sampling interval, a processing operation for data to be sent, so as to process the data to be sent through the processing operation.
The buffer management system provided by the embodiment of the invention firstly obtains the integral operation state of the current buffer; adjusting the numerical value of the current sampling interval according to the integral running state to obtain a new sampling interval; and determining the processing operation facing the data to be sent through the new sampling interval so as to process the data to be sent through the processing operation. Therefore, the embodiment of the invention considers the limitation of the capacity of the buffer area, does not adopt a mode of directly caching data at a sending end to solve the communication condition of network interruption, optimizes the mode of caching the data, specifically can adjust the sampling interval based on the whole running state of the current buffer area, and uses the adjusted new sampling interval to actually process the buffering process, thereby improving the storage efficiency and better processing the communication condition of network interruption.
The system embodiment provided in the embodiments of the present invention is for implementing the above method embodiments, and for details of the process and the details, reference is made to the above method embodiments, which are not described herein again.
Fig. 8 is a schematic entity structure diagram of an electronic device according to an embodiment of the present invention, and as shown in fig. 8, the electronic device may include: a processor (processor)401, a communication Interface (communication Interface)402, a memory (memory)403 and a bus 404, wherein the processor 401, the communication Interface 402 and the memory 403 complete communication with each other through the bus 404. The communication interface 402 may be used for information transfer of an electronic device. Processor 401 may call logic instructions in memory 403 to perform a method comprising:
acquiring the integral running state of the current buffer area;
adjusting the value of the current sampling interval according to the integral running state to obtain a new sampling interval;
and determining the processing operation facing to the data to be sent through the new sampling interval so as to process the data to be sent through the processing operation.
In addition, the logic instructions in the memory 403 may be implemented in the form of software functional units and stored in a computer readable storage medium when the software functional units are sold or used as independent products. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the above-described method embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
In another aspect, an embodiment of the present invention further provides a non-transitory computer-readable storage medium, on which a computer program is stored, where the computer program is implemented by a processor to perform the method provided by the foregoing embodiments, for example, including:
acquiring the integral running state of the current buffer area;
adjusting the value of the current sampling interval according to the integral running state to obtain a new sampling interval;
and determining the processing operation facing to the data to be sent through the new sampling interval so as to process the data to be sent through the processing operation.
The above-described embodiments of the apparatus are merely illustrative, and the units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment. One of ordinary skill in the art can understand and implement it without inventive effort.
Through the above description of the embodiments, those skilled in the art will clearly understand that each embodiment can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware. With this understanding in mind, the above-described technical solutions may be embodied in the form of a software product, which can be stored in a computer-readable storage medium such as ROM/RAM, magnetic disk, optical disk, etc., and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the methods described in the embodiments or some parts of the embodiments.
Finally, it should be noted that: the above examples are only intended to illustrate the technical solution of the present invention, but not to limit it; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present invention.

Claims (8)

1. A buffer management method, comprising:
acquiring the integral running state of the current buffer area;
adjusting the value of the current sampling interval according to the integral running state to obtain a new sampling interval;
determining a processing operation oriented to data to be sent through a new sampling interval so as to process the data to be sent through the processing operation;
the overall operating state comprises a data fill state;
the adjusting the value of the current sampling interval according to the overall operation state to obtain a new sampling interval specifically includes:
if the data filling state of the current cache area is in a data filling state, performing amplification operation on the current sampling interval to obtain a first target sampling interval;
if the data filling state of the current cache region is in the data filling state, performing an amplification operation on the current sampling interval to obtain a first target sampling interval, where the buffer region management method further includes:
performing data sampling operation through the first target sampling interval;
before the performing an amplification operation on the current sampling interval to obtain the first target sampling interval if the data filling state of the current cache region is in the data filling state, the buffer region management method further includes:
acquiring a current discarding position;
deleting the data to be replaced pointed by the current discarding position in the current buffer area, and performing self-increment operation on the current discarding position to obtain a new discarding position;
and if the numerical value of the new discarded position is greater than the area capacity of the current buffer area, regarding the data filling state of the current buffer area as a data filling state, wherein the discarded position is a field serial number pointing to the data to be replaced in the buffer area, and the data to be replaced is the data to be deleted if the newly acquired data is reserved.
2. The buffer management method according to claim 1, wherein after determining the processing operation for the data to be transmitted by the new sampling interval so as to process the data to be transmitted by the processing operation, the buffer management method further comprises:
and if the processing operation is a retention operation, determining the data to be replaced in the current buffer area, and replacing the data to be replaced with the data to be sent.
3. The buffer management method according to claim 1, wherein the overall operating state comprises a current network state;
the adjusting the value of the current sampling interval according to the overall operation state to obtain a new sampling interval specifically includes:
if the current network state is changed from an abnormal transmission state to a normal transmission state, detecting the existing data volume in the current buffer area;
if the existing data volume is within a preset data volume range, reducing the current sampling interval to obtain a second target sampling interval;
after the reducing operation is performed on the current sampling interval to obtain a second target sampling interval if the existing data volume is within the preset data volume range, the buffer management method further includes:
and performing data sampling operation through the second target sampling interval.
4. The buffer management method according to any of claims 1 to 3, wherein the determining, by the new sampling interval, a processing operation for data to be transmitted to process the data to be transmitted by the processing operation comprises:
if the data to be sent is obtained, performing self-increment operation on the state value of the current sampling state to obtain a new sampling state;
and if the state value of the new sampling state is equal to the new sampling interval, determining that the processing operation facing the data to be sent is a retention operation so as to process the data to be sent through the retention operation, wherein the sampling state is a data serial number corresponding to the sampling interval.
5. The buffer management method according to claim 4, wherein after the state value of the current sampling state is increased by itself to obtain a new sampling state if the data to be sent is obtained, the buffer management method further comprises:
and if the state value of the new sampling state is not equal to the new sampling interval, determining that the processing operation facing the data to be sent is a discarding operation, so as to process the data to be sent through the discarding operation.
6. A buffer management system, comprising:
the state determining module is used for acquiring the integral operation state of the current buffer area;
the interval adjusting module is used for adjusting the numerical value of the current sampling interval according to the integral running state so as to obtain a new sampling interval;
the data processing module is used for determining the processing operation facing to the data to be sent through a new sampling interval so as to process the data to be sent through the processing operation;
the overall operating state comprises a data fill state;
the interval adjusting module is specifically configured to:
if the data filling state of the current cache area is in a data filling state, performing amplification operation on the current sampling interval to obtain a first target sampling interval;
if the data filling state of the current cache region is in the data filling state, performing an amplification operation on the current sampling interval to obtain a first target sampling interval, where the buffer region management method further includes:
performing data sampling operation through the first target sampling interval;
before the performing an amplification operation on the current sampling interval to obtain the first target sampling interval if the data filling state of the current cache region is in the data filling state, the buffer region management method further includes:
acquiring a current discarding position;
deleting the data to be replaced pointed by the current discarding position in the current buffer area, and performing self-increment operation on the current discarding position to obtain a new discarding position;
and if the numerical value of the new discarded position is greater than the area capacity of the current buffer area, regarding the data filling state of the current buffer area as a data filling state, wherein the discarded position is a field serial number pointing to the data to be replaced in the buffer area, and the data to be replaced is the data to be deleted if the newly acquired data is reserved.
7. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the steps of the buffer management method according to any of claims 1 to 5 are implemented when the processor executes the program.
8. A non-transitory computer readable storage medium, having stored thereon a computer program, when being executed by a processor, for performing the steps of the buffer management method according to any one of claims 1 to 5.
CN202010129868.7A 2020-02-28 2020-02-28 Buffer management method, system, device and storage medium Active CN111447253B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010129868.7A CN111447253B (en) 2020-02-28 2020-02-28 Buffer management method, system, device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010129868.7A CN111447253B (en) 2020-02-28 2020-02-28 Buffer management method, system, device and storage medium

Publications (2)

Publication Number Publication Date
CN111447253A CN111447253A (en) 2020-07-24
CN111447253B true CN111447253B (en) 2021-06-25

Family

ID=71653963

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010129868.7A Active CN111447253B (en) 2020-02-28 2020-02-28 Buffer management method, system, device and storage medium

Country Status (1)

Country Link
CN (1) CN111447253B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113746937B (en) * 2021-09-16 2022-11-22 中国银行股份有限公司 Method and device for initiating message buffer analysis across border payment system channels
CN116582488B (en) * 2023-07-14 2023-10-13 中创(深圳)物联网有限公司 Data transmission method, device, equipment and storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1902864A (en) * 2003-10-29 2007-01-24 诺基亚公司 Method and apparatus providing smooth adaptive management of packets at a receiving terminal
CN101958802A (en) * 2010-09-06 2011-01-26 广东电网公司茂名供电局 Double-network online switching method of sampling values
CN203783820U (en) * 2014-02-25 2014-08-20 常州铠甲智能科技有限公司 Vibrational state monitoring device for wind generation set with distributed memory function
CN106331598A (en) * 2015-07-02 2017-01-11 杭州萤石网络有限公司 Method, device and system for controlling transmitted data
CN108322291A (en) * 2018-02-06 2018-07-24 北京和利时电机技术有限公司 A kind of multiple-axis servo operation data monitoring method based on universal serial bus
CN109327519A (en) * 2018-10-12 2019-02-12 歌尔科技有限公司 Flow data synchronous method, device, equipment and storage medium

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103809516B (en) * 2012-11-14 2016-05-04 中国科学院沈阳计算技术研究所有限公司 Based on servo-drive system equipment for inhibiting of vibration and the inhibition method thereof of the communication of principal and subordinate's platform
CN103675522B (en) * 2013-11-12 2016-05-04 国电南瑞科技股份有限公司 The multi-functional secondary device of a kind of intelligent substation towards interval
US9639465B2 (en) * 2014-04-30 2017-05-02 Qualcomm Innovation Center, Inc. Dynamic cachable memory interface frequency scaling
CN109802922A (en) * 2017-11-16 2019-05-24 电信科学技术研究院 A kind of processing method and equipment of cache synchronization exception

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1902864A (en) * 2003-10-29 2007-01-24 诺基亚公司 Method and apparatus providing smooth adaptive management of packets at a receiving terminal
CN101958802A (en) * 2010-09-06 2011-01-26 广东电网公司茂名供电局 Double-network online switching method of sampling values
CN203783820U (en) * 2014-02-25 2014-08-20 常州铠甲智能科技有限公司 Vibrational state monitoring device for wind generation set with distributed memory function
CN106331598A (en) * 2015-07-02 2017-01-11 杭州萤石网络有限公司 Method, device and system for controlling transmitted data
CN108322291A (en) * 2018-02-06 2018-07-24 北京和利时电机技术有限公司 A kind of multiple-axis servo operation data monitoring method based on universal serial bus
CN109327519A (en) * 2018-10-12 2019-02-12 歌尔科技有限公司 Flow data synchronous method, device, equipment and storage medium

Also Published As

Publication number Publication date
CN111447253A (en) 2020-07-24

Similar Documents

Publication Publication Date Title
CN109587510B (en) Live broadcast method, device, equipment and storage medium
CN111447253B (en) Buffer management method, system, device and storage medium
US8345657B2 (en) Method and device of transmitting and parsing data in wireless communication network
CN110557677A (en) Video transmission method and device
US20120005301A1 (en) Sharing an image
CN109428864B (en) Method and device for improving quality of nginx-rtmp pull flow service
CN114584833A (en) Audio and video processing method and device and storage medium
CN108924485B (en) Client real-time video stream interrupt processing method and system and monitoring system
CN115883962A (en) Camera control method, system, electronic equipment and storage medium
US10412778B2 (en) Data transmission method and apparatus for data service
CN111104233B (en) Data acquisition method, device, computer equipment and computer readable storage medium
CN110381319A (en) Image coding/decoding method and device
CN108667682B (en) Connection synchronization method, device and medium based on secure gateway deep packet detection
CN108737208B (en) Connection synchronization method and device based on secure gateway deep packet detection and computer
KR101612312B1 (en) DATA processing improvement device and method thereof
CN111953978A (en) Frame rate control method, device and storage medium
CN115001630B (en) Data transmission method, device, equipment and storage medium
CN117221617A (en) Live broadcast push flow system, method and computer storage medium
CN114422082B (en) Transmission control method, system, device and medium based on linear network coding
CN116208788B (en) Method and device for providing network application service, server equipment and storage medium
CN116962811A (en) Point location frame data processing method and device and point location frame data rendering method
CN111836117B (en) Method and device for sending supplementary frame data and related components
CN111478929B (en) Video service data transmission method and device
CN114501083A (en) Code rate adjusting method, device, equipment, medium and program product
CN113824851A (en) Image processing method, image processing device, storage medium and electronic equipment

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