Bag filling rate adjusting method and device, electronic equipment and storage medium
By collecting and analyzing the filling rate values and adjusting the filling time interval to match the maximum and current filling rate values, the problem of inaccurate rate in the software virtual filling component is solved, and higher filling rate accuracy is achieved.
Patent Information
- Application Number
- CN202110859962.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-07-28
- Publication Date
- 2026-01-02
- Estimated Expiration
- 2041-07-28
AI Technical Summary
In the existing technology, the software virtual filling component has the problem of inaccuracy in the setting and adjustment of the filling rate, which leads to a large deviation between the final rate and the expected value when the filling is stable.
By sequentially collecting N filling rate values, the subsequent rates are adjusted based on the maximum filling rate value and the current filling rate value. Specifically, the filling time interval is reduced when the maximum filling rate value is greater than or equal to the current value, and increased when the maximum filling rate value is less than or equal to the current value. Before adjustment, it is determined whether the filling rate is in a stable state.
It improves the accuracy of the filling rate, ensures that the filling rate can be precisely adjusted under stable conditions, and reduces rate deviation.
Smart Images

Figure CN115696578B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of communication, in particular to a packet filling rate adjusting method and device, electronic equipment and storage medium. BACKGROUND
[0002] High-speed packet filling instruments play a very important role in the development process of the 5th generation mobile communication (5G) network.
[0003] In order to meet the needs of high-speed packet filling, the prior art usually uses a software virtual packet filling component to fill packets. At present, the software virtual packet filling component can meet most of the packet filling needs, but there is an inaccuracy problem in setting and adjusting the packet filling rate during the packet filling process, that is, there is usually a relatively large deviation value between the final packet filling rate and the expected value when the packet filling is stable. SUMMARY
[0004] The embodiments of the present application provide a packet filling rate adjusting method and device, electronic equipment and storage medium to solve the technical problem of inaccurate packet filling rate in the prior art.
[0005] In a first aspect, the embodiments of the present application provide a packet filling rate adjusting method, comprising:
[0006] sequentially collecting N packet filling rate values; N is an integer greater than 1;
[0007] adjusting the subsequent packet filling rate based on the maximum packet filling rate value in the N packet filling rate values and the current packet filling rate value; the current packet filling rate value is the Nth packet filling rate value in the N packet filling rate values.
[0008] Optionally, in the case where the maximum packet filling rate value is greater than or equal to the current packet filling rate value, the adjusting the subsequent packet filling rate based on the maximum value and the current value in the N packet filling rate values comprises:
[0009] decreasing the packet filling time interval according to the maximum packet filling rate value and the current packet filling rate value.
[0010] Optionally, the decreasing the packet filling time interval according to the maximum packet filling rate value and the current packet filling rate value comprises:
[0011] if the maximum packet filling rate value is less than the current packet filling rate value minus a first preset value TH1, and the adjustment step is greater than 1, then decreasing the packet filling time interval by a second preset value TH2;
[0012] if the adjustment step is equal to 1, then decreasing the packet filling time interval by a third preset value TH3.
[0013] if the maximum filling rate value is less than or equal to the current filling rate value minus the TH1 and the maximum filling rate value is greater than the current filling rate value minus a fourth preset value TH4, the filling time interval is decreased by a fifth preset value TH5;
[0014] if the maximum filling rate value is less than the current filling rate value minus a sixth preset value TH6 and the maximum filling rate value is greater than the current filling rate value minus the TH1, the filling time interval is decreased by a seventh preset value TH7;
[0015] wherein the adjustment step is equal to the absolute value of the difference between the maximum filling rate value and the current filling rate value; the TH1, the TH2, the TH3, the TH4, the TH5, the TH6 and the TH7 are all positive integers.
[0016] Optionally, in the case that the maximum filling rate value is less than the current filling rate value, the adjusting the subsequent filling rate based on the maximum value and the current value in the N filling rate values comprises:
[0017] increasing the filling time interval according to the maximum filling rate value and the current filling rate value.
[0018] Optionally, the increasing the filling time interval according to the maximum filling rate value and the current filling rate value comprises:
[0019] if the maximum filling rate value is greater than the current filling rate value plus TH1 and the adjustment step is greater than 1, the filling time interval is increased by TH2;
[0020] if the adjustment step is equal to 1, the filling time interval is increased by TH3;
[0021] if the maximum filling rate value is greater than the current filling rate value plus the TH1 and the maximum filling rate value is less than the current filling rate value plus TH4, the filling time interval is increased by TH5;
[0022] if the maximum filling rate value is greater than the current filling rate value plus TH6 and the maximum filling rate value is less than or equal to the current filling rate value plus the TH1, the filling time interval is increased by TH7;
[0023] wherein the adjustment step is equal to the absolute value of the difference between the maximum filling rate value and the current filling rate value; the TH1, the TH2, the TH3, the TH4, the TH5, the TH6 and the TH7 are all positive integers.
[0024] Optionally, before the adjusting the subsequent stuffing rate based on the maximum stuffing rate value and the current stuffing rate value, the method further comprises:
[0025] determining that the current stuffing rate is in a stable state.
[0026] Optionally, the determining that the current stuffing rate is in a stable state comprises:
[0027] obtaining an absolute value of a difference between a first stuffing rate value and an Nth stuffing rate value;
[0028] in a case where the absolute value of the difference between the first stuffing rate value and the Nth stuffing rate value is less than an eighth preset value TH8, determining that the current stuffing rate is in a stable state.
[0029] In a second aspect, an embodiment of the present application provides an electronic device, comprising a memory, a transceiver and a processor.
[0030] the memory is configured to store a computer program; the transceiver is configured to transceive data under control of the processor; and the processor is configured to read the computer program in the memory and perform the following operations:
[0031] sequentially collecting N stuffing rate values; N is an integer greater than 1;
[0032] adjusting a subsequent stuffing rate based on a maximum stuffing rate value and a current stuffing rate value in the N stuffing rate values; the current stuffing rate value is an Nth stuffing rate value in the N stuffing rate values.
[0033] Optionally, in a case where the maximum stuffing rate value is greater than or equal to the current stuffing rate value, the adjusting the subsequent stuffing rate based on the maximum value and the current value in the N stuffing rate values comprises:
[0034] decreasing a stuffing time interval according to the maximum stuffing rate value and the current stuffing rate value.
[0035] Optionally, the decreasing the stuffing time interval according to the maximum stuffing rate value and the current stuffing rate value comprises:
[0036] if the maximum stuffing rate value is less than the current stuffing rate value minus a first preset value TH1, and an adjustment step is greater than 1, decreasing the stuffing time interval by a second preset value TH2;
[0037] if the adjustment step is equal to 1, decreasing the stuffing time interval by a third preset value TH3;
[0038] if the maximum filling rate value is less than or equal to the current filling rate value minus the TH1, and the maximum filling rate value is greater than the current filling rate value minus a fourth preset value TH4, then the filling time interval is decreased by a fifth preset value TH5;
[0039] if the maximum filling rate value is less than the current filling rate value minus a sixth preset value TH6, and the maximum filling rate value is greater than the current filling rate value minus the TH1, then the filling time interval is decreased by a seventh preset value TH7;
[0040] wherein the adjustment step is equal to the absolute value of the difference between the maximum filling rate value and the current filling rate value; the TH1, the TH2, the TH3, the TH4, the TH5, the TH6 and the TH7 are all positive integers.
[0041] Optionally, in the case that the maximum filling rate value is less than the current filling rate value, the adjusting the subsequent filling rate based on the maximum value and the current value in the N filling rate values comprises:
[0042] increasing the filling time interval according to the maximum filling rate value and the current filling rate value.
[0043] Optionally, the increasing the filling time interval according to the maximum filling rate value and the current filling rate value comprises:
[0044] if the maximum filling rate value is greater than the current filling rate value plus TH1, and the adjustment step is greater than 1, then the filling time interval is increased by TH2;
[0045] if the adjustment step is equal to 1, then the filling time interval is increased by TH3;
[0046] if the maximum filling rate value is greater than the current filling rate value plus the TH1, and the maximum filling rate value is less than the current filling rate value plus TH4, then the filling time interval is increased by TH5;
[0047] if the maximum filling rate value is greater than the current filling rate value plus TH6, and the maximum filling rate value is less than or equal to the current filling rate value plus the TH1, then the filling time interval is increased by TH7;
[0048] wherein the adjustment step is equal to the absolute value of the difference between the maximum filling rate value and the current filling rate value; the TH1, the TH2, the TH3, the TH4, the TH5, the TH6 and the TH7 are all positive integers.
[0049] Optionally, before the adjusting the subsequent stuffing rate based on the maximum stuffing rate value in the N stuffing rate values and the current stuffing rate value, the method further comprises:
[0050] determining that the current stuffing rate is in a stable state.
[0051] Optionally, the determining that the current stuffing rate is in a stable state comprises:
[0052] obtaining an absolute value of a difference between a first stuffing rate value and an Nth stuffing rate value;
[0053] in a case where the absolute value of the difference between the first stuffing rate value and the Nth stuffing rate value is less than an eighth preset value TH8, determining that the current stuffing rate is in a stable state.
[0054] In a third aspect, an embodiment of the present application provides a stuffing rate adjustment device, comprising:
[0055] a collection module, configured to sequentially collect N stuffing rate values; N is an integer greater than 1;
[0056] an adjustment module, configured to adjust a subsequent stuffing rate based on a maximum stuffing rate value in the N stuffing rate values and a current stuffing rate value; the current stuffing rate value is an Nth stuffing rate value in the N stuffing rate values.
[0057] In a fourth aspect, an embodiment of the present application further provides a processor-readable storage medium, which stores a computer program, and the computer program is used to make the processor execute steps of the stuffing rate adjustment method in the first aspect.
[0058] The stuffing rate adjustment method, device, electronic device and storage medium provided by the embodiments of the present application sequentially collect N stuffing rate values, and automatically adjust a subsequent stuffing rate based on a maximum stuffing rate value in the N stuffing rate values and a current stuffing rate value, thereby improving the accuracy of the stuffing rate. BRIEF DESCRIPTION OF DRAWINGS
[0059] In order to more clearly illustrate the technical solutions of the embodiments of the present application or the prior art, the following will briefly introduce the drawings needed to be used in the embodiments or the prior art description. Obviously, the drawings in the following description are some embodiments of the present application, and those skilled in the art can obtain other drawings according to these drawings without creative labor.
[0060] Figure 1 is a flowchart of the stuffing rate adjustment method provided by the embodiments of the present application;
[0061] Figure 2is a logical flow diagram of a bag filling rate adjustment provided by an embodiment of the present application;
[0062] Figure 3 is a structural diagram of a bag filling rate adjustment device provided by an embodiment of the present application;
[0063] Figure 4 is a structural diagram of an electronic device provided by an embodiment of the present application. DETAILED DESCRIPTION
[0064] To make the objectives, technical solutions, and superiorities of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be described below in connection with the drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments of the present application. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative effort belong to the scope of protection of the present application.
[0065] Figure 1 is a flow diagram of a bag filling rate adjustment method provided by an embodiment of the present application, as shown in Figure 1 The application embodiment provides a bag filling rate adjustment method, and the method comprises the following steps.
[0066] Step 101: sequentially collect N bag filling rate values; N is an integer greater than 1.
[0067] Specifically, in the embodiments of the present application, the current bag filling rate is queried in real time through a timing task, and the sampling values of the latest N times of the rate of each port are saved. N is an integer greater than 1, and the value of N can be configured according to actual needs. For example, the value of N can be 5.
[0068] Optionally, before the subsequent bag filling rate is adjusted based on the maximum bag filling rate value in the N bag filling rate values and the current bag filling rate value, the method further comprises the following steps.
[0069] It is determined that the current bag filling rate is in a stable state.
[0070] Specifically, in the embodiments of the present application, before the subsequent bag filling rate is adjusted based on the maximum bag filling rate value in the N bag filling rate values and the current bag filling rate value, it can be first determined that the current bag filling rate is in a stable state.
[0071] In the embodiments of the present application, it is first determined that the current bag filling rate is in a stable state, and then the bag filling rate is adjusted, which improves the accuracy of the bag filling rate by one step.
[0072] Optionally, the step of determining that the current bag filling rate is in a stable state comprises the following steps.
[0073] obtaining an absolute value of a difference between a first packet stuffing rate value and an Nth packet stuffing rate value;
[0074] In a case where the absolute value of the difference between the first packet stuffing rate value and the Nth packet stuffing rate value is less than an eighth preset value TH8, it is determined that the current packet stuffing rate is in a stable state.
[0075] Specifically, in the embodiment of the present application, the specific steps of determining that the current packet stuffing rate is in a stable state are as follows:
[0076] First, an absolute value of a difference between a first packet stuffing rate value and an Nth packet stuffing rate value is obtained.
[0077] For example, when the value of N can be 5, the absolute value of the difference between the first sampling and the fifth sampling is calculated every 5 times of sampling the packet stuffing rate value.
[0078] Then, the size relationship between the absolute value of the difference between the first packet stuffing rate value and the Nth packet stuffing rate value and a preset value is judged, and in a case where the absolute value of the difference between the first packet stuffing rate value and the Nth packet stuffing rate value is less than the preset value, it is determined that the current packet stuffing rate is in a stable state.
[0079] The preset value can be configured according to actual needs.
[0080] For example, when the value of N can be 5, the absolute value of the difference between the first sampling and the fifth sampling is calculated every 5 times of sampling the packet stuffing rate value. If the absolute value is less than 30, it is considered that the current rate has reached a stable state.
[0081] In the embodiment of the present application, whether the current packet stuffing rate is in a stable state is determined by judging the size relationship between the absolute value of the difference between the first packet stuffing rate value and the Nth packet stuffing rate value and a preset value, and the accuracy of the packet stuffing rate is improved by adjusting the packet stuffing rate after the current packet stuffing rate is stable.
[0082] In step 102, a subsequent packet stuffing rate is adjusted based on a maximum packet stuffing rate value in the N packet stuffing rate values and a current packet stuffing rate value; the current packet stuffing rate value is an Nth packet stuffing rate value in the N packet stuffing rate values.
[0083] Specifically, in the embodiment of the present application, after the N packet stuffing rate values are sequentially collected, a subsequent packet stuffing rate is adjusted based on a maximum packet stuffing rate value in the N packet stuffing rate values and a current packet stuffing rate value, where the current packet stuffing rate value is an Nth packet stuffing rate value in the N packet stuffing rate values.
[0084] Optionally, in a case where the maximum packet stuffing rate value is greater than or equal to the current packet stuffing rate value, the adjusting the subsequent packet stuffing rate based on the maximum value in the N packet stuffing rate values and the current value comprises:
[0085] decrease the filling time interval according to the maximum filling rate value and the current filling rate value.
[0086] For example, in the case that the maximum filling rate value is greater than or equal to the current filling rate value, if the maximum filling rate value is less than the current filling rate value minus 50, and the adjustment step is greater than 1, the filling time interval is decreased by 100.
[0087] For another example, in the case that the maximum filling rate value is greater than or equal to the current filling rate value, if the adjustment step is equal to 1, the filling time interval is decreased by 50.
[0088] For another example, in the case that the maximum filling rate value is greater than or equal to the current filling rate value, if the maximum filling rate value is less than or equal to the current filling rate value minus 50, and the maximum filling rate value is greater than the current filling rate value minus 100, the filling time interval is decreased by 7.
[0089] In the embodiment of the present application, in the case that the maximum filling rate value is greater than or equal to the current filling rate value, the filling time interval is decreased according to the maximum filling rate value and the current filling rate value, which improves the accuracy of the filling rate.
[0090] Optionally, the decreasing the filling time interval according to the maximum filling rate value and the current filling rate value comprises:
[0091] if the maximum filling rate value is less than the current filling rate value minus a first preset value TH1, and the adjustment step is greater than 1, the filling time interval is decreased by a second preset value TH2;
[0092] if the adjustment step is equal to 1, the filling time interval is decreased by a third preset value TH3;
[0093] if the maximum filling rate value is less than or equal to the current filling rate value minus the TH1, and the maximum filling rate value is greater than the current filling rate value minus a fourth preset value TH4, the filling time interval is decreased by a fifth preset value TH5;
[0094] if the maximum filling rate value is less than the current filling rate value minus a sixth preset value TH6, and the maximum filling rate value is greater than the current filling rate value minus the TH1, the filling time interval is decreased by a seventh preset value TH7;
[0095] wherein the adjustment step is equal to the absolute value of the difference between the maximum filling rate value and the current filling rate value; the TH1, the TH2, the TH3, the TH4, the TH5, the TH6 and the TH7 are all positive integers.
[0096] Specifically, Figure 2 is a logical flow diagram of the bag filling rate adjustment provided by the embodiments of the present application, as shown in the present application, according to the maximum bag filling rate value M and the current bag filling rate value C, the specific steps of reducing the bag filling time interval tx include: Figure 2
[0097] If the maximum bag filling rate value M is less than the current bag filling rate value C minus TH1, and the adjustment step is greater than 1, the bag filling time interval tx is reduced by TH2.
[0098] If the adjustment step is equal to 1, the bag filling time interval tx is reduced by TH3.
[0099] If the maximum bag filling rate value M is less than or equal to the current bag filling rate value C minus TH1, and the maximum bag filling rate value M is greater than the current bag filling rate value C minus TH4, the bag filling time interval tx is reduced by TH5.
[0100] If the maximum bag filling rate value M is less than the current bag filling rate value C minus TH6, and the maximum bag filling rate value M is greater than the current bag filling rate value C minus TH1, the bag filling time interval tx is reduced by TH7.
[0101] Wherein, the adjustment step is equal to the absolute value of the difference between the maximum bag filling rate value M and the current bag filling rate value C; TH1, TH2, TH3, TH4, TH5, TH6 and TH7 are positive integers.
[0102] For example, Figure 2 In the present application, the values of TH1, TH2, TH3, TH4, TH5, TH6 and TH7 are 50, 100, 50, 100, 7, 20 and 1 respectively.
[0103] If the maximum bag filling rate value M is less than the current bag filling rate value C minus 50, and the adjustment step is greater than 1, the bag filling time interval tx is reduced by 100.
[0104] If the adjustment step is equal to 1, the bag filling time interval tx is reduced by 50.
[0105] If the maximum bag filling rate value M is less than or equal to the current bag filling rate value C minus 50, and the maximum bag filling rate value M is greater than the current bag filling rate value C minus 100, the bag filling time interval tx is reduced by 7.
[0106] If the maximum bag filling rate value M is less than the current bag filling rate value C minus 20, and the maximum bag filling rate value M is greater than the current bag filling rate value C minus 50, the bag filling time interval tx is reduced by 1.
[0107] It should be noted that the values of TH1, TH2, TH3, TH4, TH5, TH6 and TH7 are respectively 50, 100, 50, 100, 7, 20 and 1, which is one optional solution, and TH1, TH2, TH3, TH4, TH5, TH6 and TH7 can be configured according to actual conditions, which will not be illustrated here.
[0108] In the case that the maximum filling rate value is greater than or equal to the current filling rate value, the filling time interval is reduced by different values according to the different size relationship between the maximum filling rate value and the current filling rate value, thereby improving the accuracy of the filling rate.
[0109] Optionally, in the case that the maximum filling rate value is less than the current filling rate value, the adjusting the subsequent filling rate based on the maximum value and the current value in the N filling rate values comprises:
[0110] increasing the filling time interval according to the maximum filling rate value and the current filling rate value.
[0111] For example, in the case that the maximum filling rate value is less than the current filling rate value, if the maximum filling rate value is greater than the current filling rate value plus 50, and the adjustment step is greater than 1, the filling time interval is increased by 100.
[0112] For another example, in the case that the maximum filling rate value is greater than or equal to the current filling rate value, if the adjustment step is equal to 1, the filling time interval is increased by 50.
[0113] For another example, in the case that the maximum filling rate value is greater than or equal to the current filling rate value, if the maximum filling rate value is greater than the current filling rate value plus 50, and the maximum filling rate value is less than the current filling rate value plus 100, the filling time interval is increased by 7.
[0114] In the case that the maximum filling rate value is less than the current filling rate value, the filling time interval is increased according to the maximum filling rate value and the current filling rate value, thereby improving the accuracy of the filling rate.
[0115] Optionally, the increasing the filling time interval according to the maximum filling rate value and the current filling rate value comprises:
[0116] if the maximum filling rate value is greater than the current filling rate value plus TH1, and the adjustment step is greater than 1, the filling time interval is increased by TH2;
[0117] if the adjustment step is equal to 1, the filling time interval is increased by TH3;
[0118] if the maximum filling rate value is greater than the current filling rate value plus TH1 and the maximum filling rate value is less than the current filling rate value plus TH4, the filling time interval is increased by TH5;
[0119] if the maximum filling rate value is greater than the current filling rate value plus TH6 and the maximum filling rate value is less than or equal to the current filling rate value plus TH1, the filling time interval is increased by TH7;
[0120] wherein the adjustment step is equal to the absolute value of the difference between the maximum filling rate value and the current filling rate value; the TH1, the TH2, the TH3, the TH4, the TH5, the TH6 and the TH7 are all positive integers.
[0121] Specifically, as shown in Figure 2 the specific steps of increasing the filling time interval tx according to the maximum filling rate value M and the current filling rate value C in the embodiment of the present application include:
[0122] if the maximum filling rate value M is greater than the current filling rate value C plus TH1 and the adjustment step is greater than 1, the filling time interval tx is increased by TH2.
[0123] if the adjustment step is equal to 1, the filling time interval tx is increased by TH3.
[0124] if the maximum filling rate value M is greater than the current filling rate value C plus TH1 and the maximum filling rate value M is less than the current filling rate value C plus TH4, the filling time interval tx is increased by TH5.
[0125] if the maximum filling rate value M is greater than the current filling rate value C plus TH6 and the maximum filling rate value M is less than or equal to the current filling rate value C plus TH1, the filling time interval tx is increased by TH7.
[0126] wherein the adjustment step is equal to the absolute value of the difference between the maximum filling rate value M and the current filling rate value C; the TH1, the TH2, the TH3, the TH4, the TH5, the TH6 and the TH7 are all positive integers.
[0127] For example, Figure 2 in the embodiment, the values of TH1, TH2, TH3, TH4, TH5, TH6 and TH7 are respectively 50, 100, 50, 100, 7, 20 and 1.
[0128] if the maximum filling rate value M is greater than the current filling rate value C plus 50 and the adjustment step is greater than 1, the filling time interval tx is increased by 100.
[0129] If the adjustment step is equal to 1, the filling time interval tx is increased by 50.
[0130] If the maximum filling rate value M is greater than the current filling rate value C plus 50, and the maximum filling rate value M is less than the current filling rate value C plus 100, the filling time interval tx is increased by 7.
[0131] If the maximum filling rate value M is greater than the current filling rate value C plus 20, and the maximum filling rate value M is less than or equal to the current filling rate value C plus 50, the filling time interval tx is increased by 1.
[0132] It should be noted that the values of TH1, TH2, TH3, TH4, TH5, TH6 and TH7 are 50, 100, 50, 100, 7, 20 and 1 respectively, which is one of the optional schemes, and TH1, TH2, TH3, TH4, TH5, TH6 and TH7 can be configured according to actual conditions, which will not be illustrated here.
[0133] In the embodiment of the application, in the case that the maximum filling rate value is less than the current filling rate value, the filling time interval is increased by different values according to the size relationship between the maximum filling rate value and the current filling rate value, which improves the accuracy of the filling rate by one step.
[0134] Figure 3 is a structural schematic diagram of a filling rate adjustment device provided by the embodiment of the application, as Figure 3 shown, the embodiment of the application provides a filling rate adjustment device, which comprises a collection module 301 and an adjustment module 302, wherein:
[0135] The collection module 301 is configured to sequentially collect N filling rate values; N is an integer greater than 1; the adjustment module 302 is configured to adjust a subsequent filling rate based on a maximum filling rate value in the N filling rate values and a current filling rate value; the current filling rate value is an Nth filling rate value in the N filling rate values.
[0136] Optionally, in the case that the maximum filling rate value is greater than or equal to the current filling rate value, the adjustment module comprises a first adjustment unit.
[0137] The first adjustment unit is configured to decrease a filling time interval according to the maximum filling rate value and the current filling rate value.
[0138] Optionally, the first adjustment unit is specifically configured to:
[0139] If the maximum filling rate value is less than the current filling rate value minus a first preset value TH1, and the adjustment step is greater than 1, the filling time interval is decreased by a second preset value TH2.
[0140] if the adjustment step is equal to 1, the filling time interval is decreased by a third preset value TH3;
[0141] if the maximum filling rate value is less than or equal to the current filling rate value minus the TH1, and the maximum filling rate value is greater than the current filling rate value minus a fourth preset value TH4, the filling time interval is decreased by a fifth preset value TH5;
[0142] if the maximum filling rate value is less than the current filling rate value minus a sixth preset value TH6, and the maximum filling rate value is greater than the current filling rate value minus the TH1, the filling time interval is decreased by a seventh preset value TH7;
[0143] wherein the adjustment step is equal to an absolute value of a difference between the maximum filling rate value and the current filling rate value; the TH1, the TH2, the TH3, the TH4, the TH5, the TH6 and the TH7 are all positive integers.
[0144] Optionally, in the case that the maximum filling rate value is less than the current filling rate value, the adjusting module comprises a second adjusting unit;
[0145] The second adjusting unit is configured to increase the filling time interval according to the maximum filling rate value and the current filling rate value.
[0146] Optionally, the second adjusting unit is specifically configured to:
[0147] if the maximum filling rate value is greater than the current filling rate value plus the TH1, and the adjustment step is greater than 1, the filling time interval is increased by the TH2;
[0148] if the adjustment step is equal to 1, the filling time interval is increased by the TH3;
[0149] if the maximum filling rate value is greater than the current filling rate value plus the TH1, and the maximum filling rate value is less than the current filling rate value plus a TH4, the filling time interval is increased by a TH5;
[0150] if the maximum filling rate value is greater than the current filling rate value plus a TH6, and the maximum filling rate value is less than or equal to the current filling rate value plus the TH1, the filling time interval is increased by a TH7;
[0151] The adjustment step is equal to an absolute value of a difference between the maximum filling rate value and the current filling rate value; the TH1, the TH2, the TH3, the TH4, the TH5, the TH6 and the TH7 are all positive integers.
[0152] Optionally, the method further comprises a determining module:
[0153] The determining module is configured to determine that the current filling rate is in a stable state.
[0154] Optionally, the determining module comprises an obtaining unit and a determining unit.
[0155] The obtaining unit is configured to obtain an absolute value of a difference between a first filling rate value and an Nth filling rate value.
[0156] The determining unit is configured to determine that the current filling rate is in a stable state when the absolute value of the difference between the first filling rate value and the Nth filling rate value is less than an eighth preset value TH8.
[0157] Specifically, the above filling rate adjustment device provided by the embodiments of the present application can realize all the method steps achieved by the method embodiments and achieve the same technical effects. Here, the same parts and beneficial effects of the method embodiments in the embodiments will not be described in detail.
[0158] It should be noted that the division of the units / modules in the above embodiments of the present application is illustrative, and is only a logical function division. When actually implemented, another division mode can be used. In addition, each functional unit in each embodiment of the present application can be integrated in one processing unit, or each unit can exist physically separately, or two or more units can be integrated in one unit. The above integrated unit can be realized in the form of hardware or in the form of a software functional unit.
[0159] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a processor-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) or processor to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0160] Figure 4 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application, such as... Figure 4 As shown, the electronic device may include: a processor 410, a communication interface 420, a memory 430, and a communication bus 440, wherein the processor 410, the communication interface 420, and the memory 430 communicate with each other through the communication bus 440. The processor 410 can call logical instructions in the memory 430 to execute a packet loading rate adjustment method, which includes:
[0161] N filling rate values are collected sequentially; N is an integer greater than 1.
[0162] The subsequent filling rate is adjusted based on the largest filling rate value among the N filling rate values and the current filling rate value; the current filling rate value is the Nth filling rate value among the N filling rate values.
[0163] Further, the logic instructions in the memory 430 described above can be implemented in the form of software functional units and sold or used as independent products, and can be stored in a computer readable storage medium. Based on such understanding, the technical solutions of the present application essentially or the parts that contribute to the prior art or parts of the technical solutions can be embodied in the form of a software product. The computer software product is stored in a storage medium, and includes a number of instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present application. The aforementioned storage medium includes: a U disk, a mobile hard disk, a read-only memory (ROM, Read-Only Memory), a random access memory (RAM, Random Access Memory), a magnetic disk or an optical disk, and various media that can store program codes.
[0164] Optionally, in the case that the maximum filling rate value is greater than or equal to the current filling rate value, the adjusting the subsequent filling rate based on the maximum value and the current value in the N filling rate values comprises:
[0165] According to the maximum filling rate value and the current filling rate value, the filling time interval is reduced.
[0166] Optionally, the reducing the filling time interval according to the maximum filling rate value and the current filling rate value comprises:
[0167] If the maximum filling rate value is less than the current filling rate value minus a first preset value TH1, and the adjustment step is greater than 1, the filling time interval is reduced by a second preset value TH2.
[0168] If the adjustment step is equal to 1, the filling time interval is reduced by a third preset value TH3.
[0169] If the maximum filling rate value is less than or equal to the current filling rate value minus the TH1, and the maximum filling rate value is greater than the current filling rate value minus a fourth preset value TH4, the filling time interval is reduced by a fifth preset value TH5.
[0170] If the maximum filling rate value is less than the current filling rate value minus a sixth preset value TH6, and the maximum filling rate value is greater than the current filling rate value minus the TH1, the filling time interval is reduced by a seventh preset value TH7.
[0171] The adjustment step is equal to the absolute value of the difference between the maximum filling rate value and the current filling rate value; the TH1, the TH2, the TH3, the TH4, the TH5, the TH6, and the TH7 are all positive integers.
[0172] Optionally, in the case that the maximum filling rate value is less than the current filling rate value, the adjusting the subsequent filling rate based on the maximum value and the current value in the N filling rate values comprises:
[0173] Increasing the filling time interval according to the maximum filling rate value and the current filling rate value.
[0174] Optionally, the increasing the filling time interval according to the maximum filling rate value and the current filling rate value comprises:
[0175] If the maximum filling rate value is greater than the current filling rate value plus TH1, and the adjustment step is greater than 1, the filling time interval is increased by TH2;
[0176] If the adjustment step is equal to 1, the filling time interval is increased by TH3;
[0177] If the maximum filling rate value is greater than the current filling rate value plus the TH1, and the maximum filling rate value is less than the current filling rate value plus TH4, the filling time interval is increased by TH5;
[0178] If the maximum filling rate value is greater than the current filling rate value plus TH6, and the maximum filling rate value is less than or equal to the current filling rate value plus the TH1, the filling time interval is increased by TH7;
[0179] The adjustment step is equal to the absolute value of the difference between the maximum filling rate value and the current filling rate value; the TH1, the TH2, the TH3, the TH4, the TH5, the TH6, and the TH7 are all positive integers.
[0180] Optionally, before the adjusting the subsequent filling rate based on the maximum value and the current value in the N filling rate values, the method further comprises:
[0181] Determining that the current filling rate is in a stable state.
[0182] Optionally, the determining that the current filling rate is in a stable state comprises:
[0183] Obtaining the absolute value of the difference between the first filling rate value and the Nth filling rate value;
[0184] In a case where an absolute value of a difference between the first packet stuffing rate value and the Nth packet stuffing rate value is less than an eighth preset value TH8, it is determined that the current packet stuffing rate is in a stable state.
[0185] The electronic device provided by the embodiments of the present application sequentially collects N packet stuffing rate values, and automatically adjusts a subsequent packet stuffing rate based on a maximum packet stuffing rate value in the N packet stuffing rate values and a current packet stuffing rate value, thereby improving the accuracy of the packet stuffing rate.
[0186] Optionally, the embodiments of the present application further provide a processor readable storage medium, which stores a computer program for causing a processor to execute the method provided by the above embodiments, including:
[0187] sequentially collecting N packet stuffing rate values; N is an integer greater than 1;
[0188] adjusting a subsequent packet stuffing rate based on a maximum packet stuffing rate value in the N packet stuffing rate values and a current packet stuffing rate value; the current packet stuffing rate value is an Nth packet stuffing rate value in the N packet stuffing rate values.
[0189] It should be noted that the processor readable storage medium can be any available medium or data storage device accessible by a processor, including but not limited to a magnetic memory (such as a floppy disk, a hard disk, a magnetic tape, a magneto-optical disk (MO), etc.), an optical memory (such as a CD, a DVD, a BD, a HVD, etc.), and a semiconductor memory (such as a ROM, an EPROM, an EEPROM, a non-volatile memory (NAND FLASH), a solid state disk (SSD), etc.).
[0190] The storage medium provided by the embodiments of the present application sequentially collects N packet stuffing rate values, and automatically adjusts a subsequent packet stuffing rate based on a maximum packet stuffing rate value in the N packet stuffing rate values and a current packet stuffing rate value, thereby improving the accuracy of the packet stuffing rate.
[0191] In addition, it should be noted that the terms "first", "second", etc. in the embodiments of the present application are used to distinguish similar objects, and are not used to describe a specific order or sequence. It should be understood that the terms used in this way can be interchanged under appropriate circumstances, so that the embodiments of the present application can be implemented in an order other than that illustrated or described herein, and the objects distinguished by "first", "second" are usually of a kind and do not limit the number of objects, for example, the first object can be one or more.
[0192] The term "and / or" used in the embodiments of the present application describes an association relationship of associated objects, which means that there can be three relationships, for example, A and / or B can mean that there are three cases of A alone, A and B together, and B alone. The character " / " generally represents an "or" relationship between the associated objects before and after it.
[0193] The term "multiple" in the embodiments of the present application means two or more, and other quantifiers are similar.
[0194] The device embodiments described above are only schematic, wherein the units described as separate components can or can not be physically separated, and the components displayed as units can or can not be physical units, i.e., they can be located in one place, or distributed on multiple network units. Part or all of the modules can be selected to achieve the purpose of the embodiments according to actual needs. Those skilled in the art can understand and implement without creative labor.
[0195] Through the description of the above embodiments, those skilled in the art can clearly understand that each embodiment can be realized by means of software and necessary general hardware platform, and of course, it can also be realized by hardware. Based on such understanding, the above technical solutions can be embodied in the form of software product, which can be stored in a computer readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., including a plurality of instructions to make a computer device (which can be a personal computer, server, or network device, etc.) execute the method described in each embodiment or some part of the embodiment.
[0196] Finally, it should be noted that: the above embodiments are only used to illustrate the technical solutions of the present application, and not to limit them; although the present application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that they can still modify the technical solutions recorded in the foregoing embodiments, or make equivalent replacement for some technical features; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present application.
Claims
1. A method for adjusting the filling rate, characterized in that, include: Collect N filling rate values sequentially; N is an integer greater than 1; The subsequent filling rate is adjusted based on the largest filling rate value among the N filling rate values and the current filling rate value; the current filling rate value is the Nth filling rate value among the N filling rate values. When the maximum filling rate value is greater than or equal to the current filling rate value, adjusting the subsequent filling rate based on the maximum value among the N filling rate values and the current value includes: Increase the filling time interval based on the maximum filling rate value and the current filling rate value; The step of increasing the filling time interval based on the maximum filling rate value and the current filling rate value includes: If the maximum filling rate value is greater than the current filling rate value plus a first preset value TH1, and the adjustment step size is greater than 1, then the filling time interval will be increased by a second preset value TH2. If the adjustment step size is equal to 1, then the filling time interval will be increased by a third preset value TH3; If the maximum filling rate value is greater than the current filling rate value plus TH1, and the maximum filling rate value is less than the current filling rate value plus a fourth preset value TH4, then the filling time interval will be increased by a fifth preset value TH5. If the maximum filling rate is greater than the current filling rate plus a sixth preset value TH6, and the maximum filling rate is less than or equal to the current filling rate plus TH1, then the filling time interval will be increased by a seventh preset value TH7. Wherein, the adjustment step size is equal to the absolute value of the difference between the maximum filling rate value and the current filling rate value; TH1, TH2, TH3, TH4, TH5, TH6 and TH7 are all positive integers.
2. The method for adjusting the filling rate according to claim 1, characterized in that, Before adjusting the subsequent filling rate based on the largest filling rate value among the N filling rate values and the current filling rate value, the method further includes: Determine that the current filling rate is in a stable state.
3. The method for adjusting the filling rate according to claim 2, characterized in that, Determining that the current filling rate is in a stable state includes: Obtain the absolute value of the difference between the first filling rate value and the Nth filling rate value; If the absolute value of the difference between the first filling rate value and the Nth filling rate value is less than the eighth preset value TH8, the current filling rate is determined to be in a stable state.
4. An electronic device, characterized in that, Includes memory, transceiver, and processor; A memory for storing computer programs; a transceiver for sending and receiving data under the control of the processor; and a processor for reading the computer programs from the memory and performing the following operations: N filling rate values are collected sequentially; N is an integer greater than 1. The subsequent filling rate is adjusted based on the largest filling rate value among the N filling rate values and the current filling rate value; the current filling rate value is the Nth filling rate value among the N filling rate values. When the maximum filling rate value is greater than or equal to the current filling rate value, adjusting the subsequent filling rate based on the maximum value among the N filling rate values and the current value includes: Increase the filling time interval based on the maximum filling rate value and the current filling rate value; The step of reducing the filling time interval based on the maximum filling rate value and the current filling rate value includes: If the maximum filling rate value is greater than the current filling rate value plus a first preset value TH1, and the adjustment step size is greater than 1, then the filling time interval will be increased by a second preset value TH2. If the adjustment step size is equal to 1, then the filling time interval will be increased by a third preset value TH3; If the maximum filling rate value is greater than the current filling rate value plus TH1, and the maximum filling rate value is less than the current filling rate value plus a fourth preset value TH4, then the filling time interval will be increased by a fifth preset value TH5. If the maximum filling rate is greater than the current filling rate plus a sixth preset value TH6, and the maximum filling rate is less than or equal to the current filling rate plus TH1, then the filling time interval will be increased by a seventh preset value TH7. Wherein, the adjustment step size is equal to the absolute value of the difference between the maximum filling rate value and the current filling rate value; TH1, TH2, TH3, TH4, TH5, TH6 and TH7 are all positive integers.
5. The electronic device according to claim 4, characterized in that, Before adjusting the subsequent filling rate based on the largest filling rate value among the N filling rate values and the current filling rate value, the method further includes: Determine that the current filling rate is in a stable state.
6. The electronic device according to claim 5, characterized in that, Determining that the current filling rate is in a stable state includes: Obtain the absolute value of the difference between the first filling rate value and the Nth filling rate value; If the absolute value of the difference between the first filling rate value and the Nth filling rate value is less than the eighth preset value TH8, the current filling rate is determined to be in a stable state.
7. A filling rate adjustment device, characterized in that, include: The acquisition module is used to sequentially acquire N filling rate values; N is an integer greater than 1; An adjustment module is used to adjust the subsequent filling rate based on the largest filling rate value among the N filling rate values and the current filling rate value; the current filling rate value is the Nth filling rate value among the N filling rate values. When the maximum filling rate value is greater than or equal to the current filling rate value, adjusting the subsequent filling rate based on the maximum value among the N filling rate values and the current value includes: Increase the filling time interval based on the maximum filling rate value and the current filling rate value; The step of increasing the filling time interval based on the maximum filling rate value and the current filling rate value includes: If the maximum filling rate value is greater than the current filling rate value plus a first preset value TH1, and the adjustment step size is greater than 1, then the filling time interval will be increased by a second preset value TH2. If the adjustment step size is equal to 1, then the filling time interval will be increased by a third preset value TH3; If the maximum filling rate value is greater than the current filling rate value plus TH1, and the maximum filling rate value is less than the current filling rate value plus a fourth preset value TH4, then the filling time interval will be increased by a fifth preset value TH5. If the maximum filling rate is greater than the current filling rate plus a sixth preset value TH6, and the maximum filling rate is less than or equal to the current filling rate plus TH1, then the filling time interval will be increased by a seventh preset value TH7. Wherein, the adjustment step size is equal to the absolute value of the difference between the maximum filling rate value and the current filling rate value; TH1, TH2, TH3, TH4, TH5, TH6 and TH7 are all positive integers.
8. A processor-readable storage medium, characterized in that, The processor-readable storage medium stores a computer program for causing the processor to perform the filling rate adjustment method according to any one of claims 1 to 3.
Citation Information
Patent Citations
Performance testing system, method and equipment
CN102098702A
Data rate adjusting method and device, computer readable medium and electronic equipment
CN112217608A