Skip to content

problem with openprompt #311

@komi786

Description

@komi786

i tried to use latest version of openprompt (pip install openprompt and aslo tried by cloning from github) with transformer 4.41 and 4.42 b

`oduleNotFoundError Traceback (most recent call last)
Cell In[2], line 9
7 print(transformers.version)
8 print(transformers.file)
----> 9 import openprompt
10 print(openprompt.version)
11 print(openprompt.file)

File /usr/local/lib/python3.10/dist-packages/openprompt/init.py:2
1 version = "1.0.1"
----> 2 from .pipeline_base import PromptDataLoader, PromptModel, PromptForClassification, PromptForGeneration
3 from .utils import *
4 from .prompt_base import Template, Verbalizer

File /usr/local/lib/python3.10/dist-packages/openprompt/pipeline_base.py:4
2 from torch.utils.data.sampler import RandomSampler
3 from transformers.configuration_utils import PretrainedConfig
----> 4 from transformers.generation_utils import GenerationMixin
5 import torch
6 import torch.nn as nn

ModuleNotFoundError: No module named 'transformers.generation_utils'`

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions