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

Problem with NLP #10

Closed
harry418 opened this issue Dec 4, 2020 · 2 comments
Closed

Problem with NLP #10

harry418 opened this issue Dec 4, 2020 · 2 comments

Comments

@harry418
Copy link

harry418 commented Dec 4, 2020

tokenizer_name is not defined in tokenize.
AttributeError Traceback (most recent call last)
in ()
----> 1 tokenizedX = nlp.tokenize(cleanX.values)

/usr/local/lib/python3.6/dist-packages/GML/NLP.py in tokenize(self, text)
580 Return: Tokenized
581 """
--> 582 tokenizer = AutoTokenizer.from_pretrained(self.tokenizer_name)
583 encoded = tokenizer.batch_encode_plus(
584 text,

AttributeError: 'AutoNLP' object has no attribute 'tokenizer_name'

@Muhammad4hmed
Copy link
Owner

Please make sure you called the set_params() function before tokenizing or modeling.

Just like in this notebook: https://github.com/Muhammad4hmed/GML/blob/master/DEMO/AutoTextClassification.ipynb

@Muhammad4hmed
Copy link
Owner

Closing this issue assuming it's solved. if not, feel free to reopen.

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

2 participants