text
stringlengths
81
47k
source
stringlengths
59
147
Question: <p>I've been trying to employ some basic techniques of supervised learning on a dataset that I have and I have several questions about the overall procedure (i.e. data preprocessing, model evaluation etc).</p> <p>Before I start posing the questions let me give you an insight of how my dataset looks like. The ...
https://datascience.stackexchange.com/questions/104851/some-questions-about-supervised-learning-model-evaluation-and-preprocessing
Question: <p>I want to evaluate the performance of my linear regression model. I have the true values of y (y-true). I am thinking of two way for evaluation but not sure which one is correct. </p> <p>Let's assume that we have 2 samples and each sample has two outputs as following: </p> <pre><code>y_true = [[0.5, 0.5]...
https://datascience.stackexchange.com/questions/40265/evaluation-of-linear-regression-model
Question: <p>I'm doing some research on the wide and deep model developed by Google. And I got 2 questions on the training and evaluation code fragment. (<a href="https://github.com/tensorflow/models/blob/master/official/wide_deep/wide_deep_run_loop.py#L96-L120" rel="nofollow noreferrer">Complete code</a> see here):</p...
https://datascience.stackexchange.com/questions/35993/evaluation-code-understanding-in-wide-and-deep-model-of-tensorflow
Question: <p>I've created a model with Random Forest algorithm. There are 45k observations, where 1s I have 12% and the rest are 0s. As far as I know ROC AUC is not the best evaluation metric in such a case. I went with PR AUC and got 59%. How would you assess the results ?</p> <p><a href="https://i.sstatic.net/XyA5a.p...
https://datascience.stackexchange.com/questions/114577/evaluation-of-a-model-of-imbalanced-data
Question: <p>I have been building a model, can someone please review my methods and let me know if I am making a mistake? </p> <p>I trained a model with a support vector machine as follows : </p> <p>Split data into training and test sets as 10 partitions for K10 fold cross validation. </p> <p>Split training set into...
https://datascience.stackexchange.com/questions/43370/is-anything-missing-from-my-model-evaluation-procedure
Question: <p>Scikit-learn page on Grid Search says:</p> <blockquote> <p>Model selection by evaluating various parameter settings can be seen as a way to use the labeled data to “train” the parameters of the grid.</p> <p>When evaluating the resulting model it is important to do it on held-out samples that were not seen ...
https://datascience.stackexchange.com/questions/122562/can-i-use-gridsearchcv-best-score-for-evaluation-of-model-performance
Question: <p>In the Denoising Diffusion Probabilistic Models paper (<a href="https://arxiv.org/abs/2006.11239" rel="nofollow noreferrer">https://arxiv.org/abs/2006.11239</a>), the rate-distortion plot is computed assuming access to a protocol that can transmit samples <span class="math-container">$(x_T, ... x_0)$</span...
https://datascience.stackexchange.com/questions/131567/rate-distortion-plots-in-denoising-diffusion-model-evaluation
Question: <p>I would greatly appreciate if you could let me know what to report in the following steps of CRISP-DM?</p> <ul> <li><strong>Build Model</strong>: what should be reported for parameter settings, models and model description? I used grid search to tune hyperparameters.</li> <li><strong>Assess Model</strong>...
https://datascience.stackexchange.com/questions/33265/what-to-report-in-the-build-model-asses-model-and-evaluate-results-steps-of-cri
Question: <p>Christoph Molnar, in his book <a href="https://christophm.github.io/interpretable-ml-book/" rel="nofollow noreferrer">Interpretable Machine Learning</a>, writes that</p> <blockquote> <p>Human level evaluation (simple task) is a simplified application level evaluation. The difference is that these experimen...
https://datascience.stackexchange.com/questions/92227/reliability-of-human-level-evaluation-of-the-interpretability-quality-of-a-model
Question: <p>For example I have an original sentence. The word barking corresponds to the word that is missing.</p> <pre><code>Original Sentence : The dog is barking. Incomplete Sentence : The dog is ___________. </code></pre> <p>For example, using the BERT model, it predicts the word crying instead of the word bark...
https://datascience.stackexchange.com/questions/63124/bert-model-evaluation-measure-in-terms-of-syntax-correctness-and-semantic-cohere
Question: <p>There is a deep model for prediction.</p> <p>The outputs are some numbers between 0 and 80. (In the dataset the outputs are 0-80)</p> <p>The model Loss value is 70 and I would like to reduce it.</p> <p>I printed the outputs after evaluating the model by test values and some of the predicted values are m...
https://datascience.stackexchange.com/questions/39022/restricting-the-output-of-a-model-didnt-improve-the-loss-value-of-the-model-eva
Question: <p>i'm trying to create ML model for binary classification problem with balanced dataset and i care mostly about probabilities. I was trying to search web and i find only advices to use AUC or logloss scores. There is no advices to use Brier score as evaluation metric. Can i use brier score as evaluation metr...
https://datascience.stackexchange.com/questions/110837/best-metric-to-evaluate-model-probabilities
Question: <p>Suppose I deployed a model by manual labeling the ground truth labels with my training data, as the use case is such that there's no way to get the ground truth labels without humans. Once the model is deployed, if I wanted to evaluate how the model is doing on live data, how can I evaluate it without samp...
https://datascience.stackexchange.com/questions/109553/how-is-model-evaluation-and-re-training-done-after-deployment-without-ground-tru
Question: <p>I am training some neural networks in pytorch to use as an embedded surrogate model. Since I am testing various architectures, I want to compare the accuracy of each one, but I am also interested in evaluating the computational time of a single forward pass as accurately as possible. Below is the structure...
https://datascience.stackexchange.com/questions/129480/what-is-the-most-accurate-way-of-computing-the-evaluation-time-of-a-neural-netwo
Question: <p>Consider a experiment to predict the Google-Play apps rating using a Random-Forest classifier with scikit-learn in Python. Three attributes 'Free', 'Size' and 'Category' are utilized to predict the apps rating. 'Rating' (label) is not continuous value, instead, grouped into two classes 0 and 1. Where 0 is ...
https://datascience.stackexchange.com/questions/98038/how-to-interprete-the-feature-significance-and-the-evaluation-metrics-in-classif
Question: <p>Following <a href="https://github.com/chiphuyen/tf-stanford-tutorials/blob/master/examples/03_logistic_regression_mnist_sol.py" rel="nofollow noreferrer">this</a> tutorial, I have a doubt about the evaluation part in:</p> <pre><code># test the model n_batches = int(mnist.test.num_examples/batch_size) tota...
https://datascience.stackexchange.com/questions/19850/evaluating-logistic-regression-model-in-tensorflow
Question: <p>Given that I have data containing images of oranges, apples and pineapples and I want to classify depending on a set of features.</p> <p>Expected that I have completed the model and ready for prediction.</p> <p>My questions are:</p> <p>How can I output each score for every category the model predicted l...
https://datascience.stackexchange.com/questions/36312/evaluate-prediction-from-multiple-classification-model
Question: <p>I am using machine learning models to predict an ordinal variable (values: 1,2,3,4, and 5) using 7 different features. I posed this as a regression problem, so the final outputs of a model are continuous variables. So an evaluation box plot looks like this: <a href="https://i.sstatic.net/FBXw2.jpg" rel="no...
https://datascience.stackexchange.com/questions/36550/chi-square-as-evaluation-metrics-for-nonlinear-machine-learning-regression-model
Question: <p>I should mention that even though I have some basic knowledge regarding ML, it is the first big ML project I am working on and for the proposal of my research project I need to suggest an evaluation metric.</p> <p>The problem is a multiclass(16 classes) classification problem where one data point can be c...
https://datascience.stackexchange.com/questions/63091/evaluation-method-for-multi-class-classification-problem-modeled-as-binary-class
Question: <p>I am currently on a project that will build a model (train and test) on Client-side Web data, but evaluate this model on Sever-side Web data. Unfortunately building the model on Server-side data is not an option, nor is it an option to evaluate this model on Client-side data.</p> <p>This model will be ba...
https://datascience.stackexchange.com/questions/887/modelling-on-one-population-and-evaluating-on-another-population
Question: <p>I am dealing with an imbalanced class with the following distribution : (Total dataset size : 10763 X 20)</p> <p>0 : 91%</p> <p>1 : 9%</p> <p>To build model on this dataset having class imbalance, I have compared results using </p> <p>1) SMOTE and </p> <p>2) Assigning more weight to the minority cla...
https://datascience.stackexchange.com/questions/47804/model-performance-using-precision-as-evaluation-metric
Question: <p>There are several "classical" ways to quantify the quality of (any!) regression models such as the RMSE, MSE, explained variance, r2, etc...</p> <p>These metrics however do not take "costs" into account, for example, for me it is worse to under-predict a value (Real: 0.5, Predicted: 0.4) than to over-pred...
https://datascience.stackexchange.com/questions/24950/cost-function-for-evaluating-a-regression-model
Question: <p>I have been working with Classification Modelling in R and Python for the last 6 months now. With the Classification, the evaluation of the Model was based on Precision, Recall, Hamming Loss, accuracy etc., These classification models needed the testing data to calculate these evaluation metrics.</p> <p>...
https://datascience.stackexchange.com/questions/36089/do-we-need-the-testing-data-to-evaluate-the-model-performance-regression
Question: <p>The task is to predict sentiment from 1 to 10 based on Russian reviews. The training data size is 20000 records, of which 1000 were preserved as a validation set. The preprocessing steps included punctuation removal, digit removal, Latin character removal, stopword removal, and lemmatization. Since the dat...
https://datascience.stackexchange.com/questions/121745/why-my-sentiment-analysis-model-is-overfitting
Question: <p>I am building a multiclass classifier to predict the "Intent" of a question. There are some 100 classes in the target variable and each target class contains an unequal proportion of observations/questions varying from 3 % to 40 %.</p> <p><strong>Questions</strong></p> <ol> <li>What would be a good evalu...
https://datascience.stackexchange.com/questions/40946/what-is-a-suitable-loss-function-and-evaluation-metric-for-a-classification-mode
Question: <p>I have the following problem, I have trained a CNN and I can evaluate the network in-sample. I want to use the trained model for the class prediction of images for which I have no ground truth. However, there are other features referenced to these images that I can implement in a regression model along wi...
https://datascience.stackexchange.com/questions/111330/need-term-or-method-name-for-evaluation-of-cnn-without-ground-truth-using-e-g-a
Question: <p>My dataset has about 100k entries, 6 features, and the label is simple binary classification (about 65% zeros, 35% ones).</p> <p>When I train my dataset on different models: random forest, decision tree, extra trees, k-nearest neighbors, logistic regression, sgd, dense neural networks, etc, the evaluations...
https://datascience.stackexchange.com/questions/102911/multiple-models-have-extreme-differences-during-evaluation
Question: <p>I have an CNN object detection model which has two heads(outputs) with tensor names <code>'classification'</code> and <code>'regression'</code>. </p> <p>I want to define a metric function that <strong>accepts both the outputs at the same time</strong>, so that it looks into the <strong>regression predicti...
https://datascience.stackexchange.com/questions/54443/keras-custom-metric-function-how-to-feed-2-model-outputs-to-a-single-metric-eval
Question: <p>I am using Two-Class Boosted Decision Tree to train model. </p> <p>Evaluation result I'd say really good.</p> <p>But when I am using real dataset - the result is very bad.</p> <p>What can possibly go wrong that makes such huge difference? </p> <p>Below is the screenshot of my model:</p> <p><a href="ht...
https://datascience.stackexchange.com/questions/28251/why-training-model-give-great-result-but-real-data-gives-very-bad-result-azure
Question: <p>I'm working on a use case where I need to pre process the image for my AIML model evaluation and I want to count all black pixels in RGB image.</p> <p>Instead of iterating rows*column, I'm looking for some vector based approach for this evaluation. Please suggest.</p> Answer: <p>I did this implementation,...
https://datascience.stackexchange.com/questions/100542/image-preprocessing
Question: <p>So I trained a DL algorithm using Keras for Human Action Recognition. The model has an accuracy of about 85 percent and a loss of 0.3 something. The problem is that the model did not predict well on unseen data. The dataset consists of 3 classes with 100 videos in each class.</p> <p><strong>Training Phase:...
https://datascience.stackexchange.com/questions/103955/how-to-make-an-dl-model-predict-correctly
Question: <p>Let's assume I have 2 models</p> <p>Model 1:</p> <ul> <li>Train Accuracy = 92.4%</li> <li>Validation Accuracy = 37.6%</li> <li>Test Accuracy = 35.3%</li> </ul> <p>Model 2:</p> <ul> <li>Train Accuracy = 37.0%</li> <li>Validation Accuracy = 34.2%</li> <li>Test Accuracy = 34.1%</li> </ul> <p>Which is the best...
https://datascience.stackexchange.com/questions/114204/evaluate-best-model
Question: <p>Most data imbalance questions on this stack have been asking <em>How to learn a better model</em>, but I tend to think one other problem is <em>How do we define &quot;better&quot; (i.e. fairly evaluate the learned model)</em> to ensure the evaluation performance on the limited test set does not suffer from...
https://datascience.stackexchange.com/questions/112713/how-to-effectively-evaluate-a-model-with-highly-imbalanced-and-limited-dataset
Question: <p>Is it a good practice to evaluate a model on the <strong>training set</strong> (i.e. train a model on training set and evaluate the regression error/accuracy on the same training set) <strong>and</strong> compare the evaluation result with the model regression error/accuracy of cross validation (we do the ...
https://datascience.stackexchange.com/questions/80555/is-it-a-good-practice-to-evaluate-a-model-on-the-training-set
Question: <p>Should the two sequential parts of a hurdle model (Response model and Expected value model) be tuned and evaluated independently, and then combines for the final results (Product of the probability to respond and the expected value)? Or should they be tuned and evaluated as a single model? What is the best...
https://datascience.stackexchange.com/questions/82639/how-to-evaluate-a-hurdle-model
Question: <p>I am evaluating a neural network model using cross validation in 2 different ways ( A &amp; B ) that I thought were equivalent.</p> <ul> <li><strong>Evaluation type A :</strong> For each cross validation loop, the model is instantiated and fitted.</li> <li><strong>Evaluation type B :</strong> I instantiate...
https://datascience.stackexchange.com/questions/81126/cross-validation-and-evaluation-neural-network-loss-function-continuously-decre
Question: <p>Does the objective function for model fitting and the evaluation metric for model validation need to be identical throughout the hyperparameter search process?</p> <p>For example, can a XGBoost model be fitted with the Mean Squares Error (MSE) as the objective function (setting the 'objective' argument to ...
https://datascience.stackexchange.com/questions/82224/match-between-objective-function-and-evaluation-metric
Question: <p><strong>TLDR:</strong></p> <p>I evaluated a classification model using 10-fold CV with data leakage in the training and test folds. The results were great. I then solved the data leakage and the results were garbage. I then tested the model in an independent new dataset and the results were similar to the ...
https://datascience.stackexchange.com/questions/108916/is-data-leakage-giving-me-misleading-results-independent-test-set-says-no
Question: <p>Tools like AWS Sagemaker have capability to do automated hyperparameter tuning, even with complex algos like Neural Networks using Tensorflow. So do we still need to learn how to do hyperparameter tuning, or simply leave it to tools like Sagemaker? Thx</p> Answer: <blockquote> <p>So do we still need to le...
https://datascience.stackexchange.com/questions/85426/with-automated-hyperparameter-tuning-available-do-we-still-need-to-learn-hyperp
Question: <p>Are there any advanced packages that allow automated hyperparameter tuning for neural networks and traditional machine learning algorithms like XGBoost, random forest (using method like Bayesian, random search etc. that could allow for faster discovery of the optimal parameters)? I have heard of hyperopt, ...
https://datascience.stackexchange.com/questions/27057/automated-hyperparameter-tuning
Question: <p>While designing the architecture of a Neural Network, should I consider adding regularization (like Dropout, L1/L2, etc.) even after optimizing the problem using Hyperparameter Tuning? What should be the main focus (tuning or regularization) to achieve more generalization, considering that both of these si...
https://datascience.stackexchange.com/questions/116846/hyperparameter-tuning-vs-regularization
Question: <p>My question is about the intuition for hyperparameter tuning of time series.</p> <p>In other models, like Linear or Logistic Regression there is labeled data and according to accuracy or precision, the parameters are tuned. But in time series, the future values are predicted. For example, the next 30 days....
https://datascience.stackexchange.com/questions/106346/time-series-hyperparameter-tuning
Question: <p>For what I know, and correct me if I am wrong, the use of cross-validation for hyperparameter tuning is not advisable when I have a huge dataset. So, in this case it is better to split the data in training, validation and test set; and then perform the hyperparameter tuning with the validation set.</p> <p...
https://datascience.stackexchange.com/questions/60547/hyperparameter-tuning-with-validation-set
Question: <p>Suppose I have developed a dynamic system for forecasting the future of some specific stocks. As time passes, the train set will change dynamically. For a better understanding, consider this example:</p> <ul> <li><p><strong>First Round:</strong><br /> train set = [0 : 150] (The first 150 samples are in the...
https://datascience.stackexchange.com/questions/112244/how-to-avoid-numerous-hyperparameter-tuning-in-ml
Question: <p>I have a dataset where I applied xgb model with grid search to tune the hyperparameters and class balancing. I compared the model without any hyperparameter tuning with a model that has been applied with hyperparameter tuning. The model without any hyperparameters set output an accuracy around 90 (train), ...
https://datascience.stackexchange.com/questions/112115/why-does-model-with-hyperparameter-tuning-underperform
Question: <p>Is hyperparameter tuning done on training or validation data set? The post <a href="https://stats.stackexchange.com/questions/366862/is-using-both-training-and-test-sets-for-hyperparameter-tuning-overfitting">here</a> gives mixed opinion as of whether the training set should be used for hyperparameter tuni...
https://datascience.stackexchange.com/questions/121388/is-hyperparameter-tuning-done-on-training-or-validation-data-set
Question: <p>The way I read almost lots of ML advice on these datasets sounds like &quot;You train a model that's randomly chosen hyperparameters first on the training set, then you ignore this bit of the work, and hyperparameter tune on a validation set, then choose the final model you want and test it on the test set...
https://datascience.stackexchange.com/questions/124881/ordering-of-train-val-test-set-use-in-hyperparameter-tuning
Question: <p>I have a problem where I am trying to apply a one-class svm to detect outliers. I am training on a dataset of <em>true</em> cases using a one-class radial svm and then predicting for both false and true cases. It is worth noting that the <em>true</em> cases I am training on do contain a proportion of miscl...
https://datascience.stackexchange.com/questions/74691/hyperparameter-tuning-one-class-svm
Question: <p>I have about 30 variables and trying to create a Random Forest model. All the variables are expected to be predictors of outcome. I want to find the best model based on a C-stat score with any number of features. Shall I do feature selection first or hyperparameter tuning? I read that people prefer feature...
https://datascience.stackexchange.com/questions/126768/feature-selection-or-hyperparameter-tuning-first-for-30-feature-data
Question: <p>I have a time series data that handled using GDBT to predict the next value. I always use previous 30 days data to train daily, but overtime the data to predict and train is increased because the number of combination things increased.</p> <p>My question is, how often do we need to hypertune our model? an...
https://datascience.stackexchange.com/questions/56530/hyperparameter-tuning-time-series-in-production
Question: <p>I have been trying to teach myself about machine learning and wanted to make sure I had the right idea about model selection, hyperparameter tuning, and cross validation. </p> <p>So given a data set, my understanding is that this is the general workflow should be. 1. Split into train and test 2. Use cross...
https://datascience.stackexchange.com/questions/73990/proper-workflow-for-model-selection-and-hyperparameter-tuning-using-cross-valida
Question: <p>I have a problem with Hyperparameter Tuning. Usually I getting almost the same results(or worse) than before tuning. Usually default parameters of classificator(regressor) give me a best score. Anybody could recommend other techniques or give me a tip what I should improve?</p> Answer:
https://datascience.stackexchange.com/questions/61487/getting-worse-results-after-hyperparameter-tuninggrid-random-search-tpot
Question: <p>There is a balanced binary classified dataset as seen below.</p> <p><a href="https://i.sstatic.net/NLgSH.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/NLgSH.png" alt="Target Variable count"></a></p> <p>Things I have tried using <a href="https://scikit-learn.org/stable/modules/generated/s...
https://datascience.stackexchange.com/questions/73304/hyperparameter-tuning-results-yield-no-improvement-over-spot-check
Question: <p>I tuned my hyperparameter with random search and i used <code>cv=5</code>. Is it important to validated the hyperparameter with model and testdata or is it okay to use the given back accuracy from random search?</p> Answer: <p>In machine learning there is a fundamental difference between what is known as ...
https://datascience.stackexchange.com/questions/90539/validation-after-hyperparameter-tuning
Question: <p>Using hyperopt to hyperparameter tuning on XGBoost regressor, I am receiving overfiting on the train set.</p> <p>There is any suggestion how to solve it ?</p> <p>I have used cross validation with early_stopping_rounds and it still doesn't improved.</p> <p>I have tried to tune the gamma, colsample_bytree, ...
https://datascience.stackexchange.com/questions/94600/xgboost-regressor-hyperparameter-tuning-with-hyperopt-leads-to-overfit
Question: <p>I'm trying to tune hyperparameters with bayesian optimization. It is a regression problem with the objective function: objective = 'reg:squaredlogerror'<br /> <span class="math-container">$\frac{1}{2}[log(pred+1)-log(true+1)]^2$</span></p> <p>My dataset consists of 20k vectors, each vector has length 12 (t...
https://datascience.stackexchange.com/questions/84609/hyperparameter-tuning-xgboost
Question: <p>I'm studying TensorFlow Extended and I can see that it's training pipeline includes a &quot;Tuner&quot; component for hyperparameter tuning. As a consequence, I'm wondering if inclusion of tuning is a good practice in case of a production pipeline (which, as in most cases, invoked iteratively from time to ...
https://datascience.stackexchange.com/questions/108451/is-it-a-good-practice-to-use-hyperparameter-tuning-in-production-pipeline
Question: <p>I often work with very large datasets where it would be impractical to check all relevant combinations of hyperparameters when constructing a machine learning model. I'm considering randomly sampling my dataset and then performing hyperparameter tuning using the sample. Then, I would train/test the model u...
https://datascience.stackexchange.com/questions/44109/disadvantages-of-hyperparameter-tuning-on-a-random-sample-of-dataset
Question: <p>Question 22 of <a href="https://www.projectpro.io/article/100-data-science-interview-questions-and-answers-for-2021/184" rel="nofollow noreferrer">100+ Data Science Interview Questions and Answers for 2022</a> asks <em>What is the benefit of batch normalization?</em></p> <p>The first bullet of the answers ...
https://datascience.stackexchange.com/questions/114953/how-does-batch-normalization-make-a-model-less-sensitive-to-hyperparameter-tunin
Question: <pre><code>X = all features from dataset y = all target from dataset X_train = features that already using train_test_split approach y_train = target that already using train_test split approach </code></pre> <p>So my question is which one should I choose if I would like to do hyperparameter tuning? I have...
https://datascience.stackexchange.com/questions/115204/which-data-hyperparameter-tuning-using-for-fit-the-model
Question: <p>Im currently working on biometric authentication, specifically on keystroke dynamics. I used XGBoost as binary classification so i can calculate equal error rate (EER) and ROC-AUC. Now i want to do tuning hyperparameter but i dont know how should set them up. My current approach was wraping XGBoost with On...
https://datascience.stackexchange.com/questions/129989/xgboost-binary-classification-for-authentication-hyperparameter-tuning
Question: <p>While running SVC(), how we can hyperparameter tune C vs gamma combination?</p> <p>I could see changes in C and gamma are impacting the accuracy differently. Also, what I understand about C and gamma are:</p> <ol> <li><p>C is the cost of mis-classification which means a large C gives you a low bias and hig...
https://datascience.stackexchange.com/questions/66251/svm-c-vs-gamma-hyperparameter-tuning
Question: <p>I tried random forest in both R (Caret) and Python (Scikit-learn), but the results differ drastically. Pearson correlation between predicted value and actual value was 0.2 in python whereas 0.8 in R.</p> <p>I suspect that is because of hyperparameter tuning difference and wanted to check detail settings in...
https://datascience.stackexchange.com/questions/88363/how-to-compare-hyperparameter-tuning-in-r-and-python
Question: <p>I am running machine learning models (all with sci-kit learn estimators, no neural networks) using a custom dataset with a number of features and binomial output. I first split the dataset into 0.6 (train), 0.2 (validation), 02 (test) sets, before preprocessing and converting into dataframes.</p> <p>I use ...
https://datascience.stackexchange.com/questions/131174/rfecv-and-grid-search-what-sets-to-use-for-hyperparameter-tuning
Question: <p>I use a Bayesian hyperparameter (HP) optimization approach (<a href="https://docs.ray.io/en/master/_modules/ray/tune/suggest/bohb.html" rel="nofollow noreferrer">BOHB</a>) to tune a deep learning model. However, the resulting model is not robust when repeatedly applied to the same data. I know, I could use...
https://datascience.stackexchange.com/questions/74710/robustness-of-hyperparameter-tuning
Question: <p>So, my predicament here is as follows, I performed hyperparameter tuning on a standalone Decision Tree classifier, and I got the best results, now comes the turn of Standalone Adaboost, but here is where my problem lies, if I use the Tuned Decision Tree from earlier as a base_estimator in Adaboost, then I ...
https://datascience.stackexchange.com/questions/102103/does-hyperparameter-tuning-of-decision-tree-then-use-it-in-adaboost-individually
Question: <p>Jane trains three different classifiers: Logistic Regression, Decision Tree, and Support Vector Machines on the training set. Each classifier has one hyper-parameter (regularisation parameter, depth-of-tree, etc) that needs to set, so she chooses a set of 10 reasonable values for each and performs a sweep ...
https://datascience.stackexchange.com/questions/126432/hyperparameter-tuning
Question: <p>After reading a lot of articles on cross validation, I am now confused. I know that cross validation is used to get an estimate of model performance and is used to select the best algorithm out of multiple ones. After selecting the best model (by checking the mean and standard deviation of CV scores) we tr...
https://datascience.stackexchange.com/questions/104435/cross-validation-and-hyperparameter-tuning-workflow
Question: <p>I have a binary classification task with substantial class imbalance (99% negative - 1% positive). I want to developed a Random Forest model to make prediction, and after establishing a baseline (with default parameters), I proceed to hyperparameter tuning with scikit-learn's GridSearchCV.</p> <p>After set...
https://datascience.stackexchange.com/questions/116761/is-there-a-point-in-hyperparameter-tuning-for-random-forests
Question: <p>What is the difference between Hyper-parameter Tuning and k-NN algorithm? Is k-NN also a type of Hyper-parameter tuning?</p> Answer: <p>In kNN algorithm, you only try to find a suitable value of parameter k. And some models may have many parameters that can be modified. Normal parameters are optimized by ...
https://datascience.stackexchange.com/questions/29962/hyperparameter-tuning-in-machine-learning
Question: <p>I'm working on optimizing the hyperparameters for several ML models (FFN, CNN, LSTM, BiLSTM, CNN-LSTM) at the moment, and running this alongside another experiment examining which word embeddings are best to use on the task of binary text classification.</p> <p>My question is: should I decide on which emb...
https://datascience.stackexchange.com/questions/57364/is-hyperparameter-tuning-more-affected-by-the-input-data-or-by-the-task
Question: <p>Let's say I'm comparing few models, and for my dataset I'm using train/validation/test split, and not cross validation. Let's say I'm completely done with parameter tuning for one of them and want to evaluate on the test set. Will I train a new model, on both the training and the validation datasets combin...
https://datascience.stackexchange.com/questions/89323/validation-set-after-hyperparameter-tuning
Question: <p>I'm aware of how to use <code>sklearn.pipeline.Pipeline()</code> for simple and slightly more complicated use cases alike. I know how to set up pipelines for homogeneous as well as heterogeneous data, in the latter case making use of <code>sklearn.compose.ColumnTransformer()</code>.</p> <p>Yet, in practica...
https://datascience.stackexchange.com/questions/106568/how-to-combine-preprocessor-estimator-selection-with-hyperparameter-tuning-using
Question: <p>I'm reading the following kaggle post for learning how to incorporate model stacking </p> <p><a href="http://blog.kaggle.com/2016/12/27/a-kagglers-guide-to-model-stacking-in-practice/" rel="nofollow noreferrer">http://blog.kaggle.com/2016/12/27/a-kagglers-guide-to-model-stacking-in-practice/</a> in ML mod...
https://datascience.stackexchange.com/questions/41336/hyperparameter-tuning-for-stacked-models
Question: <p>I have some confusion about proper usage of cross-validation to</p> <ol> <li>tune hyperparameters and</li> <li>evaluate estimator performance and generalizeability.</li> </ol> <p>As I understand it, this would be the process you would follow:</p> <ol> <li>Split your full dataset into a training and test se...
https://datascience.stackexchange.com/questions/61620/hyperparameter-tuning-and-cross-validation
Question: <p>I'm trying to create a SVM classifier which can predict some fault, and to train it I'm using <strong>simulated examples</strong> of the fault. Of course, the simulations are not perfect, but they appear to be good enough since I get reasonable results when predicting on the real examples. </p> <p>What is...
https://datascience.stackexchange.com/questions/47608/hyperparameter-tuning-with-simulated-data
Question: <p>Despite doing/using it a few times, I'm still slightly confused by the use of a validation set for hyper parameter tuning.</p> <p>As far as I can tell, I choose a model, train it on training data, assess performance on training data, then do hyper parameter tuning assessing model performance on validation ...
https://datascience.stackexchange.com/questions/111372/why-does-hyperparameter-tuning-occur-on-validation-dataset-and-not-at-the-very-b
Question: <p>When looking to train a model, does it make sense to have a 60-20-20 train val test split, first hyper parameter tuning over the training dataset, using the validation set, picking the best model. Then training over train+val and the final test occurring on the test set?</p> Answer: <p>I would say that th...
https://datascience.stackexchange.com/questions/118574/train-val-test-approach-for-hyperparameter-tuning
Question: <p>I am performing a set of experiments in which I need to tune a fairly small set of hyperparameters but over a very large space of models trained on relatively related datasets and I'm trying to essentially limit the amount of trials I need to run in order to find <em>somewhat</em> optimal hyperparameter se...
https://datascience.stackexchange.com/questions/114064/hyperparameter-tuning-guidelines-across-lots-of-models
Question: <p>I know that we should use the validation set to perform hyperparameter tuning and that test dataset is not anymore really the test if it is used for hyperparameter tuning. But is this a problem if i want to compare the performance of 2 algorithms (e.g., Random Forest and XGBoost) across 10 different datase...
https://datascience.stackexchange.com/questions/123982/is-it-a-problem-to-use-the-test-dataset-for-the-hyperparameter-tuning-when-i-wa
Question: <p>I'm using LightGBM for the regression problem and here is my code.</p> <pre><code> def bayesion_opt_lgbm(X, y, init_iter = 5, n_iter = 10, random_seed = 32, seed= 100, num_iterations = 50, dtrain = lgb.Dataset(data = X_train, label = y_train)): def lgb_score(y_preds, dtr...
https://datascience.stackexchange.com/questions/89047/hyperparameter-tuning-with-bayesian-optimization
Question: <p>I first construct a base model (using default parameters) and obtain MAE.</p> <pre><code># BASELINE MODEL rfr_pipe.fit(train_x, train_y) base_rfr_pred = rfr_pipe.predict(test_x) base_rfr_mae = mean_absolute_error(test_y, base_rfr_pred) </code></pre> <p>MAE = 2.188</p> <p>Then I perform GridSearchCV to get ...
https://datascience.stackexchange.com/questions/97440/worse-performance-after-hyperparameter-tuning
Question: <p>I'm working with an imbalanced multi-class dataset. I try to tune the parameters of a <code>DecisionTreeClassifier</code>, <code>RandomForestClassifier</code> and a <code>GradientBoostingClassifier</code> using a randomized search and a bayesian search.</p> <p>For now, I used just <code>accuracy</code> fo...
https://datascience.stackexchange.com/questions/30876/hyperparameter-tuning-in-multiclass-classification-problem-which-scoring-metric
Question: <p>I'm building a Feedforward Neural Network with Pytorch and doing hyperparameters tuning using Ray Tune. I have train, validation and test set, train and validation used during the training procedure. I have different versions of the model (different learning rates and numbers of neurons in the hidden layer...
https://datascience.stackexchange.com/questions/85456/metric-to-use-to-choose-between-different-models-hyperparameters-tuning
Question: <p>I'm new to the machine learning field, and I'm learning ML models by practice, and I'm facing an issue while using the machine learning model.</p> <p>While I'm implementing the <code>RandomForestClassifier model</code> with hyper tunning it's taking too much time to predict output. And I'm also using <code...
https://datascience.stackexchange.com/questions/81961/hyperparameter-tuning-in-random-forest-model
Question: <p>Generaly when using Sklearn's GridSearchCV (or RandomizedGridSearchCV), we get best model with best test score even if the model overfits a little bit. How can we compute generalization error efficiently and force GridSearchCV to get best model with minimum generalization error?</p> Answer:
https://datascience.stackexchange.com/questions/60230/minimizing-overfitting-when-doing-hyperparameter-tuning
Question: <p>I am working on titanic dataset, I achieved 92% accuracy using random forest. However, the accuracy score dropped to 89% after I tuned it using <code>Gridsearch</code>. Now, I was wondering if it caused by imbalanced dataset, since it has only 342 out of 891 passenger survived the disaster. Would appreciat...
https://datascience.stackexchange.com/questions/73526/hyperparameter-tuning-does-not-improve-accuracy
Question: <p>I am working on a basic Neural network and want to show performance of model with respect to different parameters.<a href="https://i.sstatic.net/qvcKB.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/qvcKB.png" alt="Here is my dataframe looks like." /></a></p> <p>I need help with suggestions ...
https://datascience.stackexchange.com/questions/114645/how-to-optimally-visualise-hyperparameter-tuning
Question: <p>Hey guys i need your help for a university project. The main Task is to analyze the effects of over/under-smapling on a imbalanced Dataset. But before we can even start with that, our task sheet says, that we 1) have to find/create imbalanced Datasets and 2) fit those with a binary classification model lik...
https://datascience.stackexchange.com/questions/70116/cart-classification-for-imbalanced-datasets-with-r
Question: <p>I am dealing with an extremely imbalanced dataset, with about 10,000 negative samples for each positive sample. I am now trying to come up with an adequate measurement of model accuracy but none seem to fit. Many places recommend the PR curve over the AUC curve for imbalanced datasets (e.g. <a href="http...
https://datascience.stackexchange.com/questions/74014/model-assessment-for-extremely-imbalanced-dataset
Question: <p>For an imbalanced data set, is it better to choose an L1 or L2 regularization?</p> <p>Is there a cost function more suitable for imbalanced datasets to improve the model score (<code>log_loss</code> in particular)? </p> Answer: <p>So you ask <strong>how does class imbalance affect classifier performance ...
https://datascience.stackexchange.com/questions/3699/what-cost-function-and-penalty-are-suitable-for-imbalanced-datasets
Question: <p>I am new in machine learning and just learned about feature selection. In my project, I have a dataset with 89% being a majority class and 11% as the minority class. Also, I have 24 features. I opted to use Recursive Feature Elimination with Cross-Validation (RFECV in the scikit-learn package) to find the ...
https://datascience.stackexchange.com/questions/104897/rfecv-for-feature-selection-for-imbalanced-dataset
Question: <p>For the imbalanced datasets:</p> <ol> <li>Can we say the Precision-Recall curve is more informative, thus accurate, than ROC curve? </li> <li>Can we rely on F1-score to evaluate the skillfulness of the resulted model in this case?</li> </ol> Answer: <p>Precision-recall curves are argued to be more useful...
https://datascience.stackexchange.com/questions/73757/the-most-informative-curve-for-imbalance-datasets
Question: <p>I'm trying to understand what prior probability shift (label drift) in data means.</p> <p>If I understand it correctly then it means that distribution of labels in training dataset differs compared to distribution of labels in production environment. This difference causes that ML model trained on such dat...
https://datascience.stackexchange.com/questions/116527/prior-probability-shift-vs-oversampling-undersampling-imbalanced-datasets
Question: <p>I have an imbalanced dataset. I am looking to under-sample. Even though, the oversampling process takes less time, the model training takes a lot of time. I have taken a look at <a href="https://imbalanced-learn.readthedocs.io/en/stable/index.html" rel="nofollow noreferrer">imbalanced-learn</a> website. Th...
https://datascience.stackexchange.com/questions/49575/multi-class-imbalanced-datasets-under-sampling-imblearn
Question: <p>I can see everywhere that when the dataset is imbalanced PR-AUC is a better performance indicator than ROC. From my experience, if the positive class is the most important, and there is higher percentage of positive class than the negative class in the dataset, then PR-AUC seems to be very biased. Actually...
https://datascience.stackexchange.com/questions/131105/roc-vs-pr-score-and-imbalanced-datasets
Question: <p>I'm reading a lot about how to use different metrics specifically for imbalanced datasets (e.g. two classes present, but 80% of the data is one class) and how to tackle the issue of imbalanced datasets.</p> <p>One trick is to oversample, so to take more (or even duplicate some) data belonging to the underr...
https://datascience.stackexchange.com/questions/93730/doesnt-over-undersampling-an-imbalanced-dataset-cause-issues
Question: <p>I know about the problems that imbalanced dataset will cause when we are working on classification problems. And I know the solution for that including undersampling and oversampling.</p> <p>I have to work on a Ranking problem(Ranking hotels and evaluate based on NDCG50 score <a href="https://github.com/ac...
https://datascience.stackexchange.com/questions/85453/ranking-problem-and-imbalanced-dataset
Question: <p>Based on a previous <a href="https://datascience.stackexchange.com/questions/76056/for-imbalanced-classification-should-the-validation-dataset-be-balanced">post</a>, I understand the need to ensure that the validation folds during the CV process have the same imbalanced distribution as the original dataset...
https://datascience.stackexchange.com/questions/76107/cross-validation-schema-for-imbalanced-dataset
Question: <p>I have a imbalanced dataset with 3 output labels with one class with 98 percent and other two classes with 1 percent each. I need to run decision tree on this dataset. Should i be upsampling this dataset by duplicating rows? Would this effect the impurity, entropy or information gain for nodes?</p> Answe...
https://datascience.stackexchange.com/questions/71978/upsampling-imbalanced-dataset-in-decision-tree