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

Some question about the code #38

Open
liuxiaozhu01 opened this issue Mar 11, 2024 · 2 comments
Open

Some question about the code #38

liuxiaozhu01 opened this issue Mar 11, 2024 · 2 comments

Comments

@liuxiaozhu01
Copy link

Hi! Thanks for your great work!

Im a little confused about the implementation. Your simple and efficient work only requires once forward caculate to get the activation of each layer. This line seems means that the forward caculate is excuted in sparse network, which also means the input of next layer is caculated by the current sparse layer because current layer is already masked.

Im wondering whether the "masked forward" is necessary, and I notice that if this operation is canceled, the result can be better in some conditions.

@Eric-mingjie
Copy link
Collaborator

Eric-mingjie commented Mar 11, 2024

We do not examine this closely in the paper, which we use to inherit the setup of SparseGPT. This does seem to be helpful for the LLaMA and LLaMA2 models we examined in the paper.

@liuxiaozhu01
Copy link
Author

liuxiaozhu01 commented Mar 12, 2024

I have read your paper carefully again. And i notice that this operation is mentioned as this "Given a pretrained LLM, we compute our pruning metric from the initial to the final layers of the network. After pruning a preceding layer, the subsequent layer receives updated input activations, based on which its pruning metrics will be computed."

Do you mean that the "masked forward" is helpful to LLaMA and LLaMA2 models?

And thanks for your reply! I think I need to do more further examination.

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