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

Import Error, not compatible with transformer package #502

Closed
tang-t21 opened this issue Jul 6, 2024 · 4 comments
Closed

Import Error, not compatible with transformer package #502

tang-t21 opened this issue Jul 6, 2024 · 4 comments
Assignees

Comments

@tang-t21
Copy link

tang-t21 commented Jul 6, 2024

File "/home/Qwen/infer.py", line 63, in
import mii
File "/usr/local/lib/python3.10/dist-packages/mii/init.py", line 7, in
from .legacy import MIIServer, MIIClient, mii_query_handle, deploy, terminate, DeploymentType, TaskType, aml_output_path, MIIConfig, ModelConfig, get_supported_models
File "/usr/local/lib/python3.10/dist-packages/mii/legacy/init.py", line 7, in
from .client import MIIClient, mii_query_handle
File "/usr/local/lib/python3.10/dist-packages/mii/legacy/client.py", line 12, in
from .method_table import GRPC_METHOD_TABLE
File "/usr/local/lib/python3.10/dist-packages/mii/legacy/method_table.py", line 8, in
from transformers import Conversation
ImportError: cannot import name 'Conversation' from 'transformers' (/usr/local/lib/python3.10/dist-packages/transformers/init.py)

@tang-t21
Copy link
Author

tang-t21 commented Jul 7, 2024

Need to use an older version of transformer, but 'pip install deepspeed-mii' installs the latest one.

@zyyyyy5
Copy link

zyyyyy5 commented Jul 18, 2024

Need to use an older version of transformer, but 'pip install deepspeed-mii' installs the latest one.

I encountered this issue too. May I ask which version of transformer you use?

@loadams
Copy link
Contributor

loadams commented Jul 18, 2024

Hi @tang-t21 - this is resolved in the latest source builds of DeepSpeed-MII here #492. But we have not done a new release of MII that contains these fixes. We will work on this and update you when this is done soon.

@loadams loadams self-assigned this Jul 18, 2024
@loadams
Copy link
Contributor

loadams commented Jul 25, 2024

@tang-t21 - this is resolved in the latest release of DeepSpeed MII. If you hit any issues, please let us know and we can re-open this issue.

@loadams loadams closed this as completed Jul 25, 2024
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

3 participants