一般出现在mxnet的nd模块 函数作用 将向量X转换成标量,且向量X只能为一维含单个元素的向量 X:nd类型的数据 例子 test=nd.array([5]) 输出: [5.] <NDArray 1 @cpu(0)> 转换成标量: test.asscalar() 输出: 5.0