lixinustc / GraphAdapter

The efficient tuning method for VLMs
74 stars 1 forks source link

Calculation of degree matrix #3

Closed hzau96yhz closed 7 months ago

hzau96yhz commented 11 months ago

Hello!I have a question about the paper. image Is a text/visual knowledge subgraph a kind of complete graph? According to the discription in the paper,it seems to calculate the cosine similarity between any two prompts embeddings. The formula for calculating the degree matrix(below) is a little confusing, but it seems that the diagonal elements of the matrix are all 2K at the end of the calculation. I don't know if that's right. image

hzau96yhz commented 11 months ago

Sorry to bother you again, but there is one more question. During the optimization process, each prompt text feature used for classification will be added to the subgraph. Will a node be removed from the original image after it is added for the first time?Or continue to add the second node on the graph after the first node is added

lixinustc commented 11 months ago

Since the CVPR deadline, I will provide the response after CVPR. Sorry for that.

hzau96yhz commented 10 months ago

Hi!Sorry to bother you again! Now would you mind answering the questions I raised earlier.

lixinustc commented 10 months ago

Sorry for the late response, the p is set as -0.5, therefore, it is not 2K here for the D matrix. You can print it with our codebase. Thanks.