Hi,
I’m still not able to figure out the preprocess_dataset(dataset, text_vectorizer, label_encoder): function. I keep getting label undefined. Any help is appreciated.
thanks,
Venkat
Hi,
I’m still not able to figure out the preprocess_dataset(dataset, text_vectorizer, label_encoder): function. I keep getting label undefined. Any help is appreciated.
thanks,
Venkat
please share screenshot of the error without sharing any grade cell codes
use labels not label to the label_encoder function
Hi @Deepti_Prasad ,
The lambda parameteres are text, label and so I’m not sure why we should use labels. Anyway, using labels gives the same error.
Interestingly, if I use lambda: (without parameters) it doesn’t complain about text, but complains about labels.
then I need to see your previous grade cell codes for label encoder nd fit vectorizer.
please DM me screenshot codes. click on my name and then message
thankyou for the screenshot.
Compute the number of sentences that will be used for training (should be an integer)
You have defined this code with number of sentences and you were suppose to use the data argument to the TRAINING_SPLIT to get the train_size keeping in mind that the train_size need to be integer type.
Also when you do corrections to your codes, first clear out the kernel output and reconnect the kernel, and then run the cells from beginning till you have got the error.
in the dataset code, you are missing an extra tuple for dataset code.
I will remove this code once you view the answer
closing this thread, learner had missed a tuple for dataset code