GNN
图是我们身边非常常见的结构,最近的一些研究让我们能够使用图结构的优势,在许多领域,如抗生素的研究、物理仿真、虚假新闻的识别,交通预测和推荐系统都有了最新的研究与实践。这篇学习/总结博客参考了biliili上李沐的带读以及A Gentle Introduction to GNN这篇文章探索并解释了现代图神经网络,我们将工作分为4个部分:1. 什么类型的数据可以以图的形式记录;2. 图结构的特点与优势:相较于CNN或者传统深层神经网络;3. 建造一个GNN模型:从一个骨架到SOTA;4. 提供一个GNN playground供读者探究(会超链接回原文章)。 What a Graph is图是一系列实体之间的关系如果我们用图论的知识来看,图的描述其实有多种方式,如:邻接矩阵、集合的表示。我们这里采用相对容易接受的集合表示方法:一个图主要由 节点(Nodes) 和 边(Edges) 构成。以下图为例:其中存在5个节点,与6条边。其中点集合为$V = { A,B,C,D,E }$。边集合为$E = { AB, BC,CD,DE,AE, CE...
因果推断初步——反因果框架
在这篇文章中,你将会了解到:什么是bias,为什么我们在研究中存在bias,以及如何消除bias。We sometimes call the potential outcome that happened, factual, and the one that didn’t happen, counterfactual.$Y_{0i}$ is the potential outcome for unit i without treatment, it can also be written as $Y_{i}(0)$$Y_{1i}$ is the potential outcome for unit i with treatment, it can also be written as $Y_{i}(1)$we define the individual effect as $Y_{1i}-Y_{0i}$ , which can not be accumulated for the counterfactual. so we can only accumulate Average...
循证医学9-12周回顾
非参数检验非参数检验的适应条件 等级顺序资料 偏态资料 未知分布资料 各组资料的变异度大,方差不齐,变换也不能达到齐性 数据一端或两端有不确定值的资料 初步分析可以举几个例子:1. 不满足参数检验的要求;2. 血糖水平高于最高值会显示high 非参数检验的缺点容易出现第II类错误,即假阴性概率增大,本应显示出显著性差异的结果但是却并没有出现显著性差异。 两组配对设计资料的比较Wilcoxon符号秩和检验 符号检验 配对设计差值的符号秩检验:其实就是对差值进行符号检验 单样本资料的符号秩和检验Wilcoxon符号秩和检验。对标单样本正态检验 成组设计两样本比较的秩和检验Wilcoxon秩和检验 成组设计多个样本比较的秩和检验Kruskal Wallis H检验 原始数据的多个样本比较对标参数检验中的ANOVA,用于揭示多组数据的中位数是否完全相同 多个样本两两比较的秩和检验对标参数检验中的SNK-Q,...
CLIP
CLIP将计算机视觉与自然语言处理相结合,获得更加优秀的迁移性能与zero-shot效果。同时打破了固定标签的定式。 Abstract针对目前已有的计算机视觉系统,大部分都是使用固定的标签集合,这限制了它的泛化性能和可用性。于是作者选择通过图片的语言文本来进行图像识别。作者爬取了4亿张图片以进行模型的预训练。在预训练完成后,作者在30多个任务上进行了测试。在ImageNet数据集内,CLIP模型在zero-shot的情况下便已经与训练完成的Resnet50打成平手。 IntroductionGPT作为一个”Text-in-text-out”的经典案例,反映了弱监督工作的可行性,于是作者决定提出使用图片与文字结合,进行CLIP模型的研究。已有相关研究VirTex,...
Propensity Score
The propensity score makes it so that you don’t have to condition on the entirety of X to achieve independence of the potential outcomes on the treatment. It is sufficient to condition on this single variable, which is the propensity score$$(Y_{0},Y_{1}) \perp T|e(x)$$The propensity score is the conditional probability of receiving the treatment, right? So we can think of it as some sort of function that converts X into the treatment T. The propensity score makes this middle ground between...
Stats Review
“Some equations are dangerous if you know them, and others are dangerous if you do not. The first category may pose danger because the secrets within its bounds open doors behind which lies terrible peril. The obvious winner in this is Einstein’s iconic equation $E=mc^2$, for it provides a measure of the enormous energy hidden within ordinary matter. […] Instead I am interested in equations that unleash their danger not when we know about them, but rather when we do not. Kept close at...
Beyond Confounders
Good ControlSometimes treatment’s effect on the outcome is much smaller than other factors, in order to figure out the effect of treatment, we should control other factors because:If a variable is a good predictor of the outcome, it will explain away a lot of its variance.To demonstrate this, let’s resort to the partialling out way of breaking regression into 2 steps. First, we will regress the treatment, email, and the outcome, payments, on the additional controls, credit limit and risk...
循证医学7-8周回顾
二项分布与poisson分布及其应用二项分布 $$ P(X) = C^x_{n} \pi^x (1-\pi)^{n-x}$$ $$\mu = n\pi, \sigma^2={ n\pi(1-\pi) }$$ 样本率的方差计算同正态分布时的均值的方差计算:$$S_{p}=\sqrt{ \frac{p(1-p)}{n} }$$总体率置信区间计算: 查表方法 正态近似法(样本容量>100, $\pi \approx 0.5$) $$\begin{aligned} u &= \frac{{p-\pi_{0}}}{\sigma_{p}} \\ \sigma_{p} &= \sqrt{ \frac{\pi_{0}(1-\pi_{0})}{n} } \end{aligned}$$ *既往死亡率为40%,实验中120名病人死亡30名,统计推断: H_0: 均值不等 H_1: 均值相等 确定alpha值为0.05,双尾检验* $$\begin{aligned} \sigma_{p}&=\sqrt{ \frac{\pi_{0}(1-\pi_{0})}{n}...
循证医学5-6周回顾
ANOVA多组样本均数比较 多重比较SNK-Q, Dunnet-t, LSD-t检验,其中SNK-q最难显著,LSD-t最容易显著SNK-q: 任意两组进行均数的比较Dunnet-t: k-1个实验组与一个对照组的比较LSD-t: 特定几组的比较 前提正态分布方差齐性 Bartlett检验: 服从正态分布 Levene检验:服从任意分布 双向方差分析方差分析不等于分析方差,方差分析分析均数类似于ANOVA,仅可以做到比较多组是否全部相同。 析因设计的方差分析先确定有无交互效应若无交互效应则进行主效应分析若有交互效应则进行单独效应分析 F&Q: 老师上课所使用的单变量回归该如何理解?单变量回归的作用是不是就是将不同正态分布的总体拉到同一基线上?对于析因设计的方差检验,由于数据内部存在多组正态分布,导致数据总体不满足正态分布,所以需要分析其拟合后残差是否满足正态性与方差齐性$$\begin{aligned}Y = \beta_{0} + \beta_{1} X_{1} + \beta_{2}X_{2}\end{aligned}$$如果$X_{1}$:...
循证医学3-4周回顾
假设检验 检验的对象:抽样样本的均值,均值分布满足正态分布、抽样所得样本不一定满足正态分布 从正态分布——u分布——t分布(方差未知时用,大部分时候) 可信区间的计算(CI):依赖于标准正态分布$\mathcal{N}(0,1)$ ,双边检验和单边检验的区分变换方法:$$\begin{aligned}X \sim \mathcal{N}(\mu, \sigma^2)\\X-\mu \sim \mathcal{N}(0, \sigma^2)\\\frac{X-\mu}{\sigma} \sim \mathcal{N}(0, 1)\end{aligned}$$ 两组均数比较的参数检验单样本t检验和已知的均值比较。假设我检测的样本均值为$\bar{X} \sim \mathcal{N}(\mu_{1}, \frac{\sigma_{1}^2}{n})$,总体均值为常数$\mu_{2}$,然后我们对这两个作差得到:$$\bar{X}-\mu_{2}\sim \mathcal{N}(\mu_{1}-\mu_{2},...