Copy
功能描述
计算公式
接口原型
- AspbStatus asdBlasMakeCopyPlan(asdBlasHandle handle)
- AspbStatus asdBlasScopy(asdBlasHandle handle, const int64_t n, aclTensor *x, const int64_t incx, aclTensor *y,const int64_t incy)
- AspbStatus asdBlasCcopy(asdBlasHandle handle, const int64_t n, aclTensor *x, const int64_t incx, aclTensor *y,const int64_t incy)
参数列表
- asdBlasMakeCopyPlan
参数名称
Input/Output
类型
描述
handle
Input
asdBlasHandle
copy算子的句柄。
- asdBlasScopy & asdBlasCcopy
参数名称
Input/Output
类型
描述
handle
Input
asdBlasHandle
copy算子的句柄。
n
Input
const int64_t
总的元素个数。
x
Input
aclTensor *
公式中的x,Device侧的Tensor,数据格式支持ND,shape为[n]。
- Scopy下数据类型支持FLOAT32;
- Ccopy下数据类型支持COMPLEX64。
incx
Input
const int64_t
x相邻元素间的内存地址偏移量(当前约束为1)。
y
Output
aclTensor *
公式中的y,Device侧的Tensor,数据格式支持ND,shape为[n],数据格式、类型、shape和入参x保持一致。
- Scopy下数据类型支持FLOAT32;
- Ccopy下数据类型支持COMPLEX64。
incy
Input
const int64_t
y相邻元素间的内存地址偏移量(当前约束为1)。
规格约束
- asdBlasMakeCopyPlan:无。
- asdBlasScopy
- 输入的元素个数n当前覆盖支持[1,6.71e+06];
- 算子输入shape为[n],输出shape为[n];
- 算子实际计算时,不支持ND高维度运算(不支持维度≥3的运算)。
- asdBlasCcopy
- 输入的元素个数n当前覆盖支持[1,6.71e+06];
- 算子输入shape为[n],输出shape为[n];
- 算子实际计算时,不支持ND高维度运算(不支持维度≥3的运算)。
父主题: BLAS