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

[Feature] Using the w8a8 model for inference, it should be automatically routed to the pytorch backend without adding the backend parameter. #2595

Closed
zhulinJulia24 opened this issue Oct 12, 2024 · 0 comments
Assignees

Comments

@zhulinJulia24
Copy link
Collaborator

Motivation

Currently it cannot be automatically routed to the pytorch backend without adding the backend parameter.
Need routed to the pytorch backend automatically.

reproduce step:

  1. do lite
    lmdeploy lite smooth_quant /nvme/qa_test_models/internlm/internlm2_5-7b-chat --work-dir /nvme/qa_test_models/internlm/internlm2_5-7b-chat-inner-w8a8 --batch-size 32
  2. chat with this model
    lmdeploy chat /nvme/qa_test_models/internlm/internlm2_5-7b-chat-inner-w8a8 --session-len 4096 --tp 1

Error occurs:

  File "/usr/lib/python3.10/multiprocessing/process.py", line 314, in _bootstrap
    self.run()
  File "/usr/lib/python3.10/multiprocessing/process.py", line 108, in run
    self._target(*self._args, **self._kwargs)
  File "/__w/lmdeploy/lmdeploy/autotest/utils/pipeline_chat.py", line 52, in run_pipeline_chat_test
    pipe = pipeline(hf_path, backend_config=backend_config)
  File "/opt/py3/lib/python3.10/site-packages/lmdeploy/api.py", line 81, in pipeline
    return pipeline_class(model_path,
  File "/opt/py3/lib/python3.10/site-packages/lmdeploy/serve/async_engine.py", line 158, in __init__
    self._build_turbomind(model_path=model_path,
  File "/opt/py3/lib/python3.10/site-packages/lmdeploy/serve/async_engine.py", line 197, in _build_turbomind
    self.engine = tm.TurboMind.from_pretrained(
  File "/opt/py3/lib/python3.10/site-packages/lmdeploy/turbomind/turbomind.py", line 302, in from_pretrained
    return cls(model_path=pretrained_model_name_or_path,
  File "/opt/py3/lib/python3.10/site-packages/lmdeploy/turbomind/turbomind.py", line 112, in __init__
    self.model_comm = self._from_hf(model_source=model_source,
  File "/opt/py3/lib/python3.10/site-packages/lmdeploy/turbomind/turbomind.py", line 214, in _from_hf
    tm_model = get_tm_model(model_path, self.model_name,
  File "/opt/py3/lib/python3.10/site-packages/lmdeploy/turbomind/deploy/converter.py", line 241, in get_tm_model
    assert 0, f'unsupported quant_config: {quant_config}'
AssertionError: unsupported quant_config: {'quant_method': 'smooth_quant'}

Related resources

No response

Additional context

No response

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