Detailed Description
The terms "first" and "second" are used below for descriptive purposes only and are not to be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defining "a first" or "a second" may explicitly or implicitly include one or more such feature. In the description of the present embodiment, unless otherwise specified, the meaning of "plurality" is two or more.
In embodiments of the application, words such as "exemplary" or "such as" are used to mean serving as an example, instance, or illustration. Any embodiment or design described herein as "exemplary" or "e.g." in an embodiment should not be taken as preferred or advantageous over other embodiments or designs. Rather, the use of words such as "exemplary" or "such as" is intended to present related concepts in a concrete fashion that may be readily understood.
Electronic equipment (such as a mobile phone) can interact with the base station through an antenna in the electronic equipment, so that the communication function of the electronic equipment is realized.
Currently, when an abnormality occurs in the working state of an antenna, an electronic device may adjust the antenna. For example, the electronic device tunes the antenna and/or the electronic device switches the antenna being used.
Antenna tuning performed in an electronic device may include the electronic device matching the impedance of the antenna at a particular frequency to the impedance of the transmission line by adjusting physical parameters (e.g., length, location) and electronic parameters (e.g., capacitance, inductance) of the antenna to maximize signal transmission efficiency and minimize power reflection, thereby improving antenna efficiency and thus communication quality of the electronic device. The tuning of the antenna performed in the electronic device may further include adjusting a resonant frequency of the antenna by the electronic device by adjusting a physical parameter (such as a length and a position) and an electronic parameter (such as a capacitance and an inductance) of the antenna, so that the resonant frequency of the antenna approaches an operating frequency of the antenna, thereby improving efficiency of the antenna and improving communication quality of the electronic device. The operating frequency of the antenna may be a frequency range in which the electrical characteristics of the antenna allow for its normal operation. Antenna efficiency may refer to the ability of an antenna to convert input power into radiated power.
The transmission antenna switching (TRANSMIT ANTENNA SWITCHING, TAS) performed in the electronic device may refer to an antenna that the electronic device replaces for use, so that the electronic device may use the antenna with a better status for communication.
In some implementations, the electronic device may determine a point in time of antenna tuning and antenna switching by smoothing the processed reference signal received power (REFERENCE SIGNAL RECEIVED power, RSRP). The RSRP is used for measuring the strength of a signal received by the electronic device. The RSRP may be in units of decibel milliwatts (decibel relative to one milliwatt, dbm).
The RSRP of the electronic device changes due to the environment in which the electronic device is located, the change in the transmit power of the base station, the network load and/or the user behavior, and so on.
And the signal strength icon displayed by the electronic equipment changes along with the change of the RSRP, wherein the signal strength icon is used for a user to know the stability and the reliability of the network. The signal strength icon can be seen in fig. 1.
Taking an electronic device as an example of a mobile phone, fig. 1 is a schematic diagram of a desktop of the mobile phone according to an embodiment of the present application. As shown in fig. 1, the mobile phone desktop 100 as in fig. 1 may be displayed after the mobile phone is started. As shown in fig. 1, the mobile phone desktop 100 may include a signal strength icon 101, a smart life application icon, a setup application icon, a recorder application icon, a browser application icon, a camera application icon, an address book application icon, a phone application icon, an information application icon, a time application, a weather application, and the like.
In the case where RSRP of an antenna used by a mobile phone frequently changes, the signal strength icon 101 displayed on the mobile phone desktop 100 also changes relatively frequently. The frequent change of the signal strength icon 101 based on the handset makes the user experience worse.
Thus, to reduce the frequency of the change in the signal strength icon, the electronic device may smooth the RSRP. However, smoothing RSRP tends to smooth or harmonize RSRP corresponding to the time when an abnormality occurs in the antenna state, and thus smooth RSRP corresponding to the time when an abnormality occurs in the antenna state (i.e., RSRP after smoothing) does not enter a section where antenna tuning or antenna switching is required. Therefore, at the timing when the abnormality occurs in the antenna state, the electronic device does not perform antenna tuning or antenna switching. The electronic device does not perform antenna tuning or antenna switching until the time when the smoothed RSRP enters the interval where antenna tuning or antenna switching is required. But the time when the smoothed RSRP enters the section where antenna tuning or antenna switching is required has fallen behind the time when the RSRP is abnormal. Thus, smoothing the RSRP causes hysteresis in antenna tuning and antenna switching of the electronic device. The abnormal antenna state may include that the resonant frequency of the antenna is shifted, and the resonant frequency after the shift is not in a preset range.
The hysteresis of the antenna tuning is described below with reference to fig. 2. Fig. 2 is a schematic diagram of a downlink log of an electronic device according to an embodiment of the present application.
As shown in fig. 2, the downlink modulation and coding scheme (modulation and coding scheme, MCS) level drops rapidly at times 02:47:56.402. However, the smoothed RSRP of antenna I (i.e., RSRP1 in fig. 2) and the smoothed RSRP of antenna II (i.e., RSRP2 in fig. 2) do not immediately drop to the interval where the electronic device is required to perform antenna tuning, but instead drop to the interval where the electronic device is required to perform antenna tuning at times 02:48:01.800. That is, the electronic device starts antenna tuning at the time of 02:48:01.800, and the time point of antenna tuning lags by about 5 seconds. And before the antenna tuning is successful and within 5 seconds, the electronic device communicates at a low downlink MCS level, so that the communication quality of the electronic device is poor. The MCS level is used for limiting the maximum data transmission rate of the electronic equipment, and reflects the evaluation result of the base station on the communication quality of the mobile phone.
Next, hysteresis of antenna switching will be described with reference to fig. 2 and 3. Fig. 3 is an exemplary diagram of an uplink log of an electronic device according to an embodiment of the present application.
As shown in fig. 2, the smoothed RSRP of antenna I (i.e., RSRP1 in fig. 2) is the largest of the two antennas, antenna I and antenna II, before the time 02:48:45.907 seconds. Thus, the electronic device communicates using antenna I before time 02:48:45.907. As shown in fig. 3, the uplink MCS level drops rapidly at times 02:48:45.907. However, as shown in fig. 2, the smoothed RSRP of antenna I does not immediately drop to less than the smoothed RSRP of antenna II (i.e., RSRP2 in fig. 2), but is less than the smoothed RSRP of antenna II at times 02:48:51.000. That is, the electronic device performs the upstream TAS at the time of 02:48:51.000, and the time point of the upstream TAS is delayed by about 5 seconds. The electronic device switches the antenna used by the electronic device from antenna I to antenna II through the uplink TAS. As shown in fig. 2, antenna switching is completed at 02:48:52.000 times. But at and after 02:48:52.000 the smoothed RSRP of antenna I has recovered to be greater than the smoothed RSRP of antenna II, i.e. the smoothed RSRP of antenna I is the largest of the two antennas. Thus, at and after 02:48:52.000, the antenna used by the electronic device is not the best performing antenna. Therefore, from the time when the uplink MCS level drops rapidly to the time when the antenna switches back to the antenna with the largest smooth RSRP, the electronic device does not use the antenna with the best antenna state to perform communication in this period, so that the communication quality of the electronic device is poor.
In view of the above, an embodiment of the present application provides an antenna adjustment method. In the method, the electronic device may make an antenna adjustment (e.g., the electronic device may tune the antenna and/or the electronic device may switch the antenna) in the event that an absolute value of a difference between an actual value of the cellular indicator and a predicted value of the cellular indicator is greater than or equal to a preset threshold.
The cellular index may include a series of parameters for evaluating the performance and quality of the cellular mobile communication system, among other things. Illustratively, the cellular metrics may include RSRP, MCS level, signal-to-noise ratio (SNR), and/or other key metrics. Other key indicators may include, for example, block error rate (BLER), physical uplink control channel path loss (physical uplink control CHANNEL PATH loss), physical uplink control channel transmit power (physical uplink control CHANNEL TRANSMIT power, PUCCH TX power), number of resource blocks (resource block number, RB num), channel quality indication (channel quality indicator, CQI), and/or received signal strength indication (RECEIVED SIGNAL STRENGTH indication, RSSI), among others.
The predicted value of the cellular index in the embodiment of the application is predicted by the electronic equipment according to the actual value of the cellular index. Then, the electronic device judges the actual value of the cellular index and the predicted value of the cellular index, and when the absolute value of the difference value between the actual value of the cellular index and the predicted value of the cellular index is larger than or equal to a preset threshold value, the electronic device adjusts the antenna. Therefore, the electronic equipment can timely perform antenna adjustment under the condition that the actual value of the cellular index is abnormal, and the hysteresis of the antenna adjustment is relieved, so that the time for the electronic equipment to communicate through the antenna under the abnormal cellular index can be reduced. Because the communication quality of the electronic equipment is poor when the electronic equipment communicates through the antenna under the abnormal cellular index, the whole communication quality of the electronic equipment can be improved by reducing the duration of the electronic equipment communicating through the antenna under the abnormal cellular index.
The RSRP may be used to measure the total signal strength received by the electronic device, among other things. The larger the RSRP, the greater the strength of the signal received by the electronic device. RSRP may represent the sum of the strengths of all signals received by the antennas.
The MCS level may be used to define a maximum data transmission rate for the electronic device. The higher the MCS level, the greater the maximum data transmission rate that the electronic device can achieve. The MCS level may be determined by the base station according to parameters such as CQI and BLER. For example, the uplink MCS level may be determined by the base station according to parameters such as uplink CQI and uplink BLER. The downlink MCS level may be determined by the base station according to parameters such as downlink CQI and downlink BLER. Wherein the CQI may be used to indicate the channel quality of the link. The BLER may refer to the proportion of data blocks that cannot be correctly decoded by the receiving end during data transmission. And the base station determines the MCS level according to the parameters such as CQI, BLER and the like and then sends the MCS level to the mobile phone. The MCS level reflects the evaluation result of the mobile phone communication quality by the base station. For example, when the communication quality of the mobile phone is poor, the base station selects a lower MCS level to be issued to the mobile phone so that the maximum data transmission rate which can be achieved by the mobile phone is smaller, and when the communication quality of the mobile phone is good, the base station selects a higher MCS level to be issued to the mobile phone so that the maximum data transmission rate which can be achieved by the mobile phone is larger.
SNR is the ratio of useful signal power to noise power. SNR may represent the transmission quality of a signal under noise interference. The larger the SNR, the smaller the noise mixed in the signal, and the better the signal transmission quality.
As one possible implementation, the electronic device may invoke an antenna prediction model (which may also be referred to as a first prediction model) to predict a predicted value of the cellular indicator.
As a possible implementation manner, the electronic device may invoke the antenna prediction model to obtain a comparison result of an absolute value of a difference value between an actual value of the cellular index output by the antenna prediction model and a predicted value of the cellular index and a preset threshold value. The comparison result may include that an absolute value of a difference between an actual value of the cellular index and a predicted value of the cellular index is greater than or equal to a preset threshold, or that an absolute value of a difference between an actual value of the cellular index and a predicted value of the cellular index is less than a preset threshold.
The preset threshold may be obtained by training in the process of obtaining the antenna prediction model, and the training process of the antenna prediction model will be described in detail later, which is not described in detail here.
As one possible implementation, the electronic device adjusting the antenna may include the electronic device invoking an antenna tuning model (which may also be referred to as a second predictive model) to predict an antenna state number. The electronic device may then modify the value of the usage state parameter (which may also be referred to as a first preset parameter) to an antenna state number predicted by the antenna tuning model and/or modify the usage state parameter to an antenna number indicated by the antenna state number.
The usage status parameter may be used to indicate a current antenna status (the current antenna status may also be referred to as a current status) of an antenna used by the electronic device. For example, when the value of the usage state parameter is state1, it indicates that the current state of the antenna used by the electronic device is the antenna state corresponding to the antenna state number state 1.
The antenna parameters used may be used to indicate the antenna number of the antenna currently being used by the handset. For example, when the value of the used antenna parameter is 1, it indicates that the antenna currently used by the electronic device is the antenna corresponding to the antenna number 1.
The electronic device in the embodiment of the present application may be a device with a display function, such as a mobile phone, a tablet computer, a desktop, a laptop, a handheld computer, a notebook, an ultra-mobile personal computer (UMPC), an augmented reality (augmented reality, AR) or a Virtual Reality (VR) device, and the embodiment of the present application is not limited in particular to the specific form of the electronic device.
The technical scheme provided by the embodiment of the application is further introduced by taking the example that the electronic equipment is a mobile phone. It should be understood that the embodiment of the present application does not limit the product form of the electronic device.
Fig. 4 is a schematic hardware structure of an electronic device according to an embodiment of the present application. As shown in fig. 4, the electronic device may include a processor 410, an external memory interface 420, an internal memory 421, a universal serial bus (universalserial bus, USB) interface 430, a charge management module 440, a power management module 441, a battery 442, an antenna 1, a mobile communication module 450, and a display 460. It should be understood that the structure illustrated in the embodiments of the present application does not constitute a specific limitation on the electronic device. In other embodiments of the application, the electronic device may include more or fewer components, or certain components may be combined, or certain components may be split, or different arrangements of components. The components in the examples above may be implemented in hardware, software, or a combination of software and hardware.
The processor 410 may include one or more processing units, for example, the processor 410 may include a central processor (Central Processing Unit, CPU), an application processor (application processor, AP), a modem processor, a graphics processor (graphics processing unit, GPU), an image signal processor (IMAGE SIGNAL processor, ISP), a controller, a video codec, a digital signal processor (DIGITAL SIGNAL processor, DSP), a baseband processor, and/or a neural-network processing unit, NPU, etc. Wherein the different processing units may be separate devices or may be integrated in one or more processors 410.
The processor 410 may generate operation control signals according to the instruction operation code and the timing signals to complete instruction fetching and instruction execution control.
A memory may also be provided in the processor 410 for storing instructions and data. In some embodiments, the memory in the processor 410 may be a cache memory. The memory may hold instructions or data that are used or used more frequently by the processor 410. If the processor 410 needs to use the instruction or data, it can be called directly from the memory. Repeated accesses are avoided and the latency of the processor 410 is reduced, thereby improving the efficiency of the system.
The wireless communication function of the electronic device can be implemented by the antenna 1, the mobile communication module 450, a modem processor, a baseband processor, and the like.
The antenna 1 is used for transmitting and receiving electromagnetic wave signals. Each antenna in the electronic device may be used to cover a single or multiple communication bands. Different antennas may also be multiplexed to improve the utilization of the antennas.
The mobile communication module 450 may provide a solution for wireless communication including 2G/3G/4G/5G/6G, etc. applied on an electronic device. The mobile communication module 450 may include at least one filter, switch, power amplifier, low noise amplifier (low noise amplifier, LNA), or the like. The mobile communication module 450 may receive electromagnetic waves from the antenna 1, perform processes such as filtering, amplifying, and the like on the received electromagnetic waves, and transmit the processed electromagnetic waves to the modem processor for demodulation. The mobile communication module 450 may amplify the signal modulated by the modem processor, and convert the signal into electromagnetic waves through the antenna 1 to radiate the electromagnetic waves. In some embodiments, at least some of the functional modules of the mobile communication module 450 may be disposed in the processor 410. In some embodiments, at least some of the functional modules of the mobile communication module 450 may be disposed in the same device as at least some of the modules of the processor 410.
The modem processor may include a modulator and a demodulator. The modulator is used for modulating the low-frequency baseband signal to be transmitted into a medium-high frequency signal. The demodulator is used for demodulating the received electromagnetic wave signal into a low-frequency baseband signal. The demodulator then transmits the demodulated low frequency baseband signal to the baseband processor for processing. The low frequency baseband signal is processed by the baseband processor and then transferred to the application processor. The application processor outputs sound signals through an audio device (not limited to speakers, receivers, etc.), or displays images or video through the display screen 460. In some embodiments, the modem processor may be a stand-alone device. In other embodiments, the modem processor may be provided in the same device as the mobile communication module 450 or other functional module, independent of the processor 410.
In some embodiments, the antenna 1 of the electronic device and the mobile communication module 450 are coupled such that the electronic device can communicate with networks and other electronic devices through wireless communication techniques. The wireless communication techniques can include a global system for mobile communications (global system for mobile communications, GSM), general packet radio service (GENERAL PACKET radio service, GPRS), code division multiple access (code divisionmultiple access, CDMA), wideband code division multiple access (wideband code division multiple access, WCDMA), time division code division multiple access (time-division code division multiple access, TD-SCDMA), long term evolution (long term evolution, LTE), BT, GNSS, WLAN, NFC, FM, and/or IR techniques, among others. The GNSS may include a global satellite positioning system (global positioning system, GPS), a global navigation satellite system (globalnavigation SATELLITE SYSTEM, GLONASS), a beidou satellite navigation system (beidou navigationsatellite system, BDS), a quasi zenith satellite system (quasi-zenith SATELLITE SYSTEM, QZSS) and/or a satellite based augmentation system (SATELLITE BASED AUGMENTATION SYSTEMS, SBAS).
As a possible implementation manner, the antenna adjustment method provided by the embodiment of the present application may be executed in a modem processor. In an exemplary embodiment of the present application, the electronic device may adjust a difference between an actual value of the cellular indicator and a predicted value of the cellular indicator through the modem processor. And under the condition that the absolute value of the difference value between the actual value of the cellular index and the predicted value of the cellular index is larger than or equal to a preset threshold value, the electronic equipment can conduct antenna adjustment through the modulation-demodulation processor. The cellular indicator may include, among other things, reference signal received power, modulation and coding scheme level, and/or signal-to-noise ratio.
In the embodiment of the application, when the absolute value of the difference between the actual value of the cellular index and the predicted value of the cellular index is greater than or equal to the preset threshold, the electronic equipment determines that the actual value of the cellular index is abnormal. That is, the electronic device may perform antenna adjustment under the condition that the actual value of the cellular indicator is abnormal, so that the time point of antenna adjustment is closer to the time point of the abnormality of the actual value of the cellular indicator, so as to reduce the duration of the electronic device for communication through the antenna under the abnormal cellular indicator. Because the communication quality of the electronic equipment is poor when the electronic equipment communicates through the antenna under the abnormal cellular index, the whole communication quality of the electronic equipment can be improved by reducing the duration of the electronic equipment communicating through the antenna under the abnormal cellular index.
As another possible implementation, the electronic device may also include a System On Chip (SOC). The antenna adjustment method provided by the embodiment of the application can also be executed in the SOC of the electronic equipment.
As another possible implementation manner, the electronic device may further include another chip or chip system with a simple data processing capability, and the antenna adjustment method provided by the embodiment of the present application may also be executed in the chip or chip system with a simple data processing capability. The chip with data processing capability may be, for example, a radio frequency enhanced chip.
The electronic device may implement display functions through a GPU, a display screen 460, an application processor, and the like. The GPU is a microprocessor for image processing, connected to the display screen 460 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. Processor 410 may include one or more GPUs that execute program instructions to generate or change display information.
As one possible implementation, adjusting the antenna may include tuning the antenna being used by the electronic device and/or switching the antenna being used by the electronic device.
Optionally, the electronic device may further comprise a tuning circuit comprising a tuning component (e.g., resistor, capacitor, and/or inductor) and a switch for switching the tuning component on or off. The electronic device can be used for controlling the turning-in or turning-off of the tuning component based on the control strategy corresponding to the use state parameter, so as to realize tuning of the antenna in use by the electronic device.
For example, the electronic device may control the switch in the tuning circuit for switching on or off the tuning component by using the control policy corresponding to the state parameter, so as to control the switching on or off of the tuning component, so as to switch the antenna state of the antenna being used by the electronic device to the antenna state indicated by the state parameter.
Optionally, the electronic device may further comprise an antenna switching circuit. Multiple antennas may be included in an electronic device. The antenna switching circuit may be used to switch antennas used by electronic devices.
For example, the electronic device may switch an antenna used by the electronic device to an antenna indicated using the antenna parameter through the antenna switching circuit.
The technical scheme provided by the embodiment of the application can be applied to the electronic equipment with the hardware structure shown in the figure 4.
Next, the software architecture of the electronic device will be further described.
Fig. 5 is a schematic software structure of an electronic device according to an embodiment of the present application. The software system of the electronic device may employ a layered architecture, an event driven architecture, a microkernel architecture, a microservice architecture, or a cloud architecture. The embodiment of the application takes an android system with a layered architecture as an example, and illustrates the software structure of a mobile phone.
As shown in fig. 5, the layered architecture divides the software into several layers, each with a clear role and division of work. The layers communicate with each other through a software interface. In some embodiments, the android system is divided into at least three layers, from top to bottom, an application layer, an application framework layer (framework), and a kernel layer, respectively.
The application layer may include a series of application packages, among other things. For example, the application packages may include phone, mailbox, calendar, camera, gallery, map, music, navigation, WLAN, bluetooth, and video applications.
The application framework layer may include, among other things, a window manager, a content provider, a view system, a resource manager, a notification manager, an activity manager, an input manager, and the like.
The window manager provides a Window Management Service (WMS) that may be used for window management, window animation management, surface management, and as a relay station for the input system.
The content provider is used to store and retrieve data and make such data accessible to applications. The data may include video, images, audio, calls made and received, browsing history and bookmarks, phonebooks, etc.
The view system includes visual controls, such as controls to display text, controls to display pictures, and the like. The view system may be used to build applications. The display interface may be composed of one or more views. For example, a display interface including a text message notification icon may include a view displaying text and a view displaying a picture.
The resource manager provides various resources for the application program, such as localization strings, icons, pictures, layout files, video files, and the like.
The notification manager allows the application to display notification information in a status bar, can be used to communicate notification type messages, can automatically disappear after a short dwell, and does not require user interaction. Such as notification manager is used to inform that the download is complete, message alerts, etc. The notification manager may also be a notification in the form of a chart or scroll bar text that appears on the system top status bar, such as a notification of a background running application, or a notification that appears on the screen in the form of a dialog window. For example, a text message is prompted in a status bar, a prompt tone is emitted, the electronic device vibrates, and an indicator light blinks, etc.
The activity manager may provide activity management services (ACTIVITY MANAGER SERVICE, AMS) that may be used for system component (e.g., activity, service, content provider, broadcast receiver) start-up, handoff, scheduling, and application process management and scheduling tasks.
The input manager may provide an input MANAGER SERVICE service (IMS), which may be used to manage inputs to the system, such as touch screen inputs, key inputs, sensor inputs, etc. The IMS retrieves events from the input device node and distributes the events to the appropriate windows through interactions with the WMS.
The kernel layer is a layer between hardware and software. The kernel layer at least comprises a display screen driver, a video driver, a Bluetooth driver, a WIFI driver, a modem processor driver and the like.
The modem processor performs the modem based on a protocol defined by the supported communication technology. The protocol specified by the communication technology in the embodiments of the present application may also be referred to as a communication protocol. The communication protocol stack is the sum of the communication protocols of the layers. Referring to fig. 6, fig. 6 is a schematic diagram of a communication protocol stack of a modem processor according to an embodiment of the present application. As shown in fig. 6, the communication protocol stack of the modem processor may be divided into a control plane and a user plane. The control plane is used for transmitting control signaling and mainly comprises a non-access stratum (NAS) layer, a radio resource control (radio resource control, RRC) layer, a service data adaptation protocol (SERVICE DATA adaptation protocol, SDAP) layer, a packet data convergence protocol (PACKET DATA convergence protocol, PDCP) layer, a radio link control (radio link control, RLC) layer, a medium access control (MEDIA ACCESS control, MAC) layer and a Physical (PHY) layer. The user plane is used for transmitting data information and mainly comprises an SDAP layer, a PDCP layer, an RLC layer, a MAC layer and a PHY layer. It should be understood that the protocol layers of the control plane and the user plane may be divided in different manners or the same manner under different communication technologies. Wherein, the RRC layer, SDAP layer, PDCP layer, RLC layer, MAC layer and PHY layer all belong to an Access Stratum (AS) layer. In the embodiment of the application, RSRP and SNR are parameters of a PHY layer, and MCS level is a parameter of a MAC layer.
The antenna adjustment method provided by the embodiment of the application can be realized in the mobile phone with the hardware structure and the software structure.
The following describes the workflow of the mobile software and hardware by taking RSRP, SNR and/or MCS levels included in the cellular index as examples in combination with the scenario of the interaction between the mobile and the base station.
After the mobile phone is started, an acquisition unit in the modulation and demodulation processor acquires an RSRP actual value and an SNR actual value from the PHY layer and/or acquires an MCS level actual value from the MAC layer. Then, a processing unit in the modem processor inputs the SNR actual value and/or the MCS level actual value into the antenna prediction model, and acquires the RSRP predicted value output by the antenna prediction model.
And/or a processing unit in the modem processor inputs the RSRP actual value and/or the MCS level actual value into the antenna prediction model, and acquires the SNR predicted value output by the antenna prediction model.
And/or, a processing unit in the modem processor inputs the MCS level actual value and/or the SNR actual value into the antenna prediction model, and acquires the MCS level predicted value output by the antenna prediction model.
Thereafter, in the case where the absolute value of the difference between the RSRP actual value and the RSRP predicted value is greater than or equal to a first preset threshold, the absolute value of the difference between the SNR actual value and the SNR predicted value is greater than or equal to a second preset threshold, and/or the absolute value of the difference between the MCS level actual value and the MCS level predicted value is greater than or equal to a third preset threshold, an adjustment unit of the modem processor performs antenna adjustment.
The reason why the embodiment of the present application selects RSRP, MCS level and/or SNR in the cellular index to determine whether the antenna needs adjustment is described below.
For RSRP, when the antenna efficiency is poor, the total signal strength received by the antenna becomes small, so that the RSRP of the antenna becomes small. That is, the change in RSRP of the antenna may reflect the change in antenna efficiency. When a change in the RSRP of the antenna reflects a deterioration in antenna efficiency, it is indicated that an antenna adjustment is required. Thus, the embodiment of the application selects the RSRP of the antenna to determine whether antenna adjustment is required. And when the antenna status is normal, that is, the antenna efficiency is within the allowable range, the difference between the actual RSRP value of the antenna and the predicted RSRP value of the antenna is small, and even the actual RSRP value of the antenna and the predicted RSRP value of the antenna may be equal. Therefore, when the absolute value of the difference between the RSRP actual value of the antenna and the RSRP predicted value of the antenna is greater than the first preset threshold, the mobile phone can determine that the antenna state is abnormal, and the antenna needs to be adjusted.
For SNR, SNR is the ratio of useful signal power to noise power. When the antenna state is good, the useful signal power received by the antenna is high, the noise power is relatively low, and thus the SNR is high. Conversely, if the antenna condition is abnormal, the received useful signal power may decrease, while the noise power may remain unchanged or increase relatively, resulting in a decrease in SNR. That is, when the SNR may reflect the antenna state. Therefore, the embodiment of the application selects the SNR of the antenna to determine whether antenna adjustment is needed. And when the antenna is normal, the difference between the actual SNR value of the antenna and the predicted SNR value of the antenna is small, and even the actual SNR value of the antenna and the predicted SNR value of the antenna may be equal. Therefore, when the absolute value of the difference between the actual SNR value of the antenna and the predicted SNR value of the antenna is greater than the second preset threshold, the mobile phone can determine that the antenna is abnormal, and the antenna needs to be adjusted.
For the MCS level, after the mobile phone and the base station interact, the base station can issue an MCS level to the mobile phone based on the evaluation of the communication quality of the mobile phone. When the communication quality of the mobile phone is relatively poor, the base station selects a relatively low MCS level to be issued to the mobile phone so that the maximum data transmission rate which can be achieved by the mobile phone is relatively small, and when the communication quality of the mobile phone is relatively good, the base station selects a relatively high MCS level to be issued to the mobile phone so that the maximum data transmission rate which can be achieved by the mobile phone is relatively large. In the case of abnormal antenna state, the communication quality of the mobile phone is poor. Thus, the base station selects a lower MCS level to issue to the handset. That is, the MCS level of the mobile phone may reflect the communication quality of the mobile phone, and thus reflect the antenna state of the antenna used by the mobile phone. When the MCS level reflects the abnormal antenna state of the antenna used by the mobile phone, the antenna adjustment is needed. Therefore, the embodiment of the application selects the MCS level of the mobile phone to determine whether antenna adjustment is needed. And when the antenna is normal, the MCS level actual value and the MCS level predicted value may be the same. Therefore, when the absolute value of the difference between the MCS level actual value and the MCS level predicted value is greater than the third preset threshold, the mobile phone may determine that the antenna state is abnormal, and the antenna needs to be adjusted.
Alternatively, the handset may determine whether the antenna needs to be adjusted based on RSRP, MCS level, SNR, and/or other metrics that have an impact on the handset's communication quality (e.g., other key metrics as previously described) similar to RSRP, MCS level, and SNR.
In the embodiment of the application, the cellular indexes such as RSRP, MCS level, SNR and other key indexes can reflect the communication environment of the mobile phone to a certain extent. The communication environment at the same time is relatively stable, and thus, the mobile phone can characterize the communication environment through various cellular indexes. Other types of cellular indicators are then predicted using the plurality of cellular indicators characterizing the communication environment.
Illustratively, the handset may characterize the communication environment by MCS level, SNR, and/or other key metrics. The handset may then predict the RSRP in the communication environment based on the MCS level, SNR, and/or other key indicators characterizing the communication environment.
Or the handset may characterize the communication environment through RSRP, SNR, and/or other key metrics. The handset may then predict the MCS level in the communication environment based on RSRP, SNR, and/or other key indicators characterizing the communication environment.
Or the handset may characterize the communication environment through RSRP, MCS level, and/or other key indicators. The handset may then predict SNR in the communication environment based on RSRP, MCS level, and/or other key indicators characterizing the communication environment.
Other key indicators such as BLER, PUCCH path, PUCCH TX power, RB num, CQI or RSSI may also be predicted by a similar procedure to the RSRP, RSRP or SNR prediction procedure described above.
In the embodiment of the application, when the absolute value of the difference between the actual value of the cellular index and the predicted value of the cellular index is greater than or equal to the preset threshold, the electronic equipment adjusts the antenna. Thus, the electronic equipment can adjust the antenna under the condition that the actual value of the cellular index is abnormal, and the hysteresis of antenna tuning is relieved. Therefore, the overall communication quality of the electronic equipment can be improved.
As a possible implementation manner, the predicted value of the cellular index may be predicted by the antenna prediction model provided by the embodiment of the present application.
Next, before describing the antenna adjustment method provided by the embodiment of the present application, an antenna prediction model provided by the embodiment of the present application is described.
In the embodiment of the application, the training device can train the initial prediction model by using the first training data set, and after the training completion condition (for example, the loss function converges or the training times reach the preset times under the condition that the loss function does not converge) is met, the training process of the training device on the initial prediction model is completed, so that the antenna prediction model is obtained.
The training device may be a terminal, or may be another computing device, such as a server or cloud device. For example, the training device may be a graphics processor (graphics processing unit, GPU), a neural network processor (neural network processing unit, NPU), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits for controlling program execution in accordance with aspects of the present application.
Fig. 7 is a schematic diagram of an architecture of an initial prediction model according to an embodiment of the present application. As shown in fig. 7, an input layer, an output layer, and M hidden layers may be included in the architecture of the initial prediction model. Wherein the input layer may comprise N neurons, and each hidden layer may also comprise a plurality of neurons. M, N may each be an integer greater than or equal to 1.
For convenience of description, the following embodiment is exemplified by M being 3, where the architecture of the initial prediction model may include a first hidden layer, a second hidden layer, and a third hidden layer. N may be greater than or equal to the number of input parameters in embodiments of the present application. The input parameters may include, for example, RSRP, MCS level, SNR, and/or other key metrics, etc.
Illustratively, a first neuron of the input layer is connected to a second neuron of the first hidden layer based on a weight a, and a first neuron of the input layer is connected to a third neuron of the first hidden layer based on a weight B. The first neuron is any neuron in the input layer, and the second neuron and the third neuron are any two neurons in the first hidden layer. The weight A is the connection weight between the first neuron and the second neuron, and the weight B is the connection weight between the first neuron and the third neuron.
Similar to the connection between the input layer and the first hidden layer, the second neuron of the first hidden layer is connected to the fourth neuron of the second hidden layer based on the weight C, and the second neuron of the first hidden layer is connected to the fifth neuron of the second hidden layer based on the weight D. Wherein the fourth neuron and the fifth neuron are any two neurons in the second hidden layer. The weight C is a connection weight between the second neuron and the fourth neuron, and the weight D is a connection weight between the second neuron and the fifth neuron.
Similar to the connection between the first hidden layer and the second hidden layer, the fourth neuron of the second hidden layer is connected to the sixth neuron of the third hidden layer based on the weight E, and the fourth neuron of the second hidden layer is connected to the seventh neuron of the third hidden layer based on the weight F. Wherein the sixth neuron and the seventh neuron are any two neurons in the third hidden layer. The weight E is the connection weight between the fourth neuron and the sixth neuron, and the weight F is the connection weight between the fourth neuron and the seventh neuron.
Each hidden layer is connected with the output layer. For example, the first hidden layer, the second hidden layer, and the third hidden layer are respectively connected to the output layer.
After the connection relationship between the input layer, the output layer, and the hidden layer in the architecture of the initial prediction model is introduced, the input layer, the output layer, and the hidden layer are described below.
Neurons of the input layer are configured to receive input data. Different neurons of the input layer receive different input data.
The neurons of the input layer are further configured to pass input data to each neuron of the first hidden layer based on the corresponding connection weights, respectively. For example, a first neuron of the input layer passes input data received by the first neuron to a second neuron of the first hidden layer based on weight a, and the first neuron of the input layer passes input data received by the first neuron to a third neuron of the first hidden layer based on weight B.
Neurons of the hidden layer compute neuron inputs based on the connection weights and activation functions, a process that may be referred to as a neuron transformation process.
The activation function may be a sigmoid function, a tanh function, relu, or the like. Illustratively, the sigmoid function may beOr (b)Etc. The activation functions of the different hidden layers may be different.
Where a is a weight coefficient, for example, the weight coefficient may be 1.
Exemplary, when the activation function isAnd a is 1, the graph of the activation function can be seen in fig. 8. Fig. 8 is a schematic diagram of an activation function according to an embodiment of the present application.
Exemplary, when the activation function isAnd a is 1, the graph of the activation function can be seen in fig. 9. Fig. 9 is a schematic diagram of a second activation function according to an embodiment of the present application.
The neuron input may be input data transferred by the input layer, or may be output by a neuron of a previous hidden layer. For example, the structure of any neuron of any hidden layer can be seen in fig. 10. Fig. 10 is a schematic diagram of a neuron structure according to an embodiment of the present application.
As shown in fig. 10, the neurons receive neuron inputs and weight-sum each of the neuron inputs based on their respective corresponding connection weights wi (i=1, 2. The neuron then compares the result of the weighted summation with a function threshold. When the result of the weighted summation is less than or equal to the activation function threshold, the neuron obtains a neuron output through the activation function.
Aiming at any hidden layer, the hidden layer obtains an output result of the hidden layer by carrying out aggregation treatment on the output of each neuron of the hidden layer.
Illustratively, the hidden layer may aggregate the individual neuron outputs of the hidden layer by a single matrix multiplication or multiple matrix multiplications.
The output result of each hidden layer is sent to the output layer, which can receive the output result of each hidden layer. Then, the output layer can operate the output result of each hidden layer to obtain the output result of the output layer. The output result of the output layer is the average value, root mean square value or weighted average value of the output result of each hidden layer.
Optionally, when the trained antenna prediction model is used for predicting an antenna number, the output layer of the initial prediction model may include a first storage module, a first calculation module, a first determination module, and a first output module. The first storage module can be used for storing antenna number prediction results output by all hidden layers in the training process, the first calculation module can be used for calculating an antenna switching threshold value according to the antenna number prediction results, the first judgment module can be used for comparing the antenna number prediction results output by all hidden layers with the antenna switching threshold value to obtain a first comparison result, and the first output module can be used for outputting antenna number prediction values according to the first comparison result. Wherein the antenna number may be used to identify different antennas. For example, the antenna number may be the number of the antenna. The antenna switching threshold value is the threshold value for switching the antenna number of the mobile phone.
After introducing the architecture of the initial predictive model, the first training data set and the manner in which the first training data set is obtained are described below.
As a possible implementation manner, the training device may train the initial prediction model using the first training data set, and after meeting the training end condition, the training device obtains the antenna prediction model.
In the embodiment of the application, the data acquisition equipment can acquire the first data and perform preprocessing in the process of using the mobile phone by a user or a developer to obtain the first training data set. The preprocessing may include missing value processing, outlier processing, data deduplication, and the like. The form of the data acquisition device may be similar to the training device described above and will not be described in detail herein.
It should be noted that, the first data may include parameters such as MCS level, SNR, antenna number and/or other key indicators in the uplink log file, and/or the first data may include parameters such as RSRP, MCS level, SNR, antenna number and/or other key indicators in the downlink log file.
Other key indexes may include, for example, BLER, PUCCH path loss, PUCCH TX power, RB num, CQI, RSSI, and/or the like.
And under the condition that the first data is a parameter acquired from the uplink log file, the data acquisition equipment pre-processes the first data to obtain a first training data set. The antenna prediction model obtained by training the initial prediction model by the subsequent training device through the first training data set can be used for predicting uplink MCS level, uplink SNR and/or other uplink key indexes.
And under the condition that the first data is a parameter acquired from the downlink log file, the data acquisition equipment pre-processes the first data to obtain a first training data set. The antenna prediction model obtained by training the initial prediction model by the subsequent training device through the first training data set can be used for predicting downlink RSRP, downlink MCS level, downlink SNR and/or other downlink key indexes and the like.
Under the condition that the first data comprises the parameters collected from the uplink log file and the parameters collected from the downlink log file, the data collecting equipment pre-processes the first data to obtain a first training data set. The antenna prediction model obtained by training the initial prediction model by the subsequent training device through the first training data set can be used for predicting uplink MCS (modulation and coding scheme) levels, uplink SNR (signal to noise ratio) and/or other uplink key indexes and the like, and can also be used for predicting downlink RSRP (reactive power reduction), downlink MCS levels, downlink SNR (signal to noise ratio) and/or other downlink key indexes and the like. The predicted value output by the antenna prediction model may carry uplink attribute information or downlink attribute information. For example, when the MCS level outputted by the antenna prediction model carries uplink attribute information, it indicates that the MCS level is an uplink MCS level.
For example, when the absolute value of the difference between the uplink MCS level predicted value output by the antenna prediction model and the corresponding uplink MCS level actual value is greater than or equal to a third preset threshold, the mobile phone may determine that antenna tuning is required for the uplink antenna.
Optionally, the preprocessing may further include performing a mean value processing on the first data within a preset period of time.
In an embodiment of the present application, the first training data set may include at least one first data sample (which may also be referred to as first training data). Each first data sample may include RSRP samples, MCS level samples, SNR samples, antenna number samples, and/or other key indicator samples corresponding to the same time period. The time periods corresponding to the different first data samples may be different.
Other key indicator samples may include, for example, a BLER sample, a PUCCH path loss sample, a PUCCH TX power sample, an RB num sample, a CQI sample, an RSSI sample, and/or the like.
The RSRP samples in any first data samples may be understood as data obtained by the training device performing mean value processing on RSRP in the time period T at the time of acquisition, the MCS level samples in the first data samples may be understood as data obtained by the training device performing mean value processing on MCS level in the time period T at the time of acquisition, the SNR samples in the first data samples may be understood as data obtained by the training device performing mean value processing on SNR in the time period T at the time of acquisition, and the antenna number samples in the first data samples may be understood as antenna numbers in the time period T at the time of acquisition.
The RSRP samples may be used to measure the strength of the signal received by the handset, the MCS level samples may be used to define the maximum data transmission rate of the handset, and the SNR samples are the ratio of the useful signal power to the noise power.
In the embodiment of the application, the first training data set considers the honeycomb index corresponding to each moment, and the sample number of the first training data set is reduced through mean value processing. Therefore, the training equipment can give consideration to model training efficiency and the trained antenna prediction model by training through the first training data set in the embodiment of the application, and has better model generalization capability.
In other possible implementations, each first data sample may also include RSRP samples, MCS level samples, SNR samples, and/or other key indicator samples corresponding to the same time instant. The times corresponding to the different first data samples may be different.
After the first training data set is introduced, a process of training the initial predictive model using the first training data set is described below.
In one possible implementation, the training of the initial prediction model by the training device may include training for any one of RSRP, MCS level, SNR, antenna number, or other key indicators, and the resulting antenna prediction model is used to predict any one of RSRP, MCS level, SNR, antenna number, or other key indicators.
It may be appreciated that when the antenna prediction model obtained by training is used to train the target parameter, the target parameter sample may be used as a tag of the first training data, and samples other than the target parameter sample in the first data sample may be used as features of the first training data. The target parameter may be any one of RSRP, MCS level, SNR, antenna number, or other key indicators.
The features of the first training data are used to input an initial predictive model during training. The labels of the first training data are used to calculate the loss function during the training process.
The training process is illustrated below with the training of the resulting antenna prediction model for predicting RSRP (i.e., with the target parameter RSRP as an example).
Fig. 11 is a schematic flow chart of a training process of an antenna prediction model according to an embodiment of the present application. As shown in fig. 11, the process may include steps S1101 to S1104.
S1101, the training device acquires a first training data set, wherein the first training data set can comprise characteristics of the first training data and labels of the first training data.
Wherein, the label of the first training data is an RSRP sample, and the characteristics of the first training data may include at least one of an MCS level sample, an SNR sample and other key index samples, or the characteristics of the first training data may include an antenna number sample.
It will be appreciated that the training device may train the initial predictive model using all of the first training data comprised by the first training data set, or the training device may train the initial predictive model using part of the first training data comprised by the first training data set.
S1102, the training device inputs the features of the first training data into an initial prediction model to obtain an initial training result.
For example, the initial training results may include a first initial training result, a second initial training result, and a third initial training result. The first initial training result is an output result of the first hidden layer, the second initial training result is an output result of the second hidden layer, and the third initial training result is an output result of the third hidden layer. The first initial training result, the second initial training result, and the third initial training result may each include at least one RSRP prediction result, at least one MCS level prediction result, at least one SNR prediction result, at least one antenna number prediction result, and/or at least one other key indicator prediction result. In the first initial training result, the second initial training result, or the third initial training result, the number of RSRP predictors, the number of MCS level predictors, the number of SNR predictors, the number of antenna number predictors, or the number of other key index predictors may be the same as the number of sets of features of the first training data, where a set of features of the first training data corresponds to one first data sample.
The first initial training result may be understood as a result of aggregation of the neuron outputs of the neurons in the first hidden layer. The aggregation of the neuron outputs may be performed, for example, by a training device that performs a single matrix multiplication or multiple matrix multiplications on the neuron outputs. The input of each neuron in the first hidden layer is characteristic of the first training data communicated by each neuron of the input layer.
The second initial training result may be understood as a result of the aggregation of the neuron outputs of the neurons in the second hidden layer. The input of each neuron in the second hidden layer is the neuron output of each neuron in the first hidden layer. See, for example, the description of the corresponding embodiment of fig. 7, which is not repeated here.
Similarly, the third initial training result may be understood as a result of the aggregated processing of the neuron outputs of the neurons in the third hidden layer. The input of each neuron in the third hidden layer is the neuron output of each neuron in the second hidden layer. See, for example, the description of the corresponding embodiment of fig. 7, which is not repeated here.
It will be appreciated that each hidden layer corresponds to an initial training result. The embodiment of the application is exemplified by taking the hidden layer as 3 layers, so that the initial training results are 3. The embodiment of the application does not limit the number of layers of the hidden layer and the embodiment of the application does not limit the number of initial training results.
S1103, the training device calculates a predicted loss function (may also be referred to as a first loss function) according to the first initial training result, the second initial training result, the third initial training result, and the label of the first training data.
In a possible implementation, the predicted loss functions may include a first predicted loss function, a second predicted loss function, and a third predicted loss function. The first prediction loss function may be a sum of first target difference values, where the first target difference value is a difference value between any one RSRP prediction result in the first initial training result and an RSRP sample in the corresponding first data sample. The second predictive loss function may be a sum of second target differences, the second target differences being differences between any one of the RSRP predictions in the second initial training results and the RSRP samples in the corresponding first data samples. The third predictive loss function may be a sum of third target differences, the third target differences being differences between any one of the RSRP predictions in the third initial training results and the RSRP samples in the corresponding first data samples.
Illustratively, the correspondence between the RSRP sample in the first data sample, the RSRP predicted result in the first initial training result, the RSRP predicted result in the second initial training result, the RSRP predicted result in the third initial training result, and the target error may be as shown in table 1. The target error is the average value of the first target difference value, the second target difference value and the third target difference value corresponding to the same time period.
TABLE 1
Illustratively, each target difference may be represented by an ERROR matrix ERROR:
error=err ij,i=1,2,……T,j=1,2,……M.errij is the target difference value of the jth layer hidden layer corresponding to the ith time period after the time period is ordered from the morning to the evening. At this time, the first predictive loss function may be expressed as loss1=err 11+err21+……+errT1, for example. The second predictive loss function may be expressed, for example, as los2=err 12+err22+……+errT2. The third predictive loss function may be expressed, for example, as los3=err 13+err23+……+errT3.
S1104, the training equipment iterates model parameters of the initial prediction model based on the prediction loss function until the prediction loss function converges, and an antenna prediction model is obtained.
The predicted loss function convergence may be that the first predicted loss function is less than or equal to a first preset value, the second predicted loss function is less than or equal to a second preset value, and the third predicted loss function is less than or equal to a third preset value. The first preset value, the second preset value and the third preset value may be set according to an actual scene, which is not limited in the embodiment of the present application.
In other possible implementations, step S1104 may be replaced by the training device iterating model parameters of the initial predictive model based on the predictive loss function, and obtaining the antenna predictive model when the training duration reaches the first preset duration without convergence of the predictive loss function.
The first preset duration may be set according to an actual scene, and the embodiment of the present application does not specifically limit the first preset duration.
In yet another possible implementation, step S1104 may be replaced by the training device iterating model parameters of the initial predictive model based on the predictive loss function, and obtaining the antenna predictive model when the number of iterations reaches a first preset number of times without convergence of the predictive loss function.
The first preset times can be set according to an actual scene, and the embodiment of the application does not specifically limit the first preset times.
In the embodiment of the application, in the process of training the initial prediction model to obtain the antenna prediction model, the training equipment considers the output results of each hidden layer, and avoids abnormal output results in extreme scenes. Therefore, compared with the method that only the output result of the last hidden layer (i.e. the hidden layer connected with the output layer) is considered, the prediction accuracy of the antenna prediction model obtained by training the output result of each hidden layer is considered in the embodiment of the application to be higher.
In yet another possible implementation, the training of the initial predictive model by the training device may include the training device training for any two or more of RSRP, MCS level, SNR, and other key metrics, respectively, in a sequential order.
For example, the training process of the initial prediction model will be described taking the training device training for RSRP, MCS level and SNR in order, and taking the antenna prediction model for predicting RSRP, MCS level and SNR as an example. For example, referring to fig. 12, fig. 12 is a second flow chart of a training process of an antenna prediction model according to an embodiment of the present application.
S1201, the training device obtains a first training data set, where the first training data set may include features of the first training data and a label of the first training data. The training device takes the RSRP sample as a label of the first training data, and takes samples except the RSRP sample in the first data sample as features of the first training data.
S1202, the training equipment inputs the features of the first training data into an initial prediction model to obtain an initial training result aiming at the RSRP sample.
The initial training result for the RSRP sample may be understood as an initial training result obtained after the training device inputs the features of the first training data into the initial prediction model when the training device uses the RSRP sample as a tag of the first training data and uses samples other than the RSRP sample in the first data sample as features of the first training data.
This step is similar to or the same as step S1102 described above, and will not be described here again. It is to be appreciated that initial training results for RSRP samples can include RSRP predictors, MCS level predictors, SNR predictors, antenna number predictors, and/or other index predictors.
S1203, the training device calculates an RSRP-predictive loss function according to the first initial training result, the second initial training result, the third initial training result and the label of the first training data.
The RSRP-predictive loss function may be a predictive loss function calculated by using RSRP samples as labels of the first training data. The calculation process of the RSRP-prediction loss function may be referred to the description of step S1103, and will not be repeated here.
And S1204, the training equipment iterates the model parameters of the initial prediction model based on the RSRP-prediction loss function until the RSRP-prediction loss function converges, and the initial prediction model after the RSRP-prediction loss function converges is obtained.
Wherein the RSRP-predictive loss function convergence may be that the first predictive loss function for RSRP samples is less than or equal to a first preset value for RSRP samples, the second predictive loss function for RSRP samples is less than or equal to a second preset value for RSRP samples, and the third predictive loss function for RSRP samples is less than or equal to a third preset value for RSRP samples. The first preset value for the RSRP sample, the second preset value for the RSRP sample, and the third preset value for the RSRP sample may be set according to actual scenes, which is not limited in the embodiment of the present application.
S1205, the training device takes the MCS level sample in the first training data set as a label of the first training data, and the training device takes samples except the MCS level sample in the first data sample as features of the first training data.
S1206, the training equipment inputs the characteristics of the first training data into an initial prediction model after the RSRP-prediction loss function is converged, and an initial training result aiming at the MCS level sample is obtained.
This step is similar to or the same as step S1102 described above, and will not be described here again.
It is to be appreciated that the initial training results for the MCS level samples can include RSRP predictors, MCS level predictors, SNR predictors, antenna number predictors, and/or other index predictors.
S1207, the training device calculates an MCS level-predictive loss function according to the first initial training result, the second initial training result, the third initial training result and the label of the first training data.
The MCS level-prediction loss function may be a prediction loss function calculated by using an MCS level sample as a tag of the first training data. The calculation process of the MCS level-prediction loss function is similar to the above step S1103, and will not be repeated here.
S1208, the training equipment iterates model parameters of the initial prediction model after the RSRP-prediction loss function is converged based on the MCS level-prediction loss function until the MCS level-prediction loss function is converged, and the initial prediction model after the MCS level-prediction loss function is converged is obtained.
S1209, the training device uses SNR samples in the first training data set as labels of the first training data, and the training device uses samples other than the SNR samples in the first data samples as features of the first training data.
S1210, the training device inputs the features of the first training data into an initial prediction model after convergence of the MCS level-prediction loss function, and an initial training result for the SNR sample is obtained.
This step is similar to or the same as step S1102 described above, and will not be described here again.
It is to be appreciated that initial training results for SNR samples can include RSRP predictors, MCS level predictors, SNR predictors, antenna number predictors, and/or other index predictors.
S1211, the training device calculates an SNR-prediction loss function according to the first initial training result, the second initial training result, the third initial training result and the label of the first training data.
The SNR-prediction loss function may be a prediction loss function calculated by using SNR samples as labels of the first training data. The SNR-prediction loss function calculation process is similar to the above step S1103, and will not be repeated here.
S1212, the training equipment iterates the model parameters of the initial prediction model after the MCS level-prediction loss function is converged based on the SNR-prediction loss function until the SNR-prediction loss function is converged, and an antenna prediction model is obtained.
It is to be appreciated that the above-described process of training sequentially for RSRP, MCS level and SNR is merely an exemplary illustration. The embodiment of the application does not specifically limit the training sequence aiming at RSRP, MCS level and SNR.
In yet another possible embodiment, to further reduce the data volume of the first training data set, the training of the initial predictive model by the training device may include that the training device may train against the joint index.
The joint index may be a value of a relational expression composed of any two indexes or a value of a relational expression composed of two or more indexes. For example, the joint index may be a value of a relational expression formed by two or more indices of RSRP, MCS level, SNR, BLER, PUCCH path loss, PUCCH TX power, RB num, CQI, RSSI, and the like. The value of the relation may be, for example, a weighted sum value or a product, etc.
Illustratively, the joint index is a weighted sum of RSRP and SNR. The joint index may be expressed as ob=α×rsrp+β×snr. Where OB represents a joint index, α represents a preset weight of RSRP, and β represents a preset weight of SNR.
When the joint index is represented by ob=α×rsrp+β×snr, the training process of the training device for training the joint index is similar to steps S1101 to S1104 described above. The difference is that the joint index sample is used as a label of the first training data. The joint index samples may be expressed as OB Sample of = a RSRP samples + β SNR samples. And in the process that the training device trains aiming at the joint indexes, the training device can obtain a predicted result OB Output of corresponding to the joint indexes in the time period. And, the training device may calculate a target difference value corresponding to the time period according to OB Output of and OB Sample of of the time period.
Optionally, after obtaining the predicted result OB Output of , the training device may further calculate OB Output of by using a least square method to obtain an RSRP predicted result and an SNR predicted result.
After the training device trains the initial predictive model to obtain the antenna predictive model, the antenna predictive model may be deployed onto a cell phone. In the process of using the mobile phone by a user, the mobile phone can input at least one of parameters such as the acquired RSRP, the MCS level, the SNR, other key indexes and the like into the antenna prediction model, or the mobile phone can also output the acquired antenna number into the antenna prediction model to obtain an RSRP predicted value, an MCS level predicted value, an SNR predicted value and/or other index predicted values output by the antenna prediction model.
As a possible implementation manner, after the antenna prediction model is deployed in the mobile phone, the mobile phone may update the antenna prediction model while in an idle state.
For example, during the process of using the mobile phone (such as the mobile phone is used by the user to make a call, play a game, watch a video, etc.), that is, in a case that the mobile phone is in a non-idle state, the mobile phone may record multiple sets of first actual data (which may also be referred to as a first running cellular index) of the antenna during the process of using the mobile phone by the user, where each set of first actual data may include at least one of an RSRP actual value, an MCS level actual value, an SNR actual value, and other key index actual values, or each set of first actual data may further include an antenna number actual value. The different sets of first actual data correspond to different time periods or different moments in time. And the mobile phone can also record the prediction data respectively output by the antenna prediction model for each group of first actual data, wherein the prediction data can comprise an RSRP prediction value, an MCS level prediction value, an SNR prediction value, an antenna number prediction value, other key index prediction values and the like.
Then, the mobile phone can perform screening pretreatment on the latest multiple groups of first actual data to obtain multiple groups of first actual data after the screening pretreatment. Then, the mobile phone can obtain a new first training data set according to the multiple groups of first actual data after screening pretreatment and the first data samples in the first training data set when the initial prediction model is trained.
The screening preprocessing can include removing abnormal first actual data, wherein the abnormal first actual data meets the conditions that the first actual data includes a first operation index and a second operation index, and the absolute value of a difference value between the second operation index and the third operation index is larger than or equal to a preset threshold value. The third operation index is obtained according to the first operation index or the first actual data in a prediction mode, and the type of the third operation index is the same as the type of the second operation index. For example, an absolute value of a difference between the RSRP actual value and the RSRP predicted value in the corresponding predicted data is greater than or equal to a first preset threshold, an absolute value of a difference between the SNR actual value and the SNR predicted value in the corresponding predicted data is greater than or equal to a second preset threshold, or an absolute value of a difference between the MCS level actual value and the MCS level predicted value in the corresponding predicted data is greater than or equal to a third preset threshold.
That is, the mobile phone obtains the first actual data when the absolute value of the difference between the second operation index and the third operation index is smaller than the preset threshold. And then, the mobile phone obtains a new first training data set according to the first actual data when the absolute value of the difference between the second operation index and the third operation index is smaller than a preset threshold value and the first data sample in the first training data set when the initial prediction model is trained.
In a possible implementation, the mobile phone may be abnormal data due to some external reason (for example, the mobile phone is soaked with water) and the multiple sets of first actual data collected in a period of time. To alleviate such abnormal scenarios, the new first training data set may include screening the data samples corresponding to the preprocessed sets of first actual data, and the first data samples in the first training data set when training the initial predictive model. Moreover, the ratio of the number of the first data samples to the number of samples in the new first training data set is a preset ratio. The preset ratio may be set according to an actual scene, which is not particularly limited in the embodiment of the present application. Illustratively, the preset ratio may be 10%.
And then, under the condition that the mobile phone is in an idle state, the mobile phone can train the antenna prediction model on a new first training data set so as to obtain an updated antenna prediction model. The new first training data set is obtained by preprocessing data acquired based on the use habit of the user and the communication environment in which the mobile phone is located by the mobile phone. Therefore, with the increase of the updating times, the updated antenna prediction model is more suitable for the use habit of the user and the communication environment of the mobile phone. Therefore, the prediction accuracy of the updated antenna prediction model is higher, and the communication quality of the electronic equipment can be further improved.
The process of training the antenna prediction model by the mobile phone on the new first training data set is similar to or the same as the process of training the initial prediction model by the training device, and will not be described herein.
The mobile phone being in the idle state may be understood as that the utilization rate of a central processing unit (central processing unit, CPU) of the mobile phone is lower than a preset first utilization rate, the utilization rate of a memory of the mobile phone is lower than a preset second utilization rate, the network flow of the mobile phone is lower than a preset value, the number of network connections of the mobile phone is smaller than a preset number, and/or the mobile phone enters a low power consumption mode or a standby mode. The preset first utilization rate, the preset second utilization rate, the preset numerical value and the preset number can be determined according to an actual scene, and the embodiment of the application is not particularly limited.
As a possible implementation manner, the preset threshold value in the embodiment of the present application may be obtained by training in the process that the training device trains the initial prediction model to obtain the antenna prediction model.
In a possible implementation, when the trained antenna prediction model is used to predict RSRP, MCS level, SNR and/or other key indicators, the first storage module in the output layer may be further configured to store a predicted value corresponding to each first data sample during each iteration during training of the initial prediction model by the training device. After the prediction loss function converges, the first calculation module may be further configured to calculate an average value of differences between the labels of the first training data and the predicted values corresponding to the first data samples in the last iteration, where the average value of the differences may be a preset threshold in the embodiment of the present application.
The predicted value corresponding to the first data sample may be an average value of a predicted result of the first hidden layer for the feature of the first training data, a predicted result of the second hidden layer for the feature of the first training data, and a predicted result of the third hidden layer for the feature of the first training data.
When the trained antenna prediction model is used for predicting RSRP, the first calculation module may be further configured to calculate, after the prediction loss function converges, an average value of differences between each RSRP sample and the RSRP predicted value corresponding to each RSRP sample at the last iteration, where the average value of differences may be a first preset threshold in the embodiment of the present application.
It can be appreciated that, in the process of updating the antenna prediction model by the mobile phone, the preset threshold value can be updated synchronously. The updating process is similar to the process of obtaining the preset threshold value through training by the training device, and will not be described herein.
After the antenna prediction model is obtained through training, the mobile phone can use the antenna prediction model to predict parameters such as RSRP, MCS level, SNR and/or other key indexes. The mobile phone can then determine whether the antenna state is abnormal by using parameters such as the predicted RSRP, MCS level, SNR and/or other key indexes, and parameters such as the RSRP, MCS level, SNR and/or other key indexes actually collected by the mobile phone.
Next, an antenna adjustment method provided by an embodiment of the present application will be described with reference to the accompanying drawings.
As one possible implementation, the handset may determine whether the antenna state is abnormal through RSRP, MCS level, SNR, or any other key indicator.
Next, an example will be described in which the mobile phone determines whether the antenna state is abnormal by RSRP.
Fig. 13 is a schematic flow chart of an antenna adjustment method according to an embodiment of the present application. As shown in fig. 13, the method may include steps S1301-S1304.
S1301. the acquisition unit acquires a first index (which may also be referred to as a first cellular index).
The first indicator may include an MCS level actual value, an SNR actual value, an RSRP actual value, and/or other key indicator actual values. Or the first index may also include an actual value of the antenna number.
The other key indicator actual values may include, for example, a BLER actual value, a PUCCH path loss actual value, a PUCCH TX power actual value, an RB num actual value, a CQI actual value, and/or an RSSI actual value.
In a possible implementation, the mobile phone may obtain, from the MAC layer and/or the physical layer, an actual MCS level value, an actual SNR value, an actual RSRP value, and/or an actual other key indicator value, which are up to date in the time dimension, through an acquisition unit in the modem processor, where the first indicator includes the actual MCS level value, the actual SNR value, the actual RSRP value, and/or the actual other key indicator value, which are up to date in the time dimension.
S1302. the processing unit predicts a second indicator (which may also be referred to as a second cellular indicator).
The second index may include an MCS level predictor, an SNR predictor, an RSRP predictor, and/or other key index predictors.
It is understood that, in order to improve the prediction accuracy, the number of kinds of indexes in the first index may be larger than the number of kinds of indexes in the second index. For example, the first index includes at least two indices (for example, MCS level predictor and SNR predictor, or MCS level predictor and RSRP predictor, or SNR predictor and BLER predictor, etc.) when the second index is RSRP predictor, and at least three indices when the second index is RSRP predictor and SNR predictor.
As a possible implementation, the processing unit may invoke the antenna prediction model to predict the second indicator. For example, the processing unit inputs the first index into the antenna prediction model, and acquires the second index output by the antenna prediction model.
S1303, the processing unit determines whether the antenna state is normal.
As a possible implementation manner, the processing unit may determine whether the antenna state is normal based on the target value (may also be referred to as a third cellular index) corresponding to the second index. For example, the processing unit determines that the antenna state is abnormal in the case where the absolute value of the difference between the second index and the target value corresponding to the second index is greater than or equal to a preset threshold value, and determines that the antenna state is normal in the case where the absolute value of the difference between the second index and the target value corresponding to the second index is less than the preset threshold value.
The target value corresponding to the second index may be understood as a target cellular index whose acquisition time is closest to the predicted time of the second index, or the target value corresponding to the second index may be understood as a target cellular index whose acquisition time is before and closest to the predicted time of the second index. Wherein the target cellular indicator is of the same type as the second indicator, e.g. in case the second indicator is an RSRP predicted value, the target cellular indicator is an RSRP actual value. The predicted time of the second index may be understood as the time when the processing unit calls the antenna prediction model to predict the second index.
In the embodiment of the application, the acquisition time is understood to be the time when the acquisition unit acquires the first index, and the time when the acquisition unit acquires the first index is very close to the time when the mobile phone actually measures the first index. For example, the acquisition unit acquires the actual RSRP value of the antenna at time T2 at time T1. The time T1 is the acquisition time, and the time T1 is very close to the time T2, which can be understood as the same time T1 as the time T2.
In the embodiment of the application, the prediction time of the second index is later than the acquisition time of the first index based on the time consumed in the calculation process of the antenna prediction model.
Taking the example that the second index is an RSRP predicted value and the second index is predicted by the processing unit based on the MCS level actual value and the SNR actual value at the time t2, the timing relationship between the acquisition time of the first index, the acquisition time of the target value corresponding to the second index, and the predicted time of the second index is described in conjunction with fig. 14. Fig. 14 is a timing diagram according to an embodiment of the present application.
As shown in the time axis a of fig. 14, the acquisition time of the target value corresponding to the second index and the acquisition time of the first index correspond to the acquisition time axis, and the prediction time of the second index corresponds to the calculation time axis. The processing unit can input a first index at the time t1 into the antenna prediction model to obtain a second index at the time t1', can input a first index at the time t2 into the antenna prediction model to obtain a second index at the time t2', and can input a first index at the time t3 into the antenna prediction model to obtain a second index at the time t3 '. Wherein, the time t1 is earlier than the time t2, the time t2 is earlier than the time t3, the time t1' is later than the time t1 and earlier than or equal to the time t2, the time t2' is later than the time t2 and earlier than or equal to the time t3, and the time t3' is later than the time t 3. In an actual scenario, the time difference between the time t1 and the time t1' may be close to 0.
Taking a second index at the time t2' as an RSRP predicted value, the second index is obtained by predicting an MCS level actual value and an SNR actual value at the time t2 by using the processing unit as an example, and the target value corresponding to the second index is the target cellular index whose acquisition time is closest to the predicted time of the second index.
With continued reference to the time axis a shown in fig. 14, the acquisition unit acquires the MCS level actual value and the SNR actual value at time t 2. The acquisition unit does not acquire the actual value of RSRP at the time t2, but acquires the actual value of RSRP at both the time t1 and the time t 3. When the time difference Δt1 between the time t2 'and the time t1 is smaller than or equal to the time difference Δt2 between the time t3 and the time t2', the target value corresponding to the second index is the RSRP actual value acquired by the acquisition unit at the time t 1. As shown in a time axis B of fig. 14, the acquisition unit acquires an MCS level actual value and an SNR actual value at time t 2. The acquisition unit does not acquire the actual value of RSRP at the time t2, but acquires the actual value of RSRP at both the time t1 and the time t 3. When the time difference Δt1 between the time t2 'and the time t1 is greater than the time difference Δt2 between the time t3 and the time t2', the target value corresponding to the second index is the RSRP actual value acquired by the acquisition unit at the time t 3.
As shown in the time axis C of fig. 14, the acquisition unit acquires the RSRP actual value, the MCS level actual value, and the SNR actual value at time t 2. When the time difference Δt3 between the time t2 'and the time t2 is smaller than or equal to the time difference Δt4 between the time t3 and the time t2', the target value corresponding to the second index is the RSRP actual value acquired by the acquisition unit at the time t 2.
As shown in the time axis D of fig. 14, the acquisition unit acquires the RSRP actual value, the MCS level actual value, and the SNR actual value at time t2, and the acquisition unit also acquires the RSRP actual value at time t 3. When the time difference Δt3 between the time t2 'and the time t2 is greater than the time difference Δt4 between the time t3 and the time t2', the target value corresponding to the second index is the RSRP actual value acquired by the acquisition unit at the time t 3.
Or in order to determine whether the antenna state is abnormal as early as possible, the target value corresponding to the second index may be a target cellular index whose acquisition time is before and closest to the predicted time of the second index.
Illustratively, as shown in a time axis E of fig. 14, the acquisition unit acquires an MCS level actual value and an SNR actual value at time t 2. The acquisition unit does not acquire the actual value of RSRP at time t2, but acquires the actual value of RSRP at time t 1. Since the time t1 is before the time t2' and the acquisition unit does not acquire the RSRP actual value at the time t2 and the RSRP actual value is acquired at the time t1, the target value corresponding to the second index is the RSRP actual value acquired by the acquisition unit at the time t1 no matter whether the time difference Δt1 between the time t2' and the time t1 is greater than the time difference Δt2 between the time t3 and the time t2 '. Therefore, the mobile phone can judge whether the absolute value of the difference value between the second index and the actual value corresponding to the second index is larger than the preset threshold value at the time t2', and the mobile phone does not need to wait for the time t3, so that whether the antenna state is abnormal or not can be determined as early as possible.
It will be appreciated that, with continued reference to the time axis E shown in fig. 14, when the acquisition unit acquires the actual RSRP value at the time t ' between the time t1 and the time t2, and no actual RSRP value is acquired between the time t ' and the time t2' and at the time t2', the target value corresponding to the second index is the actual RSRP value acquired at the time t '.
As shown in a time axis F of fig. 14, the acquisition unit acquires an RSRP actual value, an MCS level actual value, and an SNR actual value at time t 2. Since the time t2 is before the time t2' and the acquisition unit acquires the actual RSRP value at the time t2, the target value corresponding to the second index is the actual RSRP value acquired by the acquisition unit at the time t2 no matter whether the time difference Δt3 between the time t2' and the time t2 is greater than the time difference Δt4 between the time t3 and the time t2 '. Therefore, the mobile phone can judge whether the absolute value of the difference value between the second index and the actual value corresponding to the second index is larger than the preset threshold value at the time t2', and the mobile phone does not need to wait for the time t3, so that whether the antenna state is abnormal or not can be determined as early as possible.
It will be appreciated that, with continued reference to the time axis F shown in fig. 14, when the acquisition unit acquires the actual RSRP value at time t″ between time t2 and time t2', and no actual RSRP value is acquired between time t″ and time t2' and at time t2', the target value corresponding to the second index is the actual RSRP value acquired at time t″.
Or when the acquisition unit acquires the RSRP actual value at the time t2', the target value corresponding to the second index is the RSRP actual value acquired at the time t 2'.
In a possible implementation, the processing unit performs a weighted summation operation on the two or more indexes included in the second index to obtain a first weighted summation operation result. And the processing unit further performs weighted summation operation on the target value corresponding to the second index to obtain a second weighted summation operation result. Then, the processing unit calculates an absolute value of a difference between the first weighted sum operation result and the second weighted sum operation result. When the absolute value of the difference value is larger than or equal to a preset target threshold value, the mobile phone determines that the antenna state is abnormal.
For example, the second index includes an RSRP predicted value and an SNR predicted value. And the processing unit performs weighted summation operation on the RSRP predicted value and the SNR predicted value to obtain a first weighted summation operation result. And the processing unit further performs weighted summation operation on the target value corresponding to the second index to obtain a second weighted summation operation result. Then, the processing unit calculates an absolute value of a difference between the first weighted sum operation result and the second weighted sum operation result. When the absolute value of the difference value is larger than or equal to a preset target threshold value, the mobile phone determines that the antenna state is abnormal.
In a case where the second index includes two or more indexes, in another possible implementation, the processing unit calculates, for any one of the two or more indexes, an absolute value of a difference between the index and a target value corresponding to the index among target values corresponding to the second index. And under the condition that the absolute values calculated for the indexes in the second indexes are larger than the preset threshold corresponding to the indexes, the mobile phone determines that the antenna state is abnormal.
For example, the second index includes an RSRP predicted value and an SNR predicted value. The processing unit calculates an absolute value of a difference between the RSRP predicted value and the RSRP actual value in the target value corresponding to the second index, and calculates an absolute value of a difference between the SNR predicted value and the SNR actual value in the target value corresponding to the second index. And under the condition that the absolute value of the difference value between the RSRP predicted value and the RSRP actual value in the target value corresponding to the second index is larger than or equal to a first preset threshold value and the absolute value of the difference value between the SNR predicted value and the SNR actual value in the target value corresponding to the second index is larger than or equal to a second preset threshold value, the mobile phone determines that the antenna state is abnormal.
In the embodiment of the application, whether antenna tuning is needed or not is determined through the combination of at least two cellular indexes. In an actual scenario, when the antenna of the mobile phone is subject to instantaneous interference, but not the antenna state of the mobile phone is abnormal, a certain cellular index may be abnormal at the moment when the antenna of the mobile phone is subject to instantaneous interference, but in general, various cellular indexes are not abnormal. Thus, the accuracy of determining whether antenna tuning is needed is higher by a combination of at least two cellular indicators than by a single cellular indicator.
In the case where the processing unit determines that the antenna state is abnormal, the mobile phone performs step S1304.
That is, in the case where the absolute value of the difference between the second index and the target value corresponding to the second index is greater than or equal to the preset threshold, the mobile phone performs step S1304.
And S1304, adjusting the antenna by an adjusting unit.
In a possible implementation, the adjusting unit may adjust the antenna by tuning the antenna being used by the electronic device and/or switching the antenna being used by the electronic device.
As a possible implementation, the tuning of the antenna by the adjustment unit may be understood as the adjustment unit modifying the value of the usage status parameter to the target antenna status number. The usage status parameter may be used to indicate a current status of an antenna used by the mobile phone.
The target antenna state number is an antenna state number corresponding to a target value corresponding to the second index. The target antenna state number is the antenna state number corresponding to the target value corresponding to the second indicator, which can be understood that the target value corresponding to the second indicator is abnormal, that is, the antenna state is abnormal at the time of collecting the target value corresponding to the second indicator, and the current state of the antenna needs to be switched to the normal antenna state by the adjusting unit, and the antenna state number corresponding to the normal antenna state is the target antenna state number.
In the embodiment of the application, different antenna state numbers correspond to different control strategies, and the control strategies are used for indicating the electronic equipment to switch the antenna state of the used antenna to the antenna state corresponding to the value of the use state parameter and/or switch the used antenna to the antenna corresponding to the value of the use antenna parameter. The electronic device may then perform switching of antenna states and/or antenna switching based on the control strategy.
Wherein the antenna status number may be used to identify different antenna statuses and/or to indicate the antenna number. The same antenna may be provided with multiple antenna states. The embodiment of the application does not limit the expression form of the antenna state number in detail, so long as different antenna states can be distinguished.
As a possible implementation, the adjustment unit may invoke the antenna tuning model to predict the target antenna state number. For example, the adjusting unit inputs the actual value corresponding to the second index, the acquired latest antenna impedance actual value, other key index actual values and other parameters into the antenna tuning model, and obtains the target antenna state number output by the antenna tuning model.
In the embodiment of the application, the mobile phone can perform antenna adjustment when the absolute value of the difference between the second index and the target value corresponding to the second index is greater than or equal to the first preset threshold. That is, the mobile phone can perform antenna adjustment under the condition that the antenna state is abnormal, thereby relieving the hysteresis of the antenna adjustment in the related art, and further reducing the communication time of the mobile phone through the antenna under the abnormal antenna state. Because the communication quality of the mobile phone is poor in the abnormal antenna state, the time for the mobile phone to communicate through the antenna in the abnormal antenna state is reduced, and the overall communication quality of the mobile phone can be improved.
The procedure of separately determining whether to perform antenna switching by the mobile phone will be described.
In an actual scene, a plurality of antennas are often arranged in the mobile phone, so that the mobile phone can switch the antennas in order to improve the communication quality of the mobile phone, and an antenna with a better antenna state in the plurality of antennas is used.
As a possible implementation manner, the mobile phone may input the RSRP actual value, the MCS level actual value, the SNR actual value, and/or other key index actual values into the antenna prediction model, or the mobile phone may also input the antenna number actual value into the antenna prediction model. The handset may then determine whether to perform an antenna switch based on the antenna number prediction value output by the antenna prediction model. The antenna prediction model may be obtained by taking an antenna number sample as a tag of the first training data and taking samples such as an RSRP sample, an MCS level sample, an SNR sample and/or other key index samples as features of the first training data.
As a possible implementation manner, the mobile phone may predict the second index, where the second index is an antenna number predicted value, and if the second index does not coincide with the target value corresponding to the second index, the mobile phone performs antenna switching.
Fig. 15 is a schematic flow chart of a method for adjusting an antenna according to an embodiment of the present application. As shown in fig. 15, the method may include steps S1501 to S1504.
S1501, acquiring a first index by an acquisition unit.
This step is similar to or the same as step S1301 described above, and will not be described here again.
S1502, the processing unit obtains an antenna number predicted value.
As a possible implementation manner, the processing unit inputs the first index into the antenna prediction model to obtain the antenna number predicted value output by the antenna prediction model.
S1503, the processing unit determines whether to switch the antenna according to the antenna number predicted value and the antenna number target actual value.
The antenna number target actual value may be understood as an antenna number actual value whose acquisition time is closest to the predicted time of the antenna number predicted value, or the antenna number target actual value may be understood as an antenna number actual value whose acquisition time is not closest to the predicted time of the antenna number predicted value but is before the predicted time of the antenna number predicted value. The predicted time of the antenna number predicted value may be understood as the time when the antenna number predicted value is predicted by the processing unit calling the antenna prediction model.
In the embodiment of the application, the trained first calculation module in the antenna prediction model comprises a plurality of trained antenna switching threshold values. The method comprises the steps of obtaining a first comparison result, wherein the first comparison result is an antenna number which is smaller than the antenna switching threshold and closest to the antenna switching threshold and is output by a trained first output module in an antenna prediction model when the average value of antenna number prediction results output by hidden layers in the antenna prediction model is smaller than or equal to the antenna switching threshold or when the antenna number prediction results output by the hidden layers are smaller than or equal to the antenna switching threshold, and the first comparison result is an antenna number which is smaller than the antenna switching threshold and closest to the antenna switching threshold and is output by a trained first output module in the antenna prediction model when the average value of antenna number prediction results output by the hidden layers in the antenna prediction model is larger than the antenna switching threshold or when the antenna number prediction results output by the hidden layers are larger than the antenna switching threshold.
Fig. 16 is a schematic diagram illustrating a relationship between an antenna switching threshold and an antenna number according to an embodiment of the present application. As shown in fig. 16, when k antennas are included in the mobile phone, k-1 antenna switching threshold values may be included in the first calculation module in the output layer of the antenna prediction model. For example, the antenna numbers of the k antennas may be 1,2,3, k-1, k, respectively. The antenna switching threshold between antenna number 1 and antenna number 2 may be referred to as a first antenna switching threshold, the antenna switching threshold between antenna number 2 and antenna number 3 may be referred to as a second antenna switching threshold, and the antenna switching threshold between antenna number k-1 and antenna number k may be referred to as a k-1 th antenna switching threshold.
For example, when the average value of the antenna number prediction results output by each hidden layer is smaller than or equal to the second antenna switching threshold value and larger than the first antenna switching threshold value, the antenna number prediction value output by the first output module in the output layer of the antenna prediction model may be 2, and when the average value of the antenna number prediction results output by each hidden layer is smaller than or equal to the first antenna switching threshold value, the antenna number prediction value output by the first output module in the output layer of the antenna prediction model may be 1.
When the antenna number predicted value output by the antenna prediction model is different from the antenna number target actual value, the mobile phone executes step S1504.
S1504, the adjusting unit performs antenna switching.
In a possible implementation, the adjusting unit modifies the value of the antenna parameter used by the mobile phone (may also be referred to as a second preset parameter) to an antenna number predicted value, so that the adjusting unit switches the antenna currently used by the mobile phone to an antenna corresponding to the antenna number predicted value. The antenna parameter is used for indicating the antenna number of the antenna currently used by the mobile phone.
For example, before the antenna is switched, the value of the antenna parameter is 1, which indicates that the mobile phone currently uses the antenna corresponding to the antenna number 1. In case the antenna number prediction value is 2, the adjustment unit modifies the value of the used antenna parameter to 2. Then, the adjusting unit can switch the antenna currently used by the mobile phone to the antenna corresponding to the antenna number 2.
In the embodiment of the application, the mobile phone can predict the antenna with the optimal state in the plurality of antennas through the antenna prediction model. Therefore, the mobile phone can timely use the antenna with the optimal state for communication, so that the time of the antenna with the poor use state of the mobile phone is reduced, and the overall communication quality of the mobile phone is improved.
After the use of the antenna switching threshold is described, the process of obtaining the antenna switching threshold by the training device or the mobile phone is described below.
In one possible implementation, the first storage module of the output layer in the initial prediction model may store the antenna number prediction result output by each hidden layer at each iteration. After the prediction loss function converges, the first calculation module can perform clustering processing on the antenna number prediction results output by each hidden layer in the last iteration to obtain a plurality of sets. Different sets correspond to different antenna numbers, and antenna number prediction results in the same set correspond to the same antenna number sample. Then, the first calculating module may calculate the antenna switching threshold between the antenna number k and the antenna number k-1 through the set corresponding to the antenna number k and the set corresponding to the antenna number k-1.
In a possible implementation, the first calculation module calculates an antenna switching threshold value between the antenna number k and the antenna number k-1 through a set corresponding to the antenna number k and a set corresponding to the antenna number k-1, where the first calculation module may calculate a sum of antenna number prediction results in the set corresponding to the antenna number k to obtain a first sum, and the first calculation module may calculate a sum of antenna number prediction results in the set corresponding to the antenna number k-1 to obtain a second sum. Then, the first calculation module may calculate a sum of the first sum and the second sum to obtain a first sum, and the first calculation module may calculate a sum of the number of antenna number predictions in the set corresponding to the antenna number k and the number of antenna number predictions in the set corresponding to the antenna number k-1 to obtain a second sum. Then, the first calculation module may calculate a ratio of the first sum value to the second sum value, where the ratio is an antenna switching threshold between the antenna number k and the antenna number k-1.
For example, the features of the two first training data are input into the initial tuning model for training at each iteration of the training device, and when the prediction loss function converges, that is, the labels (that is, antenna number samples) of the first training data corresponding to the features of the two first training data input by the training device at the last iteration are respectively 1 and 2. When the set of antenna number prediction results corresponding to the antenna number sample 1 obtained after the last iteration is {0.9,1.1,1.3}, and the set of antenna number prediction results corresponding to the antenna number sample 2 is {2.3,1.9,2}, the antenna switching threshold between the antenna number 1 and the antenna number 2 is (0.9+1.1+1.3+2.3+1.9+2)/(3+3) =1.583.
The process of tuning the antenna by the handset through the tuning unit of the modem processor is described below.
As one possible implementation, the handset may determine the predicted antenna state number through an antenna tuning model to achieve antenna tuning and/or antenna switching.
Before describing the process of tuning an antenna provided by the embodiment of the present application, an antenna tuning model provided by the embodiment of the present application is described.
In the embodiment of the application, the training device can train the initial tuning model by using the second training data set, and after the training completion condition (for example, the loss function converges or the training times reach the preset times under the condition that the loss function does not converge) is met, the training process of the training device on the initial tuning model is completed, so as to obtain the antenna tuning model.
The architecture of the initial tuning model can be referred to in the corresponding embodiment of fig. 7, and the difference is the output layer. And replacing the first storage module, the first calculation module, the first judgment module and the first output module in the output layer of the initial prediction model with the second storage module, the second calculation module, the second judgment module and the second output module to obtain the framework of the initial tuning model. The second storage module can be used for storing the antenna state number prediction results output by the hidden layers in the training process, the second calculation module can be used for calculating a state switching point according to the antenna state number prediction results, the second judgment module can be used for comparing the antenna state number prediction results output by the hidden layers with the antenna state numbers to obtain second comparison results, and the second output module can be used for outputting antenna state number prediction values according to the second comparison results. The state switching point is a critical value for switching the antenna state number of the mobile phone.
After explaining the architecture of the initial tuning model, the second training data set and the way in which the second training data set is acquired are described below.
As a possible implementation, the training device may use the second training data set to train the initial tuning model, and after meeting the training end condition, the training device obtains the antenna tuning model.
In the embodiment of the application, the simulation equipment can simulate at least one communication simulation scene of the mobile phone, wherein the mobile phone is in a free space (namely, no object touches the mobile phone), the mobile phone is operated by one hand, the mobile phone is operated by two hands, the mobile phone is placed on a desktop to play videos, the mobile phone makes calls and the like. The form of the simulation device may be similar to the training device described above and will not be described in detail herein.
Then, for any communication simulation scene, the developer can adjust the total radiation power (total radiated power, TRP) and the total combined total omni-directional receiving sensitivity (combined total isotropic sensitivity, TIS) of the antenna used by the mobile phone through the simulation equipment, so that the antenna efficiency of the mobile phone in the communication simulation scene is larger than the preset efficiency. Wherein TRP may be used to measure the total radiated power of the handset when transmitting and TIS may be used to reflect the sensitivity of the handset when receiving signals. The preset efficiency may be set according to an actual scene, which is not limited in the embodiment of the present application.
Then, the data acquisition device may acquire second data when the antenna efficiency is greater than the preset efficiency in each communication simulation scene, where the second data may include at least one of RSRP, MCS level, SNR, other key indexes, and the like, and an antenna state number and an antenna impedance, or the second data may further include an antenna number. For example, the second data may include a BLER, an antenna number, an antenna state number, and an antenna impedance.
Where antenna impedance may refer to the electrical impedance characteristic exhibited by an antenna at its feed point (or input). For example, for a line antenna, the ratio of the voltage to the current at the input of the antenna is the antenna impedance. The antenna impedance may be complex, the real part of the antenna impedance being the input resistance and the imaginary part of the antenna impedance being the input reactance.
The data acquisition device may then pre-process the second data to obtain a second training data set. The preprocessing may include missing value processing, outlier processing, data deduplication, and the like.
Wherein the second training data set may comprise at least one second data sample (which may also be referred to as second training data). Each second data sample may include at least one of an RSRP sample, an MCS level sample, an SNR sample, and other key indicator samples, and an antenna state number sample and an antenna impedance sample, or the second data samples may further include an antenna number sample.
After the second training data set is introduced, the process of training the initial tuning model using the second training data set is described below.
As a possible implementation, the antenna tuning model obtained by training the initial tuning model with the second training data may be used to predict the antenna state number.
Fig. 17 is a schematic flow chart of a training process of an antenna tuning model according to an embodiment of the present application. As shown in FIG. 17, the process may include steps S1701-S1704.
S1701, the training device acquires a second training data set. The second training data set may include features of the second training data and labels of the second training data.
The second training data may be labeled as an antenna state number sample, and the characteristics of the second training data may include at least one of an MCS level sample, an SNR sample, and other key indicator samples, and an antenna impedance sample, or the characteristics of the second training data may further include an antenna number sample.
It will be appreciated that the training device may train the initial tuning model using all of the second data samples comprised by the second training data set, and the training device may train the initial tuning model using some of the second data samples comprised by the second training data set.
S1702, the training device inputs the features of the first training data into an initial tuning model to obtain an initial tuning training result.
For example, the initial tuning training results may include a first initial tuning training result, a second initial tuning training result, and a third initial tuning training result. The first initial tuning training result is an antenna state number prediction result output by the first hidden layer, the second initial tuning training result is an antenna state number prediction result output by the second hidden layer, and the third initial tuning training result is an antenna state number prediction result output by the third hidden layer.
The first initial tuning training result is a result of aggregation processing of neuron outputs of neurons in the first hidden layer. The aggregation of the neuron outputs may be performed, for example, by a training device that performs a single matrix multiplication or multiple matrix multiplications on the neuron outputs. The input of each neuron in the first hidden layer is characteristic of the first training data communicated by each neuron of the input layer.
The second initial tuning training result is a result of the aggregation of the neuron outputs of the neurons in the second hidden layer. The input of each neuron in the second hidden layer is the neuron output of each neuron in the first hidden layer. See, for example, the description of the corresponding embodiment of fig. 7, which is not repeated here.
Similarly, the third initial tuning training result is a result of the aggregation of the neuron outputs of the neurons in the third hidden layer. The input of each neuron in the third hidden layer is the neuron output of each neuron in the second hidden layer. See, for example, the description of the corresponding embodiment of fig. 7, which is not repeated here.
It will be appreciated that each hidden layer corresponds to an initial tuning training result. The embodiment of the application is exemplified by taking the hidden layer as 3 layers, so that the initial tuning training results are 3. The embodiment of the application does not limit the number of layers of the hidden layer and the embodiment of the application also does not limit the number of initial tuning training results.
S1703, the training device calculates a tuning loss function according to the first initial tuning training result, the second initial tuning training result, the third initial tuning training result and the label of the second training data.
Illustratively, the tuning loss function may include a first tuning loss function, a second tuning loss function, and a third tuning loss function. The first tuning loss function may be a sum of first differences, where the first difference is a difference between any antenna state number prediction result in the first initial tuning training result and a tag corresponding to the second training data. The second tuning loss function may be a sum of second differences, where the second differences are differences between any antenna state number prediction result in the second initial tuning training result and a tag corresponding to the second training data. The third tuning loss function may be a sum of third differences, where the third difference is a difference between any antenna state number prediction result in the third initial training result and a tag corresponding to the second training data.
And S1704, the training equipment iterates model parameters of the initial tuning model based on the tuning loss function until the tuning loss function converges to obtain an antenna tuning model.
The tuning loss function convergence may be that the first tuning loss function is less than or equal to a fourth preset value, the second tuning predictive loss function is less than or equal to a fifth preset value, and the third tuning predictive loss function is less than or equal to a sixth preset value. The fourth preset value, the fifth preset value and the sixth preset value may be set according to an actual scene, which is not limited in the embodiment of the present application.
In other possible implementations, step S1704 may be replaced by the training device iterating model parameters of the initial tuning model based on the tuning loss function, and obtaining the antenna tuning model when the training duration reaches the second preset duration in the case where the tuning loss function is not converged.
The second preset duration may be set according to an actual scene, and the embodiment of the present application does not specifically limit the second preset duration.
In yet another possible implementation, step S1704 may be replaced by the training device iterating model parameters of the initial tuning model based on the tuning loss function, and obtaining the antenna tuning model when the number of iterations reaches a second preset number of times without convergence of the tuning loss function.
The second preset times can be set according to an actual scene, and the embodiment of the application does not specifically limit the second preset times.
After the training device trains the initial tuning model to obtain the antenna tuning model, the antenna tuning model may be deployed onto a cell phone. In the process of using the mobile phone by a user, the mobile phone can input parameters such as the acquired RSRP actual value, MCS level actual value, SNR actual value, antenna number actual value, antenna state number actual value, antenna impedance actual value and/or other key index actual values into the antenna tuning model to obtain an antenna state number predicted value output by the antenna tuning model.
As a possible implementation manner, after the antenna tuning model is deployed into the handset, the handset may update the antenna tuning model while in an idle state.
For example, during the process of using the mobile phone (such as using the mobile phone to make a call, play a game, watch a video, etc.) by the user, that is, in a case that the mobile phone is in a non-idle state, the mobile phone may record multiple sets of second actual data of the antenna during the use by the user, where each set of second actual data may include at least one of an RSRP actual value, an MCS level actual value, an SNR actual value, and other key index actual values, and an antenna impedance actual value and an antenna state number actual value, or the second actual data may further include an antenna number actual value. The second actual data of different sets corresponds to different time periods or different moments in time.
Then, the mobile phone can preprocess the latest multiple groups of second actual data to obtain a new second training data set. The preprocessing may include missing value processing, outlier processing, data deduplication, and the like.
Optionally, in order to improve the prediction accuracy of the antenna tuning model, during the process of recording multiple sets of second actual data (which may also be referred to as a second operating cellular index) by the mobile phone, for any second actual data input into the antenna tuning model, the mobile phone may record the average value of output results of each hidden layer of the antenna tuning model for the second actual data. The step of preprocessing the latest multiple sets of second actual data to obtain a new second training data set may include:
the mobile phone can screen out a plurality of groups of second actual data meeting preset conditions from the preprocessed plurality of groups of second actual data. The mobile phone can obtain a new second training data set according to a plurality of groups of second actual data meeting preset conditions. For any second actual data meeting the preset condition, the absolute value of the difference value between the average value of the output results of each hidden layer of the antenna tuning model for the second actual data and the corresponding state switching point is larger than or equal to a preset first absolute value and smaller than or equal to a preset second absolute value. The preset first absolute value is smaller than the preset second absolute value.
The mobile phone may collect, for example, second actual data corresponding to a mean value of 1.22 of output results of each hidden layer of the antenna tuning model and a mean value of 1.22 of output results of each hidden layer of the antenna tuning model when the mobile phone collects, and may also collect second actual data corresponding to a mean value of 1.34 of output results of each hidden layer of the antenna tuning model and a mean value of 1.34 of output results of each hidden layer of the antenna tuning model when the mobile phone collects, when the state switching point between the antenna state number state1 and the antenna state number state2 in the trained antenna tuning model is 1.27, and when the preset first absolute value is 0.5 and the preset second absolute value is 0.7.
And then, under the condition that the mobile phone is in an idle state, the mobile phone can train the antenna tuning model on a new second training data set so as to obtain an updated antenna tuning model. The new second training data set is obtained by preprocessing data acquired based on the use habit of the user and the communication environment in which the mobile phone is located by the mobile phone. Therefore, with the increase of the updating times, the updated antenna tuning model is more suitable for the use habit of the user and the communication environment of the mobile phone. Therefore, the prediction accuracy of the updated antenna tuning model is higher, and the communication quality of the electronic equipment can be further improved.
After the training process of the antenna tuning model is introduced, the antenna tuning process is described below.
For example, referring to fig. 18, fig. 18 shows a third flowchart of an antenna adjustment method according to an embodiment of the present application. As shown in fig. 18, the step S1304 may include steps S1801 to S1804.
S1801. the acquisition unit acquires an actual antenna impedance value corresponding to the target time and a third index corresponding to the target time (the actual antenna impedance value corresponding to the target time and the third index corresponding to the target time may also be referred to as a fourth cellular index).
The target time may be a collection time corresponding to a target value corresponding to the second index. The actual value of the antenna number corresponding to the target time can be the antenna number corresponding to the antenna used by the mobile phone at the target time.
The third index may include parameters such as MCS level, SNR, RSRP, and/or other key indexes. In a possible implementation, the mobile phone may read an actual value of the antenna number corresponding to the target time, an actual value of the antenna impedance corresponding to the target time, and/or a third index corresponding to the target time from the log file.
Optionally, the fourth cellular indicator may further include an antenna number corresponding to the target time and/or an antenna state number corresponding to the target time. The subsequent processing unit may also input the antenna number corresponding to the target time and/or the antenna state number corresponding to the target time into the antenna tuning model, so that the antenna tuning model outputs the antenna state number predicted value.
S1802, the processing unit inputs the antenna impedance actual value corresponding to the target moment and a third index corresponding to the target moment into the antenna tuning model to obtain an antenna state number predicted value output by the antenna tuning model.
In the embodiment of the application, the trained second calculation module in the output layer of the antenna tuning model comprises a plurality of trained state switching points. After the antenna impedance actual value corresponding to the target moment and the third index corresponding to the target moment are input into the antenna tuning model, the trained second calculation module in the output layer of the antenna tuning model can perform mean value operation on the output result of each hidden layer, and a mean value operation result is obtained. Then, the mobile phone can obtain the antenna state number predicted value output by the antenna tuning model through the second judging unit of the output layer according to the average value operation result and the trained state switching point.
In a possible implementation, the mobile phone obtains, through the second judging unit of the output layer, an antenna state number predicted value output by the antenna tuning model according to a result of the mean value operation and a trained state switching point, where the mean value of the antenna state number predicted values output by each hidden layer in the antenna tuning model is less than or equal to the s (s is an integer greater than or equal to 1) th state switching point, and if the mean value is greater than the s-1 st state switching point, the antenna state number predicted value output by the trained second output module in the antenna tuning model is an antenna state number which is less than the s state switching point and closest to the s state switching point, and if the mean value of the antenna state number predicted values output by each hidden layer in the antenna tuning model is greater than the s state switching point and less than or equal to the s+1 th state switching point, the antenna state number predicted value output by the trained second output module in the antenna tuning model is greater than the s state switching point and closest to the s state switching point. Wherein the (s+1) th state switching point is greater than the(s) th state switching point, which is greater than the (s-1) th state switching point.
The antenna tuning model outputs an antenna state number prediction value of state1 when the average value of the antenna state number prediction results output by each hidden layer is smaller than or equal to the state switching point between the antenna state number state1 and the antenna state number state2, and an antenna state number prediction value of state2 when the average value of the antenna state number prediction results output by each hidden layer is larger than the state switching point between the antenna state number state1 and the antenna state number state2 and smaller than or equal to the state switching point between the antenna state number state2 and the antenna state number state3, and an antenna state number prediction value of state3 when the average value of the antenna state number prediction results output by each hidden layer is larger than the state switching point between the antenna state number state2 and the antenna state number state3 and smaller than or equal to the state switching point between the antenna state number state3 and the antenna state number state 4.
Or when the antenna number prediction result output by each hidden layer of the antenna tuning model is smaller than or equal to the state switching point between the antenna state number state1 and the antenna state number state2, the antenna state number prediction value output by the antenna tuning model is state1, and when the antenna number prediction result output by each hidden layer of the antenna tuning model is larger than the state switching point between the antenna state number state1 and the antenna state number state2 and smaller than or equal to the state switching point between the antenna state number state2 and the antenna state number state3, the antenna state number prediction value output by the antenna tuning model is state2, and when the antenna number prediction result output by each hidden layer of the antenna tuning model is larger than the state switching point between the antenna state number state2 and the antenna state number state3 and smaller than or equal to the state switching point between the antenna state number state3 and the antenna state number state4, the antenna state number prediction value output by the antenna tuning model is state3.
After the use of the state switch point is described, the process of obtaining the state switch point by the training device or the mobile phone is described below.
In one possible implementation, the second storage module of the output layer in the initial prediction model may store the antenna state number prediction result output by each hidden layer at each iteration. After the tuning loss function converges, the second calculation module can perform clustering processing on the antenna state number prediction results output by each hidden layer in the last iteration to obtain a plurality of sets. Different sets correspond to different antenna state numbers, and the antenna state number prediction results in the same set correspond to the same antenna state number sample. Then, the second calculating module may calculate the state switching point between the antenna state number s and the antenna state number s-1 through the set corresponding to the antenna state number s and the set corresponding to the antenna state number s-1.
In a possible implementation, the second calculation module calculates a state switching point between the antenna state number s and the antenna state number s-1 through a set corresponding to the antenna state number s and a set corresponding to the antenna state number s-1, where the second calculation module may calculate a sum of antenna state number prediction results in the set corresponding to the antenna state number s to obtain a third sum, and the second calculation module may calculate a sum of antenna state number prediction results in the set corresponding to the antenna state number s-1 to obtain a fourth sum. Then, the second calculation module may calculate a sum of the second sum and the second sum to obtain a third sum, and the second calculation module may calculate a sum of the number of antenna state number predictions in the set corresponding to the antenna state number s and the number of antenna state number predictions in the set corresponding to the antenna state number s-1 to obtain a fourth sum. Then, the second calculating module may calculate a ratio of the third sum value to the fourth sum value, where the ratio is a state switching point between the antenna state number s and the antenna state number s-1.
The features of the two second training data are input into the initial tuning model for training when the training device iterates each time, and when the tuning loss function converges, that is, the labels (that is, the antenna state number samples) of the second training data corresponding to the features of the two second training data input by the training device at the last iteration are state1 and state2. When the set of antenna state number prediction results corresponding to the antenna state number sample state1 obtained after the last iteration is { state0.8, state1.2, state1}, and the set of antenna state number prediction results corresponding to the antenna state number sample state2 is { state2, state1.9, state1.8}, the state switching point between the antenna state number state1 and the antenna state number state2 is (0.8+1.2+1+2+1.9+1.8)/(3+3) =1.45.
S1803. the processing unit determines whether to switch the antenna state.
In a possible implementation, the processing unit determines whether the value of the usage status parameter is inconsistent with the antenna status number predicted value, and executes step S1804 when the value of the usage status parameter is inconsistent with the antenna status number predicted value.
S1804. the adjusting unit switches the antenna state of the antenna and/or switches the antenna used by the mobile phone.
As a possible implementation manner, the adjustment unit may store in advance a plurality of antenna state numbers, correspondence relations between the antenna states and the antenna numbers. Then, in the case where the adjustment unit acquires the antenna state number output by the antenna tuning model, the adjustment unit may switch the antenna state of the used antenna to the antenna state corresponding to the antenna state number, and/or the adjustment unit may switch the antenna of the used antenna to the antenna corresponding to the antenna number indicated by the antenna state number.
Wherein the antenna status number may be used to identify different antenna statuses and/or to indicate the antenna number. The same antenna may be provided with multiple antenna states. The embodiment of the application does not limit the expression form of the antenna state number in detail, so long as different antenna states can be distinguished.
For example, the plurality of antenna state numbers, the correspondence between the antenna states and the antenna numbers stored in the adjustment unit in advance may include:
The antenna state1 corresponds to the antenna corresponding to the antenna number 1, the antenna corresponding to the antenna number 2 and the antenna corresponding to the antenna number 3, the antenna corresponding to the antenna number 1 is used, the antenna state of the antenna corresponding to the antenna number 1 is the first antenna state of the antenna, the antenna state of the antenna corresponding to the antenna number 2 is the first antenna state of the antenna, and the antenna state of the antenna corresponding to the antenna number 3 is the first antenna state of the antenna. I.e. the antenna number state1 indicates an antenna number of 1.
The antenna state number 2 corresponds to the antenna corresponding to the antenna number 1, the antenna corresponding to the antenna number 2 and the antenna corresponding to the antenna number 3, the antenna corresponding to the antenna number 2 is used, the antenna state of the antenna corresponding to the antenna number 1 is the second antenna state of the antenna, the antenna state of the antenna corresponding to the antenna number 2 is the second antenna state of the antenna, and the antenna state of the antenna corresponding to the antenna number 3 is the second antenna state of the antenna. I.e. the antenna number indicated by the antenna state number state2 is 2.
The antenna state3 corresponds to the antenna corresponding to the antenna number 1, the antenna corresponding to the antenna number 2 and the antenna corresponding to the antenna number 3, the antenna corresponding to the antenna number 3 is used, the antenna state of the antenna corresponding to the antenna number 1 is the first antenna state of the antenna, the antenna state of the antenna corresponding to the antenna number 2 is the first antenna state of the antenna, and the antenna state of the antenna corresponding to the antenna number 3 is the first antenna state of the antenna. I.e. antenna number 3 indicated by antenna state number state 3.
The antenna state number 4 corresponds to the antenna corresponding to the antenna number 1, the antenna corresponding to the antenna number 2 and the antenna corresponding to the antenna number 3, the antenna corresponding to the antenna number 1 is used, the antenna state of the antenna corresponding to the antenna number 1 is the third antenna state of the antenna, the antenna state of the antenna corresponding to the antenna number 2 is the third antenna state of the antenna, and the antenna state of the antenna corresponding to the antenna number 3 is the third antenna state of the antenna. I.e. the antenna number indicated by the antenna state number state4 is 1.
It is to be understood that the above-mentioned various antenna state numbers, the correspondence between the antenna states and the antenna numbers are exemplary descriptions, and the embodiments of the present application do not specifically limit which antennas, which antennas are used, and which antenna states correspond to one antenna state number.
Next, a process of switching the antenna state of the antenna in the embodiment of the present application will be exemplarily described taking the above correspondence relationship as an example.
For example, when the value of the usage status parameter in the adjustment unit is state1 and the value of the usage antenna parameter is 1, it means that the adjustment unit uses the antenna corresponding to antenna number 1, and the antenna status of the antenna corresponding to antenna number 1 is the first antenna status of the antenna, the antenna status of the antenna corresponding to antenna number 2 is the first antenna status of the antenna, and the antenna status of the antenna corresponding to antenna number 3 is the first antenna status of the antenna.
Then, in the case where the antenna state number predicted by the antenna tuning model is state4, the adjustment unit may modify the value of the usage state parameter to state4. Since the antenna number indicated by the antenna state number state4 is still 1, the adjustment unit performs only switching of the antenna state, and does not perform antenna switching.
Illustratively, based on the value of the usage state parameter being modified to state4, the adjusting unit controls the turning on or off of the tuning component in the tuning circuit according to the control policy corresponding to state4, so that the current state of the antenna is switched to the antenna state corresponding to state 4. That is, the antenna state of the antenna corresponding to antenna number 1 is switched to the third antenna state of the antenna, the antenna state of the antenna corresponding to antenna number 2 is switched to the third antenna state of the antenna, and the antenna state of the antenna corresponding to antenna number 3 is switched to the third antenna state of the antenna.
In the following, a process of switching antennas used by a mobile phone in the embodiment of the present application will be described by taking the above correspondence as an example.
For example, when the value of the usage status parameter in the adjustment unit is state1 and the value of the usage antenna parameter is 1, it means that the adjustment unit uses the antenna corresponding to antenna number 1, and the antenna status of the antenna corresponding to antenna number 1 is the first antenna status of the antenna, the antenna status of the antenna corresponding to antenna number 2 is the first antenna status of the antenna, and the antenna status of the antenna corresponding to antenna number 3 is the first antenna status of the antenna.
Then, when the antenna state number predicted by the antenna tuning model is state3, the adjustment unit modifies the use state parameter to be state3, but does not switch the antenna states, since the antenna state number 3 corresponds to the first antenna state of antenna number 1, the first antenna state of antenna number 2, and the first antenna state of antenna number 3. Since the antenna number indicated by the antenna state number state3 is3, the adjustment unit may modify the value of the used antenna parameter to 3. Then, the adjustment unit performs antenna switching.
For example, based on the value of the used antenna parameter being modified to 3, the adjusting unit controls the antenna switching circuit to switch the antenna used by the mobile phone to the antenna corresponding to the antenna number 3.
In the following, the process of switching the antenna state of the antenna and switching the antenna used by the mobile phone in the embodiment of the present application will be described by taking the above correspondence as an example.
For example, when the value of the usage status parameter in the adjustment unit is state1 and the value of the usage antenna parameter is 1, it means that the adjustment unit uses the antenna corresponding to antenna number 1, and the antenna status of the antenna corresponding to antenna number 1 is the first antenna status of the antenna, the antenna status of the antenna corresponding to antenna number 2 is the first antenna status of the antenna, and the antenna status of the antenna corresponding to antenna number 3 is the first antenna status of the antenna.
Then, in the case where the antenna state number predicted by the antenna tuning model is state2, the adjustment unit may modify the value of the usage state parameter to state2 and modify the value of the usage antenna parameter to antenna number 2 indicated by the above-described antenna state number state 2.
Then, based on the value of the use state parameter being modified to be state2, the adjusting unit controls the turning-on or turning-off of the tuning component in the tuning circuit according to the control strategy corresponding to state2, so that the current state of the antenna is switched to the antenna state corresponding to state 2. That is, the antenna state of the antenna corresponding to antenna number 1 is switched to the second antenna state of the antenna, the antenna state of the antenna corresponding to antenna number 2 is switched to the second antenna state of the antenna, and the antenna state of the antenna corresponding to antenna number 3 is switched to the second antenna state of the antenna.
And based on the value of the used antenna parameter being modified to 2, the adjusting unit controls the antenna switching circuit to switch the antenna used by the mobile phone to the antenna corresponding to the antenna number 2.
The embodiment of the application also provides an electronic device, and fig. 19 is a schematic hardware structure of another electronic device provided by the embodiment of the application. As shown in fig. 19, the electronic device may include one or more processors 1901, memory 1902, and a communication interface 1903.
Wherein a memory 1902, a communication interface 1903, and a processor 1901 are coupled. For example, memory 1902, communication interface 1903, and processor 1901 may be coupled together via bus 1904.
Wherein communication interface 1903 is used for data transmission with other devices. The memory 1902 has stored therein computer program code. The computer program code comprises computer instructions which, when executed by the processor 1901, cause the electronic device to perform the relevant method steps of the above-described method embodiments of the application.
The processor 1901 may be a processor or controller, such as a central processing unit (central processing unit, CPU), a general purpose processor, a digital signal processor (DIGITAL SIGNAL processor, DSP), an application-specific integrated circuit (ASIC), a field programmable gate array (field programmable GATE ARRAY, FPGA), or other programmable logic device, transistor logic device, hardware components, or any combination thereof. Which may implement or perform the various exemplary logic blocks, modules, and circuits described in connection with this disclosure. The processor may also be a combination that performs the function of a computation, e.g., a combination comprising one or more microprocessors, a combination of a DSP and a microprocessor, and the like.
Bus 1904 may be, among other things, a peripheral component interconnect standard (PERIPHERAL COMPONENT INTERCONNECT, PCI) bus or an extended industry standard architecture (extended industry standard architecture, EISA) bus, among others. The bus 1904 may be classified into an address bus, a data bus, a control bus, and the like. For ease of illustration, only one line is shown in fig. 19, but not only one bus or one type of bus.
The embodiment of the application also provides a chip system, and fig. 20 is a schematic structural diagram of the chip system provided by the embodiment of the application. As shown in fig. 20, the chip system 2000 includes at least one processor 2001 and at least one interface circuit 2002. The processor 2001 and interface circuit 2002 may be interconnected by wires. For example, the interface circuit 2002 may be used to receive signals from other devices (e.g., a memory of an electronic apparatus). For another example, the interface circuit 2002 may be used to send signals to other devices (e.g., the processor 2001). Illustratively, the interface circuit 2002 may read instructions stored in the memory and send the instructions to the processor 2001. The instructions, when executed by the processor 2001, may cause the electronic device to perform the various steps of the embodiments described above. Of course, the system-on-chip may also include other discrete devices, which are not particularly limited in accordance with embodiments of the present application.
The embodiment of the application also provides a computer readable storage medium, in which a computer program code is stored, which when executed by the above-mentioned processor, causes the electronic device to perform the relevant method steps in the above-mentioned method embodiments.
The present application also provides a computer program product which, when run on a computer, causes the computer to perform the relevant method steps of the method embodiments described above.
The electronic device, the computer readable storage medium or the computer program product provided by the present application are used to execute the corresponding method provided above, and therefore, the advantages achieved by the present application may refer to the advantages in the corresponding method provided above, and will not be described herein.
It will be apparent to those skilled in the art from this description that, for convenience and brevity of description, only the above-described division of the functional modules is illustrated, and in practical application, the above-described functional allocation may be performed by different functional modules according to needs, i.e. the internal structure of the apparatus is divided into different functional modules to perform all or part of the functions described above.
In the several embodiments provided by the present application, it should be understood that the disclosed apparatus and method may be implemented in other manners. For example, the apparatus embodiments described above are merely illustrative, e.g., the division of the modules or units is merely a logical functional division, and there may be additional divisions when actually implemented, e.g., multiple units or components may be combined or integrated into another apparatus, or some features may be omitted, or not performed. Alternatively, the coupling or direct coupling or communication connection shown or discussed with each other may be an indirect coupling or communication connection via some interfaces, devices or units, which may be in electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and the parts displayed as units may be one physical unit or a plurality of physical units, may be located in one place, or may be distributed in a plurality of different places. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
In addition, each functional unit in the embodiments of the present application may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit. The integrated units may be implemented in hardware or in software functional units.
The integrated units, if implemented in the form of software functional units and sold or used as stand-alone products, may be stored in a readable storage medium. Based on such understanding, the technical solution of the embodiments of the present application, or a contributing part or all or part of the technical solution, may be embodied in the form of a software product, where the software product is stored in a storage medium, and includes several instructions for causing a device (may be a single-chip microcomputer, a chip or the like) or a processor (processor) to execute all or part of the steps of the methods described in the embodiments of the present application. The storage medium includes a U disk, a removable hard disk, a Read Only Memory (ROM), a random access memory (random access memory, RAM), a magnetic disk, an optical disk, or other various media capable of storing program codes.
The foregoing is merely illustrative of specific embodiments of the present application, but the scope of the present application is not limited thereto, and any changes or substitutions within the technical scope of the present application should be covered by the scope of the present application. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.