huggingface / setfit

Efficient few-shot learning with Sentence Transformers
https://hf.co/docs/setfit
Apache License 2.0
2.24k stars 221 forks source link

Version issue #553

Open DhavalRepo18 opened 2 months ago

DhavalRepo18 commented 2 months ago

The DatasetFilter class was introduced in Hugging Face Hub version 0.12.0 and was deprecated in version 0.21.0. It was completely removed in version 0.24.0.

You can find more information about this change in the Hugging Face Hub release notes:

Version 0.21.0: https://github.com/huggingface/huggingface_hub/releases Version 0.24.0: https://github.com/huggingface/huggingface_hub/releases

from setfit import SetFitModel, Trainer, TrainingArguments, sample_dataset this has issue.

tomaarsen commented 2 months ago

Hello!

The issue has been resolved in the main branch, expect a new version to release in the coming week with this fix applied. In the meantime, you can use:

pip install git+https://github.com/huggingface/setfit
imessien commented 2 months ago

There's a new version issue now:

RuntimeError: Failed to import transformers.trainer because of the following error (look up to see its traceback): cannot import name 'is_mlu_available' from 'accelerate.utils' (/cis/home/iessien1/.local/lib/python3.9/site-packages/accelerate/utils/__init__.py)

Even when using the pip installed using git. The github/colab examples also don't work.

tomaarsen commented 1 month ago

Hello!

My guess is that your accelerate version is a bit too old:

pip install -U accelerate