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

No module named 'transformers.models.starcoder2' #31636

Closed
1 of 4 tasks
rabinghimire2023 opened this issue Jun 26, 2024 · 2 comments
Closed
1 of 4 tasks

No module named 'transformers.models.starcoder2' #31636

rabinghimire2023 opened this issue Jun 26, 2024 · 2 comments

Comments

@rabinghimire2023
Copy link

System Info

I get error while using the " from transformers import Trainer" as :
RuntimeError: Failed to import transformers.trainer because of the following error (look up to see its traceback):
No module named 'transformers.models.starcoder2'

Current version of transformers is 4.38.2.

Can anyone give ideas on this what has happened exactly on this?

Who can help?

No response

Information

  • The official example scripts
  • My own modified scripts

Tasks

  • An officially supported task in the examples folder (such as GLUE/SQuAD, ...)
  • My own task or dataset (give details below)

Reproduction

from transformers import (
AutoModelForCausalLM,
AutoTokenizer,
DataCollatorForLanguageModeling,
Trainer,
TrainingArguments,
)

Expected behavior

Working smoothly

@amyeroberts
Copy link
Collaborator

Hi @rabinghimire2023, thanks for opening this issue!

I'm unable to replicate this on a source install, on the recent release v4.41.2, or on 4.38.2.

I'd suggest trying to reinstall transformers in your environment pip install -U transformers

Copy link

This issue has been automatically marked as stale because it has not had recent activity. If you think this still needs to be addressed please comment on this thread.

Please note that issues that do not follow the contributing guidelines are likely to be ignored.

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