Comments (3)
@LeungWaiHo
A1: Yes, it can be understood as a similarity function, which measures how relevant each visual feature is to the content described in the text.
A2: The output of this function, which measures the correlation/relevance between visual and text features, should range from 0 to 1, yet the cosine function has an output range of [-1, 1]. We use Eq.1 to adapt the cosine similarity outputs to [0, 1]. You can try other functions with similar effects.
from vltvg.
I cannot understand why this S(x,y) in Eq.1 can be seen as the relevance score, and the code computes verify_score by element-wise multiplication without Transpose,which is a little different with Eq.1. Could you further explain it?Thanks a lot!
text_embed = self.text_proj(text_info)
img_embed = self.img_proj(img_feat)
verify_score = (F.normalize(img_embed, p=2, dim=-1) *
F.normalize(text_embed, p=2, dim=-1)).sum(dim=-1, keepdim=True)
verify_score = self.tf_scale *
torch.exp( - (1 - verify_score).pow(self.tf_pow)
/ (2 * self.tf_sigma**2))
from vltvg.
It's just a matter of implementation. The inside part of Eq. 1 essentially computes the inner product of two feature vectors. Actually, you can use bmm after transposing the matrix/vector ( [Bx1xC] * [BxCx1] = [Bx1x1]), which is equivalent to the way I implemented it.
from vltvg.
Related Issues (20)
- Question about the verification score HOT 1
- 关于GFlops统计和params统计 HOT 2
- What is the GPU version and cuda version? HOT 14
- how to show discriminative features HOT 1
- 您好呀 HOT 7
- 请问有人跑到论文中的精度了嘛
- 请有人跑到论文中的精度了嘛
- 请问有人跑到论文中的精度了嘛,我现在任然差了很多,可以联系我讨论一下:vx:13330411658
- 请问有人跑到论文中的精度了嘛,我现在任然差了很多,可以联系我讨论一下:vx:13330411658
- The dataset of ReferItGame and Flickr30k is unavailable. HOT 3
- 请问有人跑到论文中的精度了嘛,我现在任然差了很多,可以联系我讨论一下:vx:13330411658
- 有预训练权重可以进行推理测试吗 HOT 1
- about verification score HOT 2
- Visualize the attention map for a point HOT 2
- Doubts about the hyperparameter args.box_xyxy HOT 4
- inferece api for REC HOT 1
- Split of Flickr30K dataset HOT 3
- Hello, the download link of the "ReferitGame" dataset is no longer available. Could you please send me a file through other methods? Thank you very much! HOT 1
- How to visualize the attention map HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vltvg.