THUDM / CogDL

CogDL: A Comprehensive Library for Graph Deep Learning (WWW 2023)

Home Page:https://cogdl.ai

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

节点特征

Flians opened this issue · comments

commented

❓ Questions & Help

你好!请问我自定义的图数据集里面,节点特征为categorical,然后我使用了one-hot编码,使用experiment(model="gin", dataset=dataset)训练时,显示如下错误:
cogdl/operators/spmm/spmm.cpp:39: at::Tensor csr_spmm(at::Tensor, at::Tensor, at::Tensor, at::Tensor): Assertion B.dtype() == torch::kFloat32 || B.dtype() == torch::kFloat16' failed.`

请问有什么解决方法吗?

可以把特征转成FloatTensor来试试

commented

可以把特征转成FloatTensor来试试

谢谢了,准确率比较低,不知道是我自己数据的问题