CN108012389B - Light adjusting method, terminal device and computer readable storage medium - Google Patents

Light adjusting method, terminal device and computer readable storage medium Download PDF

Info

Publication number
CN108012389B
CN108012389B CN201711060402.0A CN201711060402A CN108012389B CN 108012389 B CN108012389 B CN 108012389B CN 201711060402 A CN201711060402 A CN 201711060402A CN 108012389 B CN108012389 B CN 108012389B
Authority
CN
China
Prior art keywords
light
adjusting
model
data
brightness
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
CN201711060402.0A
Other languages
Chinese (zh)
Other versions
CN108012389A (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.)
Shenzhen H&T Intelligent Control Co Ltd
Original Assignee
Shenzhen H&T Intelligent Control 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 Shenzhen H&T Intelligent Control Co Ltd filed Critical Shenzhen H&T Intelligent Control Co Ltd
Priority to CN201711060402.0A priority Critical patent/CN108012389B/en
Publication of CN108012389A publication Critical patent/CN108012389A/en
Application granted granted Critical
Publication of CN108012389B publication Critical patent/CN108012389B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H05ELECTRIC TECHNIQUES NOT OTHERWISE PROVIDED FOR
    • H05BELECTRIC HEATING; ELECTRIC LIGHT SOURCES NOT OTHERWISE PROVIDED FOR; CIRCUIT ARRANGEMENTS FOR ELECTRIC LIGHT SOURCES, IN GENERAL
    • H05B47/00Circuit arrangements for operating light sources in general, i.e. where the type of light source is not relevant
    • H05B47/10Controlling the light source
    • H05B47/105Controlling the light source in response to determined parameters
    • H05B47/11Controlling the light source in response to determined parameters by determining the brightness or colour temperature of ambient light
    • HELECTRICITY
    • H05ELECTRIC TECHNIQUES NOT OTHERWISE PROVIDED FOR
    • H05BELECTRIC HEATING; ELECTRIC LIGHT SOURCES NOT OTHERWISE PROVIDED FOR; CIRCUIT ARRANGEMENTS FOR ELECTRIC LIGHT SOURCES, IN GENERAL
    • H05B47/00Circuit arrangements for operating light sources in general, i.e. where the type of light source is not relevant
    • H05B47/10Controlling the light source
    • H05B47/105Controlling the light source in response to determined parameters
    • 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
    • Y02BCLIMATE CHANGE MITIGATION TECHNOLOGIES RELATED TO BUILDINGS, e.g. HOUSING, HOUSE APPLIANCES OR RELATED END-USER APPLICATIONS
    • Y02B20/00Energy efficient lighting technologies, e.g. halogen lamps or gas discharge lamps
    • Y02B20/40Control techniques providing energy savings, e.g. smart controller or presence detection

Abstract

The embodiment of the invention discloses a light adjusting method, terminal equipment and a computer readable storage medium, wherein the method comprises the following steps: acquiring test data of light to be adjusted; the test data is used as the input of a light adjusting model, so that light adjusting parameters are obtained, wherein the light adjusting parameters comprise color temperature adjusting parameters and/or brightness adjusting parameters, and the light adjusting model is obtained by training according to the training data of light; and adjusting the light according to the light adjusting parameters. By adopting the embodiment of the invention, the color temperature and/or the brightness of the lamp can be intelligently adjusted, the practicability of light adjustment is improved, and the user experience is improved.

Description

Light adjusting method, terminal device and computer readable storage medium
Technical Field
The invention relates to the technical field of lamp illumination, in particular to a light adjusting method, terminal equipment and a computer readable storage medium.
Background
During the use of the lamp, it is found that the light brightness of the environment is variable, and the reflection of the light by the illuminated object is different, so that the lighting requirements of the lamp for different environments can be different.
In the prior art, there are two main ways of adjusting the brightness and color temperature of a lamp, which are:
first, ambient brightness information around the outside is detected by a light-sensitive sensor and then transmitted back to a micro-processing chip of the lamp. The micro-processing chip adjusts the brightness of the lamp based on the ambient brightness information. However, this method only provides a scheme for adjusting the brightness of the lamp, and does not provide a specific scheme for adjusting the color temperature.
Second, lamp brightness and color temperature adjustment schemes based on user active behavior. For example, the user can adjust the brightness and color temperature of the lamp through a physical key or a terminal application APP; however, this adjustment method is completely dependent on the user, which increases the labor cost of the user and results in poor user experience.
Therefore, an intelligent and efficient floor lamp light adjusting scheme needs to be designed.
Disclosure of Invention
The embodiment of the invention provides a light adjusting method, which can automatically and intelligently adjust the color temperature and/or brightness of a lamp, save labor cost and improve user experience.
In a first aspect, an embodiment of the present invention provides a light adjustment method, where the method includes:
acquiring test data of light to be adjusted;
the test data is used as the input of a light adjusting model, so that light adjusting parameters are obtained, wherein the light adjusting parameters comprise color temperature adjusting parameters and/or brightness adjusting parameters, and the light adjusting model is obtained by training according to the training data of light;
and adjusting the light according to the light adjusting parameters.
In some possible embodiments, the test data comprises at least one of: the lighting control system comprises ambient brightness data, time data and object detection data, wherein the ambient brightness data are used for indicating the current environment of the lighting, the object detection data are used for indicating an object for adjusting the lighting, and the time data are used for indicating the current time for adjusting the lighting.
In some possible embodiments, the obtaining test data of the light to be adjusted includes:
collecting test data of the light to be adjusted by a sensor, wherein when the test data comprises the ambient brightness data and/or the object detection data, the sensor comprises at least one of: luminance sensor, optical sensor, passive form infrared PIR sensor.
In some possible embodiments, before the inputting the test data as an input of a light adjustment model to obtain light adjustment parameters, the method further includes:
obtaining training data, the training data being used to characterize adjustment data associated with the light when the light is adjusted a past time, the adjustment data including at least one of: historical light color temperature, historical light brightness, historical environment brightness, historical light adjusting objects and historical light adjusting time;
and training a machine learning model according to the training data to obtain the trained light adjusting model.
In some possible embodiments, the machine learning model or the light adjustment model comprises any one of: the system comprises a decision tree algorithm model, a Support Vector Machine (SVM) algorithm model, a lifting tree algorithm model, a neural network algorithm model, a proximity algorithm model, a batch gradient descent algorithm (BGD) model, a random gradient descent algorithm (SGD) model and a small batch gradient descent algorithm (MBGD) model.
In some possible embodiments, the light adjustment model comprises a color temperature adjustment model and/or a brightness adjustment model,
when the light adjusting model is the color temperature adjusting model, the light adjusting parameter is the color temperature adjusting parameter;
and when the light adjusting model is the brightness adjusting model, the light adjusting parameter is the brightness adjusting parameter.
In some possible embodiments, when the light adjustment model is a color temperature adjustment model, the training data includes at least a historical light color temperature; when the light adjusting model is a brightness adjusting model, the training data at least comprises historical light brightness.
In a second aspect, an embodiment of the present invention provides a terminal device, including an obtaining unit, a processing unit, and an adjusting unit, where:
the acquisition unit is used for acquiring test data of the light to be adjusted;
the processing unit is used for inputting the test data as a light adjusting model to obtain light adjusting parameters, wherein the light adjusting parameters comprise color temperature adjusting parameters and/or brightness adjusting parameters, and the light adjusting model is obtained by training according to light training data;
the adjusting unit is used for adjusting the light according to the light adjusting parameters.
In a third aspect, an embodiment of the present invention provides another terminal device, including: a processor, a memory, a communication interface, and a bus; the processor, the memory and the communication interface are connected through the bus and complete mutual communication; the memory stores executable program code; the processor executes a program corresponding to the executable program code by reading the executable program code stored in the memory to perform the method of the first aspect.
In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium, in which a computer program is stored, the computer program comprising program instructions, which, when executed by a processor, cause the processor to perform the method of the first aspect.
In the embodiment of the invention, the terminal equipment can obtain the test data of the light to be adjusted; the test data is used as the input of a light adjusting model, so that light adjusting parameters are obtained, wherein the light adjusting parameters comprise color temperature adjusting parameters and/or brightness adjusting parameters, and the light adjusting model is obtained by training according to the training data of light; adjusting the light according to the light adjusting parameters; therefore, the color temperature and/or the brightness of the lamp can be automatically and intelligently adjusted, the labor cost is saved, the practicability of light adjustment is improved, and the user experience is improved.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings needed to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
Fig. 1 is a schematic flow chart of a light adjusting method according to an embodiment of the present invention;
fig. 2 is a schematic flow chart of a light adjusting method according to another embodiment of the present invention;
fig. 3 is a schematic block diagram of a terminal device according to an embodiment of the present invention;
fig. 4 is a schematic block diagram of a terminal device according to another embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, not all, embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
It will be understood that the terms "comprises" and/or "comprising," when used in this specification and the appended claims, specify the presence of stated features, integers, steps, operations, elements, and/or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and/or groups thereof.
It is also to be understood that the terminology used in the description of the invention herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the invention. As used in the specification of the present invention and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise.
It should be further understood that the term "and/or" as used in this specification and the appended claims refers to and includes any and all possible combinations of one or more of the associated listed items.
As used in this specification and the appended claims, the term "if" may be interpreted contextually as "when", "upon" or "in response to a determination" or "in response to a detection". Similarly, the phrase "if it is determined" or "if a [ described condition or event ] is detected" may be interpreted contextually to mean "upon determining" or "in response to determining" or "upon detecting [ described condition or event ]" or "in response to detecting [ described condition or event ]".
In particular implementations, the terminals described in embodiments of the invention include, but are not limited to, other portable devices such as mobile phones, laptop computers, or tablet computers having touch sensitive surfaces (e.g., touch screen displays and/or touch pads). It should also be understood that in some embodiments, the device is not a portable communication device, but is a desktop computer having a touch-sensitive surface (e.g., a touch screen display and/or touchpad).
In the discussion that follows, a terminal that includes a display and a touch-sensitive surface is described. However, it should be understood that the terminal may include one or more other physical user interface devices such as a physical keyboard, mouse, and/or joystick.
The terminal supports various applications, such as one or more of the following: a drawing application, a presentation application, a word processing application, a website creation application, a disc burning application, a spreadsheet application, a gaming application, a telephone application, a video conferencing application, an email application, an instant messaging application, an exercise support application, a photo management application, a digital camera application, a web browsing application, a digital music player application, and/or a digital video player application.
Various applications that may be executed on the terminal may use at least one common physical user interface device, such as a touch-sensitive surface. One or more functions of the touch-sensitive surface and corresponding information displayed on the terminal can be adjusted and/or changed between applications and/or within respective applications. In this way, a common physical architecture (e.g., touch-sensitive surface) of the terminal can support various applications with user interfaces that are intuitive and transparent to the user.
Referring to fig. 1, which is a schematic flow chart of a light adjusting method according to an embodiment of the present invention, the method shown in fig. 1 may include the following steps:
and S102, the terminal equipment acquires test data of the light to be adjusted.
In this application, terminal equipment can be for can luminous lamps and lanterns, for example desk lamp, light etc. or terminal equipment can for support with communication connection's terminal is carried out to lamps and lanterns, communication connection includes but not limited to physical coupling connection or wireless communication connection, terminal equipment can to lamps and lanterns send control command, in order to control the regulation the light of lamps and lanterns. Specifically, the terminal device may control and adjust parameters such as color temperature and brightness of the lamp light, which are specifically set forth below.
The test data is related data influencing light adjustment of the lamp, and the data includes, but is not limited to, any one or more of the following items, current ambient brightness data of the lamp, current time data of the lamp to be adjusted, and current object detection data of the lamp to be adjusted. The object detection data is used to characterize an object that adjusts the lamp lighting, which may be a living object, such as a person, or an inanimate object, such as a terminal device, or the like.
In practical applications, the object detection data is usually represented by a preset character string, where the preset character string includes, but is not limited to, preset numbers, preset letters, and the like, for example, "1" usually represents an object that adjusts the lamp light, and "0" represents an object that adjusts the lamp light, such as a mobile phone, a terminal device, and the like.
And S104, inputting the test data as a light adjusting model to obtain light adjusting parameters, wherein the light adjusting parameters comprise color temperature adjusting parameters and/or brightness adjusting parameters, and the light adjusting model is obtained by training according to training data of light.
In this application, the light adjustment model may be a machine learning model including, but not limited to, any of the following algorithm models: decision Tree algorithms, Support Vector Machine (SVM) algorithms, random forest algorithms, Boosting Tree algorithms, neural network algorithms, neighbor (KNN) algorithms, gradient descent algorithms, and the like, wherein the gradient descent algorithms include, but are not limited to, any of the following: batch Gradient Descent (BGD), random Gradient Descent (SGD), and Mini-Batch Gradient Descent (MBGD). The machine learning model is not described in detail here, and is specifically described in detail below with reference to the SGD as an example.
And S106, adjusting the light of the lamp according to the light adjusting parameters.
In this application, the terminal device may correspondingly adjust the color temperature of the lamp light according to the color temperature adjustment parameter determined in step S104; accordingly, the brightness of the lamp light may be correspondingly adjusted according to the brightness adjustment parameter determined in step S104.
The following specifically illustrates some specific and alternative embodiments to which the present invention relates.
In step S102, the terminal device may collect test data of the lamp light to be adjusted through the sensor. For example, the terminal device may collect, through an optical sensor (brightness sensor), ambient brightness data of the current location of the light fixture. The terminal device can acquire whether a person exists in a preset distance range of the lamp through a passive Infrared Sensor (PIR), and if the person exists, the terminal device can default to an object supporting adjustment of lamp light as the person; correspondingly, if the object does not exist, the terminal device may default to an object supporting adjustment of the lamp light, for example, control through an application APP installed on the terminal device, and the like.
Or the terminal equipment can acquire the test data of the lamp light to be adjusted from a server or other equipment through a network.
Before step S104, the terminal device may train the created machine learning model to obtain the trained light adjustment model.
First, the terminal device may obtain sample training data. In order to ensure the completeness and accuracy of model training, the training data needs to be training data exceeding a preset time period, such as training data of 7 days and more, and the like. The training data includes, but is not limited to, one or more combinations of the following: historical light color temperature, historical light brightness, historical ambient brightness, historical light adjustment objects and historical light adjustment time.
Specifically, when the user adjusts the light each time, adjustment data of the light over the past can be recorded, for example, historical light brightness, ambient environment data of the current lamp, such as historical environment brightness, is collected through a brightness sensor, an object for adjusting the light is detected through a PIR sensor, that is, a historical light adjustment object (or object detection data), and the time for adjusting the light of the lamp, that is, historical light adjustment time, is obtained from a cloud server. Including but not limited to date, time point (e.g., 8:00 am, etc.), etc.
Second, a machine learning model is created. The invention is not described in detail with respect to the creation of the machine learning model.
And finally, training through the machine learning model by using the training data so as to obtain the trained light adjusting model.
Taking the machine learning model or the light adjusting model as an SGD algorithm model as an example, the training data includes historical light color temperature, historical light brightness, historical ambient brightness, historical light adjusting object (such as a person or an object), and historical light adjusting time. During specific training, the terminal equipment can take other parameter data except historical lamplight color temperature and historical lamplight brightness in the training data as input X of the machine learning model, and take the historical lamplight color temperature and the historical lamplight brightness as output Y of the machine learning model, so that unknown parameters in the machine learning model can be obtained, and the trained light adjusting model can be obtained.
Specifically, the SGD model is a linear function, Y = aX1+b1X2+…+bnXn. Here, { X1,X2,…,XnAnd Y is a model output parameter Y in the training data. In the training process, to minimize the error of the SGD model, a loss function can be defined, which is respectively used for (a, b)1,b2…,bn) The derivative function of (a). Is divided by the derivative functionUpdating and determining unknown parameters (a, b) in SGD models1,b2…,bn)。
For example, when the training data includes historical light brightness, historical ambient light brightness, historical light adjustment object and historical light adjustment time, the historical ambient light brightness, the historical light adjustment object and the historical light adjustment time are respectively used as input X of the SGD model1、X2And X3And correspondingly, historical lamp brightness serves as an output Y of the SGD model.
In an alternative embodiment, the light adjustment model may include a color temperature adjustment model and/or a brightness adjustment model. In the specific training, the terminal device may train the two models separately.
Illustratively, taking the brightness adjustment model as an example, the machine learning model is an SGD algorithm model. The brightness adjusting model is used for adjusting the brightness of lamp light in a personalized mode. First, sample training data in a preset time period is obtained. The preset time interval is set independently by the user side or the terminal equipment side, and if the preset time interval is 7 days, the lamp light brightness of the lamp is automatically adjusted within 7 days without using a brightness adjusting model. The training data may include historical light intensity (i.e., the adjustment value of the light intensity by the user over the past), historical ambient light intensity, historical light adjustment objects, and historical light adjustment time. Second, a machine learning model SGD is created. And finally, training the SGD model by using the training data to obtain a trained brightness adjustment model. Specifically, the historical ambient brightness, the historical light adjusting object and the historical light adjusting time in the training data can be used as the input X of the SGD model, and the historical light brightness can be used as the output Y of the SGD model, so that the trained brightness adjusting model and the trained SGD model can be obtained.
Similarly, when training the color temperature adjustment model, training data may be collected first, where the training data may include historical light color temperature (i.e., the adjustment value of the light color temperature by the user over the past), historical ambient brightness, historical light adjustment target, and historical light adjustment time. Second, a machine learning model SGD is created. And finally, training the SGD model by using the training data to obtain a trained color temperature adjusting model. Specifically, historical ambient brightness, historical light adjusting objects and historical light adjusting time in training data can be used as input X of the SGD model, and historical light color temperature can be used as output Y of the SGD model, so that a trained color temperature adjusting model and the trained SGD model can be obtained.
Accordingly, in step S104, the terminal device may utilize the trained light adjustment model to predict the test data, so as to output the obtained light adjustment parameters, such as the color temperature adjustment parameter and/or the brightness adjustment parameter. It should be understood that, when the light adjustment model is a brightness adjustment model, the prediction result output by the brightness adjustment model is a brightness adjustment parameter. Correspondingly, when the light adjusting model is the color temperature adjusting model, the prediction result output by the color temperature adjusting model is the color temperature adjusting parameter.
Correspondingly, in step S106, the terminal device adjusts the color temperature of the lamp light according to the color temperature adjustment parameter. Correspondingly, the brightness of the lamp light is adjusted according to the brightness adjusting parameter.
In an optional embodiment, the terminal may include an Internet device such as a user equipment, a smart phone (e.g., an Android phone, an IOS phone, etc.), a personal computer, a tablet computer, a palm computer, a Mobile Internet device (MID, Mobile Internet Devices), or a wearable smart device, and the embodiment of the present invention is not limited thereto.
In the embodiment of the invention, the terminal equipment can obtain the test data of the light to be adjusted, and the test data is used for influencing the adjustment of the light of the lamp; the test data is used as the input of a light adjusting model, so that light adjusting parameters are obtained, wherein the light adjusting parameters comprise color temperature adjusting parameters and/or brightness adjusting parameters, and the light adjusting model is obtained by training according to the training data of light; adjusting the light of the lamp according to the light adjusting parameters; therefore, the color temperature and/or the brightness of the lamp can be automatically and intelligently adjusted, the labor cost is saved, the practicability of light adjustment is improved, and the user experience is improved.
Fig. 2 shows another light adjustment method according to an embodiment of the present invention. The method as shown in fig. 2 may comprise the following implementation steps:
step S202, training data are obtained, the training data are used for representing adjusting data which are related to the light when the light is adjusted for a past time, and the adjusting data comprise at least one of the following items: historical light color temperature, historical light brightness, historical environment brightness, historical light adjusting objects and historical light adjusting time;
and S204, training the machine learning model according to the training data to obtain a trained light adjusting model.
S206, obtaining test data of light to be adjusted, wherein the test data is used for influencing the adjustment of the light of the lamp;
in an alternative embodiment, the test data comprises at least one of: the lamp lighting control system comprises ambient brightness data, time data and object detection data of the lamp, wherein the object detection data are used for indicating an object for adjusting lamp light, and the time data are used for indicating the current time for adjusting the lamp light.
Step S208, inputting the test data as a light adjusting model so as to obtain light adjusting parameters, wherein the light adjusting parameters comprise color temperature adjusting parameters and brightness adjusting parameters, and the light adjusting model is obtained by training according to training data of light;
in an alternative embodiment, the light adjustment model includes a color temperature adjustment model and a brightness adjustment model,
when the light adjusting model is the color temperature adjusting model, the light adjusting parameter is the color temperature adjusting parameter;
and when the light adjusting model is the brightness adjusting model, the light adjusting parameter is the brightness adjusting parameter.
And S210, adjusting the light according to the light adjusting parameters, wherein the light corresponds to the light adjusting parameters and at least comprises color temperature and brightness.
Details that are not shown or not described in the embodiment of the present invention may specifically refer to the related explanation in the embodiment described in fig. 1, and are not described herein again.
In the embodiment of the invention, the terminal equipment can obtain the test data of the light to be adjusted, and the test data is used for influencing the light adjustment of the lamp; the test data is used as the input of a light adjusting model, so that light adjusting parameters are obtained, wherein the light adjusting parameters comprise color temperature adjusting parameters and/or brightness adjusting parameters, and the light adjusting model is obtained by training according to the training data of light; adjusting the light of the lamp according to the light adjusting parameters; therefore, the color temperature and/or the brightness of the lamp can be automatically and intelligently adjusted, the labor cost is saved, the practicability of light adjustment is improved, and the user experience is improved.
While the method of the embodiments of the present invention has been described in detail, in order to better implement the above-described aspects of the embodiments of the present invention, the following also provides the related apparatus for implementing the aspects.
An embodiment of the present invention further provides a terminal device, and specifically, refer to fig. 3, which is a schematic block diagram of a terminal device provided in an embodiment of the present invention. The terminal device 300 of the present embodiment includes: an obtaining unit 302, a processing unit 304 and an adjusting unit 306, wherein:
the obtaining unit 302 is configured to obtain test data of light to be adjusted;
the processing unit 304 is configured to use the test data as input of a light adjustment model to obtain light adjustment parameters, where the light adjustment parameters include color temperature adjustment parameters and/or brightness adjustment parameters, and the light adjustment model is obtained by training according to training data of light;
the adjusting unit 306 is configured to adjust the light according to the light adjusting parameter.
In some possible embodiments, the test data comprises at least one of: the lighting control system comprises environment brightness data, time data and object detection data, wherein the environment brightness data are used for indicating the current environment of the lighting, the object detection data are used for indicating the object for adjusting the lighting of the lamp, and the time data are used for indicating the current time for adjusting the lighting of the lamp.
In some possible embodiments, the obtaining test data of the light to be adjusted includes: collecting test data of the light to be adjusted by a sensor, wherein when the test data comprises the ambient brightness data and/or the object detection data, the sensor comprises at least one of: luminance sensor, optical sensor, passive form infrared PIR sensor.
In some possible embodiments, the obtaining unit 302 is further configured to obtain training data for characterizing adjustment data associated with the light at a past light adjustment, the adjustment data including at least one of: historical light color temperature, historical light brightness, historical environment brightness, historical light adjusting objects and historical light adjusting time;
the processing unit 304 is further configured to train a machine learning model according to the training data, so as to obtain the trained light adjustment model.
In some possible embodiments, the machine learning model or the light adjustment model comprises any one of: the system comprises a decision tree algorithm model, a Support Vector Machine (SVM) algorithm model, a lifting tree algorithm model, a neural network algorithm model, a proximity algorithm model, a batch gradient descent algorithm (BGD) model, a random gradient descent algorithm (SGD) model and a small batch gradient descent algorithm (MBGD) model.
In some possible embodiments, the light adjustment model comprises a color temperature adjustment model and/or a brightness adjustment model,
when the light adjusting model is the color temperature adjusting model, the light adjusting parameter is the color temperature adjusting parameter;
and when the light adjusting model is the brightness adjusting model, the light adjusting parameter is the brightness adjusting parameter.
In some possible embodiments, when the light adjustment model is a color temperature adjustment model, the training data includes at least a historical light color temperature; when the light adjusting model is a brightness adjusting model, the training data at least comprises historical light brightness.
Details that are not shown or not described in the embodiments of the present invention may specifically refer to the related explanations in the embodiments of the method described in fig. 1-fig. 2, and are not described herein again.
Referring to fig. 4, fig. 4 is a schematic structural diagram of a terminal device according to an embodiment of the present invention. The terminal device of the embodiment includes: at least one processor 601, a communication interface 602, a user interface 603 and a memory 604, wherein the processor 601, the communication interface 602, the user interface 603 and the memory 604 can be connected by a bus or other means, and the embodiment of the present invention is exemplified by being connected by the bus 605. Wherein the content of the first and second substances,
processor 601 may be a general-purpose processor, such as a Central Processing Unit (CPU).
The communication interface 602 may be a wired interface (e.g., an ethernet interface) or a wireless interface (e.g., a cellular network interface or using a wireless local area network interface) for communicating with other electronic devices or websites. In the embodiment of the present invention, the communication interface 602 is specifically configured to recommend the target recommendation object to a user of the electronic device.
The user interface 603 may specifically be a touch panel, including a touch screen and a touch screen, for detecting an operation instruction on the touch panel, and the user interface 603 may also be a physical button or a mouse. The user interface 603 may also be a display screen for outputting, displaying images or data.
Memory 604 may include Volatile Memory (Volatile Memory), such as Random Access Memory (RAM); the Memory may also include a Non-Volatile Memory (Non-Volatile Memory), such as a Read-Only Memory (ROM), a Flash Memory (Flash Memory), a Hard Disk (Hard Disk Drive, HDD), or a Solid-State Drive (SSD); the memory 604 may also comprise a combination of the above types of memory. The memory 604 is used for storing a set of program codes, and the processor 601 is used for calling the program codes stored in the memory 604 and executing the following operations:
acquiring test data of light to be adjusted;
the test data is used as the input of a light adjusting model, so that light adjusting parameters are obtained, wherein the light adjusting parameters comprise color temperature adjusting parameters and/or brightness adjusting parameters, and the light adjusting model is obtained by training according to the training data of light;
and adjusting the light of the lamp according to the light adjusting parameters.
In some possible embodiments, the test data comprises at least one of: the lighting control system comprises environment brightness data, time data and object detection data, wherein the environment brightness data are used for indicating the current environment of the lighting, the object detection data are used for indicating the object for adjusting the lighting of the lamp, and the time data are used for indicating the current time for adjusting the lighting of the lamp.
In some possible embodiments, the processor 801 is configured to perform: collecting test data of the light to be adjusted by a sensor, wherein when the test data comprises the ambient brightness data and/or the object detection data, the sensor comprises at least one of: luminance sensor, optical sensor, passive form infrared PIR sensor.
In some possible embodiments, before the test data is used as an input of the light adjustment model to obtain the light adjustment parameters, the processor 601 is further configured to:
obtaining training data, the training data being used to characterize adjustment data associated with the light when the light is adjusted a past time, the adjustment data including at least one of: historical light color temperature, historical light brightness, historical environment brightness, historical light adjusting objects and historical light adjusting time;
and training a machine learning model according to the training data to obtain the trained light adjusting model.
In some possible embodiments, the machine learning model or the light adjustment model comprises any one of: the system comprises a decision tree algorithm model, a Support Vector Machine (SVM) algorithm model, a lifting tree algorithm model, a neural network algorithm model, a proximity algorithm model, a batch gradient descent algorithm (BGD) model, a random gradient descent algorithm (SGD) model and a small batch gradient descent algorithm (MBGD) model.
In some possible embodiments, the light adjustment model comprises a color temperature adjustment model and/or a brightness adjustment model,
when the light adjusting model is the color temperature adjusting model, the light adjusting parameter is the color temperature adjusting parameter;
and when the light adjusting model is the brightness adjusting model, the light adjusting parameter is the brightness adjusting parameter.
In some possible embodiments, when the light adjustment model is a color temperature adjustment model, the training data includes at least a historical light color temperature; when the light adjusting model is a brightness adjusting model, the training data at least comprises historical light brightness.
The content that is not shown or described in the embodiments of the present invention may refer to the related content in the foregoing embodiments, and is not described herein again.
In another embodiment of the invention, a computer-readable storage medium is provided, which stores a computer program comprising program instructions, which when executed by a processor, implement all or part of the embodiments of the method as described above.
The computer readable storage medium may be an internal storage unit of the terminal according to any of the foregoing embodiments, for example, a hard disk or a memory of the terminal. The computer readable storage medium may also be an external storage device of the terminal, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), and the like provided on the terminal. Further, the computer-readable storage medium may also include both an internal storage unit and an external storage device of the terminal. The computer-readable storage medium is used for storing the computer program and other programs and data required by the terminal. The computer readable storage medium may also be used to temporarily store data that has been output or is to be output.
Those of ordinary skill in the art will appreciate that the elements and algorithm steps of the examples described in connection with the embodiments disclosed herein may be embodied in electronic hardware, computer software, or combinations of both, and that the components and steps of the examples have been described in a functional general in the foregoing description for the purpose of illustrating clearly the interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
It can be clearly understood by those skilled in the art that, for convenience and brevity of description, the specific working processes of the terminal and the unit described above may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the several embodiments provided in the present application, it should be understood that the disclosed terminal and method can be implemented in other manners. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one logical division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may also be an electric, mechanical or other form of connection.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment of the present invention.
In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present invention essentially or partially contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product stored in a storage medium and including instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
While the invention has been described with reference to specific embodiments, the invention is not limited thereto, and various equivalent modifications and substitutions can be easily made by those skilled in the art within the technical scope of the invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.

Claims (6)

1. A light adjusting method is applied to a terminal device, and comprises the following steps:
the method comprises the steps of obtaining test data of light to be adjusted, wherein the test data comprises environment brightness data, object detection data and time data, the environment brightness data is used for indicating the current environment of the light, the object detection data is used for indicating an object for adjusting the light, the time data is used for indicating the current moment for adjusting the light, and the time data comprises date; when the object is a person, the object detection data are obtained through passive infrared sensor PIR detection, when the object is an object, the object detection data are obtained through application program APP control detection or obtained through PIR detection, and the light to be adjusted is the lamp light to be adjusted; if a person exists in a preset distance range of the lamp acquired through the PIR, determining that the object is the person; if no person exists in the preset distance range of the lamp, determining that the object is an object;
using the test data as input of a light adjustment model according to Y = aX1+b1X2+…+bnXnObtaining a light adjusting parameter, wherein the light adjusting model is a random gradient descent algorithm SGD model, and X1,X2,…,XnIs an input parameter, Y is an output parameter, (a, b)1,b2…,bn) Is determined according to a defined loss function for (a, b) respectively1,b2…,bn) A derivative function of; the light adjusting parameters comprise color temperature adjusting parameters and brightness adjusting parameters, and the light adjusting model is obtained by training according to training data of light; the light adjusting model comprises a color temperature adjusting model and a brightness adjusting model, wherein the brightness adjusting model is obtained by training by taking historical environment brightness, historical light adjusting objects and historical light adjusting time in training data as input X of an SGD model and historical light brightness as output Y of the SGD model; the color temperature adjusting model is obtained by training by taking historical environment brightness, historical light adjusting objects and historical light adjusting time in training data as input X of the SGD model and taking historical light color temperature as output Y of the SGD model;
and adjusting the light according to the light adjusting parameters.
2. The method of claim 1, wherein the obtaining test data for the light to be dimmed comprises:
collecting test data of the light to be adjusted by a sensor, wherein the sensor comprises at least one of the following items: luminance sensor, optical sensor, passive form infrared PIR sensor.
3. The method of claim 1, wherein prior to inputting the test data into a light adjustment model to obtain light adjustment parameters, further comprising:
acquiring training data, wherein the training data is used for representing adjusting data associated with light during previous light adjustment;
and training a machine learning model according to the training data to obtain the trained light adjusting model.
4. A terminal device, characterized in that the terminal device comprises an acquisition unit, a processing unit and an adjustment unit, wherein:
the acquisition unit is used for acquiring test data of light to be adjusted, the test data comprises environment brightness data, object detection data and time data, the environment brightness data is used for indicating the current environment of the light, the object detection data is used for indicating an object for adjusting the light, the time data is used for indicating the current moment for adjusting the light, and the time data comprises a date; when the object is a person, the object detection data are obtained through passive infrared sensor PIR detection, when the object is an object, the object detection data are obtained through application program APP control detection or obtained through PIR detection, and the light to be adjusted is the lamp light to be adjusted; if a person exists in a preset distance range of the lamp acquired through the PIR, determining that the object is the person; if no person exists in the preset distance range of the lamp, determining that the object is an object;
the processing unit is used for inputting the test data as a light adjusting model according to Y = aX1+b1X2+…+bnXnObtaining a light adjusting parameter, wherein the light adjusting model is a random gradient descent algorithm SGD model, and X1,X2,…,XnIs an input parameter, Y is an output parameter, (a, b)1,b2…,bn) Is determined according to a defined loss function for (a, b) respectively1,b2…,bn) A derivative function of; the light adjusting parameters comprise color temperature adjusting parameters and brightness adjusting parameters, and the light adjusting model is obtained by training according to training data of light; the light adjusting model comprises a color temperature adjusting model and a brightness adjusting model, wherein the brightness adjusting model is obtained by training by taking historical environment brightness, historical light adjusting objects and historical light adjusting time in training data as input X of an SGD model and historical light brightness as output Y of the SGD model; the color temperature adjusting model is obtained by training by taking historical environment brightness, historical light adjusting objects and historical light adjusting time in training data as input X of the SGD model and taking historical light color temperature as output Y of the SGD model;
the adjusting unit is used for adjusting the light according to the light adjusting parameters.
5. A terminal device, comprising: a processor, a memory, a communication interface, and a bus; the processor, the memory and the communication interface are connected through the bus and complete mutual communication; the memory stores executable program code; the processor executes a program corresponding to the executable program code by reading the executable program code stored in the memory to perform the method of any one of claims 1-3.
6. A computer-readable storage medium, characterized in that the computer storage medium stores a computer program comprising program instructions that, when executed by a processor, cause the processor to perform the method according to any of claims 1-3.
CN201711060402.0A 2017-10-27 2017-10-27 Light adjusting method, terminal device and computer readable storage medium Active CN108012389B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201711060402.0A CN108012389B (en) 2017-10-27 2017-10-27 Light adjusting method, terminal device and computer readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201711060402.0A CN108012389B (en) 2017-10-27 2017-10-27 Light adjusting method, terminal device and computer readable storage medium

Publications (2)

Publication Number Publication Date
CN108012389A CN108012389A (en) 2018-05-08
CN108012389B true CN108012389B (en) 2021-03-26

Family

ID=62052160

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201711060402.0A Active CN108012389B (en) 2017-10-27 2017-10-27 Light adjusting method, terminal device and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN108012389B (en)

Families Citing this family (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109041366A (en) * 2018-06-27 2018-12-18 广东小天才科技有限公司 Desk lamp light luminance adjusting method, device, equipment and storage medium
CN108717873A (en) * 2018-07-20 2018-10-30 同济大学 A kind of space luminous environment AI regulating systems based on unsupervised learning technology
CN109379813B (en) * 2018-12-07 2021-08-17 深圳和而泰智能控制股份有限公司 Color temperature adjustable illumination module and color temperature adjusting method of illumination module
CN109661069B (en) * 2019-01-08 2021-02-26 浙江工业大学 Intelligent LED illumination control method based on support vector machine
CN109740726A (en) * 2019-01-28 2019-05-10 浙江大川照明有限公司 Energy-saving lamp brightness adjusting method and energy-saving lamp based on artificial intelligence
CN110517648A (en) * 2019-09-05 2019-11-29 四川长虹电器股份有限公司 The light-dimming method and system of display device
CN110650573A (en) * 2019-09-27 2020-01-03 阿里巴巴集团控股有限公司 Interaction method and device, intelligent mirror, electronic equipment and computer storage medium
CN112641382B (en) * 2019-10-12 2022-05-06 尚科宁家(中国)科技有限公司 Light supplement control method for sweeping robot and sweeping robot
CN111322578A (en) * 2020-03-10 2020-06-23 佛山市艾温特智能科技有限公司 Household table lamp with intelligent angle adjusting function and adjusting method
CN111669881A (en) * 2020-06-19 2020-09-15 重庆深蜀科技有限公司 Lamplight control method and device based on illuminance clustering and support vector machine
CN111698409A (en) * 2020-06-23 2020-09-22 韶关市启之信息技术有限公司 Indoor photographing light dimming method
CN112074053A (en) * 2020-08-24 2020-12-11 中国建筑科学研究院有限公司 Lighting equipment regulation and control method and device based on indoor environment parameters
CN116867144B (en) * 2023-09-04 2024-01-26 电子科技大学 Navigation aid lamp brightness control method based on neural network

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106604508A (en) * 2017-02-23 2017-04-26 上海斐讯数据通信技术有限公司 Light environment control method and system based on self learning

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
ES2392195T3 (en) * 2006-06-28 2012-12-05 Koninklijke Philips Electronics N.V. Method to control a lighting system based on a target light distribution
CN102413605B (en) * 2011-08-12 2013-12-04 苏州大学 Intelligent street lamp energy-saving control system based on artificial neutral network
CN104968121B (en) * 2015-07-15 2018-02-16 深圳市通普科技有限公司 A kind of lamp light control method and device learnt automatically
CN106250012A (en) * 2016-07-20 2016-12-21 广东欧珀移动通信有限公司 Screen intensity and color temperature adjusting method, device and terminal unit
CN106154834B (en) * 2016-07-20 2019-10-29 百度在线网络技术(北京)有限公司 Method and apparatus for controlling automatic driving vehicle

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106604508A (en) * 2017-02-23 2017-04-26 上海斐讯数据通信技术有限公司 Light environment control method and system based on self learning

Also Published As

Publication number Publication date
CN108012389A (en) 2018-05-08

Similar Documents

Publication Publication Date Title
CN108012389B (en) Light adjusting method, terminal device and computer readable storage medium
KR102471174B1 (en) Method and electronic device for implementing theme
CN110083730B (en) Method and apparatus for managing images using voice tags
KR102309175B1 (en) Scrapped Information Providing Method and Apparatus
KR102329862B1 (en) Method and electronic device for converting color of image
US20160217551A1 (en) Method of configuring screen, electronic device, and storage medium
KR102240279B1 (en) Content processing method and electronic device thereof
KR102363703B1 (en) Method for processing a query, electronic apparatus and server
US20200364457A1 (en) Emotion recognition-based artwork recommendation method and device, medium, and electronic apparatus
KR102246762B1 (en) Method for content adaptation based on ambient environment in electronic device and the electronic device thereof
WO2019041773A1 (en) Apparatus and method for updating prediction model, and computer-readable storage medium
JP6383356B2 (en) Brightness control method, apparatus and program product
CN107330859B (en) Image processing method and device, storage medium and terminal
KR102343990B1 (en) Device For Controlling Respectively Multiple Areas of Display and Method thereof
CN107111335A (en) For the operation that controls electronic installation method and use its electronic installation
KR102222711B1 (en) Electronic device for providing website related to shopping mall and method for operation thereof
KR102274944B1 (en) Apparatus and method for identifying an object
JP2020507159A (en) Picture push method, mobile terminal and storage medium
US10185724B2 (en) Method for sorting media content and electronic device implementing same
CN109416615A (en) Handle the method for touch event and the electronic device suitable for this method
US20180032238A1 (en) Electronic device and method for outputting thumbnail corresponding to user input
KR20180111242A (en) Electronic device and method for providing colorable content
US20170024442A1 (en) Electronic device and method of acquiring user information in electronic device
KR102351317B1 (en) Method for displaying an electronic document and electronic device
KR20200102838A (en) Electronic device for searching content by using image and method for controlling thereof

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