Skip to content

[WIP] NVFP4 Emulation #58

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

[WIP] NVFP4 Emulation #58

wants to merge 1 commit into from

Conversation

mgoin
Copy link
Member

@mgoin mgoin commented Apr 29, 2025

Not correct yet

python -c "from vllm import LLM;out = LLM('nvidia/Llama-3.3-70B-Instruct-FP4', quantization='nvfp4', max_model_len=2048, enforce_eager=True).generate('Hi my name is');print(out)"

Processed prompts: 100%|███████████| 1/1 [00:35<00:00, 35.66s/it, est. speed input: 0.14 toks/s, output: 0.45 toks/s]
[RequestOutput(request_id=0, prompt='Hi my name is', prompt_token_ids=[128000, 13347, 856, 836, 374], encoder_prompt=None, encoder_prompt_token_ids=None, prompt_logprobs=None, outputs=[CompletionOutput(index=0, text='!!!!!!!!!!!!!!!!', token_ids=[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], cumulative_logprob=None, logprobs=None, finish_reason=length, stop_reason=None)], finished=True, metrics=None, lora_request=None, num_cached_tokens=None, multi_modal_placeholders={})]

Signed-off-by: mgoin <mgoin64@gmail.com>
Copy link

👋 Hi! Thank you for contributing to the vLLM project.

💬 Join our developer Slack at https://slack.vllm.ai to discuss your PR in #pr-reviews, coordinate on features in #feat- channels, or join special interest groups in #sig- channels.

Just a reminder: PRs would not trigger full CI run by default. Instead, it would only run fastcheck CI which starts running only a small and essential subset of CI tests to quickly catch errors. You can run other CI tests on top of those by going to your fastcheck build on Buildkite UI (linked in the PR checks section) and unblock them. If you do not have permission to unblock, ping simon-mo or khluu to add you in our Buildkite org.

Once the PR is approved and ready to go, your PR reviewer(s) can run CI to test the changes comprehensively before merging.

To run CI, PR reviewers can either: Add ready label to the PR or enable auto-merge.

🚀

@mgoin mgoin changed the title NVFP4 Emulation [WIP] NVFP4 Emulation Apr 29, 2025
@dsikka
Copy link

dsikka commented May 1, 2025

@mgoin
My branch with fixes for the weight dequant: #59
Sitll looking at activations. Seemed like we were getting gibberish even wth activation quantization turned off.

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

Successfully merging this pull request may close these issues.

2 participants