Check patentability & draft patents in minutes with Patsnap Eureka AI!

Tensor segmentation method and device, chip and medium

A tensor and molecular technology, which is applied in the field of devices, chips and media, and tensor segmentation method, can solve the problems of increasing hardware cost, high hardware cost, and increasing hardware complexity, so as to reduce the number of configurations and reduce the number of segmentations Effect

Pending Publication Date: 2021-03-16
无锡灵汐类脑科技有限公司
View PDF0 Cites 1 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0003] At present, in order to realize strided splitting of tensors, it can be realized by chips that support strided splitting, but the hardware cost is relatively high; it is also possible to configure multiple registers on the basis of chips that do not support strided splitting. However, when splitting multi-dimensional tensors, a register needs to be configured for each data split. The more splits, the more configuration registers, which not only increases the hardware cost, but also increases the hardware complexity.

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
  • Tensor segmentation method and device, chip and medium
  • Tensor segmentation method and device, chip and medium
  • Tensor segmentation method and device, chip and medium

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0027] figure 1 It is a flow chart of a tensor segmentation method provided by Embodiment 1 of the present invention. This embodiment is applicable to the situation of multi-dimensional tensor segmentation in strides. The method can be divided by the tensor segmentation provided by the embodiment of the present invention. device, which can be implemented in the form of software and / or hardware, and generally can be integrated in a chip.

[0028] like figure 1 As shown, the tensor segmentation method provided in this embodiment is applied to stride segmentation, including:

[0029] S110. Obtain an initial tensor and segmentation parameters.

[0030] The initial tensor can be a one-dimensional tensor, a two-dimensional tensor, or a multidimensional tensor.

[0031] The segmentation parameter refers to the segmentation parameter corresponding to the stride segmentation, which may include the segmentation step size. Among them, when splitting tensors in strides, the splitting ...

Embodiment 2

[0045] figure 2It is a flow chart of a tensor segmentation method provided by Embodiment 2 of the present invention. This embodiment is embodied on the basis of the foregoing embodiments, wherein the data on the dimension to be split can be rearranged according to the initial tensor and the split parameters to obtain the rearranged tensor, specifically:

[0046] Split the dimension to be split into sub-dimensions and step sub-dimensions according to the dimension size and step size of the dimension to be split, and rearrange the data on the dimension to be split according to the split result to obtain a rearrangement tensor .

[0047] Further, the rearranged tensor can be split according to the split parameter to obtain the result tensor, specifically:

[0048] According to the split start index value of the dimension to be split, perform the first split on the rearranged tensor on the step size sub-dimension to obtain a split tensor;

[0049] According to the segmentation...

Embodiment 3

[0094] Figure 5 It is a flow chart of a tensor segmentation method provided by Embodiment 3 of the present invention. This embodiment is embodied on the basis of the foregoing embodiments, wherein the number of dimensions to be split is multiple; after the step of splitting the rearranged tensor according to the split parameter to obtain the result tensor, further includes :

[0095] Judging whether there is a dimension to be split that has not completed the splitting process, if so, return to the step of rearranging the data on the dimension to be split according to the initial tensor and the splitting parameters, for the current splitting process The data on the target dimension to be split is rearranged, wherein the initial tensor when performing split processing for the target dimension to be split is the result tensor obtained when the split processing is completed for the previous dimension to be split; If not, the result tensor obtained when the splitting process is ...

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 embodiment of the invention discloses a tensor segmentation method and device, a chip and a medium. The method comprises the following steps: acquiring an initial tensor and a segmentation parameter; rearranging data on a dimension to be segmented according to the initial tensor and the segmentation parameter to obtain a rearranged tensor, so that the data to be reserved on the dimension to besegmented are adjacently arranged; and segmenting the rearranged tensor according to the segmentation parameters to obtain a result tensor. According to the method, the tensor step segmentation can be realized through the chip which does not support the step segmentation, and the register configuration number is reduced.

Description

technical field [0001] Embodiments of the present invention relate to the technical field of data processing, and in particular to a tensor splitting method, device, chip and medium. Background technique [0002] Tensor operations include: concatenation, slicing, indexing, and transformation. Stride slice is a specific way of slicing, which refers to slicing the data in the tensor according to the stride. For example, tensor A is [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10], if the segmentation step is stride=2, the stride segmentation of tensor A is obtained The segmentation result is [0,2,4,6,8,10]. [0003] At present, in order to realize strided splitting of tensors, it can be realized by chips that support strided splitting, but the hardware cost is relatively high; it is also possible to configure multiple registers on the basis of chips that do not support strided splitting. However, when splitting multi-dimensional tensors, one register needs to be configured for each data ...

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): G06F16/901G06K9/62
CPCG06F16/901G06F18/213
Inventor 吴欣洋李涵戚海涛丁瑞强冯开革
Owner 无锡灵汐类脑科技有限公司
Features
  • R&D
  • Intellectual Property
  • Life Sciences
  • Materials
  • Tech Scout
Why Patsnap Eureka
  • Unparalleled Data Quality
  • Higher Quality Content
  • 60% Fewer Hallucinations
Social media
Patsnap Eureka Blog
Learn More