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

text_image_search demo clip_op.train error #229

Open
Cheung7788 opened this issue Aug 14, 2023 · 2 comments
Open

text_image_search demo clip_op.train error #229

Cheung7788 opened this issue Aug 14, 2023 · 2 comments
Assignees

Comments

@Cheung7788
Copy link

https://github.com/towhee-io/examples/blob/main/image/text_image_search/2_deep_dive_text_image_search.ipynb 此demo教程中,运行
#step3
#train your model
clip_op.train(data_args=data_args, training_args=training_args, model_args=model_args)
抛错:

AttributeError Traceback (most recent call last)
Cell In[11], line 3
1 #step3
2 #train your model
----> 3 clip_op.train(data_args=data_args, training_args=training_args, model_args=model_args)

File ~/.towhee/operators/image-text-embedding/clip/versions/main/clip.py:156, in Clip.train(self, **kwargs)
154 training_args = kwargs.pop('training_args', None)
155 model_args = kwargs.pop('model_args', None)
--> 156 train_with_hf_trainer(self._model.backbone, self.tokenizer, data_args, training_args, model_args)

File ~/.towhee/operators/image-text-embedding/clip/versions/main/train_clip_with_hf_trainer.py:202, in train_with_hf_trainer(model, tokenizer, data_args, training_args, model_args, **kwargs)
194 logging.basicConfig(
195 format="%(asctime)s - %(levelname)s - %(name)s - %(message)s",
196 datefmt="%m/%d/%Y %H:%M:%S",
197 handlers=[logging.StreamHandler(sys.stdout)],
198 )
200 # Setup logging
201 #+ training_args
--> 202 log_level = training_args.get_process_log_level()
203 logger.setLevel(log_level)
204 transformers.utils.logging.set_verbosity(log_level)

AttributeError: 'dict' object has no attribute 'get_process_log_level'

@jaelgu
Copy link
Collaborator

jaelgu commented Aug 14, 2023

@Cheung7788 What is your towhee version?

@Jing-Fu
Copy link

Jing-Fu commented Mar 7, 2025

I have this problem too, can anyone help?
towhee Version: 1.1.3

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

4 participants