Training Process OSError
I am training a simple classifier using the Flair NLP package. The training works, but then the process crashes with an OSError when saving the model to my local drive. Why would there be an OSError pertaining to loading when I’m saving?Code below:label_type = 'label'
label_dict = corpus.make_label_dictionary(label_type=label_type)
tars = TARSClassifier.load("tars-base")
tars.add_and_switch_to_new_task(task_name="classification",
                                label_dictionary=label_dict,
                                label_type=label_type,
                                )
trainer = ModelTrainer(tars, corpus)
trainer.train(base_path='../example_data/models/few_shot_model_flair',
              learning_rate=0.02,
              mini_batch_size=1,
              max_epochs=20,
              patience=1
              )The error:OSError: None is not a local folder and is not a valid model identifier listed on 'https://huggingface.co/models'
If this is a private repository, make sure to pass a token having permission to this repo with `use_auth_token` or log in with `huggingface-cli login` and pass `use_auth_token=True`.
2023-03-29T04:59:40Z
The issue stopped when I moved my code from a Jupyter notebook to a .py file.
2023-03-30T00:18:14Z
My mistake, it stopped working again, even in the .py file.