News for hackers. Stuff that matters.
Re:70B Llama 2 at 35tokens/second on 4090 by Palmik on Wednesday September 13, 2023 @05:25AM (#37494317)
Sure, there are many ways one can be accidentally inefficient, some examples:

Batching: Your throughput (and thus cost per token) will be much worse if you don't do batching (meaning running inference for several inputs at once). To do batching, you either need to have a high sustained QPS or adjust your workload to be bursty (but this has utilization issues).

Inference engine: The regular HuggingFace, even with built in optimizations, is not competitive against inference engines like vllm, exllama, etc.

Utilization: Depending on your scale, it might be hard for you to have a nice flat utilization, or to even utilize one GPU at 100% capacity. This means you need to solve scaling up & down your machines and the issues associated with it (can you live with cold starts? etc.)

Hardware: Forget server-less GPUs like Replicate etc, their markups compared to on-demand pricing is usually >10x. On-demand A100 or H100, provided you can even get a quota for them, are also expensive. Spot instances are better. Older GPUs (A10, T4, etc.) are better. Your own GPU cluster is likely the best if you have the scale (and likely, you can resell your cluster within the next 18months without much if any depreciation).

For these reasons, I have been toying with the idea of providing a dead simple service for fine-tuning & serving open-source LLMs where the users actually own (and can download) the weights. If anyone is interested in this and would like to chat, let me know.

Re:70B Llama 2 at 35tokens/second on 4090 by TheIronYuppie on Wednesday September 13, 2023 @05:36AM (#37494424)
We’d be interested in helping! aronchick (at) expanso (dot) io
Re:70B Llama 2 at 35tokens/second on 4090 by quickthrower2 on Wednesday September 13, 2023 @05:45AM (#37494492)
Interested in this. Are you thinking of it being a SaaS type thing? I have some rudimentary experience, i.e. training NanoGPT on both Modal.com and Vast.ai (which is vastly cheaper, but privacy/cost trade off there).

It could be a layer on top of $gpu_cloud (so end user signs up for the cloud) and the service makes use of those resources.

Re:70B Llama 2 at 35tokens/second on 4090 by senseiV on Wednesday September 13, 2023 @02:20PM (#37499835)
Do you inference NanoGPT with say a Flask app? I made a WebUI for tiny Llama, but it doesn't work for NanoChatGPt
Re:70B Llama 2 at 35tokens/second on 4090 by quickthrower2 on Wednesday September 13, 2023 @07:07PM (#37502859)
Ha ha not sure yet, I have only done it from the command line. Still got a lot to learn. Building something like this will be good for that!
Re:70B Llama 2 at 35tokens/second on 4090 by algo_trader on Wednesday September 13, 2023 @11:10AM (#37497815)
Thanks for the writeup

Our special case is a single model, high throughput and latency unsensitive.

Can we use multiple lower-memory GPUs, split the the model "horizontally", and pipeline each batch/inference across the GPUs?

Is this a common scenarios handled by the engines you mentioned ?