Skip to content

FDSA和SASRECF支持使用item的预训练embedding吗? #2196

@kkckk1110

Description

@kkckk1110

您好,我想在FDSA和SASRECF两个序列推荐模型中使用Item的预训练embedding,我尝试使用两种方法导入,但都失败了。

(1)将emb作为float_seq格式和.item文件一起保存,然后在config['selected_features'] = ['emb']中指定,但模型好像并没有读取相关的特征列,报错:RuntimeError: torch.cat(): expected a non-empty list of Tensors

(2)将emb保存在.ent文件中,按照如下方式加载

additional_feat_suffix: [ent]
load_col:
    # inter/user/item/...: As usual
    ent: [ent_id, ent_emb]

但有如下报错:TypeError: can't convert np.ndarray of type numpy.object_. The only supported types are: float64, float32, float16, complex64, complex128, int64, int32, int16, int8, uint64, uint32, uint16, uint8, and bool.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions