Top "Text-classification" questions

Simply stating, text classification is all about putting a piece of text into a set of (mostly predefined) categories.

How can I plot a confusion matrix?

I am using scikit-learn for classification of text documents(22000) to 100 classes. I use scikit-learn's confusion matrix method for computing the …

python matplotlib matrix scikit-learn text-classification
sklearn classifier get ValueError: bad input shape

I have a csv, struct is CAT1,CAT2,TITLE,URL,CONTENT, CAT1, CAT2, TITLE ,CONTENT are in chinese. I want …

python scikit-learn classification text-classification
ROC for multiclass classification

I'm doing different text classification experiments. Now I need to calculate the AUC-ROC for each task. For the binary classifications, …

python scikit-learn text-classification roc multiclass-classification
Dimension of shape in conv1D

I have tried to build a CNN with one layer, but I have some problem with it. Indeed, the compilator …

python keras text-classification keras-layer
CountVectorizer: AttributeError: 'numpy.ndarray' object has no attribute 'lower'

I have a one-dimensional array with large strings in each of the elements. I am trying to use a CountVectorizer …

python numpy scikit-learn text-classification
Python text processing: AttributeError: 'list' object has no attribute 'lower'

I am new to Python and to Stackoverflow(please be gentle) and am trying to learn how to do a …

python csv text-classification
Information Gain calculation with Scikit-learn

I am using Scikit-learn for text classification. I want to calculate the Information Gain for each attribute with respect to …

python machine-learning scikit-learn text-classification feature-selection
adding words to stop_words list in TfidfVectorizer in sklearn

I want to add a few more words to stop_words in TfidfVectorizer. I followed the solution in Adding words …

python scikit-learn classification stop-words text-classification
expected dense to have shape but got array with shape

I am getting the following error while calling the model.predict function when running a text classification model in keras. …

python keras shape text-classification
Multilabel Text Classification using TensorFlow

The text data is organized as vector with 20,000 elements, like [2, 1, 0, 0, 5, ...., 0]. i-th element indicates the frequency of the i-th word in …

python tensorflow text-classification multilabel-classification