[yzhpdh]Adaptive Hypergraph Auto-Encoder for Relational Data Clustering

Title:Adaptive Hypergraph Auto-Encoder for Relational Data Clustering

introduction

图的embedded representation 和 clustering task 在关系型数据分析和挖掘方面发挥了很重要的作用,但是仅仅是成对的关系不足建模现实生活中的高阶关系。且如何适当地整合结构信息和属性信息是另一项重要的任务,但尚未得到系统的研究。因此这篇文章提出了自适应超图自动编码器(AHGAE)来学习低维空间中的节点embedding

这篇文章的贡献在于:

  1. 提出一个超图拉普拉斯平滑过滤器,通过融合节点特征与同一超边中邻接特征达到平滑节点特征的效果。
  2. 提出了一个自适应超图自动编码器(AHGAE),是一种专门用于超图聚类任务的嵌入式模型。
  3. 构建了一个属性超图数据集DBLP-HG,并且在该数据集和其他一些基准图数据集上做实验,验证了模型的有效性。

related work

首先,图聚类任务分为两大类,分别是: structural graph clustering tasks 和 attributed graph clustering tasks。
首先是介绍structural graph clustering tasks; 谱系聚类方法直接将图的结构作为输入。
直接将图的结构作为输入,通过对图的切割,使切割后的不同子图之间的边的权重尽可能低,以达到聚类的目的。还有提出将节点的邻接矩阵分解成节点表征后利用k-means的方法获得聚类。还有Deepwalk通过在图中游走使用skipgram学习节点表征,通过在图上随机行走和最大化每个节点的邻居概率,然后获得聚类结果。
然后介绍attributed graph clustering tasks;同时具有图结构和节点特征的图被称为attributed graphs。该任务的研究重点是如何平衡图的结构信息和节点特征信息。最常见的pipeline是首先学习包含结构信息的节点embedding,然后实现常见的聚类方法,如K-means或spectral clustering来获得最后的结果。像常见的GAE、VGAE、AGC、AGE都属于这类工作,且融合了图卷积网络和自动编码器等。

method

首先是方法框架:
这张图左边部分的意思是文章确定了一个指标∆c(t) ,它代表未标记的聚类度量的变化值,这个图经过一次次迭代,直到∆c(t) >0的时候获得最终结果,它是用来选择最优顺序的。
右边部分,H代表关联矩阵,A代表邻接矩阵。
请添加图片描述
先给出方法中的定义:

自适应图注意力自动编码器(Adaptive Graph Attention Auto - encoder)是处理空间分辨转录组学数据以解读空间域的有效工具。 在空间分辨转录组学中,数据包含了基因表达信息以及细胞或组织在空间中的位置信息。自适应图注意力自动编码器可以利用图结构来建模这些数据。首先,将空间转录组学数据构建成图,图中的节点代表细胞或组织区域,边代表节点之间的空间关系或基因表达相似性。 自适应图注意力机制能够为不同的邻居节点分配不同的注意力权重。在自动编码器的框架下,编码器部分通过图注意力层将节点的特征(基因表达值)进行非线性变换,学习到低维的潜在表示。解码器则尝试从潜在表示中重构原始的基因表达特征。 在训练过程中,通过最小化重构误差,使得模型能够学习到数据中的重要特征和空间结构。这样,模型可以捕捉到空间域内细胞或组织区域的基因表达模式,从而实现对空间域的解读。例如,可以根据学习到的潜在表示对细胞或组织区域进行聚类,划分出不同的空间域。 ```python import torch import torch.nn as nn import torch.nn.functional as F # 定义图注意力层 class GraphAttentionLayer(nn.Module): def __init__(self, in_features, out_features, dropout, alpha, concat=True): super(GraphAttentionLayer, self).__init__() self.dropout = dropout self.in_features = in_features self.out_features = out_features self.alpha = alpha self.concat = concat self.W = nn.Parameter(torch.empty(size=(in_features, out_features))) nn.init.xavier_uniform_(self.W.data, gain=1.414) self.a = nn.Parameter(torch.empty(size=(2*out_features, 1))) nn.init.xavier_uniform_(self.a.data, gain=1.414) self.leakyrelu = nn.LeakyReLU(self.alpha) def forward(self, h, adj): Wh = torch.mm(h, self.W) # h.shape: (N, in_features), Wh.shape: (N, out_features) e = self._prepare_attentional_mechanism_input(Wh) zero_vec = -9e15*torch.ones_like(e) attention = torch.where(adj > 0, e, zero_vec) attention = F.softmax(attention, dim=1) attention = F.dropout(attention, self.dropout, training=self.training) h_prime = torch.matmul(attention, Wh) if self.concat: return F.elu(h_prime) else: return h_prime def _prepare_attentional_mechanism_input(self, Wh): # Wh.shape (N, out_feature) # self.a.shape (2 * out_feature, 1) # Wh1&2.shape (N, 1) # e.shape (N, N) Wh1 = torch.matmul(Wh, self.a[:self.out_features, :]) Wh2 = torch.matmul(Wh, self.a[self.out_features:, :]) # broadcast add e = Wh1 + Wh2.T return self.leakyrelu(e) # 定义自适应图注意力自动编码器 class AdaptiveGraphAttentionAutoencoder(nn.Module): def __init__(self, nfeat, nhid, dropout, alpha): super(AdaptiveGraphAttentionAutoencoder, self).__init__() self.encoder = GraphAttentionLayer(nfeat, nhid, dropout=dropout, alpha=alpha, concat=True) self.decoder = nn.Linear(nhid, nfeat) def forward(self, x, adj): z = self.encoder(x, adj) recon_x = self.decoder(z) return recon_x ```
评论 1
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值