当前位置:网站首页>Gram matrix
Gram matrix
2022-06-26 05:46:00 【SP FA】
About Gram matrix
n Any... In a dimensional Euclidean space k A matrix formed by the inner product of two vectors , It's called this k A vector Gram matrix .
Vector inner product formula : a ⃗ ⋅ b ⃗ = ∑ i = 1 n a i b i \vec a\cdot\vec b=\sum\limits_{i=1}^na_ib_i a⋅b=i=1∑naibi therefore Gram The formula of a matrix is : G r a m ( a ⃗ 1 ⋯ a ⃗ k ) = ( ( a ⃗ 1 ⋅ a ⃗ 1 ) ⋯ ( a ⃗ 1 ⋅ a ⃗ k ) ⋮ ⋱ ⋮ ( a ⃗ k ⋅ a ⃗ 1 ) ⋯ ( a ⃗ k ⋅ a ⃗ k ) ) Gram(\vec a_1\cdots\vec a_k)=\begin{pmatrix}(\vec a_1\cdot\vec a_1)&\cdots&(\vec a_1\cdot\vec a_k)\\\vdots&\ddots&\vdots\\(\vec a_k\cdot\vec a_1)&\cdots&(\vec a_k\cdot\vec a_k)\end{pmatrix} Gram(a1⋯ak)=⎝⎜⎛(a1⋅a1)⋮(ak⋅a1)⋯⋱⋯(a1⋅ak)⋮(ak⋅ak)⎠⎟⎞
It can be seen that ,Gram A matrix is a symmetric matrix .
Gram The matrix can be regarded as the eccentric covariance matrix between the data ( That is, the covariance matrix without subtracting the mean , The covariance matrix can be seen in This article )
Gram Application of matrix
For a set of features , We calculate its Gram matrix , It can reflect the correlation between two features . The elements on the diagonal can be understood as the information of the feature , The rest of the elements provide information about the relevance of different features , What are the characteristics of such a matrix , It can also reflect the closeness of different characteristics .
Gram The most direct application of matrix is in the field of image style transfer . For a picture , We want to extract its style , We need to use the network to extract local texture features 、 Image outline and other information , And then calculate Gram matrix , We can find out the correlation between features , This calculated Gram The matrix reflects the style of the image . At this point, if you want to compare the style similarity between the two pictures , Just compare their Gram matrix , if Gram The difference of matrix is small , It can be considered that the two images are similar in style .
边栏推荐
- 【 langage c】 stockage des données d'analyse approfondie en mémoire
- Cyclic displacement
- [PHP] PHP two-dimensional array is sorted by multiple fields
- Feelings of virtual project failure
- redis探索之布隆过滤器
- BOM文档
- Command line interface of alluxio
- 类和对象的学习
- Positioning setting horizontal and vertical center (multiple methods)
- 使用Jedis監聽Redis Stream 實現消息隊列功能
猜你喜欢
LeetCode_二叉搜索树_简单_108.将有序数组转换为二叉搜索树
国务院发文,完善身份认证、电子印章等应用,加强数字政府建设
Recursively traverse directory structure and tree presentation
[C language] deep analysis of data storage in memory
How Navicat reuses the current connection information to another computer
Sofa weekly | open source person - Yu Yu, QA this week, contributor this week
Operator priority, associativity, and whether to control the evaluation order [detailed explanation]
5分钟包你学会正则表达式
String类学习
Could not get unknown property ‘*‘ for SigningConfig container of type org.gradle.api.internal
随机推荐
Using Jenkins to perform testng+selenium+jsup automated tests and generate extendreport test reports
Unicloud cloud development obtains applet user openid
Daily production training report (16)
cross entropy loss = log softmax + nll loss
【C语言】深度剖析数据在内存中的存储
[upsampling method opencv interpolation]
无线网络存在的安全问题及现代化解决方案
kolla-ansible部署openstack yoga版本
机器学习 05:非线性支持向量机
Last flight
力扣 875. 爱吃香蕉的珂珂
劣币驱逐良币的思考
Introduction to lcm32f037 series of MCU chip for motor
国务院发文,完善身份认证、电子印章等应用,加强数字政府建设
Redis discovery bloom filter
小小面试题之GET和POST的区别
Consul service registration and discovery
A new journey
Kolla ansible deploy openstack Yoga version
421-二叉树(226. 翻转二叉树、101. 对称二叉树、104.二叉树的最大深度、222.完全二叉树的节点个数)