PyStruct找不到匹配的签名

2024-10-01 00:15:51 发布

您现在位置:Python中文网/ 问答频道 /正文

我试图使用这里的代码:https://github.com/pystruct/pystruct/blob/master/examples/multi_label.py

我有形状为(2591, 256)的X峎u火车和形状为(2591, 175)的y火车。当我运行这个:

tree = chow_liu_tree(y_train)
tree_model = MultiLabelClf(edges=tree, inference_method="max-product")
tree_ssvm = OneSlackSSVM(tree_model, inference_cache=50, C=.1, tol=0.01)
print("fitting tree model...")
tree_ssvm.fit(X_train, y_train)

我知道了:

^{pr2}$

当我直接从链接运行代码时,它可以工作(使用它们的数据集)。有人知道问题出在哪里吗?在


Tags: 代码httpsgithubmastercomtreemodeltrain