上一页 1 ··· 32 33 34 35 36 37 38 39 40 ··· 73 下一页
摘要: ''' 摘自https://docs.dgl.ai/en/0.6.x/guide_cn/graph-feature.html ''' import dgl import torch as th # 无权图 g = dgl.graph(([0, 0, 1, 5], [1, 2, 2, 0])) # 6 阅读全文
posted @ 2021-10-22 10:58 Picassooo 阅读(777) 评论(0) 推荐(0)
摘要: ''' 摘自https://docs.dgl.ai/en/0.6.x/guide_cn/graph-graphs-nodes-edges.html ''' import dgl import torch as th import networkx as nx import matplotlib.py 阅读全文
posted @ 2021-10-22 10:55 Picassooo 阅读(437) 评论(0) 推荐(0)
摘要: 关于整图分类,有篇知乎写的很好:【图分类】10分钟就学会的图分类教程,基于pytorch和dgl。下面的代码也是来者这篇知乎。 import dgl import torch from torch._C import device import torch.nn as nn import torch 阅读全文
posted @ 2021-10-22 10:39 Picassooo 阅读(13050) 评论(0) 推荐(0)
摘要: zip(*args)解压运算 阅读全文
posted @ 2021-10-22 08:45 Picassooo 阅读(54) 评论(0) 推荐(0)
摘要: 图上的机器学习任务通常有三种类型:整图分类、节点分类和链接预测。本篇博客要实现的例子是节点分类,具体来说是用GCN对Cora数据集里的样本进行分类。 Cora数据集介绍: Cora数据集由许多机器学习领域的paper构成,这些paper被分为7个类别: Case_Based Genetic_Algo 阅读全文
posted @ 2021-10-20 21:37 Picassooo 阅读(5883) 评论(0) 推荐(0)
摘要: 网上一些博客也有关于Pycharm远程连接服务器的内容,但是他们说的方法大多需要deployment设置和interpreter配置两步,稍微有点繁琐,根据我的实践经历,只需要interpreter配置这一个步骤就可以,因为在这一步中只要设置好sync folders,就pycharm自动做好了de 阅读全文
posted @ 2021-10-09 16:00 Picassooo 阅读(1697) 评论(0) 推荐(0)
摘要: 用这个命令就可以实现空一整行:\hspace*{\fill} \\ 参考:latex中空一整行的方法 阅读全文
posted @ 2021-09-26 11:39 Picassooo 阅读(4450) 评论(0) 推荐(0)
摘要: 解决python画图中colorbar设置刻度和标签字体大小 阅读全文
posted @ 2021-09-05 12:00 Picassooo 阅读(2134) 评论(0) 推荐(0)
摘要: 1. torch.nonzero()的定义 【摘自:Pytorch:torch.nonzero()函数】 2. torch.nonzero()用来筛选张量中符合某个条件的元素,得到这些元素的索引 一维例子: 注意得到的b是二维张量。上述代码的原理是,a>6得到的是一个元素为True或False的张量 阅读全文
posted @ 2021-08-25 22:07 Picassooo 阅读(13063) 评论(0) 推荐(1)
摘要: Visio之取消自动对齐与粘附 阅读全文
posted @ 2021-08-25 11:52 Picassooo 阅读(766) 评论(0) 推荐(0)
上一页 1 ··· 32 33 34 35 36 37 38 39 40 ··· 73 下一页