Electronic device for supporting incremental merging of model, and operating method
Patent Information
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- SAMSUNG ELECTRONICS CO LTD
- Filing Date
- 2026-01-28
- Publication Date
- 2026-08-06
Smart Images

Figure KR2026001652_06082026_PF_FP_ABST
Abstract
Description
Electronic device and operation method supporting incremental merging of models
[0001] The present disclosure relates to an electronic device and a method of operation that supports the incremental merging of models.
[0002] Incremental merging or incremental aggregation of models refers to a method of gradually integrating (merging) existing models or data structures while adding new elements or changes. This method allows for updates to existing models based on new data without the need to reconfigure the entire system or retrain it from scratch. Incremental merging may include the operation of incrementally training a model and the operation of merging multiple trained models.
[0003] The information described above may be provided as related art for the purpose of aiding understanding of the present disclosure. No claim or determination is made as to whether any of the foregoing may be applied as prior art related to the present disclosure.
[0004] According to one embodiment of the present disclosure, an electronic device comprises at least one processor including a processing circuit; and a memory including at least one storage medium for storing instructions, wherein when the instructions are executed individually or collectively by the at least one processor, the electronic device may cause: to train at least one trainable layer of a base model using first data collected during a first time period to obtain a first trained model having at least one first trained parameter, to merge the at least one first trained parameter of the first trained model and at least one second trained parameter of a first merged model using model quality weight information to obtain a second merged model having at least one third trained parameter, and to deploy the second merged model. The first merged model is used for at least part of the first time period, and the model quality weight information includes a first model quality weight for the first learned model and a second model quality weight for the first merged model, and the second model quality weight can be set based on user feedback information for the first merged model.
[0005] According to one embodiment, user feedback information for the first merged model may be set based on the positive feedback ratio and the negative feedback ratio for the output of the first merged model.
[0006] According to one embodiment, the first model quality weight is set based on model performance information, model reliability information, and user feedback information for the first learned model, and the second model quality weight can be set based on model performance information, model reliability information, and user feedback information for the first merged model.
[0007] According to one embodiment, the operation of acquiring the second merged model further utilizes time weight information along with the model quality weight information, wherein the time weight information includes a first time weight for the first learned model and a second time weight for the first merged model, and the first time weight may be set higher than the second time weight.
[0008] According to one embodiment, the first data may be deleted after the first learned model is acquired.
[0009] According to one embodiment, when the instructions are executed individually or collectively by the at least one processor, the electronic device may be caused to: set some of the layers of the base model as the learnable layers, and set other of the layers of the base model as fixed layers.
[0010] According to one embodiment, when the instructions are executed individually or collectively by the at least one processor, the electronic device may be caused to: set at least one layer of a feature extractor among a plurality of layers of the base model as the fixed layer.
[0011] According to one embodiment, the second merging model may be used during at least part of the second time period, which is after the first time period.
[0012] According to one embodiment, when the instructions are executed individually or collectively by the at least one processor, the electronic device may be caused to: learn the at least one learnable layer of the base model using the first data collected during the first time period to obtain a second trained model having at least one fourth learned parameter, merge the at least one fourth learned parameter of the second trained model and at least one third learned parameter of the second merged model using the second time weight information and the second model quality weight information to obtain a third merged model having at least one fifth learned parameter, and distribute the third merged model.
[0013] According to one embodiment, the first merged model and the second merged model may be on-device models stored in the memory and executed by the electronic device.
[0014] According to one embodiment of the present disclosure, a method of an electronic device may include: an operation of obtaining a first trained model having at least one first trained parameter by training at least one trainable layer of a base model using first data collected during a first time period; an operation of obtaining a second merged model having at least one third trained parameter by merging at least one first trained parameter of the first trained model and at least one second trained parameter of a first merged model using model quality weight information; and an operation of deploying the second merged model. The first merged model is used for at least a portion of the first time period, and the model quality weight information includes a first model quality weight for the first trained model and a second model quality weight for the first merged model, and the second model quality weight may be set based on user feedback information for the first merged model.
[0015] According to one embodiment, user feedback information for the first merged model may be set based on the positive feedback ratio and the negative feedback ratio for the output of the first merged model.
[0016] According to one embodiment, the first model quality weight is set based on model performance information, model reliability information, and user feedback information for the first learned model, and the second model quality weight can be set based on model performance information, model reliability information, and user feedback information for the first merged model.
[0017] According to one embodiment, the operation of acquiring the second merged model further utilizes time weight information along with the model quality weight information, wherein the time weight information includes a first time weight for the first learned model and a second time weight for the first merged model, and the first time weight may be set higher than the second time weight.
[0018] According to one embodiment, the first data may be deleted after the first learned model is acquired.
[0019] According to one embodiment, the method may include the operation of setting some of the layers of the base model as learnable layers and setting other of the layers as fixed layers.
[0020] According to one embodiment, the method may include the operation of setting at least one layer of a feature extractor among a plurality of layers of the base model as the fixed layer.
[0021] According to one embodiment, the second merging model may be used during at least part of the second time period, which is after the first time period.
[0022] According to one embodiment, the method may include: an operation of obtaining a second trained model having at least one fourth learned parameter by training at least one learnable layer of the base model using first data collected during the first time period; an operation of obtaining a third merged model having at least one fifth learned parameter by merging at least one fourth learned parameter of the second trained model and at least one third learned parameter of the second merged model using second time weight information and second model quality weight information; and an operation of distributing the third merged model.
[0023] According to one embodiment, the first merged model and the second merged model may be on-device models stored in the memory and executed by the electronic device.
[0024] In relation to the description of the drawings, the same or similar reference numerals may be used for identical or similar components.
[0025] FIG. 1 is a block diagram of an electronic device in a network environment according to various embodiments of the present disclosure.
[0026] FIG. 2 is a drawing illustrating the configuration of an electronic device that supports incremental merging of models according to one embodiment of the present disclosure.
[0027] FIG. 3 is a flowchart illustrating an operation in which an electronic device supports the incremental merging of models according to one embodiment of the present disclosure.
[0028] FIG. 4 is a drawing illustrating a model used for incremental merging according to one embodiment of the present disclosure.
[0029] FIG. 5a is a drawing illustrating a model including a fixed part and a learnable part according to one embodiment of the present disclosure.
[0030] Figure 5b is a diagram illustrating an example of the fixed part and the learnable part of Figure 5a.
[0031] FIG. 6 is a diagram illustrating the operation of an electronic device learning a model including a learnable layer according to one embodiment of the present disclosure.
[0032] FIG. 7 is a diagram illustrating the operation of an electronic device merging two learned layers according to one embodiment of the present disclosure.
[0033] FIG. 8a is a drawing illustrating a model having a first reliability according to one embodiment of the present disclosure.
[0034] FIG. 8b is a drawing illustrating a model having a second reliability according to one embodiment of the present disclosure.
[0035] Hereinafter, embodiments of the present disclosure are described in detail with reference to the drawings so that those skilled in the art can easily practice them. However, the present disclosure may be embodied in various different forms and is not limited to the embodiments described herein. In relation to the description of the drawings, the same or similar reference numerals may be used for identical or similar components. Furthermore, in the drawings and related descriptions, descriptions of well-known functions and configurations may be omitted for clarity and brevity.
[0036] FIG. 1 is a block diagram of an electronic device in a network environment according to various embodiments of the present disclosure.
[0037] Referring to FIG. 1, in a network environment (100), an electronic device (101) may communicate with an electronic device (102) through a first network (198) (e.g., a short-range wireless communication network) or with an electronic device (104) or a server (108) through a second network (199) (e.g., a long-range wireless communication network). According to one embodiment, the electronic device (101) may communicate with the electronic device (104) through a server (108). According to one embodiment, the electronic device (101) may include a processor (120), memory (130), input module (150), sound output module (155), display module (160), audio module (170), sensor module (176), interface (177), connection terminal (178), haptic module (179), camera module (180), power management module (188), battery (189), communication module (190), subscriber identification module (196), or antenna module (197). In some embodiments, at least one of these components (e.g., connection terminal (178)) may be omitted from the electronic device (101), or one or more other components may be added. In some embodiments, some of these components (e.g., sensor module (176), camera module (180), or antenna module (197)) may be integrated into a single component (e.g., display module (160)).
[0038] The processor (120) can control at least one other component (e.g., hardware or software component) of the electronic device (101) connected to the processor (120) by executing software (e.g., program (140)), for example, and can perform various data processing or operations. According to one embodiment, as at least part of the data processing or operations, the processor (120) can store commands or data received from other components (e.g., sensor module (176) or communication module (190)) in volatile memory (132), process the commands or data stored in volatile memory (132), and store the resulting data in non-volatile memory (134). According to one embodiment, the processor (120) may include a main processor (121) (e.g., central processing unit or application processor) or an auxiliary processor (123) that can operate independently or together with it (e.g., graphics processing unit, neural processing unit (NPU), image signal processor, sensor hub processor, or communication processor). For example, if the electronic device (101) includes a main processor (121) and an auxiliary processor (123), the auxiliary processor (123) may be configured to use lower power than the main processor (121) or to be specialized for a designated function. The auxiliary processor (123) may be implemented separately from the main processor (121) or as part thereof.
[0039] The auxiliary processor (123) may control at least some of the functions or states associated with at least one component of the electronic device (101) (e.g., display module (160), sensor module (176), or communication module (190)) on behalf of the main processor (121) while the main processor (121) is in an inactive (e.g., sleep) state, or together with the main processor (121) while the main processor (121) is in an active (e.g., application execution) state. According to one embodiment, the auxiliary processor (123) (e.g., image signal processor or communication processor) may be implemented as part of another functionally related component (e.g., camera module (180) or communication module (190)). According to one embodiment, the auxiliary processor (123) (e.g., neural network processing unit) may include a hardware structure specialized for processing an artificial intelligence model. The artificial intelligence model may be generated through machine learning. Such learning may be performed, for example, on the electronic device (101) itself where the artificial intelligence is performed, or through a separate server (e.g., server (108)). The learning algorithm may include, for example, supervised learning, unsupervised learning, semi-supervised learning, or reinforcement learning, but is not limited to the examples described above. The artificial intelligence model may include a plurality of artificial neural network layers.An artificial neural network may be a deep neural network (DNN), a convolutional neural network (CNN), a recurrent neural network (RNN), a restricted Boltzmann machine (RBM), a deep belief network (DBN), a bidirectional recurrent deep neural network (BRDNN), a deep Q-network, or a combination of two or more of the above, but is not limited to the examples described above. In addition to the hardware structure, the artificial intelligence model may include a software structure, either additionally or substantially.
[0040] The memory (130) can store various data used by at least one component of the electronic device (101) (e.g., processor (120) or sensor module (176)). The data may include, for example, input data or output data for software (e.g., program (140)) and related commands. The memory (130) may include volatile memory (132) or non-volatile memory (134).
[0041] The program (140) may be stored as software in memory (130) and may include, for example, an operating system (142), middleware (144), or an application (146).
[0042] The input module (150) can receive commands or data to be used for a component of the electronic device (101) (e.g., processor (120)) from outside the electronic device (101) (e.g., user). The input module (150) may include, for example, a microphone, a mouse, a keyboard, a key (e.g., a button), or a digital pen (e.g., a stylus pen).
[0043] The sound output module (155) can output a sound signal to the outside of the electronic device (101). The sound output module (155) may include, for example, a speaker or a receiver. The speaker may be used for general purposes, such as multimedia playback or recording playback. The receiver may be used to receive incoming calls. According to one embodiment, the receiver may be implemented separately from the speaker or as part thereof.
[0044] The display module (160) can visually provide information to an external (e.g., user) of the electronic device (101). The display module (160) may include, for example, a display, a holographic device, or a projector and a control circuit for controlling said device. According to one embodiment, the display module (160) may include a touch sensor configured to detect a touch, or a pressure sensor configured to measure the intensity of the force generated by said touch.
[0045] The audio module (170) can convert sound into an electrical signal or, conversely, convert an electrical signal into sound. According to one embodiment, the audio module (170) can acquire sound through the input module (150) or output sound through the sound output module (155) or an external electronic device (e.g., electronic device (102)) (e.g., speaker or headphones) connected directly or wirelessly to the electronic device (101).
[0046] The sensor module (176) can detect the operating state of the electronic device (101) (e.g., power or temperature) or the external environmental state (e.g., user state) and generate an electrical signal or data value corresponding to the detected state. According to one embodiment, the sensor module (176) may include, for example, a gesture sensor, a gyroscope sensor, a barometric pressure sensor, a magnetic sensor, an accelerometer sensor, a grip sensor, a proximity sensor, a color sensor, an IR (infrared) sensor, a biosensor, a temperature sensor, a humidity sensor, or an illuminance sensor.
[0047] The interface (177) may support one or more specified protocols that can be used for the electronic device (101) to be connected directly or wirelessly to an external electronic device (e.g., electronic device (102)). According to one embodiment, the interface (177) may include, for example, a high definition multimedia interface (HDMI), a universal serial bus (USB) interface, an SD card interface, or an audio interface.
[0048] The connection terminal (178) may include a connector through which the electronic device (101) can be physically connected to an external electronic device (e.g., electronic device (102)). According to one embodiment, the connection terminal (178) may include, for example, an HDMI connector, a USB connector, an SD card connector, or an audio connector (e.g., a headphone connector).
[0049] The haptic module (179) can convert an electrical signal into a mechanical stimulus (e.g., vibration or movement) or an electrical stimulus that the user can perceive through tactile or kinesthetic senses. According to one embodiment, the haptic module (179) may include, for example, a motor, a piezoelectric element, or an electric stimulation device.
[0050] The camera module (180) can capture still images and video. According to one embodiment, the camera module (180) may include one or more lenses, image sensors, image signal processors, or flashes.
[0051] The power management module (188) can manage the power supplied to the electronic device (101). According to one embodiment, the power management module (188) can be implemented, for example, as at least part of a power management integrated circuit (PMIC).
[0052] The battery (189) can supply power to at least one component of the electronic device (101). According to one embodiment, the battery (189) may include, for example, a non-rechargeable primary battery, a rechargeable secondary battery, or a fuel cell.
[0053] The communication module (190) can support the establishment of a direct (e.g., wired) communication channel or a wireless communication channel between an electronic device (101) and an external electronic device (e.g., electronic device (102), electronic device (104), or server (108)), and the performance of communication through the established communication channel. The communication module (190) may include one or more communication processors that operate independently of the processor (120) (e.g., application processor) and support direct (e.g., wired) communication or wireless communication. According to one embodiment, the communication module (190) may include a communication module (192) (e.g., cellular communication module, short-range communication module, or GNSS (global navigation satellite system) communication module) or a wired communication module (194) (e.g., LAN (local area network) communication module, or power line communication module). The corresponding communication module among these communication modules can communicate with an external electronic device (104) through a first network (198) (e.g., a short-range communication network such as Bluetooth, WiFi (wireless fidelity) direct, or IrDA (infrared data association)) or a second network (199) (e.g., a legacy cellular network, a 5G network, a next-generation communication network, the Internet, or a computer network (e.g., a LAN or WAN)). These various types of communication modules may be integrated into a single component (e.g., a single chip) or implemented as multiple separate components (e.g., multiple chips). The communication module (192) can identify or authenticate the electronic device (101) within a communication network such as the first network (198) or the second network (199) using subscriber information (e.g., International Mobile Subscriber Identifier (IMSI)) stored in the subscriber identification module (196).
[0054] The communication module (192) can support 5G networks and next-generation communication technologies following 4G networks, for example, new radio access technology. NR access technology can support high-speed transmission of high-capacity data (enhanced mobile broadband (eMBB)), minimization of terminal power and connection of multiple terminals (massive machine type communications (mMTC)), or high reliability and low latency (ultra-reliable and low-latency communications (URLLC)). The communication module (192) can support a high-frequency band (e.g., mmWave band) to achieve a high data transmission rate, for example. The communication module (192) can support various technologies for securing performance in the high-frequency band, such as beamforming, massive MIMO (multiple-input and multiple-output), full-dimensional MIMO (FD-MIMO), array antenna, analog beam-forming, or large-scale antenna. The communication module (192) can support various requirements specified in the electronic device (101), external electronic device (e.g., electronic device (104)), or network system (e.g., second network (199)). According to one embodiment, the communication module (192) can support a Peak data rate (e.g., 20 Gbps or more) for eMBB realization, loss coverage (e.g., 164 dB or less) for mMTC realization, or U-plane latency (e.g., downlink (DL) and uplink (UL) each 0.5 ms or less, or round trip 1 ms or less) for URLLC realization.
[0055] An antenna module (197) can transmit a signal or power to or from an external source (e.g., an external electronic device). According to one embodiment, the antenna module (197) may include an antenna comprising a radiator made of a conductor or a conductive pattern formed on a substrate (e.g., a PCB). According to one embodiment, the antenna module (197) may include a plurality of antennas (e.g., an array antenna). In this case, at least one antenna suitable for a communication method used in a communication network, such as a first network (198) or a second network (199), may be selected from the plurality of antennas, for example, by a communication module (190). A signal or power may be transmitted or received between the communication module (190) and an external electronic device through the selected at least one antenna. According to some embodiments, in addition to the radiator, other components (e.g., a radio frequency integrated circuit (RFIC)) may be additionally formed as part of the antenna module (197).
[0056] According to various embodiments, the antenna module (197) may form a mmWave antenna module. According to one embodiment, the mmWave antenna module may include a printed circuit board, an RFIC disposed on or adjacent to a first surface (e.g., bottom surface) of the printed circuit board and capable of supporting a specified high frequency band (e.g., mmWave band), and a plurality of antennas (e.g., array antennas) disposed on or adjacent to a second surface (e.g., top surface or side surface) of the printed circuit board and capable of transmitting or receiving a signal of the specified high frequency band.
[0057] At least some of the above components can be connected to each other via a communication method between peripheral devices (e.g., bus, GPIO (general purpose input and output), SPI (serial peripheral interface), or MIPI (mobile industry processor interface) and exchange signals (e.g., commands or data) with each other.
[0058] According to one embodiment, commands or data may be transmitted or received between the electronic device (101) and an external electronic device (104) through a server (108) connected to a second network (199). Each of the external electronic devices (102, or 104) may be the same or different type of device as the electronic device (101). According to one embodiment, all or part of the operations performed on the electronic device (101) may be performed on one or more of the external electronic devices (102, 104, or 108). For example, if the electronic device (101) needs to perform a function or service automatically or in response to a request from a user or another device, the electronic device (101) may request one or more external electronic devices to perform at least part of the function or service instead of performing the function or service itself or additionally. One or more external electronic devices that receive the above request may execute at least part of the requested function or service, or additional function or service related to the request, and transmit the result of the execution to the electronic device (101). The electronic device (101) may provide the result as is or additionally processed as at least part of the response to the request. For this purpose, for example, cloud computing, distributed computing, mobile edge computing (MEC), or client-server computing technology may be used. The electronic device (101) may provide ultra-low latency services using, for example, distributed computing or mobile edge computing. In one embodiment, the external electronic device (104) may include an Internet of Things (IoT) device. The server (108) may be an intelligent server using machine learning and / or neural networks. According to one embodiment, the external electronic device (104) or the server (108) may be included within a second network (199).The electronic device (101) can be applied to intelligent services (e.g., smart home, smart city, smart car, or healthcare) based on 5G communication technology and IoT-related technology.
[0059] The number of processors (120) may be one or more. For example, the processor (120) may have the structure of a multi-core processor such as a dual core, a quad core, or a hexa core.
[0060] The processor (120) can control the operations of the electronic device (101) by executing instructions stored in memory (130). For example, the processor (120) may correspond to a plurality of processors that divide and collectively perform a plurality of operations among the processors.
[0061] FIG. 2 is a drawing illustrating the configuration of an electronic device that supports incremental merging of models according to one embodiment of the present disclosure.
[0062] According to one embodiment, the electronic device (101) may support incremental merging of models. According to one embodiment, the model may be an artificial intelligence model, for example, a machine learning model or a deep learning model, but is not limited thereto. The model may be an on-device model that is stored in, for example, the memory of the electronic device (101) (e.g., the memory (130) of FIG. 1) and executed directly on the electronic device (101).
[0063] According to one embodiment, the electronic device (101) can merge multiple trained models obtained by training models using data collected over time periods, rather than training a model at once using all the data. The electronic device (101) can delete the data collected during the corresponding time period after the training of the model is completed. Through this, the electronic device (101) can continuously merge the training results of multiple collected data while reducing the memory capacity and / or training time associated with data collection.
[0064] According to one embodiment, when merging a plurality of learned models, the electronic device (101) may apply model quality weights set based on user feedback (or response). This allows the user's intention and response to be reflected in the merged model, unlike a method of merging a plurality of learned models by simply applying time weights. Through this, efficient personalization of the model can be achieved.
[0065] Referring to FIG. 2, the electronic device (101) may include a data collection module (210), a model learning module (220), a model merging module (230), and / or a model distribution module (240). According to one embodiment, each module may be included in at least one processor of the electronic device (101) (e.g., the processor (120) of FIG. 1). According to one embodiment, a memory (130) stores instructions, and when the instructions stored in the memory (130) are executed individually and / or collectively by at least one processor (120), the electronic device (101) may be able to perform at least one function of each module included in the at least one processor (120). The operation of each component of the electronic device (101) to be described below may be understood as the operation of the electronic device (101) or the operation of at least one processor (120) of the electronic device (101).
[0066] According to one embodiment, the data collection module (210) may collect data (training data) used for training a model during a specified time period (e.g., a time window). For example, the data collection module (210) may collect training data used for training a model on a time-by-time basis. According to one embodiment, the time period may be a fixed period or a variable period. For example, the time period may be set as one of a first period during which a specified number of necessary data (e.g., 10 events) is collected, a second period during which a specified number of user feedbacks (e.g., number of feedbacks = number of positive feedbacks + number of negative feedbacks) is collected, or a third period during which a specified number of user negative feedbacks is collected. The lengths of the first period, the second period, or the third period may be set differently for each time period. The data collection module (210) may delete the training data after training for the model is completed using the training data. Through this, the capacity of the electronic device (101) can be sufficiently secured.
[0067] According to one embodiment, the model learning module (220) can learn a model using collected learning data. For example, the model learning module (220) can learn a base model using each data collected over a time period. According to one embodiment, the base model may be a zero-base or initialized common model used for incremental learning. In the present disclosure, the base model may also be referred to as a common model.
[0068] According to one embodiment, a model (e.g., a base model) may include a fixed part and / or a trainable part. The fixed part may include, for example, at least one fixed layer that is not learned during the model's training process. The trainable part may include, for example, at least one trainable layer that can be learned during the model's training process. According to one embodiment, the at least one trainable layer may include a fully connected (FC) layer, a convolution layer, an attention layer (or a transformer layer), and / or an embedding layer. When training the model, the fixed part of the model (e.g., a fixed feature extractor including at least one fixed layer) may not be trained, and only the trainable part (e.g., at least one trainable layer) may be trained. Through this, during the learning process, for example, the latent space (or embedding space) of features can be fixed, and the cost of model training (e.g., time, power) can be saved by training only some layers rather than the entire model. The fixed and trainable parts of the model are described exemplarily below with reference to FIGS. 5a and 5b.
[0069] According to one embodiment, the operation of learning a model (e.g., a base model) may include the operation of learning a learnable part of the model. According to one embodiment, the operation of learning a learnable part of the model may include the operation of learning parameter(s) of a learnable part of the model (e.g., at least one learnable layer). According to one embodiment, if the learnable layer is an FC layer, parameter(s such as weights and / or biases may be learned. If the learnable layer is a convolution layer, parameter(s such as kernels and / or biases may be learned. If the learnable layer is an attention layer, parameter(s such as queries (Q), keys (K), values (V), and / or biases generated through linear projection may be learned. If the learnable layer is an embedding layer, parameter(s such as kernels and / or biases may be learned.
[0070] According to one embodiment, the operation of learning the model's parameter(s) may include, for example, the operation of adjusting (e.g., optimizing) the values of adjustable parameter(s) within the model. For learning the model's parameter(s), a loss function and an optimization algorithm may be used.
[0071] According to one embodiment, the model learning module (220) can obtain a trained model based on learning a model using training data collected over a time period. The trained model may be, for example, a basic trained model obtained directly by learning a base model using training data, or a merged model obtained by merging two trained models. The merged model may be, for example, a first type of merged model obtained by merging two basic trained models, or a second type of merged model obtained by merging one basic trained model and one merged model. The first type of merged model may be generated during the initial stage of learning, and the second type of merged model may be generated during the learning process after the first type of merged model has been generated. In the following description, the term "trained model" may be used to collectively refer to the basic trained model and the merged model, as described above.
[0072] According to one embodiment, the model learning module (220) may acquire a first learned model having a first set of parameters based on learning at least one learnable layer of a base model using first learning data collected during a first time period, and acquire a second learned model having a second set of parameters based on learning at least one learnable layer of a base model using second learning data collected during a second time period after the first time period. According to one embodiment, the first time period may be the same time period as the second time period or a different time period. According to one embodiment, each set of parameters may include at least one learned parameter (e.g., an adjusted parameter) associated with the corresponding learned model. For example, if the learnable layer is an FC layer, each set of parameters may include a learned weight value and / or a learned bias value for the corresponding learned model. According to one embodiment, the first learned model may be a base learned model or a merged model, and the second learned model may be a base learned model. According to one embodiment, the first learned model and the second learned model may have the same structure (model architecture) as the base model. Having multiple models having the same structure may include, for example, that multiple models have the same layer configuration (e.g., layer type, order, number, and / or connection method) and / or that the dimensions of the input data and output data of multiple models are the same.
[0073] According to one embodiment, the model merging module (230) can obtain (or generate) a merged model by merging a plurality of learned models using time weight information and / or model quality weight information. For example, the model merging module (230) can generate a merged model by merging a first learned model having a first parameter set and a second learned model having a second parameter set. Each parameter set may include at least one learned parameter associated with the corresponding learned model. For example, if the learnable layer is an FC layer, each parameter set may include a learned weight value and / or a learned bias value for the corresponding learned model. According to one embodiment, the merged model may have the same structure (model structure) as the first learned model and the second learned model.
[0074] According to one embodiment, the time weight information may include time weights for a plurality of models. For example, the time weight information may include a time weight for a first learned model and a time weight for a second learned model. The time weight for the second learned model obtained after the first learned model may be set higher than the time weight for the first learned model. This allows the latest data to be better reflected in the merged model.
[0075] According to one embodiment, the model quality weight information may include quality weight information for a plurality of models. For example, the model quality weight information may include first quality weight information for a first learned model and second quality weight information for a second learned model. Each quality weight information may be associated with user feedback information for the corresponding model. For example, each quality weight information may be set based on model performance information, model reliability information, and / or user feedback information for the corresponding model.
[0076] According to one embodiment, model performance information may indicate the performance (p) of the model. The performance of the model may be set based on model evaluation metrics, such as accuracy, precision, and recall. The value of the model performance information may increase as the performance of the model increases. By setting model quality weights using this model performance information, the model with higher performance among the two trained models being merged may be better reflected in the merged model.
[0077] According to one embodiment, model reliability information may indicate the reliability (c) of the model. The reliability of the model may be used to evaluate whether the model has been well trained. The reliability of the model may be set, for example, based on trends in the model's output values. For example, if the distribution of probability values output by the model is uniform, the model may not have been well trained, and therefore, the reliability of the model may be low. For example, if a small number of probability values (e.g., one probability value) is greater than other probability value(s), the model may have been well trained, and therefore, the reliability of the model may be high. By setting model quality weights using this model reliability information, the model with higher reliability (e.g., the better trained model) among the two trained models being merged may be better reflected in the merged model. An example of comparing the reliability of the models is described below with reference to FIGS. 8a and 8b.
[0078] According to one embodiment, user feedback information may indicate user feedback (f) of the corresponding model. According to one embodiment, user feedback information may be set based on the positive feedback ratio and negative feedback ratio regarding the output of the corresponding model. According to one embodiment, positive and negative feedback may be identified based not only on the user's direct feedback regarding the output of the model, but also on situations where the user does not provide feedback (e.g., no feedback situation). Such user feedback information may serve as an evaluation of the user's preference for the model or the model's behavior. For example, the higher the value of the user feedback information, the more the user prefers the model. By setting model quality weights using such user feedback information, among the two trained models being merged, the model that better expresses the user's intent (e.g., the model with high user preference) may be better reflected in the merged model. An example of an operation for determining the positive feedback ratio and negative feedback ratio according to the model type is described exemplarily below with reference to FIG. 4.
[0079] According to one embodiment, the operation of merging a plurality of learned models may include the operation of merging parameter sets of the plurality of learned models. For example, the operation of merging a first learned model having a first parameter set and a second learned model having a second parameter set may include the operation of merging the first parameter set of the first learned model and the second parameter set of the second learned model to generate a third parameter set of the merged model. According to one embodiment, the merging of the first parameter set and the second parameter set may be performed using a specified method (e.g., linear combination, matrix decomposition).
[0080] Hereinafter, for the sake of convenience of explanation, an operation to obtain a third parameter set of a second merged model by merging the parameter sets of a plurality of learned models is described by way of example, where a first learned model having a first parameter set is a merged model obtained before a second learned model is obtained (hereinafter, the first merged model), and a second learned model having a second parameter set is a first basic learned model obtained based on a base model.
[0081] According to one embodiment, the merging of the first parameter set and the second parameter set can be performed using a linear combination of parameters included in each parameter set. For example, the merging of the first parameter set and the second parameter set can be performed using the following Equation 1.
[0082] [Mathematical Formula 1]
[0083]
[0084] Here,
[0085] D t : A set of data collected during the time period from time t-1 to t
[0086] M0: Base model or base model parameter(s)
[0087] M t : D t A trained model obtained by training M0 using as training data (e.g., the first basic trained model) or the trained parameter(s) of said trained model
[0088] M` t-1 : M t A previously acquired learned model (e.g., the first merged model) or the learned parameter(s) of said learned model
[0089] M` t : M', the two recently trained models t-1 and M tA merged model obtained by merging (e.g., a second merged model) or the parameter(s) of said merged model
[0090] r t : M t Time weights for
[0091] r t-1 : M` t-1 Time weights for
[0092] q t : M t Model quality weights for
[0093] q t-1 : M` t-1 Model quality weights for
[0094] According to one embodiment, the electronic device (101) is M t After is acquired, D t It can be deleted. Through this, the capacity of the electronic device (101) can be secured.
[0095] According to one embodiment, the time weight information is M t and M` t-1 It may include time weights for each of M t Time weights for (r t ) is M` t-1 Time weights for (r t-1 It can be set higher than ). This allows the latest data to be better reflected in the merge model.
[0096] According to one embodiment, the merging of the first parameter set and the second parameter set can be performed using matrix decomposition. For example, since the parameters of the parameter set exist in the form of a matrix such as m*n, the electronic device (101) can perform matrix decomposition on the parameters of each parameter set and then perform merging between the parameters by reflecting model quality weight information to the matrix-decomposed parameters.
[0097] According to one embodiment, the model quality weight information is M t First model quality weights (q) for t ), and / or M` t-1 Second model quality weights for (q t-1 It may include ). According to one embodiment, the first model quality weight (q t ) is, M t It can be set based on model performance information, model reliability information, and / or user feedback information. The second model quality weight (q t-1 ) is M` t-1 It can be set based on model performance information, model reliability information, and user feedback information.
[0098] According to one embodiment, model performance information can indicate the performance (p) of the model. For example, M t Model performance information regarding M t Indicates the performance of, and M' t-1 Model performance information for M` t-1 It can indicate the performance of. For a description of model performance information, refer to the above.
[0099] According to one embodiment, the model reliability information may indicate the reliability (c) of the model. For example, M t Model reliability information for M t Indicates the reliability of, and M' t-1 The model reliability information for M` t-1 It can indicate the reliability of. For an explanation of the model reliability information, refer to the above.
[0100] According to one embodiment, user feedback information can indicate user feedback (f) of the corresponding model. For example, M t User feedback information regarding M t Direct user feedback of, and M` t-1User feedback information regarding M` t-1 You can direct user feedback. You can refer to the details regarding user feedback information.
[0101] According to one embodiment, M` t-1 User feedback information regarding is M` t-1 It can be set based on the positive feedback ratio and negative feedback ratio for the output of. For example, M' t-1 User feedback information regarding can be set using the following mathematical formula 2.
[0102] [Mathematical Formula 2]
[0103] User Feedback(f) = Positive Feedback Rate * (1 - Negative Feedback Rate)
[0104] According to one embodiment, M t User feedback information regarding can be set to a specified value (e.g., 1). This refers to the merge model M' t-1 Unlike, the basic trained model M t Because it is a model used internally for model merging and is not deployed, M t This is because user feedback information regarding it cannot be obtained.
[0105] According to one embodiment, the model quality weight (q) can be calculated using the following mathematical formula 3.
[0106] [Mathematical Formula 3]
[0107]
[0108] Here,
[0109] q: Model quality weights
[0110] p: Model performance
[0111] c: Model reliability
[0112] f: User feedback on the model
[0113] Table 1 below shows M t and M` t-1 An example of the time weight and model quality weight set for is provided.
[0114] [Table 1]
[0115]
[0116] M' obtained using Equations 1 and 3 based on the setting values in Table 1 t One example of the value may be as follows.
[0117]
[0118] According to one embodiment, the model quality weight (q) can be calculated using any one of the following mathematical formulas 4 to 6 instead of mathematical formula 3.
[0119] [Mathematical Formula 4]
[0120]
[0121] [Mathematical Formula 5]
[0122]
[0123] [Mathematical Formula 6]
[0124]
[0125] Here,
[0126] q: Model quality weights
[0127] p: Model performance
[0128] c: Model reliability
[0129] f: User feedback on the model
[0130] As model quality weights (q) are set according to these various methods, the weight given to the merged model by the factors used to set the model quality weights (q), namely model performance (p), model reliability (c), and user feedback (f) on the model, can be adjusted.
[0131] According to one embodiment, the model distribution module (240) can distribute the merged model that has been merged through the model merging module (230). The operation of distributing the merged model may include the operation of saving the merged model. The operation of saving the merged model may include the operation of saving a parameter set of the merged model. The electronic device (101) can provide a specified task or service using the distributed merged model.
[0132] According to the embodiment described above in FIG. 2, when the electronic device (101) performs incremental merging to train a model, it may be advantageous in terms of data storage capacity and training time compared to the case where the entire data is collected to train the model, as exemplified in the comparison tables below, Tables 2 and 3.
[0133] [Table 2]
[0134]
[0135] [Table 3]
[0136]
[0137] Referring to Table 2, unlike the overall data storage method, using the proposed method of the present disclosure may require less data storage capacity. For example, when following the proposed method of the present disclosure, only up to two parameters of the learned model need to be stored, so approximately 2 * 1.4 kB = 2.8 kB may be required.
[0138] Referring to Table 3, unlike the overall data storage method, the learning time may be reduced when using the proposed method of the present disclosure. For example, when following the proposed method of the present disclosure, a shorter learning time (e.g., a learning time of 31.2 s) may be required because less data is stored even though time is accumulated. Due to this reduction in learning time, heat generation and power consumption for learning of the electronic device (101) may also be reduced.
[0139] FIG. 3 is a flowchart illustrating an operation in which an electronic device supports the incremental merging of models according to one embodiment of the present disclosure.
[0140] Referring to FIG. 3, in operation 310, an electronic device (e.g., electronic device (101) of FIG. 1) learns at least one trainable layer of a base model using first data (first training data) collected during a first time period (e.g., time t-1 to t) to obtain a first trained model (first basic trained model) having a first parameter set (e.g., M t ) can be obtained. According to one embodiment, the first parameter set may include at least one learned parameter associated with the first learned model. Operation 310 may be performed, for example, by a data collection module (210) and a model learning module (220) of the electronic device (101) of FIG. 2. Operation 310 may include all or part of the operation performed by the data collection module (210) and the model learning module (220). According to one embodiment, the electronic device (101) may set at least one learnable layer among a plurality of layers of a base model.
[0141] According to one embodiment, in operation 320, the electronic device (101) uses time weight information and / or model quality weight information to provide a first parameter set for a first learned model and a first merged model (e.g., M' t-1 By merging the second parameter set for ), a second merged model (e.g., M' tA third parameter set for ) can be obtained. According to one embodiment, the second parameter set may include at least one learned parameter associated with the first merge model, and the third parameter set may include at least one learned parameter associated with the second merge model. Operation 320 may be performed, for example, by a model merging module (230) of the electronic device (101) of FIG. 2. Operation 320 may include all or part of the operation performed by the model merging module (230).
[0142] According to one embodiment, the first merged model may be used during at least part of the first time period associated with the first learned model, and the second merged model may be used after the first time period associated with the first learned model.
[0143] According to one embodiment, the first merged model may be a merged model formed by merging two learned models, namely a second basic learned model and a third basic learned model, which were acquired prior to the first learned model, or a merged model formed by merging a third merged model and a second basic learned model acquired prior to the first merged model. The second basic learned model may be a learned model acquired, for example, by learning at least one learnable layer of a base model using second data (second learning data) collected during a second time period (e.g., time t-2 to t-1) prior to a first time period (e.g., time t-1 to t). The third basic learned model may be a learned model acquired, for example, by learning at least one learnable layer of a base model using third data (third learning data) collected during a third time period (e.g., time t-3 to t-2) prior to the second time period (e.g., time t-2 to t-1). The third merged model may be, for example, a model formed by merging the third basic learned model and the fourth basic learned model. The fourth basic learned model may be, for example, a learned model obtained by learning at least one learnable layer of the base model using fourth data (fourth learning data) collected during a fourth time period (e.g., time t-4 to t-3) prior to the third time period (e.g., time t-3 to t-2).
[0144] According to one embodiment, the model quality weight information is a first trained model (e.g., M t First model quality weight for ) (e.g., q t ), and the first merged model (e.g., M` t-1 Second model quality weights for ) (e.g., q t-1 It may include ).
[0145] According to one embodiment, the second model quality weight may be set based on user feedback information for the first merged model. The user feedback information may indicate user feedback for the model. For a description of the user feedback information, refer to the description above in FIG. 2.
[0146] According to one embodiment, user feedback information for the first merged model may be set based on the positive feedback ratio and the negative feedback ratio for the output of the first merged model. For example, user feedback information for the first merged model may be set using the above-described mathematical formula 2.
[0147] According to one embodiment, user feedback information for the first learned model may be set to a specified value (e.g., 1). This is because, unlike the first merged model, the first learned model is not distributed and is a model used internally for merging models, so user feedback information for the first learned model cannot be obtained.
[0148] According to one embodiment, the first model quality weight may be set based on model performance information, model reliability information, and user feedback information for the first learning model. The second model quality weight may be set based on model performance information, model reliability information, and user feedback information for the first merged model. For a description of the model performance information and model reliability information, refer to the description above in FIG. 2.
[0149] According to one embodiment, the time weight information may include time weights for each of the first learning model and the first merging model. The first learning model (e.g., M t Time weights for ) (e.g., r t ) is the first merge model (e.g., M' t-1 Time weights for ) (e.g., r t-1It can be set higher than ). This allows the latest data to be better reflected in the merge model.
[0150] According to one embodiment, in operation 330, the electronic device (101) may deploy a second merge model. Operation 330 may be performed, for example, by a model deployment module (240) of the electronic device (101) of FIG. 2. Operation 330 may include all or part of the operation performed by the model deployment module (240). The second merge module thus deployed may be used to provide a designated task or service during a time period after the first time period, in place of the first merge module.
[0151] The above-described operations 310 to 330 can be performed repeatedly using training data collected for each time period. Through this, the model can be incrementally merged using training data collected during a specific time period, rather than training data collected over the entire time period.
[0152] FIG. 4 is a drawing illustrating a model used for incremental merging according to one embodiment of the present disclosure.
[0153] FIG. 5a is a drawing illustrating a model including a fixed part and a learnable part according to one embodiment of the present disclosure.
[0154] Figure 5b is a diagram illustrating an example of the fixed part and the learnable part of Figure 5a.
[0155] Referring to FIG. 4, according to one embodiment, the model (410) is a learned model (e.g., M' t-1 , M t , M` tIt may be a base model (e.g., M0) used to generate a trained model using training data collected over a period of time. According to one embodiment, the model (410) is an artificial intelligence model, such as a machine learning model or a deep learning model, but is not limited thereto. According to one embodiment, the model (410) may include at least one layer and may be configured to output output data (402) based on input data (401) using at least one layer. The at least one layer may include, for example, an FC layer, a convolution layer, an attention layer, and / or an embedding layer.
[0156] According to one embodiment, the model (410) may provide action data as output. The action data may include, for example, actionable actions, commands, and / or decisions. For example, the model (410) may receive input data (401) including network status information and / or sensing information, and output action data as output data (402) used to determine whether to disconnect a specified wireless communication connection (e.g., Wi-Fi connection). The network status information may include information associated with the state of the network, for example, received signal strength (e.g., RSSI (received signal strength indicator)), the number of received (Rx) packets, and / or the number of transmitted (Tx) packets. The sensing information may include, for example, sensing data obtained through at least one sensor (e.g., accelerometer, barometric pressure sensor, and / or geomagnetic sensor). According to one embodiment, the electronic device (101) may take a specific action or operation based on the action data output from the model (410). For example, the electronic device (101) may determine whether to disconnect the Wi-Fi connection based on action data, and may disconnect or maintain the Wi-Fi connection based on the determination. According to one embodiment, the electronic device (101) may obtain a positive feedback ratio and a negative feedback ratio used to obtain user feedback information regarding the output of a model (410) containing action data.For example, after the model (410) outputs action data including information instructing to disconnect the Wi-Fi connection and the electronic device (101) performs the action of disconnecting the Wi-Fi connection based on the action data, the electronic device (101) may determine the first user feedback as negative feedback if a first user input (or response) requesting a Wi-Fi connection is obtained, and may determine the second user feedback as positive feedback if a second user input (or response) using another wireless connection (e.g., 5G communication connection) without requesting a Wi-Fi connection is obtained. In this way, the electronic device (101) can determine whether the user input corresponds to positive feedback or negative feedback, not only for user inputs that are contrary to the output result of the model (410) (e.g., first user input), but also for user inputs that correspond to no feedback (e.g., second user input) that are not direct feedback to the output result of the model (410).
[0157] According to one embodiment, the model (410) may provide recommendation data as output. The recommendation data may be used to present recommendations that a user can select. The recommendation data may include, for example, items or scores with assigned priorities. For example, the model (410) may receive input data (401) including user input (e.g., voice input, text input) through an application (e.g., messenger application) and output recommendation data as output data (402) used to present at least one recommended word for word auto-completion. According to one embodiment, the electronic device (101) may obtain a positive feedback ratio and a negative feedback ratio used to obtain user feedback information regarding the output of the model (410) containing the recommendation data. For example, after the model (410) outputs recommendation data presenting a recommendation, the electronic device (101) may determine that the third user feedback is positive feedback when a third user input (or response) selecting the recommendation is obtained, and may determine that the fourth user feedback is negative feedback when a fourth user input (or response) not selecting the recommendation is obtained. In this way, the electronic device (101) can determine whether the user input corresponds to positive feedback or negative feedback, not only for user inputs that accept the output result of the model (410) (e.g., third user input), but also for user inputs that do not accept the output result of the model (410) (e.g., fourth user input).
[0158] According to one embodiment, the model (410) may provide classification result data as output. The classification result data may be used to provide a classified result (e.g., a result of classifying objects included in an input image) using input data (e.g., an input image). The classification result data may include, for example, a classification result and an associated probability value. For example, the model (410) may receive input data (401) containing an image and output classification result data used to classify objects included in the image as output data (402). For example, after the model (410) outputs classification result data providing a classification result and a probability value, the electronic device (101) may determine the fifth user feedback as positive feedback if a fifth user input (or response) that accepts the classification result or uses the classification result without providing a user response to the classification result is obtained, and may determine the sixth user feedback as negative feedback if a sixth user input (or response) that does not accept the classification result is obtained.
[0159] Referring to FIG. 5a, the model (410a) (e.g., the model (410) of FIG. 4) may include a fixed part (411a) and a learnable part (412a). According to one embodiment, the model (410a) may be configured to receive input data (501a) and output output data (502a) through processing (e.g., inference) using the fixed part (411a) and the learnable part (412a). During the learning process of the model (410a), the fixed part (411a) may not be learned, and only the learnable part (412a) may be learned.
[0160] According to one embodiment, the parameters of the fixed part (411a) can be set so that they are not learned. In this way, the parameters of the fixed part (411a) can be fixed without changing during the learning process.
[0161] According to one embodiment, the parameters of the learnable portion (412a) can be set to be learnable. Through this, the parameters of the learnable portion (412a) can be adjusted (e.g., optimized) through a learning process.
[0162] In this way, if only a part of the model (410a) is set to be learnable rather than the entire part of the model (410a), the cost (e.g., time, power, resources) required for training the model (410a) can be reduced, for example, as illustrated in Tables 2 and 3. Below, with reference to FIG. 5b, an example of the fixed part (411a) and the learnable part (412a) of FIG. 5a will be described exemplarily.
[0163] Referring to FIG. 5b, the model (410b) (e.g., the model (410) of FIG. 4 or the model (410a) of FIG. 5a) may include a fixed feature extractor (411b) corresponding to a fixed part (411a) and at least one learnable layer (412b) corresponding to a learnable part (412a). According to one embodiment, the model (410b) may be configured to receive input data (501b) and output output data (502b) through processing (e.g., inference) using the fixed feature extractor (411b) and at least one learnable layer (412b). During the learning process of the model (410b), the fixed feature extractor (411b) may not be learned, and only the learnable part (412a) may be learned.
[0164] According to one embodiment, a feature extractor (411b) may perform the role of extracting features (e.g., useful information) from input data to help the model learn or perform inference. Such a feature extractor (411b) may be used to reduce the dimensionality of the data in the model or to represent information concisely.
[0165] According to one embodiment, the fixed feature extractor (411b) may include at least one fixed layer that is previously trained and then set not to be trained further, as an example of the fixed portion (411a). The parameters of the fixed layer (e.g., weights) may be set to remain unchanged and fixed. Accordingly, the latency space of the fixed feature extractor (411b) may be fixed during the training process.
[0166] According to one embodiment, the learnable layer (412b) is an example of the learnable portion (412a), and the parameters of the learnable layer (412b) can be set to be learnable. Accordingly, the parameters of the learnable layer (412b) can be adjusted (e.g., optimized) through a learning process. An example of an operation to learn the learnable layer (412b) is described exemplarily below with reference to FIGS. 6 and 7.
[0167] According to one embodiment, if the trainable layer is an FC layer, parameter(s) such as weights and / or biases may be trained. If the trainable layer is a convolution layer, parameter(s) such as kernels and / or biases may be trained. If the trainable layer is an attention layer, parameter(s) such as queries (Q), keys (K), values (V), and / or biases generated through linear projection may be trained. If the trainable layer is an embedding layer, parameters such as kernels and / or biases may be trained.
[0168] In this way, if only some layers of the model (410b) are set to be trainable instead of all layers of the model (410b), the cost (e.g., time, power, resources) required for training the model (410b) can be reduced, for example, as exemplified in Tables 2 and 3.
[0169] FIG. 6 is a diagram illustrating the operation of an electronic device learning a model including a learnable layer according to one embodiment of the present disclosure.
[0170] FIG. 7 is a diagram illustrating the operation of an electronic device merging two learned layers according to one embodiment of the present disclosure.
[0171] In the embodiments of FIGS. 6 and 7, for convenience of explanation, the model (e.g., model (410) of FIG. 4, model (410a) of FIG. 5a, model (410b) of FIG. 5b)) is described as having one learnable layer (e.g., learnable part (412a) of FIG. 5a or learnable layer (412b) of FIG. 5b). However, the description is not limited thereto, and as described above, the model may include a plurality of learnable layers, and the description of the embodiments of FIGS. 6 and 7 is applicable to operations of learning and merging a plurality of learnable layers.
[0172] According to one embodiment, when a model is composed of a fixed layer and a trainable layer, the operation of training the model may correspond to the operation of training the trainable layer of the model. According to one embodiment, the operation of training the trainable layer may include the operation of adjusting the learned parameter(s) included in the parameter set of the trainable layer. For example, when the trainable layer is an FC layer, the operation of training the trainable layer may include the operation of adjusting the values of the weights and / or biases included in the parameter set of the FC layer.
[0173] According to one embodiment, the operation of merging a plurality of trained models may include the operation of merging a plurality of trained layers. The operation of merging a plurality of trained layers may include the operation of merging trained parameters included in the parameter set of each trained layer.
[0174] According to one embodiment, an electronic device (e.g., the electronic device (101) of FIG. 1) can learn a trainable layer of a base model using training data collected over a period of time, and obtain (or generate) a trained layer. For example, as illustrated in FIG. 6, the electronic device (101) can obtain a first basic learned model Mt-3 including a first learned layer by learning a learnable layer of a base model using first learning data Dt-3 collected during a first time period from time t-4 to time t-3, obtain a second basic learned model Mt-2 including a second learned layer by learning a learnable layer of a base model using second learning data Dt-2 collected during a second time period from time t-3 to time t-2, obtain a third basic learned model Mt-1 including a third learned layer by learning a learnable layer of a base model using third learning data Dt-1 collected during a third time period from time t-2 to time t-1, and obtain a fourth basic learned model Mt including a fourth learned layer by learning a learnable layer of a base model using learning data Dt collected during a fourth time period from time t-1 to time t. According to one embodiment, time t-4 may be the point in time when training of the base model begins. According to one embodiment, each time period may be set to be the same period or different periods. For example, the time period may be set to one of a first period in which a specified number of necessary data (e.g., 10 events) is collected during the time period, a second period in which a specified number of user feedbacks (e.g., number of feedbacks = number of positive feedbacks + number of negative feedbacks) is collected during the time period, or a third period in which a specified number of user negative feedbacks is collected during the time period.The length of the first period, the second period, or the third period may be set differently for each time period. According to one embodiment, each training data may be deleted after a basic trained model based on the corresponding training data is acquired (or, generated).
[0175] According to one embodiment, the electronic device (101) can acquire (or generate) a merged model including a merged layer by merging a plurality of basic learned layers.
[0176] For example, as illustrated in FIG. 7, the electronic device (101) can obtain a first merged model M't-2 including a first merged layer by merging the first learned layer of the first base-learned model Mt-3 and the second learned layer of the second base-learned model Mt-2. In this way, during the initial stage of learning, a merged layer can be created by merging two learned models obtained by learning the learnable layer of the base model. The first merged model M't-2 including the first merged layer thus created can be distributed and used for at least part of the third time period (t-2 to t-1).
[0177] For example, after the first merged model M't-2 is generated, the electronic device (101) may merge the first merge layer of the first merged model M't-2 and the third learned layer of the third basic learned model Mt-1 to obtain a second merged model M't-1 including a second merge layer. The second merged model M't-1 including the second merge layer thus generated may be distributed and used for at least part of the fourth time period (t-1 to t). For example, after the second merged model M't-1 is generated, the electronic device (101) may merge the second merge layer of the second merged model M't-1 and the fourth learned layer of the fourth basic learned model Mt to obtain a third merged model M't including a third merge layer. The third merged model M't including the third merge layer thus generated may be distributed and used for a time period after the fourth time period (t-1 to t). In this way, during the training process after the merge layer is created, a new merge layer can be created by merging the merge layer with the newly created base trained layer.
[0178] By continuously performing the aforementioned process over time periods, incremental merging of the proposed method can be performed.
[0179] FIG. 8a is a drawing illustrating a model having a first reliability according to one embodiment of the present disclosure.
[0180] FIG. 8b is a drawing illustrating a model having a second reliability according to one embodiment of the present disclosure.
[0181] According to one embodiment, an electronic device (e.g., the electronic device (101) of FIG. 1) can calculate model confidence information indicating the confidence of the model by using the distribution of the output values (e.g., probability values) of the model.
[0182] According to one embodiment, if the model is a binary classification model (binary classification model), the electronic device (101) can calculate the reliability of the model using the following mathematical formula 7.
[0183] [Mathematical Formula 7]
[0184]
[0185] Here,
[0186] N: Number of probability values
[0187] Pi: i-th probability value (i is an integer value between 0 and N)
[0188] Referring to mathematical formula 7, the reliability of the model can increase as the probability value moves further away from 0.5.
[0189] According to one embodiment, if the model is a classification model having three or more classes, the electronic device (101) can calculate the reliability of the model using the entropy of the probability values.
[0190] According to one embodiment, if the model is a model that detects an object, the electronic device (101) can calculate the reliability of the model using the position and / or size of the object (e.g., size detected by a bounding box). For example, the electronic device (101) can calculate the reliability of the model based on the inverse of the variation of the position and / or size of the object.
[0191] According to one embodiment, if the model is a recommendation model that outputs recommendation data, the electronic device (101) can calculate the reliability of the model by using the similarity of the top N recommendations (or options) recommended by the model. For example, the more similar recommendations there are, the higher the reliability of the model.
[0192] Hereinafter, model confidence information for a binary classification model is described exemplarily with reference to Figures 8a and 8b.
[0193] Referring to FIGS. 8a and 8b, the model (810a, 810b) (e.g., the model (410, 410a, 410b) of FIGS. 4, 5a, and 5b) may be a model that outputs the result and probability value of classifying an object included in an input image into one of two objects (e.g., cat, dog) based on input data (801a1 to 801a3, 801b1 to 801b3) including an input image as output data (802a1 to 802a3, 802b1 to 802b3). The model (810a, 810b) may be, for example, a convolutional neural network (CNN) model, but is not limited thereto.
[0194] According to one embodiment, the electronic device (101) can calculate the reliability of the models (810a, 810b) using Equation 7 based on the probability values of the models (810a, 810b). For example, as illustrated in FIG. 8a, if the probability values of the model (810a) are similar, the electronic device (101) may determine that the reliability of the model is relatively low. For example, as illustrated in FIG. 8b, if the probability values of the model (810b) differ significantly, the electronic device (101) may determine that the reliability of the model is relatively high. For example, when the probability values of the model are similar as in FIG. 8a, the reliability may be lower compared to when the probability values of the model differ significantly as in FIG. 8b.
[0195] The embodiments of this document and the terms used therein are not intended to limit the technical features described in this document to specific embodiments, and should be understood to include various modifications, equivalents, or substitutions of said embodiments. In connection with the description of the drawings, similar reference numerals may be used for similar or related components. The singular form of a noun corresponding to an item may include one or more of said items unless the relevant context clearly indicates otherwise. In this document, phrases such as "A or B," "at least one of A and B," "at least one of A or B," "A, B or C," "at least one of A, B and C," and "at least one of A, B, or C" each may include any one of the items listed together in the corresponding phrase, or all possible combinations thereof. Terms such as "first," "second," or "first" or "second" may be used simply to distinguish said components from other said components and do not limit said components in any other aspect (e.g., importance or order). Where any (e.g., 1st) component is referred to as “coupled” or “connected” to another (e.g., 2nd) component, with or without the terms “functionally” or “communicationly,” it means that said any component may be connected to said other component directly (e.g., via a wire), wirelessly, or through a third component.
[0196] The term “module” as used in the embodiments of this document may include a unit implemented in hardware, software, or firmware, and may be used interchangeably with terms such as logic, logic block, component, or circuit, for example. A module may be a component formed integrally, or a minimum unit of said component or a part thereof that performs one or more functions. For example, according to one embodiment, a module may be implemented in the form of an application-specific integrated circuit (ASIC).
[0197] One embodiment of the present document may be implemented as software (e.g., program (140) of FIG. 1) comprising one or more instructions stored in a storage medium (e.g., internal memory (136) of FIG. 1 or external memory (138) of FIG. 1) that is readable by a machine (e.g., electronic device (101) of FIG. 1). For example, a processor (e.g., processor (120) of FIG. 1) of the machine (e.g., electronic device (101) of FIG. 1) may call at least one of the one or more instructions stored from the storage medium and execute it. This enables the machine to be operated to perform at least one function according to the at least one called instruction. The one or more instructions may include code generated by a compiler or code that can be executed by an interpreter. The storage medium readable by the machine may be provided in the form of a non-transitory storage medium. Here, 'non-temporary' simply means that the storage medium is a tangible device and does not contain a signal (e.g., electromagnetic waves), and the term does not distinguish between cases where data is stored semi-permanently and cases where it is stored temporarily.
[0198] According to one embodiment, the method according to the embodiments disclosed herein may be provided by being included in a computer program product. The computer program product may be traded between a seller and a buyer as a product. The computer program product may be distributed in the form of a device-readable storage medium (e.g., compact disc read-only memory (CD-ROM)), or distributed online (e.g., download or upload) through an application store (e.g., Play Store™) or directly between two user devices (e.g., smartphones). In the case of online distribution, at least a portion of the computer program product may be temporarily stored or temporarily created on a device-readable storage medium, such as the memory of a manufacturer's server, an application store's server, or a relay server.
[0199] According to one embodiment, each component (e.g., module or program) of the components described above may include a singular or multiple entities, and some of the multiple entities may be separated and placed in other components. According to one embodiment, one or more of the components or operations of the aforementioned components may be omitted, or one or more other components or operations may be added. Generally or additionally, multiple components (e.g., module or program) may be integrated into a single component. In this case, the integrated component may perform one or more functions of each of the multiple components in the same or similar manner as those performed by the corresponding component among the multiple components prior to integration. According to one embodiment, operations performed by the module, program, or other components may be executed sequentially, in parallel, iteratively, or heuristically, or one or more of the operations may be executed in a different order, omitted, or one or more other operations may be added.
Claims
1. In an electronic device, At least one processor including a processing circuit; and The electronic device comprises a memory including at least one storage medium for storing instructions, wherein the instructions, when executed individually or collectively by the at least one processor, cause: Using first data collected during a first time period, at least one trainable layer of a base model is trained to obtain a first trained model having at least one first trained parameter, and Using model quality weight information, at least one first learned parameter of the first learned model and at least one second learned parameter of the first merged model are merged to obtain a second merged model having at least one third learned parameter, and Causing the deployment of the above second merge model, The above first merging model is used for at least part of the above first time period, and An electronic device, wherein the above model quality weight information includes a first model quality weight for the first learned model and a second model quality weight for the first merged model, and the second model quality weight is set based on user feedback information for the first merged model.
2. In Paragraph 1, User feedback information regarding the above-mentioned first merger model is, An electronic device configured based on the positive feedback ratio and negative feedback ratio for the output of the first merged model.
3. In Paragraph 1 or 2, The first model quality weight is set based on model performance information, model reliability information, and user feedback information for the first learned model, and An electronic device in which the second model quality weight is set based on model performance information, model reliability information, and user feedback information for the first merged model.
4. In any one of paragraphs 1 through 3, The operation of acquiring the second merged model further utilizes time weight information along with the model quality weight information, wherein the time weight information includes a first time weight for the first learned model and a second time weight for the first merged model, and the first time weight is set higher than the second time weight, an electronic device.
5. In any one of paragraphs 1 through 4, The electronic device in which the above first data is deleted after the above first learned model is acquired.
6. In any one of paragraphs 1 through 5, When the above instructions are executed individually or collectively by the at least one processor, the electronic device: An electronic device that causes some of the multiple layers of the base model to be set as the learnable layers, and at least one layer of the feature extractor among the multiple layers to be set as a fixed layer.
7. In any one of paragraphs 1 through 6, The above second merged model is an electronic device used during at least part of the second time period, which is after the above first time period.
8. In Paragraph 7, When the above instructions are executed individually or collectively by the at least one processor, the electronic device: By using the first data collected during the first time period, the at least one trainable layer of the base model is trained to obtain a second trained model having at least one fourth learned parameter, and Using second time weight information and second model quality weight information, the at least one fourth learned parameter of the second learned model and the at least one third learned parameter of the second merged model are merged to obtain a third merged model having at least one fifth learned parameter, and Causing the deployment of the above third merged model, and electronic device.
9. In any one of paragraphs 1 through 8, The first merged model and the second merged model are on-device models stored in the memory and executed by the electronic device.
10. In a method of an electronic device, The operation of training at least one trainable layer of a base model using first data collected during a first time period to obtain a first trained model having at least one first trained parameter; The operation of obtaining a second merged model having at least one third learned parameter by merging the at least one first learned parameter of the first learned model and the at least one second learned parameter of the first merged model using model quality weight information; and It includes the operation of deploying the above-mentioned second merge model, and The above first merging model is used for at least part of the above first time period, and A method in which the above model quality weight information includes a first model quality weight for the first learned model and a second model quality weight for the first merged model, wherein the second model quality weight is set based on user feedback information for the first merged model.
11. In Paragraph 10, User feedback information regarding the above-mentioned first merger model is, A method established based on the positive feedback ratio and negative feedback ratio for the output of the first merged model.
12. In Paragraph 10 or 11, The first model quality weight is set based on model performance information, model reliability information, and user feedback information for the first learned model, and A method in which the second model quality weight is set based on model performance information, model reliability information, and user feedback information for the first merged model.
13. In any one of paragraphs 10 through 12, The operation of obtaining the second merged model further utilizes time weight information along with the model quality weight information, wherein the time weight information includes a first time weight for the first learned model and a second time weight for the first merged model, and wherein the first time weight is set higher than the second time weight.
14. In any one of paragraphs 10 through 13, A method in which the above first data is deleted after the above first learned model is acquired.
15. In any one of paragraphs 10 to 14, the method is: A method comprising the operation of setting some of the layers of the base model as learnable layers, and setting at least one layer of the feature extractor among the layers as a fixed layer.