我正在尝试将用户的@rkp solution实现到他们自己的question中,了解如何使用pycuda库通过cython来加速稀疏矩阵乘法(请注意,这是他们在帖子中的第二个解决方案)。Python3.5.2中)之后,我得到了: TypeError: 'numpy.float64' object cannot be interpreted as an integer 事实证明,产生这个错误的#PacketedSpMV produces the error
spmv = PacketedSpMV(a_sparse, is_symmetric
问题layer.adapt(x_full)错误#1(zero-based) was expected to be a uint8 tensor but is a float tensor [Op:Sub]尝试了dtype arg,但是同样的错误layer = tf.keras.layers.experimental.preprocess