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

-ngl to load ·last n layers· to gpu #12577

Open
Bobchenyx opened this issue Mar 26, 2025 · 2 comments
Open

-ngl to load ·last n layers· to gpu #12577

Bobchenyx opened this issue Mar 26, 2025 · 2 comments

Comments

@Bobchenyx
Copy link

Hi there,

I would like to know if we could use -ngl to load last N layers to GPU instead of first N.

If possible can someone please point me to a place where I should modify the source code?

llama-bench for example.

@Bobchenyx
Copy link
Author

take MoE models as an example. I would like to load first M Dense layers to CPU, then rest N MoE layers to GPU

@foldl
Copy link
Contributor

foldl commented Mar 26, 2025

My proposal: update -ngl to something like this:

https://github.com/foldl/chatllm.cpp/blob/master/docs/gpu.md#usage

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