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

TemplateAssertionError: no test named 'False' #507

Open
SaraTGRN opened this issue Mar 30, 2024 · 2 comments
Open

TemplateAssertionError: no test named 'False' #507

SaraTGRN opened this issue Mar 30, 2024 · 2 comments

Comments

@SaraTGRN
Copy link

I am trying to save SetFit in my directory (which is databricks), but both commands of :
trainer.model.save_pretrained(save directory)
OR trainer.save_pretrained(save directory)

gives me the error of TemplateAssertionError: no test named 'False',
can you help me how can I save my model.

@OliverXiaoxiong
Copy link

Sample problem, any solution?

@szhong-ssmhealth
Copy link

szhong-ssmhealth commented May 2, 2024

The following fixed the issue from my side when I use cpu for testing.
!pip install jinja2 --upgrade
import os
os.environ["TOKENIZERS_PARALLELISM"] = "false"

dump(trainer.model, 'setfit_model.pkl')
model=load('setfit_model.pkl')

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