Movatterモバイル変換


[0]ホーム

URL:


CN112328272B - Algorithm upgrading method, device, equipment and storage medium - Google Patents

Algorithm upgrading method, device, equipment and storage medium
Download PDF

Info

Publication number
CN112328272B
CN112328272BCN201910717013.3ACN201910717013ACN112328272BCN 112328272 BCN112328272 BCN 112328272BCN 201910717013 ACN201910717013 ACN 201910717013ACN 112328272 BCN112328272 BCN 112328272B
Authority
CN
China
Prior art keywords
algorithm
target
storage directory
new
content
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
CN201910717013.3A
Other languages
Chinese (zh)
Other versions
CN112328272A (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.)
Zhejiang Uniview Technologies Co Ltd
Original Assignee
Zhejiang Uniview Technologies 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 Zhejiang Uniview Technologies Co LtdfiledCriticalZhejiang Uniview Technologies Co Ltd
Priority to CN201910717013.3ApriorityCriticalpatent/CN112328272B/en
Publication of CN112328272ApublicationCriticalpatent/CN112328272A/en
Application grantedgrantedCritical
Publication of CN112328272BpublicationCriticalpatent/CN112328272B/en
Activelegal-statusCriticalCurrent
Anticipated expirationlegal-statusCritical

Links

Classifications

Landscapes

Abstract

Translated fromChinese

本发明公开了一种算法升级方法、装置、设备及存储介质。其中方法包括:获取新算法内容和新算法属性信息;根据新算法属性信息,确定新算法的目标存储目录,以及新算法在目标存储目录下的标识信息;根据新算法在目标存储目录下的标识信息,将新算法内容存储到目标存储目录下;响应于智能设备反馈的目标算法升级请求,向智能设备发送待访问存储目录中的目标算法内容,供智能设备升级目标算法。本发明通过将算法插件化并存储在调度中心端,以实现算法与软件的解耦,使得智能设备能够从调度中心端获取算法进行升级操作,从而实现了算法的自动升级,减少了算法升级时人力物力的投入成本,同时还能确保智能设备的基础业务正常运行,提高用户体验。

The invention discloses an algorithm upgrade method, device, equipment and storage medium. The method includes: obtaining the new algorithm content and new algorithm attribute information; determining the target storage directory of the new algorithm according to the new algorithm attribute information, and the identification information of the new algorithm in the target storage directory; according to the identification information of the new algorithm in the target storage directory Information, store the new algorithm content in the target storage directory; in response to the target algorithm upgrade request fed back by the smart device, send the target algorithm content in the storage directory to be accessed to the smart device for the smart device to upgrade the target algorithm. The present invention realizes the decoupling of algorithm and software by plugging the algorithm into a plug-in and storing it in the dispatching center, so that the intelligent device can obtain the algorithm from the dispatching center for upgrade operation, thereby realizing automatic upgrade of the algorithm and reducing the time required for algorithm upgrade. The investment cost of human and material resources can also be ensured to ensure the normal operation of the basic business of smart devices and improve user experience.

Description

Translated fromChinese
算法升级方法、装置、设备及存储介质Algorithm upgrade method, device, equipment and storage medium

技术领域Technical field

本发明实施例涉及计算机技术领域,尤其涉及一种算法升级方法、装置、设备及存储介质。Embodiments of the present invention relate to the field of computer technology, and in particular, to an algorithm upgrade method, device, equipment and storage medium.

背景技术Background technique

现如今,随着安防行业的迅猛发展,安防监控平台前端会有大量的智能设备,例如网络摄像机、网络视频录像机等,而对这些智能设备进行管理显得至关重要。例如,对智能设备中算法的升级、添加及删减。Nowadays, with the rapid development of the security industry, there are a large number of smart devices on the front end of the security monitoring platform, such as network cameras, network video recorders, etc., and the management of these smart devices is crucial. For example, upgrades, additions and deletions of algorithms in smart devices.

相关技术中,由于智能设备中的算法一般融合在软件中,因此对智能设备中算法进行升级时,通常是通过人工对智能设备的软件进行升级来实现算法的升级。然而,由于对软件升级耗时长,且需要人工手动进行软件升级,使得升级工作量大、成本高、及时性差,甚至影响智能设备的业务运行。In related technologies, since algorithms in smart devices are generally integrated into software, when upgrading algorithms in smart devices, the algorithm upgrade is usually achieved by manually upgrading the software of the smart device. However, since software upgrades take a long time and require manual software upgrades, the upgrade workload is heavy, the cost is high, the timeliness is poor, and it even affects the business operation of smart devices.

发明内容Contents of the invention

本发明实施例提供一种算法升级方法、装置、设备及存储介质,实现了算法的自动升级,减少了算法升级时人力物力的投入成本,同时还能确保智能设备的基础业务正常运行,提高用户体验。Embodiments of the present invention provide an algorithm upgrade method, device, equipment and storage medium, which realize automatic upgrade of the algorithm, reduce the investment cost of manpower and material resources during the algorithm upgrade, and at the same time ensure the normal operation of the basic business of the intelligent device, and improve the user experience. experience.

第一方面,本发明实施例提供了一种算法升级方法,应用于调度中心,该方法包括:In the first aspect, embodiments of the present invention provide an algorithm upgrade method, which is applied to a dispatch center. The method includes:

获取新算法内容和新算法属性信息;Obtain new algorithm content and new algorithm attribute information;

根据所述新算法属性信息,确定所述新算法的目标存储目录,以及所述新算法在所述目标存储目录下的标识信息;According to the new algorithm attribute information, determine the target storage directory of the new algorithm, and the identification information of the new algorithm in the target storage directory;

根据所述新算法在所述目标存储目录下的标识信息,将所述新算法内容存储到所述目标存储目录下;According to the identification information of the new algorithm in the target storage directory, store the new algorithm content in the target storage directory;

响应于智能设备反馈的目标算法升级请求,向所述智能设备发送待访问存储目录中的目标算法内容,供所述智能设备升级目标算法。In response to the target algorithm upgrade request fed back by the smart device, the target algorithm content in the storage directory to be accessed is sent to the smart device for the smart device to upgrade the target algorithm.

第二方面,本发明实施例提供了一种算法升级方法,应用于智能设备,该方法包括:In the second aspect, embodiments of the present invention provide an algorithm upgrade method, which is applied to smart devices. The method includes:

向调度中心反馈目标算法升级请求,以指示所述调度中心执行如下:根据所述目标算法升级请求中携带的目标算法属性信息,确定所述目标算法的待访问存储目录,并向智能设备发送所述待访问存储目录中的目标算法内容;Feed back the target algorithm upgrade request to the dispatch center to instruct the dispatch center to perform the following: determine the storage directory to be accessed of the target algorithm based on the target algorithm attribute information carried in the target algorithm upgrade request, and send the target algorithm to the intelligent device. Describe the target algorithm content in the storage directory to be accessed;

根据所述目标算法内容,对所述目标算法进行升级。The target algorithm is upgraded according to the content of the target algorithm.

第三方面,本发明实施例还提供了一种算法升级装置,配置于调度中心,该装置包括:In a third aspect, embodiments of the present invention also provide an algorithm upgrade device, which is configured in a dispatch center. The device includes:

获取模块,用于获取新算法内容和新算法属性信息;Acquisition module, used to obtain new algorithm content and new algorithm attribute information;

确定模块,用于根据所述新算法属性信息,确定所述新算法的目标存储目录,以及所述新算法在所述目标存储目录下的标识信息;A determination module, configured to determine the target storage directory of the new algorithm and the identification information of the new algorithm in the target storage directory based on the new algorithm attribute information;

存储模块,用于根据所述新算法在目标存储目录下的标识信息,将所述新算法内容存储到所述目标存储目录下;A storage module, configured to store the content of the new algorithm in the target storage directory according to the identification information of the new algorithm in the target storage directory;

响应模块,用于响应于智能设备反馈的目标算法升级请求,向所述智能设备发送待访问存储目录中的目标算法内容,供所述智能设备升级目标算法。A response module, configured to respond to a target algorithm upgrade request fed back by the smart device, and send the target algorithm content in the storage directory to be accessed to the smart device for the smart device to upgrade the target algorithm.

第四方面,本发明实施例还提供一种算法升级装置,配置于智能设备,该装置包括:In a fourth aspect, embodiments of the present invention also provide an algorithm upgrade device, which is configured on a smart device. The device includes:

请求发送模块,用于向调度中心反馈目标算法升级请求,以指示所述调度中心执行如下:根据所述目标算法升级请求中携带的目标算法属性信息,确定所述目标算法的待访问存储目录,并向智能设备发送所述待访问存储目录中的目标算法内容;The request sending module is used to feed back a target algorithm upgrade request to the dispatch center to instruct the dispatch center to perform the following: determine the storage directory to be accessed of the target algorithm according to the target algorithm attribute information carried in the target algorithm upgrade request, And send the target algorithm content in the storage directory to be accessed to the smart device;

升级模块,用于根据所述目标算法内容,对所述目标算法进行升级。An upgrade module is used to upgrade the target algorithm according to the content of the target algorithm.

第五方面,本发明实施例还提供了一种计算机设备,该计算机设备包括:In a fifth aspect, embodiments of the present invention further provide a computer device, which includes:

一个或多个处理器;one or more processors;

存储装置,用于存储一个或多个程序,a storage device for storing one or more programs,

当一个或多个程序被一个或多个处理器执行,使得一个或多个处理器实现第一方面实施例所述的算法升级方法,或第二方面实施例所述的算法升级方法。When one or more programs are executed by one or more processors, the one or more processors implement the algorithm upgrade method described in the embodiment of the first aspect, or the algorithm upgrade method described in the embodiment of the second aspect.

第六方面,本发明实施例还提供了一种计算机可读存储介质,其上存储有计算机程序,该程序被处理器执行时实现第一方面实施例所述的算法升级方法,或第二方面实施例所述的算法升级方法。In a sixth aspect, embodiments of the present invention also provide a computer-readable storage medium on which a computer program is stored. When the program is executed by a processor, the algorithm upgrade method described in the embodiments of the first aspect is implemented, or the algorithm upgrade method of the second aspect is implemented. The algorithm upgrade method described in the embodiment.

本发明实施例公开的技术方案,具有如下有益效果:The technical solutions disclosed in the embodiments of the present invention have the following beneficial effects:

通过获取新算法内容和新算法属性信息,以根据新算法属性信息,确定新算法的目标存储目录,以及新算法在目标存储目录下的标识信息,根据新算法在目标存储目录下的标识信息,将新算法内容存储到目标存储目录下,然后响应于智能设备反馈的目标算法升级请求,向智能设备发送带访问存储目录中的目标算法内容,供智能设备升级目标算法。由此,通过将算法插件化并存储在调度中心端,以实现算法与软件的解耦,使得智能设备能够从调度中心端获取算法进行升级操作,从而实现了算法的自动升级,减少了算法升级时人力物力的投入成本,同时还能确保智能设备的基础业务正常运行,提高用户体验。By obtaining the new algorithm content and new algorithm attribute information, the target storage directory of the new algorithm is determined based on the new algorithm attribute information, as well as the identification information of the new algorithm in the target storage directory. According to the identification information of the new algorithm in the target storage directory, Store the new algorithm content in the target storage directory, and then respond to the target algorithm upgrade request fed back by the smart device, and send the target algorithm content in the storage directory with access to the smart device for the smart device to upgrade the target algorithm. Therefore, by plugging the algorithm into a plug-in and storing it in the dispatch center, the decoupling of the algorithm and the software is achieved, so that the smart device can obtain the algorithm from the dispatch center for upgrade operations, thereby realizing automatic upgrade of the algorithm and reducing the need for algorithm upgrades. It reduces the investment cost of human and material resources, while also ensuring the normal operation of the basic business of smart devices and improving user experience.

附图说明Description of drawings

图1是本发明提供的一种算法升级方法的流程示意图;Figure 1 is a schematic flow chart of an algorithm upgrade method provided by the present invention;

图2是本发明提供的另一种算法升级方法的流程示意图Figure 2 is a schematic flow chart of another algorithm upgrade method provided by the present invention.

图3是本发明提供的再一种算法升级方法的流程示意图;Figure 3 is a schematic flow chart of yet another algorithm upgrade method provided by the present invention;

图4是本发明提供的又一种算法升级方法的流程图;Figure 4 is a flow chart of yet another algorithm upgrade method provided by the present invention;

图5是本发明提供的一个具体实施例的调度中心与智能设备进行信令交互的示意图;Figure 5 is a schematic diagram of signaling interaction between a dispatch center and an intelligent device according to a specific embodiment of the present invention;

图6是本发明提供的一种算法升级装置的结构示意图;Figure 6 is a schematic structural diagram of an algorithm upgrade device provided by the present invention;

图7是本发明提供的另一种算法升级装置的结构示意图;Figure 7 is a schematic structural diagram of another algorithm upgrade device provided by the present invention;

图8为本发明提供的一种计算机设备的结构示意图。Figure 8 is a schematic structural diagram of a computer device provided by the present invention.

具体实施方式Detailed ways

下面结合附图和实施例对本发明实施例作进一步的详细说明。可以理解的是,此处所描述的具体实施例仅仅用于解释本发明实施例,而非对本发明实施例的限定。另外还需要说明的是,为了便于描述,附图中仅示出了与本发明实施例相关的部分而非全部结构。The embodiments of the present invention will be further described in detail below with reference to the accompanying drawings and examples. It can be understood that the specific embodiments described here are only used to explain the embodiments of the present invention, but not to limit the embodiments of the present invention. In addition, it should be noted that, for convenience of description, only some but not all structures related to the embodiments of the present invention are shown in the drawings.

本发明实施例针对相关技术中,通过人工对智能设备中的软件进行升级来实现算法升级,存在的软件升级耗时长,且需要人工手动进行软件升级,使得升级工作量大、成本高、及时性差,甚至影响智能设备的业务运行的问题,提出一种算法升级方法。Embodiments of the present invention are directed at related technologies where algorithm upgrades are implemented by manually upgrading software in smart devices. Existing software upgrades take a long time and require manual software upgrades, resulting in heavy workload, high cost, and poor timeliness. , and even problems that affect the business operation of smart devices, an algorithm upgrade method is proposed.

本发明实施例,通过获取新算法内容和新算法属性信息,以根据新算法属性信息,确定新算法的目标存储目录,以及新算法在目标存储目录下的标识信息,根据新算法在目标存储目录下的标识信息,将新算法内容存储到目标存储目录下,然后响应于智能设备反馈的目标算法升级请求,向智能设备发送带访问存储目录中的目标算法内容,供智能设备升级目标算法。由此,通过将算法插件化并存储在调度中心端,以实现算法与软件的解耦,使得智能设备能够从调度中心端获取算法进行升级操作,从而实现了算法的自动升级,减少了算法升级时人力物力的投入成本,同时还能确保智能设备的基础业务正常运行,提高用户体验。In the embodiment of the present invention, by obtaining the new algorithm content and the new algorithm attribute information, the target storage directory of the new algorithm is determined based on the new algorithm attribute information, as well as the identification information of the new algorithm in the target storage directory, and the new algorithm is stored in the target storage directory according to the new algorithm. Then, in response to the target algorithm upgrade request fed back by the smart device, send the target algorithm content in the storage directory with access to the smart device for the smart device to upgrade the target algorithm. Therefore, by plugging the algorithm into a plug-in and storing it in the dispatch center, the decoupling of the algorithm and the software is achieved, so that the smart device can obtain the algorithm from the dispatch center for upgrade operations, thereby realizing automatic upgrade of the algorithm and reducing the need for algorithm upgrades. It reduces the investment cost of human and material resources, while also ensuring the normal operation of the basic business of smart devices and improving user experience.

下面参考附图描述本发明实施例的算法升级方法、装置、设备及存储介质进行详细说明。The algorithm upgrade method, apparatus, equipment and storage medium according to the embodiments of the present invention will be described in detail below with reference to the accompanying drawings.

首先,以调度中心为例对本发明实施例的算法升级方法进行详细描述。First, the algorithm upgrade method of the embodiment of the present invention is described in detail by taking the dispatch center as an example.

图1是本发明提供的一种算法升级方法的流程示意图,本发明实施例可适用于对智能设备中算法升级的场景,该方法可由本发明实施例提供的配置于调度中心的算法升级装置来执行,该装置可以由软件和/硬件实现,并可应用于调度中心中。该方法具体包括如下:Figure 1 is a schematic flow chart of an algorithm upgrade method provided by the present invention. The embodiment of the present invention can be applied to the scenario of upgrading the algorithm in the intelligent device. The method can be performed by the algorithm upgrade device configured in the dispatch center provided by the embodiment of the present invention. Execution, the device can be implemented by software and/or hardware, and can be applied in a dispatch center. The method specifically includes the following:

S101,获取新算法内容和新算法属性信息。S101, obtain new algorithm content and new algorithm attribute information.

在本实施例中,新算法是技术人员对任意算法进行更新后得到的,并在得到新算法之后通过客户端向调度中心发送新算法上传请求,以使调度中心根据获取到的新算法上传请求,获取新算法上传请求中携带的新算法内容和新算法属性信息。In this embodiment, the new algorithm is obtained by technicians after updating any algorithm. After obtaining the new algorithm, a new algorithm upload request is sent to the dispatch center through the client, so that the dispatch center uploads the request according to the obtained new algorithm. , obtain the new algorithm content and new algorithm attribute information carried in the new algorithm upload request.

其中,客户端可以是任一具有操作入口的设备,例如电脑、个人数字化助理等,此处对其不做具体限定。The client can be any device with an operation portal, such as a computer, a personal digital assistant, etc., which is not specifically limited here.

S102,根据所述新算法属性信息,确定所述新算法的目标存储目录,以及所述新算法在所述目标存储目录下的标识信息。S102: Determine the target storage directory of the new algorithm and the identification information of the new algorithm in the target storage directory based on the new algorithm attribute information.

由于新算法属性信息可包括:新算法版本和/或新算法更新时间,以及新算法类型和新算法模型。其中,新算法类型可以是,但不限于:人脸算法、车辆算法、机非人算法、人体算法等,此处对其不做具体限定。Because the new algorithm attribute information may include: new algorithm version and/or new algorithm update time, as well as new algorithm type and new algorithm model. Among them, the new algorithm type can be, but is not limited to: face algorithm, vehicle algorithm, machine-non-human algorithm, human body algorithm, etc., which are not specifically limited here.

为此,本实施例中根据新算法属性信息,确定新算法的目标存储目录,以及新算法在目标存储目录下的标识信息,可包括:To this end, in this embodiment, the target storage directory of the new algorithm is determined based on the attribute information of the new algorithm, and the identification information of the new algorithm in the target storage directory may include:

根据新算法类型和新算法模型,确定新算法的目标存储目录;According to the new algorithm type and new algorithm model, determine the target storage directory of the new algorithm;

根据新算法版本和/或新算法更新时间,确定新算法在目标存储目录下的标识信息。Determine the identification information of the new algorithm in the target storage directory based on the new algorithm version and/or the new algorithm update time.

需要说明的是,本实施例中新算法模型可以根据设备端中图像处理器芯片的性能来确定,同一种算法,芯片不一样,模型也会不一样。其中新算法模型可根据不同维度算法来确定。例如,256维度算法为一个算法模型;128维度算法为另一个算法模型。在本实施例中,对于图像而言,维度是指图像中特征向量的数量。It should be noted that the new algorithm model in this embodiment can be determined based on the performance of the image processor chip in the device. For the same algorithm, if the chip is different, the model will be different. The new algorithm model can be determined based on algorithms of different dimensions. For example, the 256-dimensional algorithm is one algorithm model; the 128-dimensional algorithm is another algorithm model. In this embodiment, for an image, the dimension refers to the number of feature vectors in the image.

在本实施例中,新算法模型可以通过新算法的精度,或者新算法复杂度描述。其中,若芯片性能好,则新算法精度越高或者复杂度越高,反之新算法精度低或者复杂度越低。In this embodiment, the new algorithm model can be described by the accuracy of the new algorithm or the complexity of the new algorithm. Among them, if the chip performance is good, the new algorithm will have higher accuracy or complexity, otherwise the new algorithm will have low accuracy or complexity.

进一步的,本实施例可通过以下方式,确定新算法的目标存储目录:Further, this embodiment can determine the target storage directory of the new algorithm in the following manner:

方式一:method one:

将新算法类型与预先建立的至少两个存储目录进行匹配,若新算法类型与任意存储目录匹配成功,则将新算法模型与上述任意存储目录再匹配;若新算法模型与上述任一存储目录匹配成功,则将该存储目录确定为新算法的目标存储目录。Match the new algorithm type with at least two pre-established storage directories. If the new algorithm type successfully matches any storage directory, then match the new algorithm model with any of the above storage directories; if the new algorithm model matches any of the above storage directories, If the match is successful, the storage directory is determined as the target storage directory of the new algorithm.

例如,若预先建立4个存储目录,分别为:/mnt/face/model1;/mnt/face/model2;/mnt/vehicle/model1;/mnt/vehicle/model1,新算法类型为face,新算法模型为model2,则算法升级装置可先将face分别与/mnt/face/model1;/mnt/face/model2;/mnt/vehicle/model1;/mnt/vehicle/model1进行匹配,确定出新算法类型face,与/mnt/face/model1和/mnt/face/model2匹配,然后再将model2分别与/mnt/face/model1和/mnt/face/model2匹配,确定出model2与/mnt/face/model2匹配,则确定/mnt/face/model2为目标存储目录。For example, if 4 storage directories are created in advance, namely: /mnt/face/model1; /mnt/face/model2; /mnt/vehicle/model1; /mnt/vehicle/model1, the new algorithm type is face, and the new algorithm model is model2, the algorithm upgrade device can first match face with /mnt/face/model1; /mnt/face/model2; /mnt/vehicle/model1; /mnt/vehicle/model1 respectively to determine the new algorithm type face, Match /mnt/face/model1 and /mnt/face/model2, and then match model2 with /mnt/face/model1 and /mnt/face/model2 respectively to determine that model2 matches /mnt/face/model2, then Determine /mnt/face/model2 as the target storage directory.

方式二:Method two:

根据新算法类型建立一级目录,根据新算法模型建立二级目录,得到目标存储目录。Establish a first-level directory based on the new algorithm type and a second-level directory based on the new algorithm model to obtain the target storage directory.

例如,若新算法类型为face,新算法模型为model3,则可将face作为一级目录,model3作为二级目录,得到目标存储目录为/mnt/face/model3。For example, if the new algorithm type is face and the new algorithm model is model3, then face can be used as the first-level directory and model3 as the second-level directory, and the target storage directory is /mnt/face/model3.

其中,若任一新算法的算法类型和算法模型与已建好的存储目录相匹配,则直接将匹配的存储目录确定为目标存储目录,从而能够提高确定目标存储目录速度,且避免相同存储目录的重复建立。Among them, if the algorithm type and algorithm model of any new algorithm match the already established storage directory, the matching storage directory will be directly determined as the target storage directory, thereby improving the speed of determining the target storage directory and avoiding the same storage directory. of repeated creation.

需要说明的是,本实施例上述两种方式可以单独实施,也可以相互结合实施,此处对其不做具体限定。It should be noted that the above two methods in this embodiment can be implemented individually or in combination with each other, and are not specifically limited here.

进一步的,由于新算法属性信息中不同新算法类型和新算法模型,对应有不同的新算法版本和/或新算法更新时间,为了便于后续获取新算法内容进行升级操作,本实施例可根据新算法版本和/或新算法更新时间,确定新算法在目标存储目录下的标识信息。Furthermore, since different new algorithm types and new algorithm models in the new algorithm attribute information correspond to different new algorithm versions and/or new algorithm update times, in order to facilitate subsequent acquisition of new algorithm content for upgrade operations, this embodiment can be based on the new algorithm. Algorithm version and/or new algorithm update time, determine the identification information of the new algorithm in the target storage directory.

例如,若新算法版本为2.0,新算法更新时间为2019-6-2,目标存储目录为/mnt/face/model3,则可将2.0,2019-6-2确定为新算法在/mnt/face/model3下的标识信息。For example, if the new algorithm version is 2.0, the new algorithm update time is 2019-6-2, and the target storage directory is /mnt/face/model3, then 2.0 and 2019-6-2 can be determined as the new algorithm in /mnt/face Identification information under /model3.

可以理解的是,本实施例中新算法版本和/或新算法更新时间,可以是新算法版本;或者,新算法更新时间;又或者,新算法版本和新算法更新时间,此处对其不做具体限定。It can be understood that in this embodiment, the new algorithm version and/or the new algorithm update time may be the new algorithm version; or the new algorithm update time; or the new algorithm version and the new algorithm update time, which are not discussed here. Make specific limitations.

S103,根据所述新算法在所述目标存储目录下的标识信息,将所述新算法内容存储到所述目标存储目录下。S103: Store the new algorithm content in the target storage directory according to the identification information of the new algorithm in the target storage directory.

例如,若新算法属性信息中新算法版本为2.2,新算法更新时间为2019-7-3,目标存储目录为:/mnt/face/model3,则根据标识信息为2.2;2019-7-3,将新算法内容存储到/mnt/face/model3下。即建立标识信息与目标存储目录的对应关系。For example, if the new algorithm version in the new algorithm attribute information is 2.2, the new algorithm update time is 2019-7-3, and the target storage directory is: /mnt/face/model3, then according to the identification information, it is 2.2; 2019-7-3. Store the new algorithm content under /mnt/face/model3. That is, a corresponding relationship between the identification information and the target storage directory is established.

进一步的,为了对算法进行统一的管理,本实施例还可在调度中心设置一算法仓库,以用于存储不同的算法内容。也就是说,当技术人员对任意算法进行更新得到新算法之后,可通过客户端将新算法上传至调度中心,以使调度中心根据新算法内容在目标存储目录下的标识信息,将新算法内容存储于算法仓库中,以得到新算内容存储路径。进而,根据新算法内容存储路径即可获取对应的新算法内容。Furthermore, in order to uniformly manage algorithms, this embodiment can also set up an algorithm warehouse in the dispatch center to store different algorithm contents. That is to say, when technicians update any algorithm to obtain a new algorithm, they can upload the new algorithm to the dispatch center through the client, so that the dispatch center can upload the new algorithm content to the dispatch center based on the identification information of the new algorithm content in the target storage directory. Store it in the algorithm warehouse to obtain the new calculation content storage path. Furthermore, the corresponding new algorithm content can be obtained according to the new algorithm content storage path.

S104,响应于智能设备反馈的目标算法升级请求,向所述智能设备发送待访问存储目录中的目标算法内容,供所述智能设备升级目标算法。S104. In response to the target algorithm upgrade request fed back by the smart device, send the target algorithm content in the storage directory to be accessed to the smart device for the smart device to upgrade the target algorithm.

在本实施例中,智能设备可以是但不限于:网络摄像机、网络视频录像机、智能服务器等。In this embodiment, the smart device may be but is not limited to: a network camera, a network video recorder, a smart server, etc.

可选的,将新算法内容存储到目标存储目录下之后,智能设备可向调度中心发送目标算法升级请求,使得调度中心可根据目标算法升级请求获取相应的目标算法内容,以将获取的目标算法内容发送给智能设备,从而智能设备可根据获取到的目标算法内容进行目标算法的升级操作。Optionally, after storing the new algorithm content in the target storage directory, the smart device can send a target algorithm upgrade request to the dispatch center, so that the dispatch center can obtain the corresponding target algorithm content according to the target algorithm upgrade request, so as to transfer the obtained target algorithm The content is sent to the smart device, so that the smart device can perform an upgrade operation of the target algorithm based on the acquired target algorithm content.

其中,智能设备向调度中心反馈目标算法升级请求的方式,可以通过有线方式,或者无线方式实现,此处对其不做具体限定。Among them, the way in which the smart device feeds back the target algorithm upgrade request to the dispatch center can be implemented through wired or wireless methods, which are not specifically limited here.

具体实现时,调度中心可根据获取的目标算法请求中携带的目标算法类型和目标算法模型,确定待访问存储目录,再根据目标算法请求中携带的目标算法版本和/或目标算法更新时间,从上述待访问存储目录中获取目标算法内容,然后将获取的目标算法内容下发给智能设备,以供智能设备升级目标算法。During specific implementation, the dispatch center can determine the storage directory to be accessed based on the target algorithm type and target algorithm model carried in the obtained target algorithm request, and then based on the target algorithm version and/or target algorithm update time carried in the target algorithm request, from The target algorithm content is obtained from the above-mentioned storage directory to be accessed, and then the obtained target algorithm content is delivered to the smart device so that the smart device can upgrade the target algorithm.

本发明实施例提供的算法升级方法,通过获取新算法内容和新算法属性信息,以根据新算法属性信息,确定新算法的目标存储目录,以及新算法在目标存储目录下的标识信息,根据新算法在目标存储目录下的标识信息,将新算法内容存储到目标存储目录下,然后响应于智能设备反馈的目标算法升级请求,向智能设备发送带访问存储目录中的目标算法内容,供智能设备升级目标算法。由此,通过将算法插件化并存储在调度中心端,以实现算法与软件的解耦,使得智能设备能够从调度中心端获取算法进行升级操作,从而实现了算法的自动升级,减少了算法升级时人力物力的投入成本,同时还能确保智能设备的基础业务正常运行,提高用户体验。The algorithm upgrade method provided by the embodiment of the present invention determines the target storage directory of the new algorithm based on the new algorithm attribute information and the identification information of the new algorithm in the target storage directory by obtaining the new algorithm content and the new algorithm attribute information. The identification information of the algorithm in the target storage directory, stores the new algorithm content in the target storage directory, and then responds to the target algorithm upgrade request fed back by the smart device, sends the target algorithm content in the storage directory with access to the smart device for the smart device Upgrade the target algorithm. Therefore, by plugging the algorithm into a plug-in and storing it in the dispatch center, the decoupling of the algorithm and the software is achieved, so that the smart device can obtain the algorithm from the dispatch center for upgrade operations, thereby realizing automatic upgrade of the algorithm and reducing the need for algorithm upgrades. It reduces the investment cost of human and material resources, while also ensuring the normal operation of the basic business of smart devices and improving user experience.

在上述实施例的基础上,S103之后还包括:若根据任一算法内容的标识信息确定该算法内容在调度中心的存储时长超过算法留存期,则删除该算法内容。Based on the above embodiment, S103 also includes: if it is determined based on the identification information of any algorithm content that the storage time of the algorithm content in the dispatch center exceeds the algorithm retention period, delete the algorithm content.

其中,算法留存期可以根据实际应用场景进行适应性设置,例如6个月、8个月等等,此处对其不做具体限定。Among them, the algorithm retention period can be adaptively set according to actual application scenarios, such as 6 months, 8 months, etc., and there is no specific limit here.

可选的,为了使得设备端在进行算法升级后,仍能使用历史算法提取图像特征执行以图搜图等应用,本实施例调度中心可将历史算法内容与新算法内容同时存储。从而设备端根据自身的算法内容进行以图搜图应用时,可利用调度中心存储的新算法内容和历史算法内容,分别对待搜索图像进行图像特征提取。然后,根据新算法内容提取的图像特征和历史算法内容提取的图像特征,与各自对应图像数据进行匹配,得到与图像特征相匹配的全部图像数据。Optionally, in order to enable the device to still use the historical algorithm to extract image features and perform applications such as image search after the algorithm is upgraded, the dispatch center in this embodiment can store the historical algorithm content and the new algorithm content at the same time. Therefore, when the device performs an image search application based on its own algorithm content, it can use the new algorithm content and historical algorithm content stored in the dispatch center to extract image features from the image to be searched respectively. Then, the image features extracted according to the new algorithm content and the image features extracted from the historical algorithm content are matched with their corresponding image data to obtain all image data that match the image features.

然而,随着时间的推移,历史算法内容在调度中心的存储时长会早于升级后的新算法内容,超过算法留存期。对应的历史算法内容产生的图像数据也会被新算法内容产生的图像数据完全覆盖。从而,当设备端在利用历史算法内容提取图像特征执行以图搜图应用时,无法获取历史算法内容产生的图像数据,这就造成不必要的计算资源浪费,并且还会增加调度中心的维护压力。However, as time goes by, the historical algorithm content will be stored in the dispatch center earlier than the upgraded new algorithm content, exceeding the algorithm retention period. The image data generated by the corresponding historical algorithm content will also be completely covered by the image data generated by the new algorithm content. Therefore, when the device uses the historical algorithm content to extract image features and execute the image search application, it cannot obtain the image data generated by the historical algorithm content, which causes unnecessary waste of computing resources and increases the maintenance pressure of the dispatch center. .

对此,本实施例通过根据算法内容的标识信息(算法版本和/或算法更新时间)确定该算法内容在调度中心的存储时长是否超过算法留存期,若该算法内容存储时长超过算法留存期,则将该算法内容删除,以增加算法内容存储空间,同时减轻调度中心的维护压力。In this regard, this embodiment determines whether the storage time of the algorithm content in the dispatch center exceeds the algorithm retention period based on the identification information of the algorithm content (algorithm version and/or algorithm update time). If the storage time of the algorithm content exceeds the algorithm retention period, Then delete the algorithm content to increase the storage space of the algorithm content and reduce the maintenance pressure of the dispatch center.

在本发明实施例中,调度中心可根据新算法内容的图像采集时间和历史算法内容的更新时间,确定历史算法内容的图像数据是否能被新算法内容的图像数据完全覆盖。具体实现时,可将新算法内容的图像采集时间,与历史算法内容的更新时间相比较,以确定新算法内容采集图像时间是否晚于历史算法更新时间,若是则说明历史算法内容的图像数据可被覆盖,依次类推直至历史算法内容的全部图像数据被新算法内容采集的图像完全覆盖为止。In the embodiment of the present invention, the dispatch center can determine whether the image data of the historical algorithm content can be completely covered by the image data of the new algorithm content based on the image collection time of the new algorithm content and the update time of the historical algorithm content. During specific implementation, the image acquisition time of the new algorithm content can be compared with the update time of the historical algorithm content to determine whether the image acquisition time of the new algorithm content is later than the update time of the historical algorithm. If so, it means that the image data of the historical algorithm content can be be covered, and so on until all the image data of the historical algorithm content are completely covered by the images collected by the new algorithm content.

其中,当历史算法内容生成的图像数据被新算法内容生成的图像数据完全覆盖时,可通过后台自动向调度中心发送删除指令,以使调度中心将历史算法内容删除。Among them, when the image data generated by the historical algorithm content is completely covered by the image data generated by the new algorithm content, a deletion instruction can be automatically sent to the dispatch center through the background, so that the dispatch center deletes the historical algorithm content.

也就是说,本实施例通过将存储时长超过算法留存期的算法内容进行删除,可保证调度中心始终有足够的存储空间来存储新算法,并且还能减轻调度中心对算法的维护压力。In other words, this embodiment can ensure that the dispatch center always has enough storage space to store new algorithms by deleting algorithm content that has been stored longer than the algorithm retention period, and can also reduce the dispatch center's maintenance pressure on the algorithm.

通过上述分析可知,本发明实施例通过根据新算法属性信息,确定新算法的目标存储目录,以及新算法在目标存储目录下的标识信息,根据新算法在目标存储目录下的标识信息,将新算法内容存储到目标存储目录下,以供智能设备根据存储的新算法内容对目标算法进行升级。It can be seen from the above analysis that the embodiment of the present invention determines the target storage directory of the new algorithm based on the attribute information of the new algorithm, and the identification information of the new algorithm in the target storage directory, and stores the new algorithm according to the identification information of the new algorithm in the target storage directory. The algorithm content is stored in the target storage directory for the smart device to upgrade the target algorithm based on the stored new algorithm content.

在本发明的另一种实现场景中,本发明实施例还可将新算法内容存储到目标存储目录下还包括:将历史算法内容和新算法内容兼容性存储到目标存储目录下,以便于后续执行以图搜图等应用。下面结合图2,对本发明实施例的算法升级方法的上述情况进行具体说明。In another implementation scenario of the present invention, the embodiment of the present invention can also store the new algorithm content in the target storage directory, which also includes: storing the compatibility of the historical algorithm content and the new algorithm content in the target storage directory to facilitate subsequent Execute applications such as image search. The above situation of the algorithm upgrade method according to the embodiment of the present invention will be described in detail below with reference to FIG. 2 .

S201,获取新算法内容和新算法属性信息。S201: Obtain new algorithm content and new algorithm attribute information.

S202,根据所述新算法属性信息,确定所述新算法的目标存储目录,以及所述新算法在所述目标存储目录下的标识信息。S202: Determine the target storage directory of the new algorithm and the identification information of the new algorithm in the target storage directory based on the new algorithm attribute information.

S203,若所述目标存储目录中存储有与新算法内容类型相同的历史算法内容,则在所述目标存储目录中兼容存储所述新算法内容和所述历史算法内容;其中,所述新算法内容和所述历史算法内容在所述目标存储目录下的标识信息不同。S203. If the target storage directory stores historical algorithm content of the same type as the new algorithm content, then compatible storage of the new algorithm content and the historical algorithm content in the target storage directory; wherein, the new algorithm The identification information in the target storage directory of the content and the historical algorithm content is different.

实际应用过程中,当设备端的算法进行升级后,存在新算法内容提取的图像特征与历史算法内容提取的图像特征不相同的问题。例如,以人脸图像为例,历史算法内容基于128位提取图像特征,而新算法内容基于256位提取图像特征。从而导致新算法内容无法对历史算法内容提取的图像特征执行以图搜图的应用,仅能根据新算法内容提取的图像特征执行以图搜图应用,使得搜索的图像数据无法获取历史算法内容产生的图像数据,导致获取的数据不全面应用受到限制。In the actual application process, when the algorithm on the device side is upgraded, there is a problem that the image features extracted by the content of the new algorithm are different from the image features extracted by the content of the historical algorithm. For example, taking human face images as an example, the historical algorithm content is based on 128-bit extraction of image features, while the new algorithm content is based on 256-bit extraction of image features. As a result, the new algorithm content cannot perform the image search application on the image features extracted from the historical algorithm content. It can only perform the image search application based on the image features extracted by the new algorithm content, making the searched image data unable to obtain the historical algorithm content. image data, resulting in limited application of the acquired data.

为此,本实施例可将相同类型的新算法内容和历史算法内容兼容性存储在目标存储目录下,并且新算法内容和历史算法内容在目标存储目录下的标识信息不同。从而使得后续执行以图搜图应用时,可从新算法内容和历史算法内容各自对应的图像数据中,获取符合条件的图像,使得最终获取的数据更全面。To this end, this embodiment can store the same type of new algorithm content and historical algorithm content in the target storage directory with compatibility, and the new algorithm content and the historical algorithm content have different identification information in the target storage directory. Therefore, when the image search application is subsequently executed, qualified images can be obtained from the image data corresponding to the new algorithm content and the historical algorithm content, making the final data obtained more comprehensive.

具体实现时,本实施例在利用调度中心存储的算法执行以图搜图应用时,可加载已存储的相同类型的新算法内容和历史算法内容。然后利用新算法内容和历史算法内容,分别对用户输入的图像进行图像特征提取,并为新算法内容和历史算法内容提取的图像特征设置标注信息,以标注图像特征是由哪个算法提取。从而调度中心可根据算法提取的图像特征的标注信息,在对应算法的图像数据中进行图像特征匹配,以得到与图像特征相匹配的图像数据,并将匹配结果通过客户端向用户进行显示,从而使得获取到的图像数据更全面。During specific implementation, this embodiment can load new algorithm content and historical algorithm content of the same type that have been stored when executing the image search application using the algorithm stored in the dispatch center. Then use the new algorithm content and the historical algorithm content to extract image features from the image input by the user, and set annotation information for the image features extracted from the new algorithm content and the historical algorithm content to mark which algorithm the image features were extracted by. Therefore, the dispatch center can perform image feature matching in the image data of the corresponding algorithm based on the annotation information of the image features extracted by the algorithm to obtain image data that matches the image features, and display the matching results to the user through the client, thereby This makes the image data obtained more comprehensive.

通过上述分析可知,本发明实施例在目标存储目录中存储有与新算法内容类型相同的历史算法内容,则在目标存储目录中兼容存储新算法内容和历史算法内容,以实现算法内容的兼容性存储。From the above analysis, it can be seen that in the embodiment of the present invention, if the historical algorithm content of the same type as the new algorithm content is stored in the target storage directory, then the new algorithm content and the historical algorithm content are compatible and stored in the target storage directory to achieve compatibility of the algorithm content. storage.

在本发明的另一种实现场景中,本实施例调度中心向智能设备发送目标算法内容之前,还可接收智能设备发送的算法信息获取请求,以根据算法信息获取请求携带的目标算法的设备端算法类型和设备端算法模型,确定待访问存储目录,以将待访问存储目录中的目标算法的调度端版本和/或调度端更新时间下发给智能设备,供智能设备确定目标算法是否升级。下面结合图3,对本发明实施例的算法升级方法的上述情况进行具体说明。In another implementation scenario of the present invention, before sending the target algorithm content to the smart device, the dispatch center in this embodiment can also receive an algorithm information acquisition request sent by the smart device to obtain the device side of the target algorithm carried in the algorithm information acquisition request. The algorithm type and device-side algorithm model are used to determine the storage directory to be accessed, so as to deliver the scheduling-side version and/or the scheduling-side update time of the target algorithm in the storage directory to be accessed to the smart device for the smart device to determine whether the target algorithm is upgraded. The above situation of the algorithm upgrade method according to the embodiment of the present invention will be described in detail below with reference to FIG. 3 .

图3是本发明提供的再一种算法升级方法的流程示意图。如图3所示,该算法升级方法可以包括以下:Figure 3 is a schematic flow chart of yet another algorithm upgrade method provided by the present invention. As shown in Figure 3, the algorithm upgrade method can include the following:

S301,获取新算法内容和新算法属性信息。S301. Obtain new algorithm content and new algorithm attribute information.

S302,根据所述新算法属性信息,确定所述新算法的目标存储目录,以及所述新算法在所述目标存储目录下的标识信息。S302: Determine the target storage directory of the new algorithm and the identification information of the new algorithm in the target storage directory based on the new algorithm attribute information.

S303,根据所述新算法在所述目标存储目录下的标识信息,将所述新算法内容存储到所述目标存储目录下。S303: Store the new algorithm content in the target storage directory according to the identification information of the new algorithm in the target storage directory.

S304,响应于所述智能设备发送的算法信息获取请求,根据所述算法信息获取请求中携带的目标算法的设备端算法类型和设备端算法模型,确定所述待访问存储目录。S304. In response to the algorithm information acquisition request sent by the smart device, determine the storage directory to be accessed according to the device-side algorithm type and device-side algorithm model of the target algorithm carried in the algorithm information acquisition request.

S305,将所述待访问存储目录中的目标算法的调度端版本和/或调度端更新信息下发给所述智能设备,供所述智能设备确定所述目标算法是否升级。S305: Send the dispatcher version and/or dispatcher update information of the target algorithm in the storage directory to be accessed to the smart device, so that the smart device can determine whether the target algorithm is upgraded.

其中,智能设备可以是但不限于:网络摄像机、网络视频录像机、智能服务器等。Among them, smart devices can be but are not limited to: network cameras, network video recorders, smart servers, etc.

可选的,智能设备可向调度中心发送算法信息获取请求,并将目标算法的设备端算法类型和设备端算法模型携带在算法信息获取请求中,以使调度中心通过对算法信息获取请求进行解析,得到目标算法的设备端算法类型和设备端算法模型。然后,根据设备端算法类型和设备端算法模型,在存储目录中确定待访问存储目录。Optionally, the smart device can send an algorithm information acquisition request to the dispatch center, and carry the device-side algorithm type and device-side algorithm model of the target algorithm in the algorithm information acquisition request, so that the dispatch center can parse the algorithm information acquisition request. , obtain the device-side algorithm type and device-side algorithm model of the target algorithm. Then, according to the device-side algorithm type and the device-side algorithm model, the storage directory to be accessed is determined in the storage directory.

在本实施例中,智能设备可周期性的向调度中心发送算法信息获取请求,以提高算法升级的及时性。其中,智能设备向调度中心发送算法信息获取请求的方式,可以通过有线方式,或者无线方式实现,此处对其不做具体限定。In this embodiment, the smart device can periodically send algorithm information acquisition requests to the dispatch center to improve the timeliness of algorithm upgrades. Among them, the way in which the smart device sends the algorithm information acquisition request to the dispatch center can be implemented through wired or wireless methods, which are not specifically limited here.

例如,设备端算法类型为face、设备端算法模型为model1,则调度中心可根据face和model1在存储目录中进行查找匹配的存储目录,若存储目录2与face和model1匹配,并将该存储目录2确定为待访问存储目录。For example, if the device-side algorithm type is face and the device-side algorithm model is model1, the dispatch center can search for a matching storage directory in the storage directory based on face and model1. If storage directory 2 matches face and model1, the storage directory will be 2. Determine the storage directory to be accessed.

在得到待访问存储目录之后,调度中心可将该待访问存储目录中的目标算法的调度端版本和/或调度端更新时间下发给智能设备,以使智能设备根据调度中心下发的调度端版本和/或调度端更新时间,与设备端版本和/或设备端更新时间进行比较,以确定目标算法是否需要升级。After obtaining the storage directory to be accessed, the dispatching center can issue the dispatching end version and/or the dispatching end update time of the target algorithm in the to-be-accessed storage directory to the smart device, so that the intelligent device can adjust the dispatching end version according to the dispatching end issued by the dispatching center. The version and/or schedule-side update time are compared with the device-side version and/or device-side update time to determine whether the target algorithm needs to be upgraded.

可以理解的是,本实施例中调度端版本和/或调度端更新时间,可以是调度端版本;或者,调度端更新时间;又或者,调度端版本和调度端更新时间,此处对其不做具体限定。It can be understood that in this embodiment, the dispatching end version and/or the dispatching end update time may be the dispatching end version; or the dispatching end update time; or the dispatching end version and the dispatching end update time, which are not discussed here. Make specific limitations.

S306,响应于智能设备反馈的目标算法升级请求,向智能设备发送待访问存储目录中的目标算法内容,供智能设备升级目标算法。S306: In response to the target algorithm upgrade request fed back by the smart device, send the target algorithm content in the storage directory to be accessed to the smart device for the smart device to upgrade the target algorithm.

可选的,若智能设备根据调度中心下发的目标算法的调度端版本和/或调度端更新时间,比设备端算法版本和/或设备端更新时间新,则确定目标算法需要升级。此时,智能设备可通过向调度中心反馈目标算法升级请求,以获取目标算法内容进行目标算法升级。Optionally, if the smart device determines that the target algorithm needs to be upgraded based on the scheduling-side version and/or the scheduling-side update time of the target algorithm issued by the dispatching center, which is newer than the device-side algorithm version and/or the device-side update time. At this time, the smart device can obtain the target algorithm content and upgrade the target algorithm by feeding back the target algorithm upgrade request to the dispatch center.

调度中心可根据获取的目标算法请求中携带的目标算法类型和目标算法模型,确定待访问存储目录,再根据目标算法请求中携带的目标算法版本和/或目标算法更新时间,从上述待访问存储目录中获取目标算法内容,然后将获取的目标算法内容下发给智能设备,以供智能设备升级目标算法。The dispatch center can determine the storage directory to be accessed based on the target algorithm type and target algorithm model carried in the obtained target algorithm request, and then determine the storage directory to be accessed based on the target algorithm version and/or target algorithm update time carried in the target algorithm request. Obtain the target algorithm content from the directory, and then deliver the obtained target algorithm content to the smart device so that the smart device can upgrade the target algorithm.

本发明实施例提供的算法升级方法,通过响应于智能设备发送的算法信息获取请求,根据算法信息获取请求中携带的目标算法的设备端算法类型和设备端算法模型,确定待访问存储目录,并将待访问存储目录中的目标算法的调度端版本和/或调度端更新时间下发给智能设备,供智能设备确定目标算法是否升级,当接收到智能设备反馈的目标算法升级请求时,向智能设备发送待访问存储目录中的目标算法内容,供智能设备升级目标算法。由此,使得智能设备能够随时随地获取算法进行升级操作,从而实现了算法的自动升级,减少了算法升级时人力物力的投入成本,同时还能确保智能设备的基础业务正常运行,提高用户体验。The algorithm upgrade method provided by the embodiment of the present invention determines the storage directory to be accessed by responding to an algorithm information acquisition request sent by a smart device and based on the device-side algorithm type and device-side algorithm model of the target algorithm carried in the algorithm information acquisition request, and Send the dispatcher version and/or dispatcher update time of the target algorithm in the storage directory to be accessed to the smart device for the smart device to determine whether the target algorithm has been upgraded. When receiving a target algorithm upgrade request fed back by the smart device, The device sends the target algorithm content in the storage directory to be accessed for the smart device to upgrade the target algorithm. As a result, smart devices can obtain algorithms for upgrade operations anytime and anywhere, thereby realizing automatic upgrades of algorithms, reducing the cost of manpower and material resources during algorithm upgrades, while also ensuring the normal operation of basic services of smart devices and improving user experience.

下面结合附图,以智能设备为例对本发明实施例提出的算法升级方法进行详细描述。图4是本发明提供的再一种算法升级方法的流程图。本实施例适用于对智能设备中算法升级的情况,该方法可以由本发明实施例提供的配置于智能设备的算法升级装置来执行,该装置可以采用软件和/或硬件的方式实现。在本实施例中智能设备可以是但不限于:网络摄像机、网络视频录像机、智能服务器等。如图4所示,该方法可以包括:The algorithm upgrade method proposed in the embodiment of the present invention will be described in detail below with reference to the accompanying drawings, taking a smart device as an example. Figure 4 is a flow chart of yet another algorithm upgrade method provided by the present invention. This embodiment is suitable for upgrading algorithms in smart devices. The method can be executed by the algorithm upgrade device configured in the smart device provided by the embodiment of the present invention. The device can be implemented in software and/or hardware. In this embodiment, smart devices may be but are not limited to: network cameras, network video recorders, smart servers, etc. As shown in Figure 4, the method may include:

S401,向调度中心反馈目标算法升级请求,以指示调度中心执行如下:根据目标算法升级请求中携带的目标算法属性信息,确定目标算法的待访问存储目录,并向智能设备发送待访问存储目录中的目标算法内容。S401. Feed back the target algorithm upgrade request to the dispatch center to instruct the dispatch center to perform the following: determine the storage directory to be accessed of the target algorithm based on the target algorithm attribute information carried in the target algorithm upgrade request, and send the storage directory to be accessed to the smart device. The content of the target algorithm.

S402,根据目标算法内容,对目标算法进行升级。S402: Upgrade the target algorithm according to the content of the target algorithm.

可选的,智能设备可向调度中心主动发送算法升级请求,并根据调度中反馈的目标算法内容进行升级操作。Optionally, the smart device can proactively send an algorithm upgrade request to the dispatch center, and perform upgrade operations based on the target algorithm content fed back in the dispatch.

其中,根据目标算法内容,对目标算法进行升级时,利用目标算法内容替换目标算法原始内容。可以理解的是,本实施例中对目标算法进行升级时,无需对智能设备中的软件进行更新,只需更新目标算法即可,使得算法升级过程中,智能设备还可保持基础业务的正常运行,从而提高了智能设备的实用性。Among them, according to the target algorithm content, when upgrading the target algorithm, the target algorithm content is used to replace the original content of the target algorithm. It can be understood that when upgrading the target algorithm in this embodiment, there is no need to update the software in the smart device, only the target algorithm is updated, so that during the algorithm upgrade process, the smart device can still maintain the normal operation of the basic business. , thus improving the practicality of smart devices.

需要说明的是,本实施例中调度中心发送的目标算法内容的具体方式,可具体参见上述实施例,此处对其不做过多赘述。It should be noted that, for the specific method of sending the target algorithm content sent by the dispatching center in this embodiment, reference can be made to the above embodiment, which will not be described in detail here.

在本申请的一个实施例中,向调度中心发送目标算法升级请求之前,还包括:In one embodiment of this application, before sending the target algorithm upgrade request to the dispatch center, it also includes:

向调度中心发送算法信息获取请求,以指示调度中心执行如下:根据算法信息获取请求中携带的目标算法的设备端算法类型和设备端算法模型,确定待访问存储目录;将待访问存储目录中的目标算法的调度端版本和/或调度端更新时间下发给设备端,供设备端确定目标算法是否升级;Send an algorithm information acquisition request to the dispatch center to instruct the dispatch center to perform the following: determine the storage directory to be accessed based on the device-side algorithm type and device-side algorithm model of the target algorithm carried in the algorithm information acquisition request; The dispatcher version of the target algorithm and/or the dispatcher update time are sent to the device side for the device side to determine whether the target algorithm is upgraded;

若确定目标算法需要升级时,则向调度中心反馈目标算法升级请求,以使调度中心反馈待访问存储目录下的目标算法内容。If it is determined that the target algorithm needs to be upgraded, a target algorithm upgrade request is fed back to the dispatch center, so that the dispatch center feeds back the target algorithm content in the storage directory to be accessed.

例如,若调度中心向智能设备下发的调度端版本为2.1,调度端更新时间为2019-7-8,而设备端版本为1.5,设备端更新时间为2018-12-7,则确定目标算法需要升级,此时智能设备可向调度中心反馈目标算法升级请求,以获取目标算法内容进行升级。For example, if the dispatching side version issued by the dispatching center to the smart device is 2.1, the dispatching side update time is 2019-7-8, and the device side version is 1.5, and the device side update time is 2018-12-7, then determine the target algorithm When an upgrade is required, the smart device can feedback the target algorithm upgrade request to the dispatch center to obtain the target algorithm content for upgrade.

又如,若调度中心向智能设备下发的调度端版本为1.1,而设备端版本为1.1,则确定目标算法无需升级,则结束此次操作。For another example, if the dispatching side version issued by the dispatching center to the smart device is 1.1, and the device side version is 1.1, it is determined that the target algorithm does not need to be upgraded, and the operation ends.

本发明实施例提供的算法升级方法,通过向调度中心反馈目标算法升级请求,并根据调度中心发送的目标算法内容进行升级操作。由此,通过将算法插件化并存储在调度中心端,以实现算法与软件的解耦,使得智能设备能够从调度中心端获取算法进行升级操作,从而实现了算法的自动升级,减少了算法升级时人力物力的投入成本,同时还能确保智能设备的基础业务正常运行,提高用户体验。The algorithm upgrade method provided by the embodiment of the present invention feeds back the target algorithm upgrade request to the dispatch center, and performs the upgrade operation according to the target algorithm content sent by the dispatch center. Therefore, by plugging the algorithm into a plug-in and storing it in the dispatch center, the decoupling of the algorithm and the software is achieved, so that the smart device can obtain the algorithm from the dispatch center for upgrade operations, thereby realizing automatic upgrade of the algorithm and reducing the need for algorithm upgrades. It reduces the investment cost of human and material resources, while also ensuring the normal operation of the basic business of smart devices and improving user experience.

下面通过一个具体实施例,对上述实施例算法升级方法进行具体说明,具体参见图5。图5是本发明提供的一个具体实施例的调度中心与智能设备进行信令交互的示意图。The algorithm upgrade method of the above embodiment will be described in detail below through a specific embodiment. See Figure 5 for details. Figure 5 is a schematic diagram of signaling interaction between a dispatch center and an intelligent device according to a specific embodiment of the present invention.

假设本实施例中,调度中心为A、智能设备包括N个,分别为:N1、N2、…Nn,则调度中心与智能设备的交互过程可包括以下:Assume that in this embodiment, the dispatch center is A and the smart devices include N, namely: N1, N2,...Nn, then the interaction process between the dispatch center and the smart devices may include the following:

S501,调度中心A获取新算法内容和新算法属性信息,并根据新算法属性信息,确定新算法的目标存储目录,以及新算法在目标存储目录下的标识信息。S501. Scheduling center A obtains the new algorithm content and new algorithm attribute information, and determines the target storage directory of the new algorithm and the identification information of the new algorithm in the target storage directory based on the new algorithm attribute information.

S502,调度中心A根据新算法在目标存储目录下的标识信息,将新算法内容存储到目标存储目录下。S502: Scheduling center A stores the new algorithm content in the target storage directory based on the identification information of the new algorithm in the target storage directory.

S503,智能设备N1、N2、…Nn向调度中心A发送算法信息获取请求。S503. The smart devices N1, N2,...Nn send an algorithm information acquisition request to the dispatch center A.

S504,智能设备N1、N2、…Nn接收调度中心A下发的目标算法的调度端版本和/或调度端更新时间,确定目标算法是否升级。S504. The smart devices N1, N2,...Nn receive the dispatching end version and/or dispatching end update time of the target algorithm issued by the dispatching center A, and determine whether the target algorithm is upgraded.

S505,智能设备N1、N2、…Nn确定目标算法需要升级,则向调度中心A反馈目标算法升级请求;S505, the smart devices N1, N2,...Nn determine that the target algorithm needs to be upgraded, and then feedback the target algorithm upgrade request to the dispatch center A;

S506,调度中心A根据智能设备N1、N2、…Nn反馈的目标算法升级请求,反馈目标算法内容。S506: The dispatch center A feeds back the target algorithm content based on the target algorithm upgrade request fed back by the smart devices N1, N2,...Nn.

S507,智能设备N1、N2、…Nn根据调度中心A反馈的目标算法内容,对目标算法进行升级。S507: The intelligent devices N1, N2,...Nn upgrade the target algorithm according to the target algorithm content fed back by the dispatch center A.

通过上述实施例提供的算法升级方法,通过将算法插件化并存储在调度中心端,以实现算法与软件的解耦,使得智能设备能够从调度中心端获取算法进行升级操作,从而实现了算法的自动升级,减少了算法升级时人力物力的投入成本,同时还能确保智能设备的基础业务正常运行,提高用户体验。Through the algorithm upgrade method provided by the above embodiment, the algorithm is plugged into a plug-in and stored in the dispatch center to realize the decoupling of the algorithm and the software, so that the smart device can obtain the algorithm from the dispatch center for upgrade operations, thereby realizing the algorithm Automatic upgrade reduces the cost of manpower and material resources when upgrading algorithms. It also ensures the normal operation of basic services of smart devices and improves user experience.

为了实现上述目的,本发明提出了一种算法升级装置,其中该算法升级装置,配置于调度中心。图6是本发明提供的一种算法升级装置的结构示意图。如图6所示,本发明实施例算法升级装置包括:获取模块610、确定模块612、存储模块614及响应模块616。In order to achieve the above object, the present invention proposes an algorithm upgrade device, wherein the algorithm upgrade device is configured in a dispatch center. Figure 6 is a schematic structural diagram of an algorithm upgrade device provided by the present invention. As shown in Figure 6, the algorithm upgrade device according to the embodiment of the present invention includes: an acquisition module 610, a determination module 612, a storage module 614 and a response module 616.

其中,获取模块610用于获取新算法内容和新算法属性信息;Among them, the acquisition module 610 is used to acquire the new algorithm content and new algorithm attribute information;

确定模块612用于根据所述新算法属性信息,确定所述新算法的目标存储目录,以及所述新算法在所述目标存储目录下的标识信息;The determination module 612 is configured to determine the target storage directory of the new algorithm and the identification information of the new algorithm under the target storage directory according to the new algorithm attribute information;

存储模块614用于根据所述新算法在目标存储目录下的标识信息,将所述新算法内容存储到所述目标存储目录下;The storage module 614 is configured to store the new algorithm content in the target storage directory according to the identification information of the new algorithm in the target storage directory;

响应模块616用于响应于智能设备反馈的目标算法升级请求,向所述智能设备发送待访问存储目录中的目标算法内容,供所述智能设备升级目标算法。The response module 616 is configured to respond to the target algorithm upgrade request fed back by the smart device, and send the target algorithm content in the storage directory to be accessed to the smart device for the smart device to upgrade the target algorithm.

作为本发明实施例的一种可选的实现方式,所述新算法属性信息包括新算法版本和/或新算法更新时间,以及新算法类型和新算法模型;As an optional implementation manner of the embodiment of the present invention, the new algorithm attribute information includes a new algorithm version and/or a new algorithm update time, as well as a new algorithm type and a new algorithm model;

相应地,所述确定模块612,具体用于:Correspondingly, the determination module 612 is specifically used to:

根据所述新算法类型和所述新算法模型,确定所述新算法的目标存储目录;Determine the target storage directory of the new algorithm according to the new algorithm type and the new algorithm model;

根据所述新算法版本和/或所述新算法更新时间,确定所述新算法在所述目标存储目录下的标识信息。According to the new algorithm version and/or the new algorithm update time, the identification information of the new algorithm in the target storage directory is determined.

作为本发明实施例的一种可选的实现方式,算法升级装置还包括:第二响应模块和信息下发模块;As an optional implementation manner of the embodiment of the present invention, the algorithm upgrade device further includes: a second response module and an information delivery module;

其中,第二响应模块,用于响应于所述智能设备发送的算法信息获取请求,根据所述算法信息获取请求中携带的目标算法的设备端算法类型和设备端算法模型,确定所述待访问存储目录;Wherein, the second response module is configured to respond to the algorithm information acquisition request sent by the smart device, and determine the device-side algorithm type and device-side algorithm model of the target algorithm carried in the algorithm information acquisition request to determine the to-be-accessed storage directory;

信息下发模块,用于将所述待访问存储目录中的目标算法的调度端版本和/或调度端更新时间下发给所述智能设备,供所述智能设备确定所述目标算法是否升级。An information delivery module is configured to deliver the dispatcher version and/or dispatcher update time of the target algorithm in the storage directory to be accessed to the smart device, so that the smart device can determine whether the target algorithm is upgraded.

作为本发明实施例的一种可选的实现方式,算法升级装置还包括:删除模块;As an optional implementation manner of the embodiment of the present invention, the algorithm upgrade device further includes: a deletion module;

其中删除模块用于若根据任一算法内容的标识信息确定该算法内容在调度中心的存储时长超过算法留存期,则删除该算法内容。The deletion module is used to delete the algorithm content if it is determined based on the identification information of any algorithm content that the storage time of the algorithm content in the dispatch center exceeds the algorithm retention period.

作为本发明实施例的一种可选的实现方式,存储模块614,还用于:As an optional implementation manner of the embodiment of the present invention, the storage module 614 is also used to:

若所述目标存储目录中存储有与新算法内容类型相同的历史算法内容,则在所述目标存储目录中兼容存储所述新算法内容和所述历史算法内容;其中,所述新算法内容和所述历史算法内容在所述目标存储目录下的标识信息不同。If the target storage directory stores historical algorithm content of the same type as the new algorithm content, then the new algorithm content and the historical algorithm content are compatible and stored in the target storage directory; wherein, the new algorithm content and The identification information of the historical algorithm content in the target storage directory is different.

需要说明的是,前述对算法升级方法实施例的解释说明也适用于该实施例的算法升级装置,其实现原理类似,此处不再赘述。It should be noted that the foregoing explanation of the algorithm upgrade method embodiment also applies to the algorithm upgrade device of this embodiment, and its implementation principles are similar and will not be described again here.

本发明实施例提供的算法升级装置,通过将算法插件化并存储在调度中心端,以实现算法与软件的解耦,使得智能设备能够从调度中心端获取算法进行升级操作,从而实现了算法的自动升级,减少了算法升级时人力物力的投入成本,同时还能确保智能设备的基础业务正常运行,提高用户体验。The algorithm upgrade device provided by the embodiment of the present invention realizes the decoupling of the algorithm and the software by plugging the algorithm into a plug-in and storing it in the dispatch center, so that the intelligent device can obtain the algorithm from the dispatch center for upgrade operations, thereby realizing the algorithm Automatic upgrade reduces the cost of manpower and material resources when upgrading algorithms. It also ensures the normal operation of basic services of smart devices and improves user experience.

图7是本发明提供的另一种算法升级装置的结构示意图,其中该算法升级装置,配置于智能设备。如图7所示,本发明实施例算法升级装置包括:请求发送模块710及升级模块712。Figure 7 is a schematic structural diagram of another algorithm upgrading device provided by the present invention, wherein the algorithm upgrading device is configured in an intelligent device. As shown in Figure 7, the algorithm upgrade device according to the embodiment of the present invention includes: a request sending module 710 and an upgrade module 712.

其中,请求发送模块710用于向调度中心反馈目标算法升级请求,以指示所述调度中心执行如下:根据所述目标算法升级请求中携带的目标算法属性信息,确定所述目标算法的待访问存储目录,并向智能设备发送所述待访问存储目录中的目标算法内容;Among them, the request sending module 710 is used to feed back a target algorithm upgrade request to the dispatch center to instruct the dispatch center to perform the following: determine the storage to be accessed of the target algorithm according to the target algorithm attribute information carried in the target algorithm upgrade request. directory, and send the target algorithm content in the storage directory to be accessed to the smart device;

升级模块712用于根据所述目标算法内容,对所述目标算法进行升级。The upgrade module 712 is used to upgrade the target algorithm according to the content of the target algorithm.

作为本发明实施例的一种可选的实现方式,算法升级装置还包括:信息获取模块和反馈模块;As an optional implementation manner of the embodiment of the present invention, the algorithm upgrade device also includes: an information acquisition module and a feedback module;

其中,信息获取模块用于向所述调度中心发送算法信息获取请求,以指示所述调度中心执行如下:根据所述算法信息获取请求中携带的目标算法的设备端算法类型和设备端算法模型,确定待访问存储目录;将所述待访问存储目录中的目标算法的调度端版本和/或调度端更新时间下发给所述智能设备,供所述智能设备确定所述目标算法是否升级;Wherein, the information acquisition module is used to send an algorithm information acquisition request to the dispatch center to instruct the dispatch center to perform the following: according to the device-side algorithm type and device-side algorithm model of the target algorithm carried in the algorithm information acquisition request, Determine the storage directory to be accessed; send the dispatcher version and/or the dispatcher update time of the target algorithm in the storage directory to be accessed to the smart device for the smart device to determine whether the target algorithm is upgraded;

反馈模块用于若确定所述目标算法需要升级时,则向所述调度中心反馈目标算法升级请求,以使所述调度中心反馈所述待访问存储目录下的目标算法内容。The feedback module is configured to feed back a target algorithm upgrade request to the dispatch center if it is determined that the target algorithm needs to be upgraded, so that the dispatch center feeds back the target algorithm content in the storage directory to be accessed.

需要说明的是,前述对算法升级方法实施例的解释说明也适用于该实施例的算法升级装置,其实现原理类似,此处不再赘述。It should be noted that the foregoing explanation of the algorithm upgrade method embodiment also applies to the algorithm upgrade device of this embodiment, and its implementation principles are similar and will not be described again here.

本发明实施例提供的算法升级装置,通过将算法插件化并存储在调度中心端,以实现算法与软件的解耦,使得智能设备能够从调度中心端获取算法进行升级操作,从而实现了算法的自动升级,减少了算法升级时人力物力的投入成本,同时还能确保智能设备的基础业务正常运行,提高用户体验。The algorithm upgrade device provided by the embodiment of the present invention realizes the decoupling of the algorithm and the software by plugging the algorithm into a plug-in and storing it in the dispatch center, so that the intelligent device can obtain the algorithm from the dispatch center for upgrade operations, thereby realizing the algorithm Automatic upgrade reduces the cost of manpower and material resources when upgrading algorithms. It also ensures the normal operation of basic services of smart devices and improves user experience.

图8为本发明提供的一种计算机设备的结构示意图。图8示出了适于用来实现本发明实施方式的示例性计算机设备12的框图。图8显示的计算机设备12仅仅是一个示例,不应对本发明实施例的功能和使用范围带来任何限制。Figure 8 is a schematic structural diagram of a computer device provided by the present invention. Figure 8 shows a block diagram of an exemplary computer device 12 suitable for implementing embodiments of the present invention. The computer device 12 shown in FIG. 8 is only an example and should not bring any limitations to the functions and scope of use of the embodiments of the present invention.

如图8所示,计算机设备12以通用计算设备的形式表现。计算机设备12的组件可以包括但不限于:一个或者多个处理器或者处理单元16,系统存储器28,连接不同系统组件(包括系统存储器28和处理单元16)的总线18。As shown in Figure 8, computer device 12 is embodied in the form of a general purpose computing device. The components of computer device 12 may include, but are not limited to: one or more processors or processing units 16, system memory 28, and a bus 18 connecting various system components, including system memory 28 and processing unit 16.

总线18表示几类总线结构中的一种或多种,包括存储器总线或者存储器控制器,外围总线,图形加速端口,处理器或者使用多种总线结构中的任意总线结构的局域总线。举例来说,这些体系结构包括但不限于工业标准体系结构(ISA)总线,微通道体系结构(MAC)总线,增强型ISA总线、视频电子标准协会(VESA)局域总线以及外围组件互连(PCI)总线。Bus 18 represents one or more of several types of bus structures, including a memory bus or memory controller, a peripheral bus, a graphics accelerated port, a processor, or a local bus using any of a variety of bus structures. For example, these architectures include, but are not limited to, the Industry Standard Architecture (ISA) bus, the Micro Channel Architecture (MAC) bus, the Enhanced ISA bus, the Video Electronics Standards Association (VESA) local bus, and the Peripheral Component Interconnect ( PCI) bus.

计算机设备12典型地包括多种计算机系统可读介质。这些介质可以是任何能够被计算机设备12访问的可用介质,包括易失性和非易失性介质,可移动的和不可移动的介质。Computer device 12 typically includes a variety of computer system readable media. These media can be any available media that can be accessed by computer device 12, including volatile and nonvolatile media, removable and non-removable media.

系统存储器28可以包括易失性存储器形式的计算机系统可读介质,例如随机存取存储器(RAM)30和/或高速缓存存储器32。计算机设备12可以进一步包括其它可移动/不可移动的、易失性/非易失性计算机系统存储介质。仅作为举例,存储系统34可以用于读写不可移动的、非易失性磁介质(图8未显示,通常称为“硬盘驱动器”)。尽管图8中未示出,可以提供用于对可移动非易失性磁盘(例如“软盘”)读写的磁盘驱动器,以及对可移动非易失性光盘(例如CD-ROM,DVD-ROM或者其它光介质)读写的光盘驱动器。在这些情况下,每个驱动器可以通过一个或者多个数据介质接口与总线18相连。存储器28可以包括至少一个程序产品,该程序产品具有一组(例如至少一个)程序模块,这些程序模块被配置以执行本发明各实施例的功能。System memory 28 may include computer system readable media in the form of volatile memory, such as random access memory (RAM) 30 and/or cache memory 32 . Computer device 12 may further include other removable/non-removable, volatile/non-volatile computer system storage media. By way of example only, storage system 34 may be used to read and write to non-removable, non-volatile magnetic media (not shown in Figure 8 and commonly referred to as a "hard drive"). Although not shown in FIG. 8, a disk drive for reading and writing removable non-volatile disks (e.g., "floppy disks"), and removable non-volatile optical disks (e.g., CD-ROM, DVD-ROM) may be provided. or other optical media) that can read and write optical disc drives. In these cases, each drive may be connected to bus 18 through one or more data media interfaces. Memory 28 may include at least one program product having a set (eg, at least one) of program modules configured to perform the functions of embodiments of the invention.

具有一组(至少一个)程序模块42的程序/实用工具40,可以存储在例如存储器28中,这样的程序模块42包括但不限于操作系统、一个或者多个应用程序、其它程序模块以及程序数据,这些示例中的每一个或某种组合中可能包括网络环境的实现。程序模块42通常执行本发明所描述的实施例中的功能和/或方法。A program/utility 40 having a set of (at least one) program modules 42, including but not limited to an operating system, one or more application programs, other program modules, and program data, may be stored, for example, in memory 28 , each of these examples or some combination may include the implementation of a network environment. Program modules 42 generally perform functions and/or methods in the described embodiments of the invention.

计算机设备12也可以与一个或多个外部设备14(例如键盘、指向设备、显示器24等)通信,还可与一个或者多个使得用户能与该计算机设备12交互的设备通信,和/或与使得该计算机设备12能与一个或多个其它计算设备进行通信的任何设备(例如网卡,调制解调器等等)通信。这种通信可以通过输入/输出(I/O)接口22进行。并且,计算机设备12还可以通过网络适配器20与一个或者多个网络(例如局域网(LAN),广域网(WAN)和/或公共网络,例如因特网)通信。如图所示,网络适配器20通过总线18与计算机设备12的其它模块通信。应当明白,尽管图中未示出,可以结合计算机设备12使用其它硬件和/或软件模块,包括但不限于:微代码、设备驱动器、冗余处理单元、外部磁盘驱动阵列、RAID系统、磁带驱动器以及数据备份存储系统等。Computer device 12 may also communicate with one or more external devices 14 (e.g., keyboard, pointing device, display 24, etc.), with one or more devices that enable a user to interact with computer device 12, and/or with Any device (eg, network card, modem, etc.) that enables the computer device 12 to communicate with one or more other computing devices. This communication may occur through input/output (I/O) interface 22. Furthermore, computer device 12 may also communicate with one or more networks (eg, a local area network (LAN), a wide area network (WAN), and/or a public network, such as the Internet) through network adapter 20. As shown, network adapter 20 communicates with other modules of computer device 12 via bus 18 . It should be understood that, although not shown in the figures, other hardware and/or software modules may be used in conjunction with computer device 12, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives And data backup storage system, etc.

处理单元16通过运行存储在系统存储器28中的程序,从而执行各种功能应用以及数据处理,例如实现本发明实施例所提供的算法升级方法,包括:The processing unit 16 executes various functional applications and data processing by running programs stored in the system memory 28, such as implementing the algorithm upgrade method provided by the embodiment of the present invention, including:

获取新算法内容和新算法属性信息;Obtain new algorithm content and new algorithm attribute information;

根据所述新算法属性信息,确定所述新算法的目标存储目录,以及所述新算法在所述目标存储目录下的标识信息;According to the new algorithm attribute information, determine the target storage directory of the new algorithm, and the identification information of the new algorithm in the target storage directory;

根据所述新算法在所述目标存储目录下的标识信息,将所述新算法内容存储到所述目标存储目录下;According to the identification information of the new algorithm in the target storage directory, store the new algorithm content in the target storage directory;

响应于智能设备反馈的目标算法升级请求,向所述智能设备发送待访问存储目录中的目标算法内容,供所述智能设备升级目标算法。In response to the target algorithm upgrade request fed back by the smart device, the target algorithm content in the storage directory to be accessed is sent to the smart device for the smart device to upgrade the target algorithm.

或者,向调度中心反馈目标算法升级请求,以指示所述调度中心执行如下:根据所述目标算法升级请求中携带的目标算法属性信息,确定所述目标算法的待访问存储目录,并向智能设备发送所述待访问存储目录中的目标算法内容;Or, feed back the target algorithm upgrade request to the dispatch center to instruct the dispatch center to perform the following: determine the storage directory to be accessed for the target algorithm according to the target algorithm attribute information carried in the target algorithm upgrade request, and send the request to the intelligent device Send the target algorithm content in the storage directory to be accessed;

根据所述目标算法内容,对所述目标算法进行升级。The target algorithm is upgraded according to the content of the target algorithm.

需要说明的是,前述对算法升级方法实施例的解释说明也适用于该实施例的计算机设备,其实现原理类似,此处不再赘述。It should be noted that the foregoing explanation of the embodiment of the algorithm upgrade method also applies to the computer device of this embodiment, and its implementation principles are similar and will not be described again here.

本发明实施例提供的计算机设备,通过将算法插件化并存储在调度中心端,以实现算法与软件的解耦,使得智能设备能够从调度中心端获取算法进行升级操作,从而实现了算法的自动升级,减少了算法升级时人力物力的投入成本,同时还能确保智能设备的基础业务正常运行,提高用户体验。The computer device provided in the embodiment of the present invention realizes the decoupling of the algorithm from the software by making the algorithm into a plug-in and storing it in the dispatching center, so that the intelligent device can obtain the algorithm from the dispatching center for upgrading, thereby realizing the automatic upgrading of the algorithm and reducing the investment cost of manpower and material resources when upgrading the algorithm. At the same time, it can also ensure the normal operation of the basic business of the intelligent device and improve the user experience.

为了实现上述目的,本发明还提出了一种计算机可读存储介质。本发明实施例提供的计算机可读存储介质,其上存储有计算机程序,该程序被处理器执行时实现如本发明实施例的算法升级方法,该方法包括:In order to achieve the above object, the present invention also provides a computer-readable storage medium. The computer-readable storage medium provided by the embodiment of the present invention has a computer program stored thereon. When the program is executed by the processor, the algorithm upgrade method according to the embodiment of the present invention is implemented. The method includes:

获取新算法内容和新算法属性信息;Obtain new algorithm content and new algorithm attribute information;

根据所述新算法属性信息,确定所述新算法的目标存储目录,以及所述新算法在所述目标存储目录下的标识信息;According to the new algorithm attribute information, determine the target storage directory of the new algorithm, and the identification information of the new algorithm in the target storage directory;

根据所述新算法在所述目标存储目录下的标识信息,将所述新算法内容存储到所述目标存储目录下;According to the identification information of the new algorithm in the target storage directory, store the new algorithm content in the target storage directory;

响应于智能设备反馈的目标算法升级请求,向所述智能设备发送待访问存储目录中的目标算法内容,供所述智能设备升级目标算法。In response to the target algorithm upgrade request fed back by the smart device, the target algorithm content in the storage directory to be accessed is sent to the smart device for the smart device to upgrade the target algorithm.

或者,向调度中心反馈目标算法升级请求,以指示所述调度中心执行如下:根据所述目标算法升级请求中携带的目标算法属性信息,确定所述目标算法的待访问存储目录,并向智能设备发送所述待访问存储目录中的目标算法内容;Or, feed back the target algorithm upgrade request to the dispatch center to instruct the dispatch center to perform the following: determine the storage directory to be accessed for the target algorithm according to the target algorithm attribute information carried in the target algorithm upgrade request, and send the request to the intelligent device Send the target algorithm content in the storage directory to be accessed;

根据所述目标算法内容,对所述目标算法进行升级。The target algorithm is upgraded according to the content of the target algorithm.

本发明实施例的计算机存储介质,可以采用一个或多个计算机可读的介质的任意组合。计算机可读介质可以是计算机可读信号介质或者计算机可读存储介质。计算机可读存储介质例如可以是——但不限于——电、磁、光、电磁、红外线、或半导体的系统、装置或器件,或者任意以上的组合。计算机可读存储介质的更具体的例子(非穷举的列表)包括:具有一个或多个导线的电连接、便携式计算机磁盘、硬盘、随机存取存储器(RAM)、只读存储器(ROM)、可擦式可编程只读存储器(EPROM或闪存)、光纤、便携式紧凑磁盘只读存储器(CD-ROM)、光存储器件、磁存储器件、或者上述的任意合适的组合。在本文件中,计算机可读存储介质可以是任何包含或存储程序的有形介质,该程序可以被指令执行系统、装置或者器件使用或者与其结合使用。The computer storage medium in this embodiment of the present invention may be any combination of one or more computer-readable media. The computer-readable medium may be a computer-readable signal medium or a computer-readable storage medium. The computer-readable storage medium may be, for example, but is not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus or device, or any combination thereof. More specific examples (non-exhaustive list) of computer readable storage media include: electrical connections having one or more conductors, portable computer disks, hard drives, random access memory (RAM), read only memory (ROM), Erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination of the above. As used herein, a computer-readable storage medium may be any tangible medium that contains or stores a program for use by or in connection with an instruction execution system, apparatus, or device.

计算机可读的信号介质可以包括在基带中或者作为载波一部分传播的数据信号,其中承载了计算机可读的程序代码。这种传播的数据信号可以采用多种形式,包括但不限于电磁信号、光信号或上述的任意合适的组合。计算机可读的信号介质还可以是计算机可读存储介质以外的任何计算机可读介质,该计算机可读介质可以发送、传播或者传输用于由指令执行系统、装置或者器件使用或者与其结合使用的程序。A computer-readable signal medium may include a data signal propagated in baseband or as part of a carrier wave carrying computer-readable program code therein. Such propagated data signals may take many forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. A computer-readable signal medium may also be any computer-readable medium other than a computer-readable storage medium that can send, propagate, or transmit a program for use by or in connection with an instruction execution system, apparatus, or device .

计算机可读介质上包含的程序代码可以用任何适当的介质传输,包括——但不限于无线、电线、光缆、RF等等,或者上述的任意合适的组合。Program code embodied on a computer-readable medium may be transmitted using any suitable medium, including but not limited to wireless, wire, optical cable, RF, etc., or any suitable combination of the foregoing.

可以以一种或多种程序设计语言或其组合来编写用于执行本发明操作的计算机程序代码,程序设计语言包括面向对象的程序设计语言—诸如Java、Smalltalk、C++,还包括常规的过程式程序设计语言—诸如”C”语言或类似的程序设计语言。程序代码可以完全地在用户计算机上执行、部分地在用户计算机上执行、作为一个独立的软件包执行、部分在用户计算机上部分在远程计算机上执行、或者完全在远程计算机或服务器上执行。在涉及远程计算机的情形中,远程计算机可以通过任意种类的网络——包括局域网(LAN)或广域网(WAN)—连接到用户计算机,或者,可以连接到外部计算机(例如利用因特网服务提供商来通过因特网连接)。Computer program code for performing the operations of the present invention may be written in one or more programming languages, including object-oriented programming languages such as Java, Smalltalk, C++, and conventional procedural programming languages, or a combination thereof. Programming language - such as "C" or a similar programming language. The program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In situations involving remote computers, the remote computer can be connected to the user's computer through any kind of network, including a local area network (LAN) or a wide area network (WAN), or it can be connected to an external computer (such as an Internet service provider through Internet connection).

注意,上述仅为本发明的较佳实施例及所运用技术原理。本领域技术人员会理解,本发明不限于这里的特定实施例,对本领域技术人员来说能够进行各种明显的变化、重新调整和替代而不会脱离本发明的保护范围。因此,虽然通过以上实施例对本发明进行了较为详细的说明,但是本发明不仅仅限于以上实施例,在不脱离本发明构思的情况下,还可以包括更多其他等效实施例,而本发明的范围由所附的权利要求范围决定。Note that the above are only the preferred embodiments of the present invention and the technical principles used. Those skilled in the art will understand that the present invention is not limited to the specific embodiments herein, and that various obvious changes, readjustments and substitutions can be made to those skilled in the art without departing from the scope of the invention. Therefore, although the present invention has been described in detail through the above embodiments, the present invention is not limited to the above embodiments. Without departing from the concept of the present invention, it can also include more other equivalent embodiments, and the present invention The scope is determined by the scope of the appended claims.

Claims (11)

Translated fromChinese
1.一种算法升级方法,其特征在于,应用于调度中心,所述方法包括:1. An algorithm upgrade method, characterized in that it is applied to a dispatch center, and the method includes:获取新算法内容和新算法属性信息;Obtain new algorithm content and new algorithm attribute information;根据所述新算法属性信息,确定所述新算法的目标存储目录,以及所述新算法在所述目标存储目录下的标识信息;According to the new algorithm attribute information, determine the target storage directory of the new algorithm, and the identification information of the new algorithm in the target storage directory;根据所述新算法在所述目标存储目录下的标识信息,将所述新算法内容存储到所述目标存储目录下;所述目标存储目录位于调度中心的算法仓库中;According to the identification information of the new algorithm in the target storage directory, the new algorithm content is stored in the target storage directory; the target storage directory is located in the algorithm warehouse of the dispatch center;响应于智能设备反馈的目标算法升级请求,向所述智能设备发送待访问存储目录中的目标算法内容,供所述智能设备升级目标算法。In response to the target algorithm upgrade request fed back by the smart device, the target algorithm content in the storage directory to be accessed is sent to the smart device for the smart device to upgrade the target algorithm.2.根据权利要求1所述的方法,其特征在于,所述新算法属性信息包括新算法版本和/或新算法更新时间,以及新算法类型和新算法模型;2. The method according to claim 1, characterized in that the new algorithm attribute information includes a new algorithm version and/or a new algorithm update time, as well as a new algorithm type and a new algorithm model;相应地,根据所述新算法属性信息,确定所述新算法的目标存储目录,以及所述新算法在目标存储目录下的标识信息,包括:Correspondingly, according to the new algorithm attribute information, the target storage directory of the new algorithm is determined, and the identification information of the new algorithm in the target storage directory includes:根据所述新算法类型和所述新算法模型,确定所述新算法的目标存储目录;Determine the target storage directory of the new algorithm according to the new algorithm type and the new algorithm model;根据所述新算法版本和/或所述新算法更新时间,确定所述新算法在所述目标存储目录下的标识信息。According to the new algorithm version and/or the new algorithm update time, the identification information of the new algorithm in the target storage directory is determined.3.根据权利要求1所述的方法,其特征在于,向所述智能设备发送待访问存储目录中的目标算法内容,供所述智能设备升级目标算法之前,还包括:3. The method according to claim 1, characterized in that before sending the target algorithm content in the storage directory to be accessed to the smart device for the smart device to upgrade the target algorithm, it also includes:响应于所述智能设备发送的算法信息获取请求,根据所述算法信息获取请求中携带的目标算法的设备端算法类型和设备端算法模型,确定所述待访问存储目录;In response to the algorithm information acquisition request sent by the smart device, determine the storage directory to be accessed according to the device-side algorithm type and device-side algorithm model of the target algorithm carried in the algorithm information acquisition request;将所述待访问存储目录中的目标算法的调度端版本和/或调度端更新时间下发给所述智能设备,供所述智能设备确定所述目标算法是否升级。The dispatcher version and/or dispatcher update time of the target algorithm in the storage directory to be accessed are delivered to the smart device for the smart device to determine whether the target algorithm is upgraded.4.根据权利要求1-3任一所述的方法,其特征在于,根据所述新算法在所述目标存储目录下的标识信息,将所述新算法内容存储到所述目标存储目录下之后,还包括:4. The method according to any one of claims 1-3, characterized in that, according to the identification information of the new algorithm in the target storage directory, after storing the new algorithm content in the target storage directory ,Also includes:若根据任一算法内容的标识信息确定该算法内容在调度中心的存储时长超过算法留存期,则删除该算法内容。If it is determined based on the identification information of any algorithm content that the storage time of the algorithm content in the dispatch center exceeds the algorithm retention period, the algorithm content will be deleted.5.根据权利要求1-3任一所述的方法,其特征在于,所述将所述新算法内容存储到所述目标存储目录下,包括:5. The method according to any one of claims 1-3, characterized in that storing the new algorithm content under the target storage directory includes:若所述目标存储目录中存储有与所述新算法内容类型相同的历史算法内容,则在所述目标存储目录中兼容存储所述新算法内容和所述历史算法内容;其中,所述新算法内容和所述历史算法内容在所述目标存储目录下的标识信息不同。If the target storage directory stores historical algorithm content of the same type as the new algorithm content, then the new algorithm content and the historical algorithm content are compatible and stored in the target storage directory; wherein, the new algorithm The identification information in the target storage directory of the content and the historical algorithm content is different.6.一种算法升级方法,其特征在于,应用于智能设备,所述方法包括:6. An algorithm upgrade method, characterized in that it is applied to smart devices, and the method includes:向调度中心反馈目标算法升级请求,以指示所述调度中心执行如下:根据所述目标算法升级请求中携带的目标算法属性信息,确定所述目标算法的待访问存储目录,并向智能设备发送所述待访问存储目录中的目标算法内容;所述待访问存储目录位于调度中心的算法仓库中;Feed back the target algorithm upgrade request to the dispatch center to instruct the dispatch center to perform the following: determine the storage directory to be accessed of the target algorithm based on the target algorithm attribute information carried in the target algorithm upgrade request, and send the target algorithm to the intelligent device. Describe the target algorithm content in the storage directory to be accessed; the storage directory to be accessed is located in the algorithm warehouse of the dispatch center;根据所述目标算法内容,对所述目标算法进行升级。The target algorithm is upgraded according to the content of the target algorithm.7.根据权利要求6所述的方法,其特征在于,向调度中心反馈目标算法升级请求之前,还包括:7. The method according to claim 6, characterized in that before feeding back the target algorithm upgrade request to the dispatch center, it further includes:向所述调度中心发送算法信息获取请求,以指示所述调度中心执行如下:根据所述算法信息获取请求中携带的目标算法的设备端算法类型和设备端算法模型,确定待访问存储目录;将所述待访问存储目录中的目标算法的调度端版本和/或调度端更新时间下发给所述智能设备,供所述智能设备确定所述目标算法是否升级;Send an algorithm information acquisition request to the dispatch center to instruct the dispatch center to perform the following: determine the storage directory to be accessed according to the device-side algorithm type and device-side algorithm model of the target algorithm carried in the algorithm information acquisition request; The dispatcher version and/or dispatcher update time of the target algorithm in the storage directory to be accessed are sent to the smart device for the smart device to determine whether the target algorithm is upgraded;若确定所述目标算法需要升级时,则向所述调度中心反馈目标算法升级请求,以使所述调度中心反馈所述待访问存储目录下的目标算法内容。If it is determined that the target algorithm needs to be upgraded, a target algorithm upgrade request is fed back to the dispatch center, so that the dispatch center feeds back the target algorithm content in the storage directory to be accessed.8.一种算法升级装置,其特征在于,配置于调度中心,所述装置包括:8. An algorithm upgrade device, characterized in that it is configured in a dispatch center, and the device includes:获取模块,用于获取新算法内容和新算法属性信息;Acquisition module, used to obtain new algorithm content and new algorithm attribute information;确定模块,用于根据所述新算法属性信息,确定所述新算法的目标存储目录,以及所述新算法在所述目标存储目录下的标识信息;A determination module, configured to determine the target storage directory of the new algorithm and the identification information of the new algorithm in the target storage directory based on the new algorithm attribute information;存储模块,用于根据所述新算法在目标存储目录下的标识信息,将所述新算法内容存储到所述目标存储目录下;所述目标存储目录位于调度中心的算法仓库中;A storage module, configured to store the new algorithm content in the target storage directory according to the identification information of the new algorithm in the target storage directory; the target storage directory is located in the algorithm warehouse of the dispatch center;响应模块,用于响应于智能设备反馈的目标算法升级请求,向所述智能设备发送待访问存储目录中的目标算法内容,供所述智能设备升级目标算法。A response module, configured to respond to a target algorithm upgrade request fed back by the smart device, and send the target algorithm content in the storage directory to be accessed to the smart device for the smart device to upgrade the target algorithm.9.一种算法升级装置,其特征在于,配置于智能设备,所述装置包括:9. An algorithm upgrade device, characterized in that it is configured on an intelligent device, and the device includes:请求发送模块,用于向调度中心反馈目标算法升级请求,以指示所述调度中心执行如下:根据所述目标算法升级请求中携带的目标算法属性信息,确定所述目标算法的待访问存储目录,并向智能设备发送所述待访问存储目录中的目标算法内容;所述待访问存储目录位于调度中心的算法仓库中;The request sending module is used to feed back a target algorithm upgrade request to the dispatch center to instruct the dispatch center to perform the following: determine the storage directory to be accessed of the target algorithm according to the target algorithm attribute information carried in the target algorithm upgrade request, And send the target algorithm content in the storage directory to be accessed to the smart device; the storage directory to be accessed is located in the algorithm warehouse of the dispatch center;升级模块,用于根据所述目标算法内容,对所述目标算法进行升级。An upgrade module is used to upgrade the target algorithm according to the content of the target algorithm.10.一种计算机设备,其特征在于,包括:10. A computer device, characterized in that it includes:一个或多个处理器;one or more processors;存储装置,用于存储一个或多个程序,a storage device for storing one or more programs,当一个或多个程序被一个或多个处理器执行,使得一个或多个处理器实现如权利要求1-5中任一所述的算法升级方法,或如权利要求6-7中任一所述的算法升级方法。When one or more programs are executed by one or more processors, the one or more processors implement the algorithm upgrade method as described in any one of claims 1-5, or as described in any one of claims 6-7. The algorithm upgrade method described above.11.一种计算机可读存储介质,其上存储有计算机程序,其特征在于,该程序被处理器执行时实现如权利要求1-5中任一所述的算法升级方法,或如权利要求6-7中任一所述的算法升级方法。11. A computer-readable storage medium with a computer program stored thereon, characterized in that when the program is executed by a processor, the algorithm upgrade method as claimed in any one of claims 1-5 is implemented, or as claimed in claim 6 -The algorithm upgrade method described in any one of 7.
CN201910717013.3A2019-08-052019-08-05Algorithm upgrading method, device, equipment and storage mediumActiveCN112328272B (en)

Priority Applications (1)

Application NumberPriority DateFiling DateTitle
CN201910717013.3ACN112328272B (en)2019-08-052019-08-05Algorithm upgrading method, device, equipment and storage medium

Applications Claiming Priority (1)

Application NumberPriority DateFiling DateTitle
CN201910717013.3ACN112328272B (en)2019-08-052019-08-05Algorithm upgrading method, device, equipment and storage medium

Publications (2)

Publication NumberPublication Date
CN112328272A CN112328272A (en)2021-02-05
CN112328272Btrue CN112328272B (en)2024-03-22

Family

ID=74319585

Family Applications (1)

Application NumberTitlePriority DateFiling Date
CN201910717013.3AActiveCN112328272B (en)2019-08-052019-08-05Algorithm upgrading method, device, equipment and storage medium

Country Status (1)

CountryLink
CN (1)CN112328272B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN114911505A (en)*2022-05-312022-08-16奥比中光科技集团股份有限公司 Firmware update method, device, terminal device and medium for algorithm board
CN115277411A (en)*2022-06-232022-11-01中国银行股份有限公司Method, device and equipment for upgrading edge box
CN114911507B (en)*2022-07-152022-09-23浙江大华技术股份有限公司Updating method and equipment of algorithm package

Citations (4)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN106933630A (en)*2017-03-092017-07-07百度在线网络技术(北京)有限公司A kind of client side upgrading method, device, equipment and storage medium
CN108108181A (en)*2017-12-142018-06-01深圳市雷鸟信息科技有限公司The function renewal method, apparatus and computer readable storage medium of application program
US10042634B1 (en)*2015-12-282018-08-07EMC IP Holding Company LLCStorage management system and method
CN109416629A (en)*2017-11-012019-03-01深圳市大疆创新科技有限公司Firmware upgrade method, electronic equipment, camera system and unmanned vehicle

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
US10042634B1 (en)*2015-12-282018-08-07EMC IP Holding Company LLCStorage management system and method
CN106933630A (en)*2017-03-092017-07-07百度在线网络技术(北京)有限公司A kind of client side upgrading method, device, equipment and storage medium
CN109416629A (en)*2017-11-012019-03-01深圳市大疆创新科技有限公司Firmware upgrade method, electronic equipment, camera system and unmanned vehicle
CN108108181A (en)*2017-12-142018-06-01深圳市雷鸟信息科技有限公司The function renewal method, apparatus and computer readable storage medium of application program

Also Published As

Publication numberPublication date
CN112328272A (en)2021-02-05

Similar Documents

PublicationPublication DateTitle
US9456229B2 (en)Parsing single source content for multi-channel publishing
CN104539685B (en)The USB flash disk identifying system and method for a kind of OpenStack clouds desktop
CN112328272B (en)Algorithm upgrading method, device, equipment and storage medium
CN103401934A (en)Method and system for acquiring log data
CN109597640B (en)Account management method, device, equipment and medium for application program
CN112100092B (en)Information caching method, device, equipment and medium
CN114285838A (en) A file uploading method, device, system, storage medium and electronic device
CN111818145B (en)File transmission method, device, system, equipment and storage medium
CN110049118A (en)Information push method, device, equipment and storage medium
CN107247629A (en)Cloud computing system and cloud computing method and device for controlling server
US8515732B2 (en)Opening a message catalog file for a language that is not installed
CN109147091B (en) Unmanned vehicle data processing method, device, equipment and storage medium
CN113626512A (en)Data processing method, device, equipment and readable storage medium
CN109284108A (en)Date storage method, device, electronic equipment and storage medium
CN109347899B (en) Method of writing log data in distributed storage system
CN114020689B (en) Data processing method, data processing device, electronic device and storage medium
CN109657167B (en)Data acquisition method, device, server and storage medium
CN112506871B (en) Automated task management and log management method, system, electronic device and medium
CN118227720A (en) Vehicle trajectory segmentation method, device, electronic device and storage medium
CN113220237B (en)Distributed storage method, device, equipment and storage medium
CN113764110B (en)Data processing method, device, electronic equipment and storage medium
CN116303320A (en)Real-time task management method, device, equipment and medium based on log file
CN115222545A (en)Message modular processing method and device, computer equipment and storage medium
CN114461595A (en) Method, apparatus, medium and electronic device for sending messages
CN114218000A (en)Log management method and device, electronic equipment and computer readable storage medium

Legal Events

DateCodeTitleDescription
PB01Publication
PB01Publication
SE01Entry into force of request for substantive examination
SE01Entry into force of request for substantive examination
GR01Patent grant
GR01Patent grant

[8]ページ先頭

©2009-2025 Movatter.jp