Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reproduction Implementation #2

Open
zcablii opened this issue Oct 28, 2023 · 3 comments
Open

Reproduction Implementation #2

zcablii opened this issue Oct 28, 2023 · 3 comments

Comments

@zcablii
Copy link

zcablii commented Oct 28, 2023

It's an excellent work! Your implementation of RMT is truly impressive!
Nevertheless, I have a couple of questions regarding the code implementation. Was the "1D to 2D" and the "Decomposed ReSA in Early Stage" described in the paper also implemented in the code? If they were, could you please indicate their specific location in the code? I would greatly appreciate your assistance in clarifying this matter.

@jiaowoguanren0615
Copy link
Owner

jiaowoguanren0615 commented Oct 28, 2023 via email

@zcablii
Copy link
Author

zcablii commented Oct 28, 2023

Thank you for your prompt response. I apologize for any confusion caused by my previous message.

Regarding my initial inquiry about "1D to 2D," I was referring to equation (5) in the paper. In this equation, D is defined as \gamma^ {|x_n-x_m| + |y_n-y_m|}. However, upon inspecting the code in retention.py, specifically in line 102 within the _get_D() function, it appears that the image is treated as tokens in a Vision Transformer (ViT) and the |y_n-y_m| part has not been implemented.

Regarding my second question, my understanding is that "Decomposed ReSA in Early Stage" refers to the implementation of equation (7) in the paper. This implementation can be likened to a strip strip pooling decomposition technique.

@jiaowoguanren0615
Copy link
Owner

jiaowoguanren0615 commented Oct 29, 2023 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants