Looking for breakthrough ideas for innovation challenges? Try Patsnap Eureka!

Calibration method and device, terminal equipment and storage medium

A calibration method and technology of terminal equipment, applied in the field of data processing, can solve the problem of slow model calculation speed and so on

Pending Publication Date: 2020-11-10
LYNXI TECH CO LTD
View PDF0 Cites 1 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0004] In the current calibration algorithm, it usually calibrates each layer of the model layer by layer according to the direction of data input in the model, and calculates one layer or adjacent layers each time, which leads to the technical problem of slow calculation speed during model calibration

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Calibration method and device, terminal equipment and storage medium
  • Calibration method and device, terminal equipment and storage medium
  • Calibration method and device, terminal equipment and storage medium

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0049] figure 1 It is a schematic flowchart of a calibration method provided in Embodiment 1 of the present invention. The method can be applied to the case of calibrating the layer to be calibrated in the model. The method can be executed by a calibration device, wherein the device can be software and / or hardware. It is implemented and generally integrated on a terminal device. In this embodiment, the terminal device includes, but is not limited to, devices such as a mobile phone, a computer, and a personal digital assistant.

[0050] The present invention can be applied to model quantization scenarios, and after the model training is completed, the layers to be calibrated in the model are calibrated in groups by the calibration method provided by the present invention, so as to obtain the quantization factors of each layer to be calibrated. Quantization factors can be used to achieve model quantization. like figure 1 As shown, a calibration method provided in Embodiment 1 ...

Embodiment 2

[0067] figure 2 This is a schematic flowchart of a calibration method provided in Embodiment 2 of the present invention, and Embodiment 2 is embodied on the basis of the foregoing embodiments. In this embodiment, the grouping information corresponding to the layer to be calibrated is determined according to the attribute information and available resource information of each layer, which is further embodied as:

[0068] Determining the target layers of the layers to be calibrated in descending order of the required memory information;

[0069] determining the grouping information of the target layer;

[0070] The target layer is re-determined until the grouping information of each layer to be calibrated in the model is determined.

[0071] Please refer to the first embodiment for the content that is not yet detailed in this embodiment.

[0072] like figure 2 As shown, a calibration method provided by the second embodiment of the present invention includes the following s...

Embodiment 3

[0125] image 3 This is a schematic structural diagram of a calibration device provided in Embodiment 3 of the present invention. The device is applicable to the case of calibrating the layer to be calibrated in the model, wherein the device can be implemented by software and / or hardware, and is generally integrated on terminal equipment. .

[0126] like image 3 As shown, the device includes:

[0127] The first determination module 31 is used to determine the layer attribute information of the layer to be calibrated in the model;

[0128] The second determining module 32 is configured to determine the grouping information corresponding to the layer to be calibrated according to the attribute information of each layer and the available resource information;

[0129] The grouping calibration module 33 is configured to perform grouping calibration on the layers to be calibrated according to the grouping information.

[0130] In this embodiment, the device first determines th...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The invention discloses a calibration method and device, terminal equipment and a storage medium. The method comprises the steps of determining layer attribute information of each to-be-calibrated layer in a model; determining grouping information corresponding to the to-be-calibrated layer according to the layer attribute information and the available resource information; and performing groupingcalibration on the to-be-calibrated layer according to the grouping information. By means of the method, on the premise that available resources can support, all to-be-calibrated layers are reasonably grouped, so that multiple layers are calibrated at the same time through one-time calibration operation, the number of times of calibration operation is reduced, computing resources are fully utilized, and therefore the computing speed during model calibration is increased.

Description

technical field [0001] Embodiments of the present invention relate to the technical field of data processing, and in particular, to a calibration method, an apparatus, a terminal device, and a storage medium. Background technique [0002] Model quantization is a commonly used technique in the field of deep learning. By quantizing model parameters and inputs from high precision to low precision, such as quantizing from float32 to int8, the model operation speed can be improved and the model size can be reduced. [0003] In order to reduce the loss of accuracy in the model quantization process, the model needs to be calibrated to obtain the dynamic range of the value to be quantized, and then obtain the quantization factor, wherein the quantization factor is obtained by calculating the dynamic range. [0004] In the current calibration algorithm, each layer of the model is usually calibrated layer by layer according to the direction of data input in the model, and one layer or...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
IPC IPC(8): G06N20/00
CPCG06N20/00G06N3/0495
Inventor 李康丁瑞强李涵
Owner LYNXI TECH CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Patsnap Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Patsnap Eureka Blog
Learn More
PatSnap group products