CN116048765B - Task processing method, sample data processing method and electronic equipment - Google Patents

Task processing method, sample data processing method and electronic equipment Download PDF

Info

Publication number
CN116048765B
CN116048765B CN202310258100.3A CN202310258100A CN116048765B CN 116048765 B CN116048765 B CN 116048765B CN 202310258100 A CN202310258100 A CN 202310258100A CN 116048765 B CN116048765 B CN 116048765B
Authority
CN
China
Prior art keywords
event
task
data
event content
sample
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202310258100.3A
Other languages
Chinese (zh)
Other versions
CN116048765A (en
Inventor
杨威
张能斌
张莲龙
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Honor Device Co Ltd
Original Assignee
Honor Device Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Honor Device Co Ltd filed Critical Honor Device Co Ltd
Priority to CN202310258100.3A priority Critical patent/CN116048765B/en
Publication of CN116048765A publication Critical patent/CN116048765A/en
Application granted granted Critical
Publication of CN116048765B publication Critical patent/CN116048765B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/48Program initiating; Program switching, e.g. by interrupt
    • G06F9/4806Task transfer initiation or dispatching
    • G06F9/4843Task transfer initiation or dispatching by program, e.g. task dispatcher, supervisor, operating system
    • G06F9/4881Scheduling strategies for dispatcher, e.g. round robin, multi-level priority queues
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/901Indexing; Data structures therefor; Storage structures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/903Querying
    • G06F16/9035Filtering based on additional data, e.g. user or group profiles
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Computational Linguistics (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The embodiment of the application provides a task processing method, a sample data processing method and electronic equipment, wherein the method comprises the following steps: the index identification of the event content item matched with the task to be executed is determined, candidate event content indicated by the index identification is screened in the recorded event sequence to serve as target event content matched with the task to be executed, and the task to be executed is executed based on the target event content, so that the data storage consumption during task processing can be effectively reduced, and the processing resource cost of data is effectively reduced.

Description

Task processing method, sample data processing method and electronic equipment
Technical Field
The embodiment of the application relates to the field of terminal equipment, in particular to a task processing method, a sample data processing method and electronic equipment.
Background
With the increase of computing power and hardware power, electronic devices support model training and content prediction tasks with more and more characteristics, and accordingly, business scenarios that electronic devices can support are more and more diversified.
At present, when the electronic equipment performs multi-characteristic service development, the phenomena of high data storage resource consumption and high data redundancy degree exist.
Disclosure of Invention
In order to solve the technical problems, the application provides a task processing method, a sample data processing method and electronic equipment. In the method, when the electronic equipment performs task processing or model training, the problems of high data storage resource consumption and high data redundancy degree can be effectively relieved by adopting a hierarchical index storage mode for the data.
In a first aspect, an embodiment of the present application provides a task processing method. The method comprises the following steps: determining event content items matched with a first task type according to the first task type of the task to be executed; determining an index identifier for the event content item according to the content item identifier of the event content item; screening candidate event content indicated by the index identifier from the recorded event sequence to serve as target event content matched with the task to be executed; and executing the task based on the target event content to obtain a task execution result. The method can effectively reduce the consumption of storage resources of the target event content, and is beneficial to reducing the data redundancy degree in the task execution process.
According to a first aspect, determining an event content item matching a first task type according to the first task type of a task to be performed, comprises: and determining a preamble event content item matched with the first task type and based on the target time as an event content item matched with the first task type, wherein the event occurrence time corresponding to the preamble event content item is earlier than the target time. Candidate event content corresponding to the preamble event content item may be regarded as target event content matching the task to be performed.
According to a first aspect, or any implementation manner of the first aspect, determining an index identity for an event content item from a content item identity of the event content item, comprises: according to the content item identification, determining search screening conditions aiming at target event content; in the recorded event sequence, index identifiers meeting the search screening condition are used as index identifiers for event content items. The target event content matched with the task to be executed is stored in an index mode, so that the consumption of storage resources of the target event content can be effectively reduced, the data processing efficiency in the task execution process can be improved, and the applicability of the system in a scene based on service expansion and more data accumulation can be effectively improved.
According to the first aspect, or any implementation manner of the first aspect, a plurality of candidate event contents are stored in the event sequence, a time sequence association relationship is provided between the plurality of candidate event contents, and the candidate event contents are acquired based on a trigger event in the terminal. Each candidate event content in the recorded event sequence has a corresponding index identifier, and the index identifier indicates a generation time of the corresponding candidate event content.
According to a first aspect, or any implementation manner of the first aspect, the recording of the event sequence is based on: in response to detecting a trigger event for the data output item, obtaining candidate event content generated based on the trigger event; the candidate event content is stored according to the index identification indicated by the generation time of the candidate event content to obtain a recorded event sequence. By recording the form of event sequences and intensively storing the candidate event content generated based on the trigger event, the defects of high data redundancy degree and large data storage consumption can be effectively solved, and the resource cost generated in the scenes of data writing, external memory, cloning, aging and the like can be effectively reduced.
According to the first aspect, or any implementation manner of the first aspect, task execution is performed based on the target event content, so as to obtain a task execution result, including: taking the target event content and the current event content based on the target moment as state input data of a task to be executed; and executing the task based on the state input data to obtain a task execution result. In the case that the number of the target event contents is more than one, a plurality of target event contents constitute a preamble event sequence, and the preamble event sequence and the current event content are used as state input data of a task to be executed. The event occurrence time corresponding to the target event content is earlier than the target time, the event occurrence time corresponding to the current event content is the target time, and the target time can be, for example, the current time when the task is executed.
According to the first aspect, or any implementation manner of the first aspect, the task to be performed includes at least one of a content prediction task, an information push task, and an object recommendation task.
In a second aspect, an embodiment of the present application provides a method for processing sample data. The method comprises the following steps: determining a sample event content item matched with a second task type according to the second task type of the task to be trained; determining an index identification for the sample event content item based on a preset recorded event sequence; training sample data for a task to be trained is generated from the index identification and the sample tag associated with the sample event content item. The collected candidate event content and the training sample data for model training are subjected to hierarchical index storage, so that the storage resource consumption of the training sample data can be effectively reduced, the data redundancy degree of the training sample data can be effectively reduced, and the method is well applicable to multi-characteristic model training under a service expansion scene and a scene with more data accumulation.
According to a second aspect, the sequence of recorded events is derived based on: in response to detecting a trigger event for the sample output item, obtaining candidate event content generated based on the trigger event; the candidate event content is stored according to the index identification indicated by the generation time of the candidate event content to obtain a recorded event sequence. The sequence of recorded events may be stored by the physical layer, training sample data for the task to be trained may be stored by the logical layer, and the logical layer may mask the underlying complex data storage structure.
According to a second aspect, or any implementation manner of the second aspect, in response to detecting a trigger event for a sample output item, acquiring candidate event content generated based on the trigger event includes: in response to detecting the annotation event and/or the timeout event for the sample output item, candidate event content generated based on the annotation event and/or the timeout event is obtained. The timeout event includes a specified event that satisfies a preset timeout trigger condition for determining whether the timeout event is triggered, which may include, for example, a timeout time threshold.
According to a second aspect, or any implementation manner of the second aspect, generating training sample data for a task to be trained according to an index identification and a sample tag associated with a sample event content item, includes: the index identification is used as data content in a sample data structure, and the data content and the sample label form training sample data. The method can effectively reduce the consumption of storage resources of the training sample data, is beneficial to reducing the construction operation amount and the calculation time delay of the training sample data, and can be well applied to business expansion scenes and multi-characteristic model training scenes.
According to a second aspect, or any implementation manner of the second aspect, the method further includes: object operational feedback matching the sample event content item is determined and used as a sample tag for the sample event content item. The subject operational feedback includes positive operational feedback and negative operational feedback.
According to a second aspect, or any implementation manner of the second aspect, the task to be trained is implemented based on at least one of a content prediction model, an information push model and an object recommendation model to be trained.
In a third aspect, an embodiment of the present application provides an electronic device. The electronic device includes a memory and a processor coupled, the memory storing program instructions that, when executed by the processor, cause the electronic device to perform the steps of: determining event content items matched with a first task type according to the first task type of the task to be executed; determining an index identifier for the event content item according to the content item identifier of the event content item; screening candidate event content indicated by the index identifier from the recorded event sequence to serve as target event content matched with the task to be executed; and executing the task based on the target event content to obtain a task execution result.
According to a third aspect, determining, according to a first task type of a task to be performed, an event content item matching the first task type, comprises: and determining a preamble event content item matched with the first task type and based on the target time as an event content item matched with the first task type, wherein the event occurrence time corresponding to the preamble event content item is earlier than the target time.
According to a third aspect, or any implementation manner of the above third aspect, determining an index identity for an event content item from a content item identity of the event content item, comprises: according to the content item identification, determining search screening conditions aiming at target event content; in the recorded event sequence, index identifiers meeting the search screening condition are used as index identifiers for event content items.
According to a third aspect, or any implementation manner of the third aspect, a plurality of candidate event contents are stored in a record event sequence, a time sequence association relationship is provided among the plurality of candidate event contents, and the candidate event contents are acquired based on a trigger event in a terminal.
According to a third aspect, or any implementation manner of the above third aspect, the recording of the event sequence is based on: in response to detecting a trigger event for the data output item, obtaining candidate event content generated based on the trigger event; the candidate event content is stored according to the index identification indicated by the generation time of the candidate event content to obtain a recorded event sequence.
According to a third aspect, or any implementation manner of the third aspect, performing task execution based on the target event content to obtain a task execution result, including: taking the target event content and the current event content based on the target moment as state input data of a task to be executed; and executing the task based on the state input data to obtain a task execution result, wherein the event occurrence time corresponding to the current event content is the target time.
According to a third aspect, or any implementation manner of the above third aspect, the task to be performed includes at least one of a content prediction task, an information push task, and an object recommendation task.
In a fourth aspect, an embodiment of the present application provides an electronic device. The electronic device includes a memory and a processor coupled, the memory storing program instructions that, when executed by the processor, cause the electronic device to perform the steps of: determining a sample event content item matched with a second task type according to the second task type of the task to be trained; determining an index identification for the sample event content item based on a preset recorded event sequence; training sample data for a task to be trained is generated from the index identification and the sample tag associated with the sample event content item.
According to a fourth aspect, the sequence of recorded events is derived based on: in response to detecting a trigger event for the sample output item, obtaining candidate event content generated based on the trigger event; the candidate event content is stored according to the index identification indicated by the generation time of the candidate event content to obtain a recorded event sequence.
According to a fourth aspect, or any implementation manner of the fourth aspect, in response to detecting a trigger event for a sample output item, acquiring candidate event content generated based on the trigger event includes: and in response to detecting the labeling event and/or the overtime event for the sample output item, acquiring candidate event content generated based on the labeling event and/or the overtime event, wherein the overtime event comprises a specified event meeting a preset overtime trigger condition.
According to a fourth aspect, or any implementation manner of the above fourth aspect, training sample data for a task to be trained is generated according to an index identifier and a sample tag associated with a sample event content item, including: the index identification is used as data content in a sample data structure, and the data content and the sample label form training sample data.
According to a fourth aspect, or any implementation of the fourth aspect above, the computer program, when executed by the one or more processors, further causes the electronic device to perform the steps of: object operational feedback matching the sample event content item is determined and is used as a sample tag for the sample event content item, wherein the object operational feedback comprises positive operational feedback and negative operational feedback.
According to a fourth aspect, or any implementation manner of the fourth aspect, the task to be trained is implemented based on at least one of a content prediction model, an information push model and an object recommendation model to be trained.
Any implementation manner of the third aspect and any implementation manner of the third aspect corresponds to any implementation manner of the first aspect and any implementation manner of the first aspect, respectively. The technical effects corresponding to the third aspect and any implementation manner of the third aspect may be referred to the technical effects corresponding to the first aspect and any implementation manner of the first aspect, which are not described herein.
Any implementation manner of the fourth aspect and any implementation manner of the fourth aspect corresponds to any implementation manner of the second aspect and any implementation manner of the second aspect. Technical effects corresponding to any implementation manner of the fourth aspect may be referred to technical effects corresponding to any implementation manner of the second aspect and the fourth aspect, and are not described herein.
In a fifth aspect, embodiments of the present application provide a computer readable medium storing a computer program comprising instructions for performing the method of the first aspect or any of the possible implementations of the first aspect, or instructions for performing the method of the second aspect or any of the possible implementations of the second aspect.
In a sixth aspect, embodiments of the present application provide a computer program comprising instructions for performing the method of the first aspect or any of the possible implementations of the first aspect, or instructions for performing the method of the second aspect or any of the possible implementations of the second aspect.
In a seventh aspect, an embodiment of the present application provides a chip, where the chip includes a processing circuit and a transceiver pin. Wherein the transceiver pin and the processing circuit communicate with each other via an internal connection path, the processing circuit performing the method of the first aspect or any one of the possible implementations of the first aspect, or performing the method of the second aspect or any one of the possible implementations of the second aspect, to control the receiving pin to receive signals, to control the transmitting pin to transmit signals.
Drawings
Fig. 1 is a schematic diagram illustrating an application scenario;
FIG. 2 schematically illustrates a schematic diagram of a feature sub-table store;
FIG. 3 schematically illustrates a schematic diagram of a sample sub-table store;
fig. 4 is a schematic structural view of an exemplary electronic device;
FIG. 5 is a block diagram of a software architecture of an exemplary electronic device;
FIG. 6 is a schematic diagram of interaction between modules according to an embodiment of the present application;
FIG. 7 is a schematic diagram of interaction between modules according to an embodiment of the present application;
FIG. 8 is a schematic diagram illustrating a sample data processing procedure according to an embodiment of the present application;
FIG. 9 is a schematic diagram illustrating a sample data processing procedure according to an embodiment of the present application;
FIG. 10 is a schematic diagram of hierarchical storage of samples provided by an embodiment of the present application;
FIG. 11 is a schematic diagram of a task processing procedure according to an embodiment of the present application;
fig. 12 is a schematic structural diagram of an apparatus according to an embodiment of the present application.
Detailed Description
The following description of the embodiments of the present application will be made clearly and fully with reference to the accompanying drawings, in which it is evident that the embodiments described are some, but not all embodiments of the application. All other embodiments, which can be made by those skilled in the art based on the embodiments of the application without making any inventive effort, are intended to be within the scope of the application.
The term "and/or" is herein merely an association relationship describing an associated object, meaning that there may be three relationships, e.g., a and/or B, may represent: a exists alone, A and B exist together, and B exists alone.
The terms first and second and the like in the description and in the claims of embodiments of the application, are used for distinguishing between different objects and not necessarily for describing a particular sequential order of objects. For example, the first target object and the second target object, etc., are used to distinguish between different target objects, and are not used to describe a particular order of target objects.
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.
In the description of the embodiments of the present application, unless otherwise indicated, the meaning of "a plurality" means two or more. For example, the plurality of processing units refers to two or more processing units; the plurality of systems means two or more systems.
Referring to fig. 1, for example, in an information recommendation scenario, a trained recommendation algorithm model may be used to obtain a content recommendation result by using target event content as input state data of the recommendation algorithm model. The recommendation algorithm model can be trained based on sample event content.
Taking subway card recommendation as an example for explanation, target event content matched with a subway card recommendation task can be obtained, the target event content is used as input state data of a trained travel recommendation algorithm model, and subway card recommendation results are obtained and displayed. The target event content matched with the subway card recommendation task includes, for example, geographic position data, motion state data, wiFi connection state data, APP (Application) usage data and the like of the user terminal within a preset time period.
The sample event content utilized by the recommendation algorithm model training corresponds to the target event content utilized when performing the content recommendation task. In the process of training a recommendation algorithm model by using training sample data and executing a content recommendation task by using the trained recommendation algorithm model, the phenomena of high data storage consumption and high data redundancy exist.
Fig. 2 schematically illustrates a schematic diagram of feature sub-table storage, as shown in fig. 2, wiFi connection state data, motion state data, APP usage data, geographic position data and the like in the electronic device are collected, and the WiFi connection state data, the motion state data, the APP usage data, and the geographic position data are separately stored according to a data collection time sequence. For example, when the WiFi connection status data is stored separately, the storage item may include an ID, time, wiFi status, and the like, and the WiFi status includes a connection status and a disconnection status.
And when specific model training is carried out, acquiring the triggering time of the positive and negative samples, inquiring the characteristics required by the algorithm from each storage table based on the triggering time, and correlating the characteristics required by the algorithm to obtain training sample data for model training. For example, when the payment recommendation algorithm model is trained, the required characteristics of the algorithm can be queried from each storage table, and the required characteristics of the algorithm are associated to obtain training sample data for payment recommendation model training.
For example, in conducting payment recommendation model training, the trigger event for the sample output item may be a payment event detected in the electronic device, the sample output item constituting a feature required for the algorithm, the sample output item (i.e. the feature required for the algorithm) including, for example, wiFi connection status data, motion status data and APP usage data detected in the electronic device.
And according to the data category, the sample output items are separately stored in a sub-table. When training a specific model, the sample output items (namely the characteristics required by an algorithm) are independently sequenced, filtered and associated, so that the defects of large operation amount, high calculation time delay and low data processing efficiency exist, and the applicability is poor in a service expansion scene and a scene with more data accumulation.
Fig. 3 schematically illustrates a schematic diagram of a sample sub-table storage, as shown in fig. 3, for collecting WiFi connection status data, motion status data, APP usage data, geographical location data, etc. in an electronic device. And when the specific model is trained, correlating sample output items required by the model training in real time to obtain an independent sample library matched with the specific model.
For example, in conducting payment recommendation model training, the trigger event for the sample output item may be a payment event detected in the electronic device, and the sample output items required for model training may include, for example, wiFi connection state data, motion state data, and APP usage data. And correlating the sample output items in real time to obtain an independent sample library matched with the payment recommendation model.
Further exemplary, in performing travel recommendation model training, the trigger event for the sample output item may be a driving event detected in the electronic device, and the sample output item required for model training may include, for example, geographic position data, movement state data, and APP usage data. And correlating the sample output items in real time to obtain an independent sample library matched with the travel recommendation model.
In the process of training the multi-characteristic model, an independent sample library matched with each characteristic model is constructed, so that the defects of high data redundancy degree and large data volume are easily caused, and extra resource expenditure is generated in the scenes of data writing, external memory, cloning, aging and the like.
Fig. 4 is a schematic structural diagram of the electronic device 100. Optionally, the electronic device 100 may be referred to as a terminal, or may be referred to as a terminal device, and the specific product form may be an intelligent terminal, such as a product of a mobile phone, a tablet, a DV, a smart watch, a smart wearable device, a laptop, a notebook, a smart speaker, or the like. Specifically, the functional module related to the present application may be deployed on a DSP chip of a related device, and may specifically be an application program or software therein. A task processing function may be provided by software installation or upgrade, and by call coordination of hardware.
It should be understood that the electronic device 100 shown in fig. 4 is only one example of an electronic device, and that the electronic device 100 may have more or fewer components than shown in the figures, may combine two or more components, or may have different component configurations. The various components shown in fig. 4 may be implemented in hardware, software, or a combination of hardware and software, including one or more signal processing and/or application specific integrated circuits.
The electronic device 100 may include: processor 110, external memory interface 120, internal memory 121, universal serial bus (universal serial bus, USB) interface 130, charge management module 140, power management module 141, battery 142, antenna 1, antenna 2, mobile communication module 150, wireless communication module 160, audio module 170, sensor module 180, keys 190, motor 191, indicator 192, camera 193, display 194, subscriber identity module (subscriber identification module, SIM) card interface 195, and the like. The sensor module 180 may include a pressure sensor, a gyroscope sensor, an acceleration sensor, a temperature sensor, a motion sensor, a barometric sensor, a magnetic sensor, a distance sensor, a proximity sensor, a fingerprint sensor, a touch sensor, an ambient light sensor, a bone conduction sensor, etc.
The processor 110 may include one or more processing units, such as: the processor 110 may include 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 memory, a video codec, a digital signal processor (digital signal processor, DSP), a baseband processor and/or a neural Network Processor (NPU), etc. Wherein the different processing units may be separate devices or may be integrated in one or more processors.
The controller may be a neural hub and a command center of the electronic device 100, among others. The controller can generate operation control signals according to the instruction operation codes and the time sequence signals to finish the control of instruction fetching and instruction execution.
A memory may also be provided in the processor 110 for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory.
The USB interface 130 is an interface conforming to the USB standard specification, and may specifically be a Mini USB interface, a Micro USB interface, a USB Type C interface, or the like.
The charge management module 140 is configured to receive a charge input from a charger. The charger can be a wireless charger or a wired charger. The charging management module 140 may also supply power to the electronic device through the power management module 141 while charging the battery 142. The power management module 141 is used for connecting the battery 142, the charge management module 140 and the processor 110. The power management module 141 receives input from the battery 142 and/or the charge management module 140 and provides power to the processor 110, the internal memory 121, the external memory, the display 194, the camera 193, the wireless communication module 160, and the like.
The wireless communication function of the electronic device 100 may be implemented by the antenna 1, the antenna 2, the mobile communication module 150, the wireless communication module 160, a modem processor, a baseband processor, and the like.
The antennas 1 and 2 are used for transmitting and receiving electromagnetic wave signals. Each antenna in the electronic device 100 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 150 may provide a solution for wireless communication including 2G/3G/4G/5G, etc., applied to the electronic device 100. The mobile communication module 150 may include at least one filter, switch, power amplifier, low noise amplifier (low noise amplifier, LNA), etc.
The wireless communication module 160 may provide solutions for wireless communication including wireless local area network (wireless local area networks, WLAN) (e.g., wireless fidelity (wireless fidelity, wi-Fi) network), bluetooth (BT), global navigation satellite system (global navigation satellite system, GNSS), frequency modulation (frequency modulation, FM), near field wireless communication technology (near field communication, NFC), infrared technology (IR), etc., applied to the electronic device 100.
In some embodiments, antenna 1 and mobile communication module 150 of electronic device 100 are coupled, and antenna 2 and wireless communication module 160 are coupled, such that electronic device 100 may communicate with a network and other devices through wireless communication techniques.
The electronic device 100 implements display functions through a GPU, a display screen 194, an application processor, and the like. Processor 110 may include one or more GPUs that execute program instructions to generate or change display information.
The display screen 194 is used to display images, videos, and the like. The display 194 includes a display panel. In some embodiments, the electronic device 100 may include 1 or N display screens 194, N being a positive integer greater than 1.
The electronic device 100 may implement a photographing function through an ISP, a camera 193, a video codec, a GPU, a display screen 194, an application processor, and the like.
The ISP is used to process data fed back by the camera 193. For example, when photographing, the shutter is opened, light is transmitted to the camera photosensitive element through the lens, the optical signal is converted into an electrical signal, and the camera photosensitive element transmits the electrical signal to the ISP for processing, so that the electrical signal is converted into an image visible to naked eyes.
The camera 193 is used to capture still images or video. The object generates an optical image through the lens and projects the optical image onto the photosensitive element. The photosensitive element may be a charge coupled device (charge coupled device, CCD) or a Complementary Metal Oxide Semiconductor (CMOS) phototransistor. The photosensitive element converts the optical signal into an electrical signal, which is then transferred to the ISP to be converted into a digital image signal. The ISP outputs the digital image signal to the DSP for processing. The DSP converts the digital image signal into an image signal in a standard RGB, YUV, or the like format. In some embodiments, electronic device 100 may include 1 or N cameras 193, N being a positive integer greater than 1.
The camera 193 may be located in an edge area of the electronic device, may be an under-screen camera, or may be a liftable camera. Camera 193 may include a rear camera and may also include a rear camera. The specific position and shape of the camera 193 is not limited in the embodiment of the present application. The electronic device 100 may include one or more cameras of focal segments, e.g., cameras of different focal segments may include a tele camera, a wide camera, an ultra-wide camera, a panoramic camera, or the like.
The external memory interface 120 may be used to connect an external memory card, such as a Micro SD card, to enable expansion of the memory capabilities of the electronic device 100. The external memory card communicates with the processor 110 through an external memory interface 120 to implement data storage functions.
The internal memory 121 may be used to store computer executable program code including instructions. The processor 110 executes various functional applications of the electronic device 100 and data processing by executing instructions stored in the internal memory 121, for example, to cause the electronic device 100 to implement a task processing method in an embodiment of the present application. The internal memory 121 may include a storage program area and a storage data area. The storage program area may store an application program (such as a sound playing function, an image playing function, etc.) required for at least one function of the operating system, and the like. The storage data area may store data created during use of the electronic device 100 (e.g., audio data, phonebooks, etc.), and so on. In addition, the internal memory 121 may include a high-speed random access memory, and may further include a nonvolatile memory such as at least one magnetic disk storage device, a flash memory device, a universal flash memory (universal flash storage, UFS), and the like.
The electronic device 100 may implement audio functions through an audio module 170, an application processor, and the like. Such as music playing, recording, etc.
The audio module 170 is used to convert digital audio information into an analog audio signal output and also to convert an analog audio input into a digital audio signal. The audio module 170 may also be used to encode and decode audio signals. In some embodiments, the audio module 170 may be disposed in the processor 110, or a portion of the functional modules of the audio module 170 may be disposed in the processor 110.
Touch sensors, also known as "touch panels". The touch sensor may be disposed on the display screen 194, and the touch sensor and the display screen 194 form a touch screen, which is also referred to as a "touch screen". The touch sensor is used to detect a touch operation acting on or near it. The touch sensor may communicate the detected touch operation to the application processor to determine the touch event type. Visual output related to touch operations may be provided through the display 194.
The pressure sensor is used for sensing a pressure signal and can convert the pressure signal into an electric signal. In some embodiments, the pressure sensor may be provided on the display screen 194. The electronic device 100 may also calculate the location of the touch based on the detection signal of the pressure sensor.
The gyroscopic sensor may be used to determine a motion pose of the electronic device 100. In some embodiments, the angular velocity of electronic device 100 about three axes (i.e., x, y, and z axes) may be determined by a gyroscopic sensor.
The acceleration sensor may detect the magnitude of acceleration of the electronic device 100 in various directions (typically three axes). The acceleration sensor may detect the magnitude and direction of gravity when the electronic device 100 is stationary. The acceleration sensor can also be used for recognizing the gesture of the electronic equipment and is applied to applications such as switching of a transverse screen and a vertical screen, a pedometer and the like.
The keys 190 include a power key (or power key), a volume key, etc. The keys 190 may be mechanical keys. Or may be a touch key. The electronic device 100 may receive key inputs, generating key signal inputs related to user settings and function controls of the electronic device 100.
The software system of the electronic device 100 may employ a layered architecture, an event driven architecture, a microkernel architecture, a microservice architecture, or a cloud architecture. In the embodiment of the application, taking an Android system with a layered architecture as an example, a software structure of the electronic device 100 is illustrated.
Fig. 5 is a block diagram of a software architecture of the electronic device 100 according to an embodiment of the present application, where the layered architecture of the electronic device 100 divides the software into several layers, each layer having a distinct role and division of labor. The layers communicate with each other through a software interface. In some embodiments, the Android system is divided into five layers, from top to bottom, an application layer, an application framework layer, an Zhuoyun rows (Android run), a system library, a hardware abstraction layer (hardware abstraction layer, HAL), and a kernel layer, respectively.
The application layer may include a series of application packages, as shown in FIG. 5, which may include applications for cameras, maps, navigation, WLAN, bluetooth, payment applications, taxi taking applications, and the like.
The application framework layer provides an application programming interface (Application Programming Interface, API) and programming framework for application programs of the application layer, including various components and services to support the android development of the developer. The application framework layer includes a number of predefined functions. As shown in fig. 5, the application framework layer may include a view system, a window manager, a resource manager, a content provider, a notification manager, a camera service, a multimedia management module, and the like.
The window manager is used for managing window programs. The window manager may obtain the display screen size, determine if there is a status bar, lock the screen, intercept the screen, etc.
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 an application, and the display interface may be composed of one or more views, including for example, a view displaying a text notification icon, 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 information is used to inform of the completion of the download, message alerts, etc. The notification information may also be a notification in the form of a chart or scroll bar text appearing in the system top status bar, such as a notification of a background running application, or a notification appearing on the screen in the form of a dialog window. Such as prompting text messages in status bars, sounding prompts, vibrating electronic devices, flashing indicator lights, etc.
The content recommendation service may obtain a sequence of recorded events by recording user operations, system events, sensor state data, network state data, etc. in the electronic device. Based on the recorded event sequence, multi-feature services such as content prediction, information pushing and object recommendation are provided for users.
The system layer includes a system library and Android Runtime (Android run time). The system library may include a plurality of functional modules, such as a browser kernel, a 3D graphics library (e.g., openGL ES), a font library, and the like. The browser kernel is responsible for interpreting the web page language (e.g., one application HTML, javaScript in standard generic markup language) and rendering (displaying) the web page. The 3D graphics library is used for realizing three-dimensional graphics drawing, image rendering, synthesis, layer processing and the like. The font library is used for realizing the input of different fonts. The android runtime comprises a core library and a virtual machine, and is responsible for scheduling and management of an android system. The core library consists of two parts: one part is a function which needs to be called by java language, and the other part is a core library of android. The application program layer and the application program framework layer run in the virtual machine, and the virtual machine executes java files of the application program layer and the application program framework layer into binary files. The virtual machine is used for executing the functions of object life cycle management, stack management, thread management, security and exception management, garbage collection and the like.
It is to be understood that the components contained in the system framework layer, the system library, and the runtime layer shown in fig. 5 do not constitute a specific limitation on the electronic device 100. In other embodiments of the application, electronic device 100 may include more or fewer components than shown, or certain components may be combined, or certain components may be split, or different arrangements of components.
The HAL layer is an interface layer between the operating system kernel and the hardware circuitry. The HAL layer includes, for example, an Audio hardware abstraction layer (Audio HAL), a Camera hardware abstraction layer (Camera HAL), and the like. The Audio HAL is used for processing the Audio stream, such as noise reduction, directional enhancement and the like, and the Camera HAL is used for processing the image stream.
The kernel layer is a layer between the hardware and the software layers described above. The kernel layer at least comprises a display driver, a camera driver, an audio driver and a sensor driver. The hardware may include cameras, displays, microphones, processors, memory, and the like.
Fig. 6 is a schematic diagram showing interaction of each module, and as shown in fig. 6, event data generated at a device side is collected by a data collection module of a perception center, where the event data includes, for example, a system event, a service event, a resource usage record, sensor data generated in an electronic device. In addition, third party contribution data is collected by the data collection module of the perception center, which may be data provided by a third party application, including, for example, event data generated based on application start events, application switch events, application usage records, application close events, and the like.
The data center includes a data access service, a data storage service, and a data query service. And caching the event data and the third-party contribution data to a real-time data pipeline in the data storage service through a data shunt caching module in the data access service. And determining index identification aiming at corresponding data according to the generation time of the event data and the third-party contribution data by a persistence policy module in the data storage service, and storing the event data and the third-party contribution data in a high-performance storage architecture in an index storage mode to obtain a recorded event sequence. After indexing the data in the real-time data pipeline, the event data and third party contribution data stored in an indexed manner may be memory aged in a high-performance storage architecture. In addition, the real-time data pipeline may free up window buffering to continue buffering event data newly acquired by the data acquisition module.
The learning middle station comprises a model training module and a content prediction module. The model training module is used for carrying out model training based on training sample data, wherein the training sample data is obtained based on event data and third party contribution data acquired by the data acquisition module. The content prediction module is used for performing content prediction based on target event content, wherein the target event content is obtained based on the event data collected by the data collection module and the third party contribution data.
When the characteristic model is trained by the model training module, the model training module initiates a data query request about training sample data to a query engine through a data query interface in a data query service. The index identification of the sample event content item matched with the model to be trained is determined by the query engine based on the recorded event sequence stored in the high-performance storage architecture according to the model type of the model to be trained. The index identification is used as data content in a sample data structure, and the data content and the sample label form training sample data. And the query engine returns training sample data matched with the model to be trained to the data query interface, and the training sample data is returned to the model training module through the data query interface so as to perform characteristic model training by using the training sample data.
The content prediction module initiates a data query request regarding the content of the target event to the query engine via a data query interface in the data query service while the prediction task is performed by the content prediction module. The index identification of the event content item matched with the task to be executed is determined by the query engine based on the recorded event sequence stored in the high-performance storage architecture according to the task type of the task to be executed. The event content indicated by the index identification is screened in the recorded event sequence by the query engine as target event content matched with the task to be executed. And returning the target event content matched with the task to be executed to a data query interface by the query engine, and returning the target event content to the content prediction module through the data query interface so that the content prediction module executes the content prediction task based on the target event content.
Fig. 7 is a schematic diagram showing interaction between each module, and as shown in fig. 7, event data generated at the device side is collected by a data collection module, where the event data includes, for example, system events, service events, resource usage records, sensor data, and the like generated in an electronic device, and the resource usage records include, for example, usage records of various resources such as virtual machines, networks, servers, storage, applications, services, containers, and the like in a resource pool.
And carrying out data standardization processing on the collected event data through a data standardization module, and caching the processed event data to a real-time data pipeline according to an enqueuing strategy, wherein the real-time data pipeline is used as a window caching module and can be used for adding the event data generated by the equipment side. The data normalization processing includes, for example, normalization, min-max normalization, and z-score normalization, and this embodiment is not limited thereto.
Training sample data for model training is generated by a data correlation module based on event data cached in the real-time data pipeline. As shown in fig. 8, which is a schematic diagram of a sample data processing process, as shown in fig. 8, the sample data processing process includes the following operations:
And S1, determining a sample event content item matched with the second task type according to the second task type of the task to be trained by the data association module.
For example, in the case that the task to be trained is a model to be trained, the model type of the model to be trained constitutes a second task type, and the sample event content item matching the model to be trained is determined. The model to be trained can comprise a content prediction model to be trained, an information push model, an object recommendation model and the like.
And S2, the data association module determines index identification aiming at the sample event content item based on a preset recorded event sequence.
Illustratively, the sequence of recorded events is based on the following operations: the data association module obtains candidate event content generated based on the trigger event from the real-time data pipeline in response to detecting the trigger event for the sample output item. The data association module stores the candidate event content in a high performance storage architecture according to an index identification indicated by a time of generation of the candidate event content to obtain a sequence of recorded events.
The data association module obtains candidate event content generated based on the trigger event in response to detecting the trigger event for the sample output item. The triggering event may include, for example, a system event detected in the electronic device, a business event, a user operation event, and so forth. The event type of the triggering event may include, for example, a labeling event and/or a timeout event, where the timeout event includes a specified event that satisfies a preset timeout triggering condition, and the labeling event includes a preset specified event detected in the electronic device, and may be, for example, a driving event detected in the electronic device, a payment event, a WiFi connection switching event, a geographic location change event, a motion state switching event, a hardware information uploading event, a sensor data uploading event, a screen lighting event, a connection base station, and so on.
In one possible implementation, in response to detecting a labeling event and/or a timeout event for a sample output item, candidate event content generated based on the labeling event and/or the timeout event is obtained. The timeout trigger condition is used to determine whether a timeout event is triggered, and may include, for example, a timeout time threshold, a timeout number threshold, and the like. Taking a payment scenario as an example, when the user does not complete payment within the timeout time threshold, determining that the payment timeout event is triggered, and acquiring candidate event content generated based on the payment timeout event.
And storing the candidate event content in a high-performance storage architecture by an index storage mode according to the index identification indicated by the generation time of the candidate event content to obtain a recorded event sequence. The record event sequence stores a plurality of candidate event contents, and the plurality of candidate event contents have time sequence association relations. The index identification for the candidate event content may indicate a time of generation of the corresponding event content, e.g., the smaller the index identification, the earlier the time of generation of the corresponding event content.
With continued reference to fig. 7, the data correlation module determines a trigger event for the sample output item based on the service identification of the target service. The sample output item and the target service have a preset mapping relation, as shown in fig. 7, and the target service includes, for example, service a, service B, and the like. In response to detecting a trigger event for a sample output item in the real-time data pipeline, the data association module may extract event data matching the sample output item from the real-time data pipeline as candidate event content, thereby establishing a data association between the target service and the candidate event content. The trigger event for the sample output item may include, for example, a labeling event and/or a timeout event, and the data correlation module may extract event data generated based on the trigger event from the real-time data pipeline as candidate event content.
The data association module determines index identification aiming at the candidate event content according to the generation time of the candidate event content, and stores the candidate event content in a high-performance storage architecture in an index storage mode to obtain a recorded event sequence. After indexing candidate event content in the real-time data pipeline, the indexed candidate event content may be memory aged in a high performance storage architecture. In addition, the real-time data pipeline may free up window buffering to continue buffering event data newly acquired by the data acquisition module.
And S3, the data association module generates training sample data aiming at the task to be trained according to the index identification and the sample label associated with the sample event content item.
The data association module generates training sample data for a task to be trained based on the sequence of recorded events, according to the index identification and the sample tag associated with the sample event content item. In one example manner, the data association module determines an index identification associated with a sample event content item based on a sequence of recorded events. And under the condition that the number of the sample event content items is more than one, correlating index identifiers correlated with each sample event content item to obtain correlated sample index data.
In addition, the data association module may further determine object operation feedback matching the sample event content item from the real-time data pipeline, and use the object operation feedback as a sample tag for the sample event content item, where the object operation feedback may include positive operation feedback and negative operation feedback.
For example, in the case where the model to be trained is a travel recommendation model, the sample event content item includes, for example, geographic position data, movement state data, and APP usage data detected in the electronic device, and the object operation feedback matching the sample event content item includes whether the user adopts a travel recommendation result. Under the condition that the user adopts a travel recommendation result, the object operation feedback is forward operation feedback; and under the condition that the user does not adopt the travel recommendation result, the object operation feedback is negative operation feedback.
The sample label and the associated sample index data may constitute training sample data for a task to be trained. In one possible implementation, the sequence of recorded events is stored by the physical layer, the training sample data is stored by the logical layer, which may be a logical module in the software system of the electronic device that performs a specific function, and the logical layer may mask the underlying complex data storage structure.
Referring to fig. 7, upon performing a particular model training (e.g., including an a-algorithm training, a B-algorithm training, etc.), a data correlation module may be utilized to determine sample event content items that match the model to be trained. Training sample data for model training is generated based on a recorded event sequence stored in a high-performance storage architecture from an index identification and a sample tag associated with a sample event content item using a data association module. For example, the index identity (which may be an index value, for example) may be populated as the data content of the sample data structure, resulting in training sample data. In addition, sample persistence can be performed on training sample data in a high-performance storage architecture, so that a training sample library matched with a model to be trained is obtained.
The collected candidate event content and the training sample data for model training are subjected to hierarchical index storage, so that the storage resource consumption of the training sample data can be effectively reduced, the data redundancy degree of the training sample data can be effectively reduced, and the method is well applicable to multi-characteristic model training under a service expansion scene and a scene with more data accumulation.
As shown in fig. 9, which is a schematic diagram of a sample data processing process, as shown in fig. 9, the sample data processing process may include the following operations:
S101, a service module initiates a session request beginSampleSession () for creating a sample to a central control module.
And the service module initiates a session request for creating a sample to the central control module according to the model type of the model to be trained. Model types of the model to be trained can include, for example, a content prediction model, an information push model, an object recommendation model, and the like.
S102, the central control module initiates a sample record request register () to the persistence policy module.
S103, the persistence policy module creates a session of one sample storage based on the sample record request register ().
S104, the service module initiates a request queryItemData () for inquiring the sample data item to the central control module.
The sample data item may be, for example, a sample event content item that matches the model to be trained.
S105, the central control module transmits a query request query () to the query management module.
S106, the query management module initiates a data item query request dataItemquery () to the Pipeline cache module.
S107, the Pipeline caching module fills indexes for the referenced sample data items.
The Pipeline buffer module may fill the index identifier corresponding to the generation time as the index of the sample data item according to the generation time of the sample event content corresponding to the sample data item.
S108, the query management module initiates a sample feature addition request addFeatureRef () to the high-performance sample library.
S109, the high-performance sample library judges whether the sample data item can be used as a library-falling feature, and after the sample data item is determined to be used as the library-falling feature, the high-performance sample library stores the sample data item according to a sample storage session created by the persistence policy module.
For example, in the case where the sample data item is a sample event content item that matches the model to be trained, the high performance sample library determines that the sample data item can be a library-falling feature. For sample data items of a falling library, the high-performance sample library persistently stores the sample data items and sample event content corresponding to the sample data items.
Referring to fig. 9, in the case where a sample tag exists, the sample data processing process may further include the operations of:
s1010, the business module sends a label quotation request appdLable () to the central control module.
For example, the sample tag for the sample data item may be an object operational feedback matching the sample data item, which may be, for example, an operational feedback result of the user on the recommended content provided by the business module, which may include positive operational feedback and negative operational feedback.
S1011, the central control module initiates a tag identification request (identification table) to the persistence policy module.
S1012, a persistence policy module initiates a label update session updata lable ().
S1013, the persistence policy module initiates a sample serialization request serialisation sample () to the high-performance sample library module, and the high-performance sample library module stores the updated sample tag to the sample library.
Referring to fig. 9, in a scenario where there is no sample tag, the sample data processing procedure may further include the following operations:
s1014, the service module initiates an end session request endSession () to the central control module.
S1015, the central control module initiates an end session request endSession () to the persistence policy module.
S1016, the persistence policy module initiates a sample serialization request serialisation sample () to the high-performance sample library module, and the high-performance sample library module stores the updated sample tag to the sample library.
FIG. 10 schematically illustrates a schematic diagram of sample hierarchical storage, as shown in FIG. 10, in response to detecting a trigger event for a sample output item, candidate event content generated based on the trigger event is acquired. The sample output items may include, for example, wiFi connection status detected in the electronic device, motion status data (msdp), APP usage data (activity), geographic location data (location), and the like.
And acquiring candidate event contents generated based on the trigger event, and determining index identification aiming at the candidate event contents according to the generation time of the candidate event contents. The candidate event content is stored in the recorded event sequence according to the index identification for the candidate event content. Multiple candidate event contents can be stored in the recorded event sequence, and the multiple candidate event contents have time sequence association relations. The recorded event sequence is stored in the physical layer in an index mode, so that the storage space consumption of the recorded event sequence can be effectively reduced.
For example, the candidate event content corresponding to "WiFi connection status" includes
{ "WifiRssi":66, "WifiLevel":3, "timestamp":1658713806697, "longitude":171.40162, "geodetic System …" }, the index for the candidate event content is identified as 1.
The candidate event content corresponding to the motion state data comprises
{ "content": { "eventType":2, "confidence":1, "timestamp":1658713737683, "status": micro_walk … "}, the index for the candidate event content is identified as 3.
The index identification indicates the timing of generation of candidate event content. Illustratively, the smaller the index identification, the earlier the generation of candidate event content.
As a possible implementation manner, the current event content based on the target time is acquired, and the current event content is stored in the context event sequence table in an index manner. The generation time of the current event content is the target time, and the smaller the index mark is, the earlier the generation time of the current event content is. As shown in fig. 6, the index identification of the current event content includes, for example, 15, 16, …. When training a specific model, the matched candidate event content can be used as a preamble event sequence, the preamble event sequence and the current event content based on the target moment are used as state input data of the model to be trained, and the specific model is trained based on the state input data.
And when training a specific model, carrying out sample inquiry according to the model type of the model to be trained, determining a sample event content item matched with the model to be trained, and correlating candidate event contents corresponding to the sample event content item in an index mode to obtain training sample data for training the model. In the case that the current event content based on the target moment is required to be used as the state input data of the model to be trained, the current event content is associated with the sample event content in an index mode, and training sample data for model training is obtained.
For example, when the payment recommendation model is trained, the sample event content item matched with the payment recommendation model includes WiFi connection status data, motion status data and APP usage data, the index identifier of the candidate event content corresponding to the WiFi connection status data includes 1, 8 and …, the index identifier of the candidate event content corresponding to the motion status data includes 3, 9 and …, and the index identifier of the candidate event content corresponding to the APP usage data includes 2, 10 and …. When the payment recommendation model is trained, the current event content based on the target moment is required to be used as state input data of the model to be trained, namely, the current event content, namely, the context event content, and the index identification of the context event content comprises 2, 15 and ….
For another example, when the travel recommendation model is trained, the sample event content item matched with the travel recommendation model includes geographic position data, motion state data and APP usage data, the index identifier of the candidate event content corresponding to the geographic position data includes 11, 15 and …, the index identifier of the candidate event content corresponding to the motion state data includes 3, 9 and …, and the index identifier of the candidate event content corresponding to the APP usage data includes 2, 10 and …. When the travel recommendation model is trained, the current event content based on the target moment is required to be used as state input data of the model to be trained, namely the current event content, namely the context event content, and the index identification of the context event content comprises 2, 15 and ….
Fig. 11 is a schematic diagram showing a task processing procedure, in which, by determining an event content item matching a task to be processed, a target event content for task processing is determined according to an index identification for the event content item. Under the condition that the number of tasks to be processed is large, the consumption of storage resources of target event content can be effectively reduced, and the data redundancy degree and the data processing resource cost in the task execution process can be reduced.
As shown in fig. 11, the task processing procedure includes the following operations:
s4: and determining the event content item matched with the first task type according to the first task type of the task to be executed.
By way of example, the tasks to be performed may include, for example, a content prediction task, an information push task, an object recommendation task, and the like. And determining the event content item matched with the first task type according to the first task type of the task to be executed. For example, in the case where the task to be performed is a payment recommendation task, the event content items that match the payment recommendation task may include, for example, wiFi connection status data, sports status data, and APP usage data.
In one possible implementation manner, a target time-based preamble event content item matched with the first task type is determined as an event content item matched with a task to be executed, where an event occurrence time corresponding to the preamble event content item is earlier than a target time, and the target time may be, for example, a current time when the task is executed.
S5: an index identification for the event content item is determined from the content item identification of the event content item.
Illustratively, the index identification for the event content item is determined from the content item identification of the event content item. Illustratively, a search screening condition for the target event content may be determined based on the content item identification, and an index identification satisfying the search screening condition in the recorded event sequence may be used as the index identification for the event content item.
The recorded event sequence stores a plurality of candidate event contents, the plurality of candidate event contents have time sequence association relations, and the candidate event contents are acquired based on triggering events in the terminal. For example, the recorded event sequence includes candidate event content 1 generated at time t1, candidate event content 2 generated at time t2, … …, and candidate event content n generated at time tn, where n is an integer greater than 2. Each candidate event content in the recorded event sequence has a corresponding index identifier indicating a time of generation of the candidate event content. For example, the smaller the index identification, the earlier the generation time of the corresponding candidate event content.
Search screening conditions for target event content may include, for example, content screening conditions, time screening conditions, format screening conditions, and the like. Content screening conditions, such as content items for screening candidate event content, time screening conditions, such as generation moments for screening candidate event content, and format screening conditions, such as data formats for screening candidate event content. In the recorded event sequence, index identifiers meeting the search screening condition are used as index identifiers for event content items.
S6: candidate event content indicated by the index identification is screened in the recorded event sequence to serve as target event content matched with the task to be executed.
Illustratively, candidate event content indicated by the index identification is filtered as target event content matching the task to be performed based on the recorded event sequence, the target event content corresponding to, for example, a target time-based preamble event content item.
S7: and executing the task based on the target event content to obtain a task execution result.
And executing the task based on the target event content to obtain a task execution result. The target event content is taken as a preamble event sequence of the task to be executed, the preamble event sequence and the current event content based on the target moment are taken as state input data of the task to be executed, and task execution is performed based on the state input data, so that a task execution result is obtained. The event occurrence time corresponding to the target event content (i.e. the preamble event sequence) is earlier than the target time, and the event occurrence time corresponding to the current event content is the target time.
For example, when recommending a travel mode, the current time when the travel recommendation task is executed may be taken as the target time, and the precursor event sequence and the current event content based on the current time are taken as the state input data of the travel recommendation model, so as to obtain the travel recommendation result. The preamble event sequence includes, for example, wiFi connection status data, APP usage data, geographical location data, etc. within a preset period of time before the current time detected in the electronic device, and the current event content includes, for example, wiFi connection status data, APP usage data, geographical location data, etc. detected in the electronic device based on the current time.
It will be appreciated that the electronic device, in order to achieve the above-described functions, includes corresponding hardware and/or software modules that perform the respective functions. The present application can be implemented in hardware or a combination of hardware and computer software, in conjunction with the example algorithm steps described in connection with the embodiments disclosed herein. Whether a function is implemented as hardware or computer software driven hardware depends upon the particular application and design constraints imposed on the solution. Those skilled in the art may implement the described functionality using different approaches for each particular application in conjunction with the embodiments, but such implementation decisions should not be interpreted as causing a departure from the scope of the present application.
In one example, a schematic block diagram apparatus 1200 of an apparatus 1200 illustrating an embodiment of the application, fig. 12 may include: the processor 1201 and transceiver/transceiving pin 1202, optionally, also include a memory 1203.
The various components of the apparatus 1200 are coupled together by a bus 1204, where the bus 1204 includes a power bus, a control bus, and a status signal bus in addition to a data bus. For clarity of illustration, the various buses are referred to in the figures as bus 1204.
Alternatively, the memory 1203 may be used for instructions in the foregoing method embodiments. The processor 1201 may be configured to execute instructions in the memory 1203 and control the receive pins to receive signals and the transmit pins to transmit signals.
The apparatus 1200 may be an electronic device or a chip of an electronic device in the above-described method embodiments.
All relevant contents of each step related to the above method embodiment may be cited to the functional description of the corresponding functional module, which is not described herein.
The present embodiment also provides a computer storage medium having stored therein computer instructions that, when executed on an electronic device, cause the electronic device to execute the above-described related method steps to implement the camera invoking method in the above-described embodiments.
The present embodiment also provides a computer program product which, when run on a computer, causes the computer to perform the above-described relevant steps to implement the camera invoking method in the above-described embodiments.
In addition, embodiments of the present application also provide an apparatus, which may be embodied as a chip, component or module, which may include a processor and a memory coupled to each other; the memory is used for storing computer execution instructions, and when the device runs, the processor can execute the computer execution instructions stored in the memory so that the chip executes the camera calling method in the method embodiments.
The electronic device, the computer storage medium, the computer program product, or the chip provided in this embodiment are used to execute the corresponding methods provided above, so that the beneficial effects thereof can be referred to the beneficial effects in the corresponding methods provided above, and will not be described herein.
It will be appreciated by those skilled in the art 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 modules or units is merely a logical function 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 shown 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.
Any of the various embodiments of the application, as well as any of the same embodiments, may be freely combined. Any combination of the above is within the scope of the application.
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 may be essentially or a part contributing to the prior art or all or part of the technical solution may be embodied in the form of a software product stored in a storage medium, including several instructions for causing a device (may be a single-chip microcomputer, a chip or the like) or a processor (processor) to perform all or part of the steps of the methods of the embodiments of the present application. And the aforementioned 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, or an optical disk, or other various media capable of storing program codes.
The embodiments of the present application have been described above with reference to the accompanying drawings, but the present application is not limited to the above-described embodiments, which are merely illustrative and not restrictive, and many forms may be made by those having ordinary skill in the art without departing from the spirit of the present application and the scope of the claims, which are to be protected by the present application.
The steps of a method or algorithm described in connection with the present disclosure may be embodied in hardware, or may be embodied in software instructions executed by a processor. The software instructions may be comprised of corresponding software modules that may be stored in random access Memory (Random Access Memory, RAM), flash Memory, read Only Memory (ROM), erasable programmable Read Only Memory (Erasable Programmable ROM), electrically Erasable Programmable Read Only Memory (EEPROM), registers, hard disk, a removable disk, a compact disc Read Only Memory (CD-ROM), or any other form of storage medium known in the art. An exemplary storage medium is coupled to the processor such the processor can read information from, and write information to, the storage medium. In the alternative, the storage medium may be integral to the processor. The processor and the storage medium may reside in an ASIC.
Those skilled in the art will appreciate that in one or more of the examples described above, the functions described in the embodiments of the present application may be implemented in hardware, software, firmware, or any combination thereof. When implemented in software, these functions may be stored on or transmitted over as one or more instructions or code on a computer-readable medium. Computer-readable media includes both computer storage media and communication media including any medium that facilitates transfer of a computer program from one place to another. A storage media may be any available media that can be accessed by a general purpose or special purpose computer.
The embodiments of the present application have been described above with reference to the accompanying drawings, but the present application is not limited to the above-described embodiments, which are merely illustrative and not restrictive, and many forms may be made by those having ordinary skill in the art without departing from the spirit of the present application and the scope of the claims, which are to be protected by the present application.

Claims (21)

1. A method of task processing, comprising:
Determining event content items matched with a first task type according to the first task type of a task to be executed;
determining an index identification for the event content item according to the content item identification of the event content item;
screening candidate event content indicated by the index identifier from a recorded event sequence to serve as target event content matched with the task to be executed;
performing task execution based on the target event content through a trained model corresponding to the task to be executed to obtain a task execution result; the data content of the training sample corresponding to the trained model is an index identifier, and the index identifier is used for extracting sample event content corresponding to the model from the recorded event sequence during model training so as to complete model training;
wherein the sequence of recorded events is based on:
in response to detecting a trigger event for a data output item, obtaining candidate event content generated based on the trigger event;
storing the candidate event content according to an index identifier indicated by the generation moment of the candidate event content so as to obtain the recorded event sequence; the candidate event content comprises at least one of Wi-Fi connection state data, motion state data, APP use data and geographic position data;
The index in the recorded event sequence identifies training samples for generating a plurality of models respectively corresponding to different tasks to be performed.
2. The method of claim 1, wherein the determining, based on a first task type of a task to be performed, an event content item that matches the first task type comprises:
determining a target time-based preamble event content item matching the first task type as an event content item matching the first task type,
and the event occurrence time corresponding to the preamble event content item is earlier than the target time.
3. The method of claim 1, wherein the determining an index identification for the event content item based on the content item identification of the event content item comprises:
determining search screening conditions for the target event content according to the content item identification;
and in the recorded event sequence, the index identification meeting the search screening condition is used as the index identification aiming at the event content item.
4. A method according to any one of claim 1 to 3, wherein,
the recorded event sequence stores a plurality of candidate event contents, the plurality of candidate event contents have time sequence association relations, and the candidate event contents are acquired based on triggering events in the terminal.
5. The method according to claim 2, wherein performing task execution based on the target event content to obtain a task execution result comprises:
taking the target event content and the current event content based on the target moment as state input data of the task to be executed;
performing task execution based on the state input data to obtain a task execution result,
and the event occurrence time corresponding to the current event content is the target time.
6. The method of claim 1, wherein the task to be performed comprises at least one of a content prediction task, an information push task, and an object recommendation task.
7. A method of processing sample data, comprising:
determining a sample event content item matched with a second task type according to the second task type of the task to be trained;
determining an index identification for the sample event content item based on a preset recorded event sequence;
the index mark is used as data content in a sample data structure, and the data content and a sample label are stored to obtain training sample data;
Wherein, when the training sample data is used for model training, the index identifier is used for extracting sample event content corresponding to a model from the recorded event sequence to complete model training;
wherein the sequence of recorded events is based on:
in response to detecting a trigger event for a sample output item, obtaining candidate event content generated based on the trigger event;
storing the candidate event content according to an index identifier indicated by the generation moment of the candidate event content so as to obtain the recorded event sequence; the candidate event content comprises at least one of Wi-Fi connection state data, motion state data, APP use data and geographic position data;
the index in the recorded event sequence identifies training sample data for generating a plurality of models respectively corresponding to different tasks to be trained.
8. The method of claim 7, wherein the acquiring candidate event content generated based on the trigger event in response to detecting the trigger event for the sample output item comprises:
in response to detecting a labeling event and/or a timeout event for a sample output item, obtaining candidate event content generated based on the labeling event and/or the timeout event,
The timeout event comprises a specified event meeting a preset timeout triggering condition.
9. The method as recited in claim 7, further comprising:
determining object operational feedback matching the sample event content item and regarding the object operational feedback as a sample tag for the sample event content item,
wherein the subject operational feedback includes positive operational feedback and negative operational feedback.
10. The method according to any one of claims 7 to 9, wherein the task to be trained is implemented based on at least one of a content prediction model, an information push model and an object recommendation model to be trained.
11. An electronic device, comprising: one or more processors, memory, and one or more computer programs, wherein the one or more computer programs are stored on the memory, which when executed by the one or more processors, cause the electronic device to perform the steps of:
determining event content items matched with a first task type according to the first task type of a task to be executed;
determining an index identification for the event content item according to the content item identification of the event content item;
Screening candidate event content indicated by the index identifier from a recorded event sequence to serve as target event content matched with the task to be executed;
performing task execution based on the target event content through a trained model corresponding to the task to be executed to obtain a task execution result; the data content of the training sample corresponding to the trained model is an index identifier, and the index identifier is used for extracting sample event content corresponding to the model from the recorded event sequence during model training so as to complete model training;
wherein the sequence of recorded events is based on:
in response to detecting a trigger event for a data output item, obtaining candidate event content generated based on the trigger event;
storing the candidate event content according to an index identifier indicated by the generation moment of the candidate event content so as to obtain the recorded event sequence; the candidate event content comprises at least one of Wi-Fi connection state data, motion state data, APP use data and geographic position data;
the index in the recorded event sequence identifies training samples for generating a plurality of models respectively corresponding to different tasks to be performed.
12. The apparatus of claim 11, wherein the determining, based on a first task type of a task to be performed, an event content item that matches the first task type comprises:
determining a target time-based preamble event content item matching the first task type as an event content item matching the first task type,
and the event occurrence time corresponding to the preamble event content item is earlier than the target time.
13. The apparatus of claim 11, wherein the determining an index identification for the event content item based on the content item identification of the event content item comprises:
determining search screening conditions for the target event content according to the content item identification;
and in the recorded event sequence, the index identification meeting the search screening condition is used as the index identification aiming at the event content item.
14. The apparatus according to any one of claims 11 to 13, wherein,
the recorded event sequence stores a plurality of candidate event contents, the plurality of candidate event contents have time sequence association relations, and the candidate event contents are acquired based on triggering events in the terminal.
15. The apparatus of claim 12, wherein performing task execution based on the target event content to obtain a task execution result comprises:
taking the target event content and the current event content based on the target moment as state input data of the task to be executed;
performing task execution based on the state input data to obtain a task execution result,
and the event occurrence time corresponding to the current event content is the target time.
16. The apparatus of claim 11, wherein the task to be performed comprises at least one of a content prediction task, an information push task, and an object recommendation task.
17. An electronic device, comprising: one or more processors, memory, and one or more computer programs, wherein the one or more computer programs are stored on the memory, which when executed by the one or more processors, cause the electronic device to perform the steps of:
determining a sample event content item matched with a second task type according to the second task type of the task to be trained;
Determining an index identification for the sample event content item based on a preset recorded event sequence;
the index mark is used as data content in a sample data structure, and the data content and a sample label are stored to obtain training sample data;
wherein, when the training sample data is used for model training, the index identifier is used for extracting sample event content corresponding to a model from the recorded event sequence to complete model training;
wherein the sequence of recorded events is based on:
in response to detecting a trigger event for a sample output item, obtaining candidate event content generated based on the trigger event;
storing the candidate event content according to an index identifier indicated by the generation moment of the candidate event content so as to obtain the recorded event sequence; the candidate event content comprises at least one of Wi-Fi connection state data, motion state data, APP use data and geographic position data;
the index in the recorded event sequence identifies training sample data for generating a plurality of models respectively corresponding to different tasks to be trained.
18. The apparatus of claim 17, wherein the obtaining candidate event content generated based on the trigger event in response to detecting the trigger event for the sample output item comprises:
In response to detecting a labeling event and/or a timeout event for a sample output item, obtaining candidate event content generated based on the labeling event and/or the timeout event,
the timeout event comprises a specified event meeting a preset timeout triggering condition.
19. The device of claim 17, wherein the computer program, when executed by the one or more processors, further causes the electronic device to:
determining object operational feedback matching the sample event content item and regarding the object operational feedback as a sample tag for the sample event content item,
wherein the subject operational feedback includes positive operational feedback and negative operational feedback.
20. The apparatus according to any one of claims 17 to 19, wherein the task to be trained is implemented based on at least one of a content prediction model, an information push model, and an object recommendation model to be trained.
21. A computer readable storage medium comprising a computer program which, when run on an electronic device, causes the electronic device to perform the task processing method of any one of claims 1 to 6 or to perform the sample data processing method of any one of claims 7 to 10.
CN202310258100.3A 2023-03-17 2023-03-17 Task processing method, sample data processing method and electronic equipment Active CN116048765B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310258100.3A CN116048765B (en) 2023-03-17 2023-03-17 Task processing method, sample data processing method and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310258100.3A CN116048765B (en) 2023-03-17 2023-03-17 Task processing method, sample data processing method and electronic equipment

Publications (2)

Publication Number Publication Date
CN116048765A CN116048765A (en) 2023-05-02
CN116048765B true CN116048765B (en) 2023-09-01

Family

ID=86133420

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310258100.3A Active CN116048765B (en) 2023-03-17 2023-03-17 Task processing method, sample data processing method and electronic equipment

Country Status (1)

Country Link
CN (1) CN116048765B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116561185B (en) * 2023-07-11 2023-11-24 荣耀终端有限公司 Data processing method, system and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107665710A (en) * 2016-07-27 2018-02-06 上海博泰悦臻网络技术服务有限公司 Mobile terminal sound data processing method and device
CN109815980A (en) * 2018-12-18 2019-05-28 北京三快在线科技有限公司 Prediction technique, device, electronic equipment and the readable storage medium storing program for executing of user type
CN112214636A (en) * 2020-09-21 2021-01-12 华为技术有限公司 Audio file recommendation method and device, electronic equipment and readable storage medium
WO2022100221A1 (en) * 2020-11-16 2022-05-19 Oppo广东移动通信有限公司 Retrieval processing method and apparatus, and storage medium

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107665710A (en) * 2016-07-27 2018-02-06 上海博泰悦臻网络技术服务有限公司 Mobile terminal sound data processing method and device
CN109815980A (en) * 2018-12-18 2019-05-28 北京三快在线科技有限公司 Prediction technique, device, electronic equipment and the readable storage medium storing program for executing of user type
CN112214636A (en) * 2020-09-21 2021-01-12 华为技术有限公司 Audio file recommendation method and device, electronic equipment and readable storage medium
WO2022100221A1 (en) * 2020-11-16 2022-05-19 Oppo广东移动通信有限公司 Retrieval processing method and apparatus, and storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
基于事件通知服务的RFID数据处理框架;梁昌勇等;《计算机技术与发展》;第19卷(第8期);第74-81页 *

Also Published As

Publication number Publication date
CN116048765A (en) 2023-05-02

Similar Documents

Publication Publication Date Title
WO2020168929A1 (en) Method for identifying specific position on specific route and electronic device
WO2022100221A1 (en) Retrieval processing method and apparatus, and storage medium
CN111881315A (en) Image information input method, electronic device, and computer-readable storage medium
CN114255745A (en) Man-machine interaction method, electronic equipment and system
CN116048765B (en) Task processing method, sample data processing method and electronic equipment
CN115422480B (en) Method, apparatus and storage medium for determining region of event venue
CN113066048A (en) Segmentation map confidence determination method and device
CN114330374A (en) Fusion scene perception machine translation method, storage medium and electronic equipment
CN115115679A (en) Image registration method and related equipment
CN114241415A (en) Vehicle position monitoring method, edge calculation device, monitoring device and system
CN113409041B (en) Electronic card selection method, device, terminal and storage medium
CN116709180B (en) Geofence generation method and server
CN114610419A (en) Method and device for adding widget and computer readable storage medium
CN113039513B (en) Recommendation method for candidate content of input method and electronic equipment
CN116033069B (en) Notification message display method, electronic device and computer readable storage medium
CN112416984A (en) Data processing method and device
CN116861066A (en) Application recommendation method and electronic equipment
CN115134453A (en) Riding information display method and electronic equipment
CN115993993A (en) Cold start method and related equipment
CN114995963A (en) Advertisement display system and method
CN114077713A (en) Content recommendation method, electronic device and server
CN115550843B (en) Positioning method and related equipment
CN115297438B (en) Express delivery prompt method, equipment and storage medium
CN116028707B (en) Service recommendation method, device and storage medium
CN116089368B (en) File searching method and related device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant