New answers tagged

0

It can be complex to one-hot encode features for a neural network. Often categories are feature hashed instead. Each category value is assigned a numeric value: orange: 1 apple: 2 banana: 3 lemon: 4 grape: 5 … The sequence then becomes: 1, 2, 3, 4 -> 5 A neural network is then able learn the sequence of numbers which represents the categories.


1

Few points to not here: Multicollinearity effects linear model much more as compared to Random forest as it is picking up different set of features (read sampling with replacement) for every model and every model/tree see different data points. Feature importance may be impacted a little by multicollinearity Multicollinearity does not impact model ...


0

Yes, the problem of imbalance is indeed genuine while pre processing. There are no hard and fast rules for removing outliers, but generic methodologies (percentile,boxplot,Z-score etc). Like gender, if you take salary of all employess then removing outliers means eliminating all highly paid employees.That will make your model learn more about middle/average ...


0

My assumption is that it used to be a necessary step when computing resources were scarce, but with today's resources it is basically irrelevant. You are entirely right. In the early days of computing, when resources were scarce, it was necessary just to keep important features and discard the rest. However, with the current abundance of resources, that is ...


0

Generally I think we want to get rid of unnecessary/bad features to save ourselves from the curse of dimensionality -- the more features we use, the more data we need to make sure each part of the feature space has enough data to fit the model. On top of that there are concerns specific to our model choice, for example, Random Forest / GBDT. If we have 30 ...


1

The feature selection step is there to guard against model overfitting. The feature selection step may decide that all the variables in the dataset are relevant, or it may decide to remove some. If no feature selection step is performed then no variables are removed and the resulting model may be well-fitted but may be (and likely is) overfitted. The main ...


16

You are right. If someone is using regularization correctly and doing hyperparameter tuning to avoid overfitting, then it should not be a problem theoretically (ie multi-collinearity will not reduce model performance) However it may matter in a number of practical circumstances. Here are two examples: You want to limit the amount of data you need to store ...


1

First, apply min-max normalization on the training set rather than the whole data set. Then, use the minimum and maximum of the training set to normalize the test set. Because, the test set is unseen by the model and should be normalized using the minimum and maximum of the training set (seen by the model).


0

One way to potentially do this is to choose peak widths such that those under a certain value are no longer detected as peaks and instead replaced with Median like Niels has suggested above.


1

It is crucial to measure the final result reached with prepropressing as best as possible. Therefore, there is a lot of different options depending on the datasets and depending on the algorithms/models. For instance, some models needs data normalization, some models needs logarithm or other transformation to improve the final results. Sometimes, you can ...


1

This is simply how the tokenizer works given the defaults that are defined, see also the documentation. By default the value for the split argument is ' ', meaning that it splits the sentences on every space character to get the tokens for that sentence. You can change this to get other multi-character tokens from a sentence. In addition, there is the ...


1

Often words are used as tokens as they carrie a meaning. This meaning is translated into "machine readable" format, which happens to be a number. So one distinct word will be one distinct token (or variable if you want to say so). Per docs you can change the TF/Keras default behaviour of "choosing words" by adding the option char_level=...


Top 50 recent answers are included