在存算一体(Computing-in-memory,CIM)芯片中,相较于传统的数字计算方案,模拟计算方案由于具有低功耗特性,可以更高效地完成计算任务.加权电荷累加电路(Weighted charge accumulation circuit,WCAC)作为模拟计算方案中的关键计算单元,因复杂的测试激励和控制时序,在测试方面具有一定挑战性.本文基于模拟计算架构和数据流的特点分析了线性度和误差分布这两项关键性能参数;提出了测试系统的设计方案,并根据目标数据集设计测试激励完成了对线性度和误差分布的测量.对于线性度,仿真与测量的结果分别为99.79%和99.11%.对于误差分布,仿真结果的平均值为-0.06 mV,标准差为1.54 mV.测量结果与仿真结果具有相同的分布趋势,其均值为0.37 mV,标准差为2.07 mV.电路整体呈现优良的线性度和计算精度.此外,为了评估WCAC在网络模型中可靠性,将测量的误差分布结果分别抽象到LeNet和AlexNet中,并在MNIST和CIFAR-10上进行了准确性实验.实验结果表明,在权重参数4比特和8比特量化条件下,LeNet对MNIST的识别准确率分别降低了 0.25%和0.18%;在权重参数8比特量化条件下,AlexNet对CAFAR-10的识别准确率降低了 3.12%.
In computing-in-memory(CIM)chips,analogue computing is more efficient than traditional digital computing due to its low power consumption.As a critical unit in analogue computing,the weighted charge accumulation circuit(WCAC)is challenging to measure because of its complex test pattern and control timing.In order to solve these problems,two key performance metrics:linearity and error distribution,are analysed based on the characteristics of analogue computing architecture and data flow.Further,the design scheme of the test system is proposed,and the test pattern is designed according to target data sets to measure linearities and error distribution.The simulation and measurement results of linearity are 99.79%and 99.11%,respectively.For the error distribution,the mean value of the simulation is-0.06 mV,and the standard deviation is 1.54 mV.The measurement result indicates the same distribution trend as the simulation,with a mean value of 0.37 mV and a standard deviation of 2.07 mV.Overall,the circuit exhibits excellent linearity and calculation accuracy.Furthermore,to evaluate the reliability of the WCAC in network models,the measured error distribution metrics are abstracted into LeNet and AlexNet,respectively,and accuracy experiments are performed on MNIST and CIFAR-10.Experimental results reveal that the accuracies of LeNet on MNIST are reduced by 0.25%and 0.18%,when weight parameters are quantized to 4 bits and 8 bits.The accuracy of AlexNet on CIFAR-10 is reduced by 3.12%,when weight parameters are quantized to 8 bits.