id int64 1 141k | title stringlengths 15 150 | body stringlengths 45 28.5k | tags stringlengths 1 102 | label int64 1 1 | text stringlengths 128 28.6k | source stringclasses 1
value |
|---|---|---|---|---|---|---|
75,431 | Generate dataframe series from current series which is a list of objects | <p>I currently have a JSON object that looks like this</p>

<pre><code>{"submissionTime":"2019-02-25T09:26:00","b_data":{"bName":"Masato","b_Acc":[{"id":0,"transactions":[{"date":"2019-12-19","text":"PERIODICAL PAYMENT","amount":3397,"type":"","tags":[{"institution":"University of MC"},{"lenderType":"private"},... | python pandas dataframe | 1 | Generate dataframe series from current series which is a list of objects -- (python pandas dataframe)
<p>I currently have a JSON object that looks like this</p>

<pre><code>{"submissionTime":"2019-02-25T09:26:00","b_data":{"bName":"Masato","b_Acc":[{"id":0,"transactions":[{"date":"2019-12-19","text":"PERIODICAL... | habedi/stack-exchange-dataset |
75,439 | PCA vs.KernelPCA: which one to use for high dimensional data? | <p>I have a dataset which contains a lot of features (>>3). For computational reasons, I would like to apply a dimensionality reduction. At this point I could use different techniques:</p>

<p>standard PCA
Kernel PCA
LLE
...
My problem is to choose the right approach since the number of features... | feature selection pca dimensionality reduction kernel linearly separable | 1 | PCA vs.KernelPCA: which one to use for high dimensional data? -- (feature selection pca dimensionality reduction kernel linearly separable)
<p>I have a dataset which contains a lot of features (>>3). For computational reasons, I would like to apply a dimensionality reduction. At this point I could use different techniq... | habedi/stack-exchange-dataset |
75,446 | Using Random Forest Regression correctly | <p>I have run Random forest regression with python and I have the fear that I haven't done it correct.</p>

<p>I have original image that has 3 different bands (each pixels has 3 values) and I want to try to see if I can predict the first value using the two others.</p>

<p>For that I used Random Forest... | machine learning python scikit learn random forest | 1 | Using Random Forest Regression correctly -- (machine learning python scikit learn random forest)
<p>I have run Random forest regression with python and I have the fear that I haven't done it correct.</p>

<p>I have original image that has 3 different bands (each pixels has 3 values) and I want to try to see if ... | habedi/stack-exchange-dataset |
75,454 | Appropriate loss function for multi-hot output vectors | <p>I have some data in which model inputs and outputs (which are the same size) belong to multiple classes concurrently. A single input or output is a vector of zeros somewhere between one and four values that are equal to 1:</p>

<pre><code>[0 0 0 1 0 0 1 0 1 0 0]
</code></pre>

<p>These kinds of v... | neural network loss function multiclass classification optimization categorical data | 1 | Appropriate loss function for multi-hot output vectors -- (neural network loss function multiclass classification optimization categorical data)
<p>I have some data in which model inputs and outputs (which are the same size) belong to multiple classes concurrently. A single input or output is a vector of zeros somewher... | habedi/stack-exchange-dataset |
75,457 | How to add a new column with labels in a dataframe? | <p>I have thousands of sentences that I would need to label based on their sentiment. 
An example is</p>

<pre><code>Testo
"Può dirmi quale fotocamera della Sony fa delle belle foto?"
"Che macchina fantastica! Ha smesso di funzionare dopo due giorni"
"Quel pallavolista ha un fisico pauroso"
... | python pandas sentiment analysis nltk | 1 | How to add a new column with labels in a dataframe? -- (python pandas sentiment analysis nltk)
<p>I have thousands of sentences that I would need to label based on their sentiment. 
An example is</p>

<pre><code>Testo
"Può dirmi quale fotocamera della Sony fa delle belle foto?"
"Che macchina fantast... | habedi/stack-exchange-dataset |
75,466 | XGboost and regularization | <p>Does the <code>XGBClassifier</code> method utilizes the two regularization terms <code>reg_alpha</code> and <code>reg_lambda</code>, or are they redundant and only utilized in the regression method (i.e., <code>XGBRegressor</code>)?</p>

<p>I think that some hyperparameters in XGBoost could have no effect on... | xgboost hyperparameter tuning hyperparameter | 1 | XGboost and regularization -- (xgboost hyperparameter tuning hyperparameter)
<p>Does the <code>XGBClassifier</code> method utilizes the two regularization terms <code>reg_alpha</code> and <code>reg_lambda</code>, or are they redundant and only utilized in the regression method (i.e., <code>XGBRegressor</code>)?</p>
... | habedi/stack-exchange-dataset |
75,474 | Issue while predicting multiple values which possess different order of magnitude (regression) | <p>I have a system that take electric signal and output parameters (regression). However I run into an issue. The parameters I want to predict are not on the same magnitude. I would like also to use only one neural networks if possible.</p>

<pre><code>Parameter 1:
Mean = 12.53673
Minimum = 10.00461&... | keras regression | 1 | Issue while predicting multiple values which possess different order of magnitude (regression) -- (keras regression)
<p>I have a system that take electric signal and output parameters (regression). However I run into an issue. The parameters I want to predict are not on the same magnitude. I would like also to use only... | habedi/stack-exchange-dataset |
75,483 | Is this a valid stability concern/improvement for DQN/DDQN reinforcement training? | <p>As you all know, DQN or DDQN are known for "unstable training".</p>

<p>Let's use the well known "CartPole". The agent has to balance the stick and gets a reward of +1 per frame. You can reach the 195 threshold with Cartpole-v0, but results will vary a lot. You will have a hard time to get this working until... | reinforcement learning q learning dqn | 1 | Is this a valid stability concern/improvement for DQN/DDQN reinforcement training? -- (reinforcement learning q learning dqn)
<p>As you all know, DQN or DDQN are known for "unstable training".</p>

<p>Let's use the well known "CartPole". The agent has to balance the stick and gets a reward of +1 per frame. You ... | habedi/stack-exchange-dataset |
75,496 | What's the best graphic in R to study air pollution? | <p>I have a Python dataframe (in addition to an excel file) with data on air pollution for countries, (one line every day between 2014 and 2020). I would like to see what's the polluant the most related to industrial production, fort that I want to compare the data during quarantine and after.</p>

<p>These are... | python r | 1 | What's the best graphic in R to study air pollution? -- (python r)
<p>I have a Python dataframe (in addition to an excel file) with data on air pollution for countries, (one line every day between 2014 and 2020). I would like to see what's the polluant the most related to industrial production, fort that I want to comp... | habedi/stack-exchange-dataset |
75,544 | What is an object detection problem with only one class called? | <p>Object detection is defined as the problem in which a model needs to figure out the bounding boxes and the class for each object. A lot of ML solutions for object detection base around having "two passes" - one for creating the bounding box of the region and another for classifying it.</p>

<p>I was wonderin... | machine learning deep learning computer vision object detection theory | 1 | What is an object detection problem with only one class called? -- (machine learning deep learning computer vision object detection theory)
<p>Object detection is defined as the problem in which a model needs to figure out the bounding boxes and the class for each object. A lot of ML solutions for object detection base... | habedi/stack-exchange-dataset |
75,568 | Clusters: how to improve results for text classification | <p>I am trying to classify texts using kmeans, TfidfVectorizer, PCA. However, it seems that many texts are not correctly classified as you can see: I have texts in cluster2 that should be in Cluster 0 or 1. 
My question is on how to improve the results, if increasing the number of clusters or adding more constraint... | python clustering k means pca text classification | 1 | Clusters: how to improve results for text classification -- (python clustering k means pca text classification)
<p>I am trying to classify texts using kmeans, TfidfVectorizer, PCA. However, it seems that many texts are not correctly classified as you can see: I have texts in cluster2 that should be in Cluster 0 or 1. &... | habedi/stack-exchange-dataset |
75,587 | Interpreting Loss in neural network: Neural network train loss gradually tappers and validation loss never reaches a minima | <p><a href="https://i.stack.imgur.com/vbWG7.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/vbWG7.png" alt="Validation and train loss"></a></p>

<p>Unable to improve the network validation loss. Is it overfitting/underfitting. How can I get a better validation loss?.The code is below</p>
... | neural network keras tensorflow loss function | 1 | Interpreting Loss in neural network: Neural network train loss gradually tappers and validation loss never reaches a minima -- (neural network keras tensorflow loss function)
<p><a href="https://i.stack.imgur.com/vbWG7.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/vbWG7.png" alt="Validation and tra... | habedi/stack-exchange-dataset |
75,595 | CSVs: how to output missing data to make processing easier? | <p>If supplying data (that can be either string or numeric) via CSVs, what's a good strategy for marking that a value is missing?</p>

<ul>
<li>Some non-empty sentinel, like <code>NA</code></li>
<li>Some non-empty sentinel, but quoted like <code>"NA"</code></li>
<li>The empty string, e.g. in the CSV... | python pandas data cleaning csv excel | 1 | CSVs: how to output missing data to make processing easier? -- (python pandas data cleaning csv excel)
<p>If supplying data (that can be either string or numeric) via CSVs, what's a good strategy for marking that a value is missing?</p>

<ul>
<li>Some non-empty sentinel, like <code>NA</code></li>
<li>So... | habedi/stack-exchange-dataset |
75,609 | How to solve (or even effectively think about) a complex real-life multivariate problem | <p>In my work, we get estimates. </p>

<p>An estimate may include up to 12 different categories of costs (Development, Legal Travel, etc.) to produce any number of assets/deliverables from dozens of different deliverable categories (TV Spot, Radio, Podcast, Talent Session, etc.). Each estimate will come with ... | linear regression data analysis | 1 | How to solve (or even effectively think about) a complex real-life multivariate problem -- (linear regression data analysis)
<p>In my work, we get estimates. </p>

<p>An estimate may include up to 12 different categories of costs (Development, Legal Travel, etc.) to produce any number of assets/deliverables fr... | habedi/stack-exchange-dataset |
75,618 | How to work with Log-transformation? | <p>I'm beginning my data science journey and I've faced a challenge that confuses me a bit.
I have a set with few features and a target variable whose raw distribution is highly skewed. </p>

<p><a href="https://i.stack.imgur.com/BbyPd.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/BbyPd... | regression feature engineering feature scaling data analysis | 1 | How to work with Log-transformation? -- (regression feature engineering feature scaling data analysis)
<p>I'm beginning my data science journey and I've faced a challenge that confuses me a bit.
I have a set with few features and a target variable whose raw distribution is highly skewed. </p>

<p><a href="h... | habedi/stack-exchange-dataset |
75,631 | What is syntax V and S standing for nominal subject? | <p>I was reading the recent paper <a href="https://www.aclweb.org/anthology/P19-1580.pdf" rel="nofollow noreferrer">https://www.aclweb.org/anthology/P19-1580.pdf</a> and noticed that in section 5.2, the syntactic relation is studied in terms of the "direction between two tokens". In table 1, the result is further shown... | deep learning nlp bert | 1 | What is syntax V and S standing for nominal subject? -- (deep learning nlp bert)
<p>I was reading the recent paper <a href="https://www.aclweb.org/anthology/P19-1580.pdf" rel="nofollow noreferrer">https://www.aclweb.org/anthology/P19-1580.pdf</a> and noticed that in section 5.2, the syntactic relation is studied in ter... | habedi/stack-exchange-dataset |
75,635 | in NLP academic paper, would it be okay to refer the "token embeddings" as "tokens"? | <p>I am writing a paper in Natural Language Processing (NLP), and I just have a quick question about terminology.</p>

<p>In language models like Transformers, "token" refers to individual word in a text sequence, whereas there is a special term "token embedding" to refer to the embedding that results after tok... | nlp | 1 | in NLP academic paper, would it be okay to refer the "token embeddings" as "tokens"? -- (nlp)
<p>I am writing a paper in Natural Language Processing (NLP), and I just have a quick question about terminology.</p>

<p>In language models like Transformers, "token" refers to individual word in a text sequence, wher... | habedi/stack-exchange-dataset |
75,640 | CNN model contains several images that are null | <p>I'm using a deep CNN with the ReLU activation function. When visualizing the layers (each with 32 filters), several of the filtered images are zeros.</p>
<p>I am trying to reason why this may be happening? What would cause the entire image to be zero? I can understand having a sparse image (given the ReLU), but ... | cnn convolution convolutional neural network | 1 | CNN model contains several images that are null -- (cnn convolution convolutional neural network)
<p>I'm using a deep CNN with the ReLU activation function. When visualizing the layers (each with 32 filters), several of the filtered images are zeros.</p>
<p>I am trying to reason why this may be happening? What woul... | habedi/stack-exchange-dataset |
75,643 | Random Forest in R with only character variables | <p>I am new to using random forest in R an my goal is to identify the independent variables which have the highest impact on the dependent variables. I am looking at sales data, and sales is my dependent variable (1 vs. 0) I have other variables which have different levels such as professional status (retired, employed... | r dataset data random forest dummy variables | 1 | Random Forest in R with only character variables -- (r dataset data random forest dummy variables)
<p>I am new to using random forest in R an my goal is to identify the independent variables which have the highest impact on the dependent variables. I am looking at sales data, and sales is my dependent variable (1 vs. 0... | habedi/stack-exchange-dataset |
75,655 | What supervised machine learning model can be used to generate a scorecard-like result? | <p>A scorecard is typically used in Credit Application. One very common model for developing a credit scorecard is logistic regression since it has well-defined probabilities.</p>

<p>Apart from logistic regression, is there any model that can be used in the scorecard?</p>

<p>For example, I don't know ... | logistic regression svm model selection | 1 | What supervised machine learning model can be used to generate a scorecard-like result? -- (logistic regression svm model selection)
<p>A scorecard is typically used in Credit Application. One very common model for developing a credit scorecard is logistic regression since it has well-defined probabilities.</p>
&#x... | habedi/stack-exchange-dataset |
75,708 | neural network probability output and loss function (example: dice loss) | <p>A commonly loss function used for semantic segmentation is the dice loss function. (see the image below. It resume how I understand it)</p>

<p><a href="https://i.stack.imgur.com/OsH4y.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/OsH4y.png" alt="enter image description here"></a></p>&#x... | neural network image segmentation | 1 | neural network probability output and loss function (example: dice loss) -- (neural network image segmentation)
<p>A commonly loss function used for semantic segmentation is the dice loss function. (see the image below. It resume how I understand it)</p>

<p><a href="https://i.stack.imgur.com/OsH4y.png" rel="no... | habedi/stack-exchange-dataset |
75,715 | Find matches between columns and manipulate data based on match | <p>I have a pandas dataframe that contains two columns, components, and sub-components (first table below). I would like to add a product column as shown below (second table). The problem is, some (not all) components are actually sub-components (B is also contained in the sub-component column in this simplified examp... | python pandas | 1 | Find matches between columns and manipulate data based on match -- (python pandas)
<p>I have a pandas dataframe that contains two columns, components, and sub-components (first table below). I would like to add a product column as shown below (second table). The problem is, some (not all) components are actually sub-c... | habedi/stack-exchange-dataset |
75,726 | What is the difference between sklearn's transform() and predict() methods? | <p>What I have understood thus far is that transform() gives you values that are qualitatively similar to X (your features) and predict() gives you values that are qualitatively similar to y (your labels). But what I'm seeking some clarity over is why are there only a few classes that have BOTH of these methods, e.g KM... | machine learning python scikit learn | 1 | What is the difference between sklearn's transform() and predict() methods? -- (machine learning python scikit learn)
<p>What I have understood thus far is that transform() gives you values that are qualitatively similar to X (your features) and predict() gives you values that are qualitatively similar to y (your label... | habedi/stack-exchange-dataset |
75,730 | Can bidirectional RNN use variable sequence length? | <p>A bidirectional RNN consists of two RNNs, one for the forward and another for the backward sequential directions, which outcome is concatenated at each time step. Would this configuration restrict the model to always use a fixed sequence length? Or would it still work as the unidirectional RNN, which can be applied ... | neural network rnn sequence | 1 | Can bidirectional RNN use variable sequence length? -- (neural network rnn sequence)
<p>A bidirectional RNN consists of two RNNs, one for the forward and another for the backward sequential directions, which outcome is concatenated at each time step. Would this configuration restrict the model to always use a fixed seq... | habedi/stack-exchange-dataset |
75,731 | Use serialized model without installing dependencies | <p>I prototyped an ML model consisting of preprocessing + multiple stacked regressors. I would like a colleague of mine to develop an API that will query the model. Is there any way to query the model (sklearn pipeline) without having to download all the dependencies (XGBoost, LGBM, CatBoost, ...).</p>

<p>I tr... | scikit learn machine learning model serialisation | 1 | Use serialized model without installing dependencies -- (scikit learn machine learning model serialisation)
<p>I prototyped an ML model consisting of preprocessing + multiple stacked regressors. I would like a colleague of mine to develop an API that will query the model. Is there any way to query the model (sklearn pi... | habedi/stack-exchange-dataset |
75,733 | PCA for complex-valued data | <p>I'm quite shocked for encountering this error on <code>PCA</code> from <code>sklearn</code></p>

<blockquote>
 <p>ValueError: Complex data not supported</p>
</blockquote>

<p>After trying to fit complex-valued data. Is this just unimplemented thing? Should I just go ahead and do it 'manually... | machine learning scikit learn feature selection pca dimensionality reduction | 1 | PCA for complex-valued data -- (machine learning scikit learn feature selection pca dimensionality reduction)
<p>I'm quite shocked for encountering this error on <code>PCA</code> from <code>sklearn</code></p>

<blockquote>
 <p>ValueError: Complex data not supported</p>
</blockquote>

<p>After t... | habedi/stack-exchange-dataset |
75,737 | how to read emotion label of MSP-IMPROV dataset samples? | <p>I need to read MSP-IMPROV dataset audio file's to conduct research. I read the help file that says 15th character of the file name, shows the emotion label of each utterance.
For example:
MSP-IMPROV-S01<strong>A</strong>-M01-P-FM01 intended <strong>Angry</strong> emotion.</p>
<p>But when I run the code ... | python deep learning matlab | 1 | how to read emotion label of MSP-IMPROV dataset samples? -- (python deep learning matlab)
<p>I need to read MSP-IMPROV dataset audio file's to conduct research. I read the help file that says 15th character of the file name, shows the emotion label of each utterance.
For example:
MSP-IMPROV-S01<strong>A</strong... | habedi/stack-exchange-dataset |
75,749 | ValueError: X has 3 features per sample; expecting 1500 | <pre class="lang-py prettyprint-override"><code>import numpy as np
from flask import Flask, request, jsonify, render_template
import pickle
from sklearn.feature_extraction.text import TfidfVectorizer
from sklearn.feature_extraction.text import TfidfTransformer
from sklearn.linear_model import Logist... | machine learning scikit learn python 3.x | 1 | ValueError: X has 3 features per sample; expecting 1500 -- (machine learning scikit learn python 3.x)
<pre class="lang-py prettyprint-override"><code>import numpy as np
from flask import Flask, request, jsonify, render_template
import pickle
from sklearn.feature_extraction.text import TfidfVectorizer
fr... | habedi/stack-exchange-dataset |
75,757 | Finding a range of values for each feature that contribute to positive classification | <p>Consider a classification problem(lets say 2 classes, 'good' and 'bad), where all features are continuous. </p>

<p>what I need is a range of values for each feature that contributes to 'good' classification.
What I thought was simply partitioning the feature values based on good or bad label, problem is... | machine learning classification regression feature extraction | 1 | Finding a range of values for each feature that contribute to positive classification -- (machine learning classification regression feature extraction)
<p>Consider a classification problem(lets say 2 classes, 'good' and 'bad), where all features are continuous. </p>

<p>what I need is a range of values for eac... | habedi/stack-exchange-dataset |
75,758 | Implement the following loss function without interrupting the gradient chain registered by the gradient tape | <p>I have spent five days trying to implement the following algorithm as a loss function to use it in my neural network, but it has been impossible for me. Impossible because, when I have finally implemented, I get the error:</p>

<blockquote>
 <p>No gradients provided for any variable: ['conv1_1/kernel:0'... | machine learning deep learning cnn computer vision loss function | 1 | Implement the following loss function without interrupting the gradient chain registered by the gradient tape -- (machine learning deep learning cnn computer vision loss function)
<p>I have spent five days trying to implement the following algorithm as a loss function to use it in my neural network, but it has been imp... | habedi/stack-exchange-dataset |
75,789 | Why is 10 considered the default value for k-fold cross-validation? | <p>I understand very well what k-fold cross-validation is. In my studies, and at work, I've always heard something along the lines of:</p>

<blockquote>
 <p>We most often use <code>k=10</code> because evidence shows it's the best value for <code>k</code>. Smaller values don't give as good estimates, and la... | machine learning statistics cross validation | 1 | Why is 10 considered the default value for k-fold cross-validation? -- (machine learning statistics cross validation)
<p>I understand very well what k-fold cross-validation is. In my studies, and at work, I've always heard something along the lines of:</p>

<blockquote>
 <p>We most often use <code>k=10</co... | habedi/stack-exchange-dataset |
75,814 | Daily new data for my neural network, and I want transfer(?) learning | <p>I made my neural network, it is <code>pre-trained for 180 days of data.</code></p>

<pre><code>It filters the fraud data of credit cards everyday and 1-days new data is comming in.
</code></pre>

<p>And I also want after the filtering, </p>

<blockquote>
 <p>I want to re-train my AI-... | neural network transfer learning early stopping | 1 | Daily new data for my neural network, and I want transfer(?) learning -- (neural network transfer learning early stopping)
<p>I made my neural network, it is <code>pre-trained for 180 days of data.</code></p>

<pre><code>It filters the fraud data of credit cards everyday and 1-days new data is comming in.
<... | habedi/stack-exchange-dataset |
75,819 | Using random forest when not all the observations have data | <p>I have this given database:</p>

<p><a href="https://i.stack.imgur.com/3WZ4V.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/3WZ4V.png" alt="enter image description here"></a></p>

<p>I would like to predict column "y" using the columns "index_1","index_2","index_3" using the rando... | random forest | 1 | Using random forest when not all the observations have data -- (random forest)
<p>I have this given database:</p>

<p><a href="https://i.stack.imgur.com/3WZ4V.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/3WZ4V.png" alt="enter image description here"></a></p>

<p>I would like to pre... | habedi/stack-exchange-dataset |
75,822 | Differerent ways to detect the appropriate number of topics | <p>I implemet the LDA topic modeling in R.</p>

<p>One essential parameter is the selection of the number of topics</p>

<p>Which of the following ways could it be the most suitable:</p>

<pre><code>1. mallet
2. stm
3. or this way https://cran.r-project.org/web/packages/ldatuning/vignett... | machine learning r topic model | 1 | Differerent ways to detect the appropriate number of topics -- (machine learning r topic model)
<p>I implemet the LDA topic modeling in R.</p>

<p>One essential parameter is the selection of the number of topics</p>

<p>Which of the following ways could it be the most suitable:</p>

<pre><code>1... | habedi/stack-exchange-dataset |
75,824 | Naive Bayes vs Full Bayes model classifiers | <p>I have a hard time to understand when Naive Bayes works better than Full Bayes.<br/>
In general, i know that naive bayes does the assumption that features are independent given the class.<br/> However, if features indeed independent, does it mean that assuming that they are dependent yield worst result?<br/></p>... | naive bayes classifier distribution classifier | 1 | Naive Bayes vs Full Bayes model classifiers -- (naive bayes classifier distribution classifier)
<p>I have a hard time to understand when Naive Bayes works better than Full Bayes.<br/>
In general, i know that naive bayes does the assumption that features are independent given the class.<br/> However, if features ind... | habedi/stack-exchange-dataset |
75,835 | Zero-inflated independent feature in tree-based models | <p>What is the best approach to include a zero-inflated continuous independent feature (e.g., 90% of the values are Zero, 10% are >0) in a Tree-based models (DT, random forest, gradient boosting. etc). I am considering the following three options:</p>
<ul>
<li><p>Option 1: Keep the zero-inflated continues fe... | random forest decision trees xgboost correlation | 1 | Zero-inflated independent feature in tree-based models -- (random forest decision trees xgboost correlation)
<p>What is the best approach to include a zero-inflated continuous independent feature (e.g., 90% of the values are Zero, 10% are >0) in a Tree-based models (DT, random forest, gradient boosting. etc). I am c... | habedi/stack-exchange-dataset |
75,855 | What types of matrix multiplication are used in Machine Learning? When are they used? | <p>I'm looking at equations for neural networks and backpropagation and I see this symbol in the equations, ⊙. I thought matrix multiplication of neural networks always involved matrices that matched dimensions on both sides, such as... [3, 3]@[3, 2]. (This is what is happening in the animated gif).</p>

<p>Wha... | matrix matrix factorisation notation | 1 | What types of matrix multiplication are used in Machine Learning? When are they used? -- (matrix matrix factorisation notation)
<p>I'm looking at equations for neural networks and backpropagation and I see this symbol in the equations, ⊙. I thought matrix multiplication of neural networks always involved matrices that ... | habedi/stack-exchange-dataset |
75,867 | How to identify similar words as input from a dictionary | <p>Let's say I have a CSV file (single column) with a list of words as input. Meaning the file looks like below</p>

<p><strong>Input Terms</strong></p>

<pre><code>Subaaaash 
Paruuru 
Mettromin 
Paracetamol ... | machine learning neural network deep learning text mining nlp | 1 | How to identify similar words as input from a dictionary -- (machine learning neural network deep learning text mining nlp)
<p>Let's say I have a CSV file (single column) with a list of words as input. Meaning the file looks like below</p>

<p><strong>Input Terms</strong></p>

<pre><code>Subaaaash ... | habedi/stack-exchange-dataset |
75,869 | Classification model to classify large number of classifiers? | <p>Hello I am very new into the field of machine learning/deep learning , and I am finding it hard to select the right model for my research.</p>

<p>What I am trying to build is a model to classify which subway route a user have used based on travel time and transfer time given the origin station and destinat... | machine learning classification r multilabel classification | 1 | Classification model to classify large number of classifiers? -- (machine learning classification r multilabel classification)
<p>Hello I am very new into the field of machine learning/deep learning , and I am finding it hard to select the right model for my research.</p>

<p>What I am trying to build is a mod... | habedi/stack-exchange-dataset |
75,871 | Alternative means of clustering streams of incoming facial recognition data | <p>I have a time-series dataset of incoming face data. Each data point is a facial-feature-vector of length 256 that represents the facial features of a person (it is generated by a modified RESNET). Features that are close together are deemed to belong to the same person.</p>

<p>I am (successfully) clustering... | python clustering | 1 | Alternative means of clustering streams of incoming facial recognition data -- (python clustering)
<p>I have a time-series dataset of incoming face data. Each data point is a facial-feature-vector of length 256 that represents the facial features of a person (it is generated by a modified RESNET). Features that are clo... | habedi/stack-exchange-dataset |
75,894 | How to divide a dataset for training and testing when the features and targets are in two different files? | <p>I am trying to divide a dataset into training dataset and testing dataset for multi-label classification. The datset I am working on is this <a href="https://www.kaggle.com/stackoverflow/stacklite" rel="nofollow noreferrer">one</a>. It is divided into a file which contains the features and another file which contain... | multilabel classification kaggle | 1 | How to divide a dataset for training and testing when the features and targets are in two different files? -- (multilabel classification kaggle)
<p>I am trying to divide a dataset into training dataset and testing dataset for multi-label classification. The datset I am working on is this <a href="https://www.kaggle.com... | habedi/stack-exchange-dataset |
75,906 | Tensorflow / Keras Python CNN | <p>I'm doing a project where a Python script used a convolutional neural network to determine if a plant is healthy, and then water it based on that. While training the CNN, it seems to get up to 100% accuracy quite early, although it isn't accurate. I only have a little less than 2000 images, and was wondering if I di... | python keras tensorflow cnn | 1 | Tensorflow / Keras Python CNN -- (python keras tensorflow cnn)
<p>I'm doing a project where a Python script used a convolutional neural network to determine if a plant is healthy, and then water it based on that. While training the CNN, it seems to get up to 100% accuracy quite early, although it isn't accurate. I only... | habedi/stack-exchange-dataset |
75,924 | How are the gradients of a Neural Network calculated just by matrix multiplication? | <p>I would have expected some kind of derivative solving equation to be at work in order to back propagate the loss to each neuron. I hope my question is not too confused to answer.<br>
In the network below, why does h_relu.T @ grad_y_pred (y hat - y) produce the gradient for w2? I understand sometimes the derivati... | neural network pytorch backpropagation | 1 | How are the gradients of a Neural Network calculated just by matrix multiplication? -- (neural network pytorch backpropagation)
<p>I would have expected some kind of derivative solving equation to be at work in order to back propagate the loss to each neuron. I hope my question is not too confused to answer.<br>
In... | habedi/stack-exchange-dataset |
75,940 | looking for public dataset for stock market | <p>I want to do some modelling and data visualization on historical stock data, including price, volume, financials, etc. Is there an public dataset available for stock price history? I looked at a few, but either they have a high cost, or not sure they would be reliable. Free would be preferred, also established and r... | machine learning dataset visualization web scraping | 1 | looking for public dataset for stock market -- (machine learning dataset visualization web scraping)
<p>I want to do some modelling and data visualization on historical stock data, including price, volume, financials, etc. Is there an public dataset available for stock price history? I looked at a few, but either they ... | habedi/stack-exchange-dataset |
75,947 | a data point - too little to spend resources during data preparation? | <p>I am learning analytics online and have some quick questions.</p>

<p>Usually when we do analysis, why is that we usually ignore the items/data points that are less frequent?</p>

<p>Let's say for ex: we have is drug frequency data and no of patients who consumed that drug in a hospital. As an exampl... | machine learning neural network deep learning data mining statistics | 1 | a data point - too little to spend resources during data preparation? -- (machine learning neural network deep learning data mining statistics)
<p>I am learning analytics online and have some quick questions.</p>

<p>Usually when we do analysis, why is that we usually ignore the items/data points that are less ... | habedi/stack-exchange-dataset |
75,948 | How to setup and run Conda on Google Colab | <p>I am interested in using Google Colab for data modeling. How do I install conda, create an environment and run python in a notebook? I did some searching and found some helpful hints, but had several issues with this. I can only get a partially functional environment so far. 
I get stuck in running another cell ... | python jupyter anaconda google cloud | 1 | How to setup and run Conda on Google Colab -- (python jupyter anaconda google cloud)
<p>I am interested in using Google Colab for data modeling. How do I install conda, create an environment and run python in a notebook? I did some searching and found some helpful hints, but had several issues with this. I can only get... | habedi/stack-exchange-dataset |
75,949 | Multivariate, Multi-step LSTM time series forecast | <p>I'm trying to predict the Pollution using a Multivariate and Multi-step LSTM code, I've been following this <a href="https://machinelearningmastery.com/multivariate-time-series-forecasting-lstms-keras/" rel="nofollow noreferrer">tutorial</a>. </p>

<p>I've been following the code until the end, but couldn't ... | machine learning python deep learning prediction forecasting | 1 | Multivariate, Multi-step LSTM time series forecast -- (machine learning python deep learning prediction forecasting)
<p>I'm trying to predict the Pollution using a Multivariate and Multi-step LSTM code, I've been following this <a href="https://machinelearningmastery.com/multivariate-time-series-forecasting-lstms-keras... | habedi/stack-exchange-dataset |
75,954 | Are there machine learning methods that can give captions to the New Yorker magazine cartoons? | <p>Are there machine learning methods that can give captions to the New Yorker magazine cartoons?</p>
 | machine learning | 1 | Are there machine learning methods that can give captions to the New Yorker magazine cartoons? -- (machine learning)
<p>Are there machine learning methods that can give captions to the New Yorker magazine cartoons?</p>
 | habedi/stack-exchange-dataset |
75,999 | Keeping DataFrame in Memory while working - R vs Python in VS Code | <p>I am considering migrating from R-Studio to Python. So I am just starting Python with VS Code as my editor. My purpose is mainly to analyze data, build predictive models and make such models available via a web API.</p>

<p>When working in R-studio with a large data set, I can run a script to read in the dat... | python rstudio | 1 | Keeping DataFrame in Memory while working - R vs Python in VS Code -- (python rstudio)
<p>I am considering migrating from R-Studio to Python. So I am just starting Python with VS Code as my editor. My purpose is mainly to analyze data, build predictive models and make such models available via a web API.</p>

<... | habedi/stack-exchange-dataset |
76,006 | Why don't different output weights break symmetry? | <p>My deep learning lecturer told us that if a hidden node has identical input weights to another, then the weights will remain the same over the training/there will be no separation. This is confusing to me, because my expectation was that you should only need the input or output weights to be different. Even if the i... | weight initialization | 1 | Why don't different output weights break symmetry? -- (weight initialization)
<p>My deep learning lecturer told us that if a hidden node has identical input weights to another, then the weights will remain the same over the training/there will be no separation. This is confusing to me, because my expectation was that y... | habedi/stack-exchange-dataset |
76,022 | What does the descision boundary of a relu look like? | <p>A single non activated neuron is just a linear combination of its inputs.</p>

<p>Thresholding this neuron's output as-is against 0 would create a hyperplane binary separator, whose parameters can be learned.</p>

<p>What would be the shape of this separator (decision boundary) in case we also take a... | neural network visualization activation function | 1 | What does the descision boundary of a relu look like? -- (neural network visualization activation function)
<p>A single non activated neuron is just a linear combination of its inputs.</p>

<p>Thresholding this neuron's output as-is against 0 would create a hyperplane binary separator, whose parameters can be l... | habedi/stack-exchange-dataset |
76,023 | Precision and recall clarification | <p>I'm reading the book Fundamentals of Machine Learning for Predictive Data Analytics by Kelleher, et al. I've come across something that I think as an error but I want to check to be sure. When explaining precision and recall the authors write:</p>

<blockquote>
 <p>Email classification is a good applica... | books | 1 | Precision and recall clarification -- (books)
<p>I'm reading the book Fundamentals of Machine Learning for Predictive Data Analytics by Kelleher, et al. I've come across something that I think as an error but I want to check to be sure. When explaining precision and recall the authors write:</p>

<blockquote>&#... | habedi/stack-exchange-dataset |
76,045 | Prediction Outputs from LSTM NN | <p>I'm working with an LSTM network to predict the surface roughness due to biogrowth on ships. I've got a Network that fits the input data I have relatively well, the problem is when I'm using it to predict future roughness values.
I've 3 case scenarios - one where the hull is not cleaned, second where the hull is... | predictive modeling lstm | 1 | Prediction Outputs from LSTM NN -- (predictive modeling lstm)
<p>I'm working with an LSTM network to predict the surface roughness due to biogrowth on ships. I've got a Network that fits the input data I have relatively well, the problem is when I'm using it to predict future roughness values.
I've 3 case scenarios... | habedi/stack-exchange-dataset |
76,052 | Unusually High BLEU score on a NMT model | <p>This is the project on Neural Machine Translation on the English/Irish language pair. I have been spending the past month or so trying to train a good baseline to do 'experimentation' on. I have a corpus of ~850k sentences (unfortunately Irish is very limiting). When I trained it and evaluated it with BLEU, I got a ... | nlp machine translation | 1 | Unusually High BLEU score on a NMT model -- (nlp machine translation)
<p>This is the project on Neural Machine Translation on the English/Irish language pair. I have been spending the past month or so trying to train a good baseline to do 'experimentation' on. I have a corpus of ~850k sentences (unfortunately Irish is ... | habedi/stack-exchange-dataset |
76,053 | What is the use of the np.ndarray() function and how is it used? | <p>I just started Data Science and I want to know what the <code>np.ndarray()</code> function's use is, and in which scenario(s) it is used in. Thanks for the help.</p>
 | numpy | 1 | What is the use of the np.ndarray() function and how is it used? -- (numpy)
<p>I just started Data Science and I want to know what the <code>np.ndarray()</code> function's use is, and in which scenario(s) it is used in. Thanks for the help.</p>
 | habedi/stack-exchange-dataset |
76,056 | For imbalanced classification, should the validation dataset be balanced? | <p>I am building a binary classification model for imbalanced data (e.g., 90% Pos class vs 10% Neg Class).</p>

<p>I already balanced my training dataset to reflect a a 50/50 class split, while my holdout (training dataset) was kept similar to the original data distribution (i.e., 90% vs 10%). 
My question ... | classification class imbalance imbalanced learn | 1 | For imbalanced classification, should the validation dataset be balanced? -- (classification class imbalance imbalanced learn)
<p>I am building a binary classification model for imbalanced data (e.g., 90% Pos class vs 10% Neg Class).</p>

<p>I already balanced my training dataset to reflect a a 50/50 class spli... | habedi/stack-exchange-dataset |
76,060 | Clustering with k-means for text classification based on similarity | <p>I have a column that contains all texts that I would like to cluster in order to find some patterns/similarity among each other. </p>

<pre><code>Text
Word2vec is a two-layer neural net that processes text by “vectorizing” words. 

Its input is a text corpus and its output is a set of vectors: fe... | machine learning python scikit learn clustering k means | 1 | Clustering with k-means for text classification based on similarity -- (machine learning python scikit learn clustering k means)
<p>I have a column that contains all texts that I would like to cluster in order to find some patterns/similarity among each other. </p>

<pre><code>Text
Word2vec is a two-layer n... | habedi/stack-exchange-dataset |
76,086 | Is epsilon error a standard known error or custom created by this paper? | <p>I'm reading this computer vision paper, <a href="https://data.vision.ee.ethz.ch/cvl/publications/papers/proceedings/eth_biwi_01229.pdf" rel="nofollow noreferrer">research paper link</a>, about creating a model to estimate the real age and perceived age of the person in the image (or at least that's what I think it's... | deep learning computer vision evaluation | 1 | Is epsilon error a standard known error or custom created by this paper? -- (deep learning computer vision evaluation)
<p>I'm reading this computer vision paper, <a href="https://data.vision.ee.ethz.ch/cvl/publications/papers/proceedings/eth_biwi_01229.pdf" rel="nofollow noreferrer">research paper link</a>, about creat... | habedi/stack-exchange-dataset |
76,099 | how to classify text based on more than one column | <p>I passages of text to classify by topic. I am using scikit learn, e.g. linear svc, but open to other options. Currently, use only the text of each passage (column labeled <code>"En"</code> below). But I feel that using the title of each passage (column labeled <code>"Ref"</code> below) would help... | classification multilabel classification text | 1 | how to classify text based on more than one column -- (classification multilabel classification text)
<p>I passages of text to classify by topic. I am using scikit learn, e.g. linear svc, but open to other options. Currently, use only the text of each passage (column labeled <code>"En"</code> below). But I fe... | habedi/stack-exchange-dataset |
76,109 | Multivariate Linear Regression with exponential trend-line | <p>The dataset that I'm working with has 2 independent variables (qty, volume) and 1 dependent variable (cost). When I plot individual X with Y, it turns out <strong>qty vs cost</strong> gives an exponential decay trend line while <strong>volume vs cost</strong> gives a linear relationship.</p>
<p>I'm trying to co... | machine learning linear regression | 1 | Multivariate Linear Regression with exponential trend-line -- (machine learning linear regression)
<p>The dataset that I'm working with has 2 independent variables (qty, volume) and 1 dependent variable (cost). When I plot individual X with Y, it turns out <strong>qty vs cost</strong> gives an exponential decay trend ... | habedi/stack-exchange-dataset |
76,114 | How to understand the performance of different machine learning models? | <p>I have a dataset, which contains the processing conditions (i.e., 42 features) and the property (i.e., 1 target) of a class of material. To know the performance of different machine learning models, I tested five different machine learning models by considering different numbers of features in training. These models... | machine learning machine learning model | 1 | How to understand the performance of different machine learning models? -- (machine learning machine learning model)
<p>I have a dataset, which contains the processing conditions (i.e., 42 features) and the property (i.e., 1 target) of a class of material. To know the performance of different machine learning models, I... | habedi/stack-exchange-dataset |
76,118 | What is the distribution of the goal feature in this dataset | <p><a href="https://www.kaggle.com/kemical/kickstarter-projects" rel="nofollow noreferrer">https://www.kaggle.com/kemical/kickstarter-projects</a></p>
<p>I was checking the distribution of the "goal" feature in this 2016 KickStarter data set. I figure goal would be more normally distributed but it wasn't.... | machine learning python pandas distribution | 1 | What is the distribution of the goal feature in this dataset -- (machine learning python pandas distribution)
<p><a href="https://www.kaggle.com/kemical/kickstarter-projects" rel="nofollow noreferrer">https://www.kaggle.com/kemical/kickstarter-projects</a></p>
<p>I was checking the distribution of the "goal&qu... | habedi/stack-exchange-dataset |
76,128 | When should mutual information be used for feature selection over other feature selection methods like correlation, ANOVA , etc? | <p>I have a data set with categorical and continuous/ordinal explanatory variables and continuous target variable. I tried to filter features using one-way ANOVA for categorical variables and using Spearman's correlation coefficient for continuous/ordinal variables.I am using p-value to filter. I then also used mutual ... | machine learning feature selection mutual information anova spearmans rank correlation | 1 | When should mutual information be used for feature selection over other feature selection methods like correlation, ANOVA , etc? -- (machine learning feature selection mutual information anova spearmans rank correlation)
<p>I have a data set with categorical and continuous/ordinal explanatory variables and continuous t... | habedi/stack-exchange-dataset |
76,138 | Should the baseline comparison be done on the training or the test set results? | <p>I have a classification problem where I want to find out whether feature engineering has improved my final model. Cross-validation is used evaluate the impact of the feature engineering steps, so there is no validation set (only train/test). In short, my situation entails the following:</p>
<ul>
<li>Collect ... | machine learning classification | 1 | Should the baseline comparison be done on the training or the test set results? -- (machine learning classification)
<p>I have a classification problem where I want to find out whether feature engineering has improved my final model. Cross-validation is used evaluate the impact of the feature engineering steps, so ther... | habedi/stack-exchange-dataset |
76,139 | Need for Dense layer in Text Classifcation | <p>While creating a model for text classification, what is the need for a Dense Layer? I noticed in multiple examples the following is the structure. A softmax is what required right instead of the Dense Layer?</p>
<pre><code>model = tf.keras.Sequential([
 tf.keras.layers.Embedding(encoder.vocab_size, 64),&#... | deep learning keras tensorflow text text classification | 1 | Need for Dense layer in Text Classifcation -- (deep learning keras tensorflow text text classification)
<p>While creating a model for text classification, what is the need for a Dense Layer? I noticed in multiple examples the following is the structure. A softmax is what required right instead of the Dense Layer?</p>&#... | habedi/stack-exchange-dataset |
76,149 | ExtraTreesRegressor criterion | <p>As I understand, <code>ExtraTreesRegressor</code> from <code>sklearn</code> works by doing random splits instead of minimizing a metric like gini for classification or mae for regression.</p>
<p>I don't understand why there's a <code>criterion</code> parameter, as the criterion for the splits should be random.</... | python scikit learn random forest | 1 | ExtraTreesRegressor criterion -- (python scikit learn random forest)
<p>As I understand, <code>ExtraTreesRegressor</code> from <code>sklearn</code> works by doing random splits instead of minimizing a metric like gini for classification or mae for regression.</p>
<p>I don't understand why there's a <code>criterion<... | habedi/stack-exchange-dataset |
76,164 | How Calculate Effect (percentage) label of the input variables on the output variable by DecisionTreeClassifier | <p>a description problem below.
I have 10 words like X1 , X2 , X3 , ... , X10
<br />
and three Label like short , long , hold.
<br />
My problem is that how calculate Effect (percentage) label of the input variables <br />
by DecisionTreeClassifier Algorithm.</p>
<pre><code>DT=DecisionTreeCl... | machine learning python decision trees python 3.x features | 1 | How Calculate Effect (percentage) label of the input variables on the output variable by DecisionTreeClassifier -- (machine learning python decision trees python 3.x features)
<p>a description problem below.
I have 10 words like X1 , X2 , X3 , ... , X10
<br />
and three Label like short , long , hold.
<... | habedi/stack-exchange-dataset |
76,167 | How to get back stationary data from non stationary data after performing diff operations in var (time series)? | <p>I have applied var model on multiple features ,but var model accepts the stationary data so i have converted non-stationary data to stationary data by doing diff() ,given the data to var model.
what my question is ,is their option get back data normal data from stationary to non-stationary in time series?</p>&... | python time series pandas | 1 | How to get back stationary data from non stationary data after performing diff operations in var (time series)? -- (python time series pandas)
<p>I have applied var model on multiple features ,but var model accepts the stationary data so i have converted non-stationary data to stationary data by doing diff() ,given the... | habedi/stack-exchange-dataset |
76,170 | Is there any problem with dropping only part of the OneHot generated features? | <p>The one hot encoder adds more columns to the data, one for each category in the encoded feature. In the example below, the column <code>City</code> was transformed into 4 other columns.
Suppose a Decision Tree is ran on a dataset the below is part of and <code>City_Chicago</code> and <code>City_New_York</code> a... | feature selection feature engineering feature extraction one hot encoding | 1 | Is there any problem with dropping only part of the OneHot generated features? -- (feature selection feature engineering feature extraction one hot encoding)
<p>The one hot encoder adds more columns to the data, one for each category in the encoded feature. In the example below, the column <code>City</code> was transfo... | habedi/stack-exchange-dataset |
76,179 | Machine learning goal: given a population of 100,000 students, predict a group of 3,000, and minimize the median grade of that group | <p>In other words, I am looking to predict students that will fail out of school before it happens. The data includes socioeconomic status and other related variables.</p>
<p>I have tried an XGB binary classification (both tree and forest), but the problem is that it doesn't penalize severely wrong answers (predict... | python classification regression reinforcement learning xgboost | 1 | Machine learning goal: given a population of 100,000 students, predict a group of 3,000, and minimize the median grade of that group -- (python classification regression reinforcement learning xgboost)
<p>In other words, I am looking to predict students that will fail out of school before it happens. The data includes ... | habedi/stack-exchange-dataset |
76,191 | XGB custom objective function - small change to default regression squared error objective function | <p>Where can I find the code for the default squared error objective function? I just want to make a small change to re-weight certain datapoints?</p>
 | xgboost objective function | 1 | XGB custom objective function - small change to default regression squared error objective function -- (xgboost objective function)
<p>Where can I find the code for the default squared error objective function? I just want to make a small change to re-weight certain datapoints?</p>
 | habedi/stack-exchange-dataset |
76,192 | Understanding Loss function and Learning Algorithm | <p>In Keras, when specifying a loss such as Mean absolute error, does it replace the cost function in the learning algorithm (Adam or SGD) with the mean absolute error? I'm new to ML and a bit confused on this aspect.</p>
 | keras loss function | 1 | Understanding Loss function and Learning Algorithm -- (keras loss function)
<p>In Keras, when specifying a loss such as Mean absolute error, does it replace the cost function in the learning algorithm (Adam or SGD) with the mean absolute error? I'm new to ML and a bit confused on this aspect.</p>
 | habedi/stack-exchange-dataset |
76,224 | How Calculate Effect (percentage) label of the input variables on the output variable by BernoulliNB | <p>a description problem below. I have 10 words like X1 , X2 , X3 , ... , X10 <br />
and three Label like short , long , hold.<br />
My problem is that how calculate Effect (percentage) label of the input variables<br />
by BernoulliNB Algorithm.<br /></p>
<pre><code>NB = BernoulliNB()
NB.fit(X_trai... | machine learning python naive bayes classifier python 3.x | 1 | How Calculate Effect (percentage) label of the input variables on the output variable by BernoulliNB -- (machine learning python naive bayes classifier python 3.x)
<p>a description problem below. I have 10 words like X1 , X2 , X3 , ... , X10 <br />
and three Label like short , long , hold.<br />
My problem is t... | habedi/stack-exchange-dataset |
76,230 | XG Boost result interpretation for unbalanced datasets (Accuracy & AUCROC) | <p>My dataset is of shape – <code>5621*8</code> (binary classification)</p>
<ul>
<li><p>Label/target : Success (4324, 77 %) & Not success (1297, 23 %)</p>
<p>(success and Not success were been equally important for my prediction i.e, TP & TN)</p>
</li>
</ul>
<p>I split my data into 3 (Tr... | xgboost accuracy class imbalance auc | 1 | XG Boost result interpretation for unbalanced datasets (Accuracy & AUCROC) -- (xgboost accuracy class imbalance auc)
<p>My dataset is of shape – <code>5621*8</code> (binary classification)</p>
<ul>
<li><p>Label/target : Success (4324, 77 %) & Not success (1297, 23 %)</p>
<p>(success and Not success were... | habedi/stack-exchange-dataset |
76,243 | What happens if at leaf node both classes have same number of samples? | <p>I analyzed a small dataset which had three features, so I kept max_depth of decision tree to be 3, in doing so I found it something intresting, there was a leaf node which had number of samples of both classes to be equal and decision tree choose one class, now I am intrested to know how class is decided in such sce... | machine learning scikit learn decision trees machine learning model | 1 | What happens if at leaf node both classes have same number of samples? -- (machine learning scikit learn decision trees machine learning model)
<p>I analyzed a small dataset which had three features, so I kept max_depth of decision tree to be 3, in doing so I found it something intresting, there was a leaf node which h... | habedi/stack-exchange-dataset |
76,246 | Challenge in visualizing large coronavirus clusters in US data | <p>I'm trying to take the data on large coronavirus clusters in the US and visualize them to show the sizes and the different settings (prisons, healthcare facilities, etc). I want to show the difference between the different settings.</p>
<p>If the sizes were more similar, I'd try to show a stacked bar chart (wit... | visualization | 1 | Challenge in visualizing large coronavirus clusters in US data -- (visualization)
<p>I'm trying to take the data on large coronavirus clusters in the US and visualize them to show the sizes and the different settings (prisons, healthcare facilities, etc). I want to show the difference between the different settings.</... | habedi/stack-exchange-dataset |
76,252 | Transform large pd.Series into a DataFrame of n columns | <p>I have a <code>pd.Series</code> with, for instance, <code>n</code> lines. I would like to transform this series in a <code>pd.DataFrame</code> as follows:</p>
<p>Ex:</p>
<p>Input: <code>pd.Series([10,11,12,13,14,15])</code> and a variable <code>chunk_size = 2</code> that will be the number of columns.</p>&#x... | dataset pandas numpy dataframe | 1 | Transform large pd.Series into a DataFrame of n columns -- (dataset pandas numpy dataframe)
<p>I have a <code>pd.Series</code> with, for instance, <code>n</code> lines. I would like to transform this series in a <code>pd.DataFrame</code> as follows:</p>
<p>Ex:</p>
<p>Input: <code>pd.Series([10,11,12,13,14,15])<... | habedi/stack-exchange-dataset |
76,258 | Why would GradientBoostClassifier do better than XGBoostClassifier? | <p>I am working on the Kaggle home loan model and interestingly enough, the GradientBoostClassifier has a considerably better score than XGBClassifier. At the same time it seems to not overfit as much. (note, I am running both algos with default settings).
From what I've been reading XGBClassifier is the same as Gr... | python xgboost natural gradient boosting | 1 | Why would GradientBoostClassifier do better than XGBoostClassifier? -- (python xgboost natural gradient boosting)
<p>I am working on the Kaggle home loan model and interestingly enough, the GradientBoostClassifier has a considerably better score than XGBClassifier. At the same time it seems to not overfit as much. (not... | habedi/stack-exchange-dataset |
76,277 | Should I use keras or sklearn for PCA? | <p>Recentl I saw that there is some basic overlapping of functionality between keras and sklearn regarding data preprocessing.
So I am a bit confused that whether should I introduce a dependency on another library like sklearn for basic data preprocessing or should I stick with only keras as I am using keras for bu... | deep learning keras scikit learn feature engineering pca | 1 | Should I use keras or sklearn for PCA? -- (deep learning keras scikit learn feature engineering pca)
<p>Recentl I saw that there is some basic overlapping of functionality between keras and sklearn regarding data preprocessing.
So I am a bit confused that whether should I introduce a dependency on another library l... | habedi/stack-exchange-dataset |
76,320 | Classify text as logical/ not logical | <p>Can some one advise me direction where to look in.Or some resources. Here is a task:</p>
<ol>
<li>User leaves feed back-text with min 50 characters.</li>
<li>I need to check if it's normal human sentences/ word combination OR just bag of words and characters.</li>
</ol>
<p>For ex ( 1-normal, 0-no... | nlp text mining text classification | 1 | Classify text as logical/ not logical -- (nlp text mining text classification)
<p>Can some one advise me direction where to look in.Or some resources. Here is a task:</p>
<ol>
<li>User leaves feed back-text with min 50 characters.</li>
<li>I need to check if it's normal human sentences/ word combination OR ... | habedi/stack-exchange-dataset |
76,339 | What is semantic gap? Why it exists in AI | <p>The semantic gap characterizes the difference between two descriptions of an object by different linguistic representations, for instance languages or symbols. The semantic gap can be defined as "the difference in meaning between constructs formed within different representation systems".</p>
<p>I need... | computer vision ai | 1 | What is semantic gap? Why it exists in AI -- (computer vision ai)
<p>The semantic gap characterizes the difference between two descriptions of an object by different linguistic representations, for instance languages or symbols. The semantic gap can be defined as "the difference in meaning between constructs forme... | habedi/stack-exchange-dataset |
76,358 | is there an adequate number of levels of categorical variables? | <p>I have a project that I'm working on. The dataset contains many categorical variables and some of them have too many levels (+100). My question is : is there any advice to know the "adequate" number of levels of a variable ? is it based on the number of levels of other variables ? (for example most variabl... | categorical data | 1 | is there an adequate number of levels of categorical variables? -- (categorical data)
<p>I have a project that I'm working on. The dataset contains many categorical variables and some of them have too many levels (+100). My question is : is there any advice to know the "adequate" number of levels of a variabl... | habedi/stack-exchange-dataset |
76,361 | How can I explain this chart showing 5-days moving average? | <p>I have plotted the frequency of items sold through time, trying to determine the trends by moving average.
I considered a 5-days window. I would like to know if this approach makes sense and how I could interpret the results.
It's my first time with time-series and moving average (I have no a scientific back... | python time series statistics forecasting | 1 | How can I explain this chart showing 5-days moving average? -- (python time series statistics forecasting)
<p>I have plotted the frequency of items sold through time, trying to determine the trends by moving average.
I considered a 5-days window. I would like to know if this approach makes sense and how I could int... | habedi/stack-exchange-dataset |
76,365 | Classifier using pytorch | <p>I'm writing a demo code to predict a 2-class classification for a dataset of 10-D inputs. Below, function <code> _data</code> generates the data:</p>
<pre><code>import math
import numpy as np
import torch
import torch.nn as nn
import torch.optim as optim

def _data(dimension, num_examples... | pytorch | 1 | Classifier using pytorch -- (pytorch)
<p>I'm writing a demo code to predict a 2-class classification for a dataset of 10-D inputs. Below, function <code> _data</code> generates the data:</p>
<pre><code>import math
import numpy as np
import torch
import torch.nn as nn
import torch.optim as optim
... | habedi/stack-exchange-dataset |
76,370 | How many layers should I replace in transfer learning CNN | <p>I am designing a convolutional neural network that I believe requires transfer learning to function in practice. The network will be a character level CNN for text classification, more specifically, authorship identification of an author given unknown texts. The initial model will be trained on millions of texts fro... | neural network deep learning classification transfer learning text classification | 1 | How many layers should I replace in transfer learning CNN -- (neural network deep learning classification transfer learning text classification)
<p>I am designing a convolutional neural network that I believe requires transfer learning to function in practice. The network will be a character level CNN for text classifi... | habedi/stack-exchange-dataset |
76,385 | Why to adjust class weights instead of simply finding the best threshold? | <p>In a binary supervised classification where classes 1 and 0 have different number of samples in training, it’s very common to find tutorials about adjusting class weights, over and under sampling for imbalanced data sets. In a situation where there are enough samples for both classes (e.g. not an anomaly detection),... | machine learning imbalanced learn | 1 | Why to adjust class weights instead of simply finding the best threshold? -- (machine learning imbalanced learn)
<p>In a binary supervised classification where classes 1 and 0 have different number of samples in training, it’s very common to find tutorials about adjusting class weights, over and under sampling for imba... | habedi/stack-exchange-dataset |
76,398 | Load data from multiple dataframes containing both path and labels in keras | <p>I am aware that there exists a function in <code>keras.preprocessing.image.ImageDataGenerator</code> called <code>flow_from_dataframe</code>. But this function assumes that we have one dataframe containing all the paths to the images and labels associated with it. But what if we have multiple dataframes and we want ... | keras dataframe image preprocessing | 1 | Load data from multiple dataframes containing both path and labels in keras -- (keras dataframe image preprocessing)
<p>I am aware that there exists a function in <code>keras.preprocessing.image.ImageDataGenerator</code> called <code>flow_from_dataframe</code>. But this function assumes that we have one dataframe conta... | habedi/stack-exchange-dataset |
76,399 | Overfitting results with Random Forest Regression | <p>I have one image that contains for each pixel 4 different values.
I have used RF in order to see if I can predict the 4th value based on the other 3 values of each pixel. for that I have used python and scikit learn. first I have fit the model, and after validate it I used it to predict this image.
I was ver... | machine learning python scikit learn random forest accuracy | 1 | Overfitting results with Random Forest Regression -- (machine learning python scikit learn random forest accuracy)
<p>I have one image that contains for each pixel 4 different values.
I have used RF in order to see if I can predict the 4th value based on the other 3 values of each pixel. for that I have used python... | habedi/stack-exchange-dataset |
76,415 | How can I reshape this array? | <p>I have few difficulties in picking values from an array. Here is a simplified version of the concerned part of the code. (If you would like to put the whole code please mention it)</p>
<pre><code>n=2
m=8
test= test[:,-n*m:] 
test=test.reshape(test.shape[0],n,m)
</code></pre>
<p>So, I end up w... | machine learning python deep learning numpy reshape | 1 | How can I reshape this array? -- (machine learning python deep learning numpy reshape)
<p>I have few difficulties in picking values from an array. Here is a simplified version of the concerned part of the code. (If you would like to put the whole code please mention it)</p>
<pre><code>n=2
m=8
test= test[:,-... | habedi/stack-exchange-dataset |
76,421 | Which between random forest or extra tree is best in a unbalance dataset? | <p>I have an unbalanced dataset, with 3 classes, with 60% of class 1, 38% of class 2, and 2% of class 3.</p>
<p>I don't want to generate more examples of class 3, and I cannot get more examples of class 3.</p>
<p>The problem is that I need to choose between RandomForest, and ExtraTree (this is homework), and ex... | machine learning class imbalance variance bias | 1 | Which between random forest or extra tree is best in a unbalance dataset? -- (machine learning class imbalance variance bias)
<p>I have an unbalanced dataset, with 3 classes, with 60% of class 1, 38% of class 2, and 2% of class 3.</p>
<p>I don't want to generate more examples of class 3, and I cannot get more examp... | habedi/stack-exchange-dataset |
76,433 | How to set different weights for different training samples? | <p>Suppose that your supervised learning training set is made out of 3 different datasets, merged into a big one. Because of the way each of those was labeled before merging, you might be suspicious that one of them (maybe the smallest one) is more "important" than the other ones, meaning that their labels ar... | machine learning scikit learn supervised learning | 1 | How to set different weights for different training samples? -- (machine learning scikit learn supervised learning)
<p>Suppose that your supervised learning training set is made out of 3 different datasets, merged into a big one. Because of the way each of those was labeled before merging, you might be suspicious that ... | habedi/stack-exchange-dataset |
76,443 | Choosing attributes for k-means clustering | <p>The k-means clustering tries to minimize the within-cluster scatter and maximizing the distances between clusters. It does so on all attributes.</p>
<p>I am learning about this method on several datasets. To illustrate, in one the datasets countries are compared based on attributes related to their Human develop... | clustering unsupervised learning k means noise | 1 | Choosing attributes for k-means clustering -- (clustering unsupervised learning k means noise)
<p>The k-means clustering tries to minimize the within-cluster scatter and maximizing the distances between clusters. It does so on all attributes.</p>
<p>I am learning about this method on several datasets. To illustrate... | habedi/stack-exchange-dataset |
76,451 | Can 1D-CNN method apply to real-time time series classification? | <p>So I got an EEG dataset with shape (data points, 19), each row's shape (1,19) represent 1 second of EEG.</p>
<p>I read much research on EEG classification that used many Deep Learning method and 1D-CNN is one of that.</p>
<p>My question is as the input of the 1D-CNN must have multi-row data, ex (50,19) for m... | classification time series cnn prediction | 1 | Can 1D-CNN method apply to real-time time series classification? -- (classification time series cnn prediction)
<p>So I got an EEG dataset with shape (data points, 19), each row's shape (1,19) represent 1 second of EEG.</p>
<p>I read much research on EEG classification that used many Deep Learning method and 1D-CNN... | habedi/stack-exchange-dataset |
76,456 | Why do we use 2D kernel for RGB data? | <p>I have recently started kearning CNN and I coukdnt understand that why are we using a 2D kernel like of shape (3x3) for a RGB data in place of a 3D kernel like of shape (3x3x3)?</p>
<p>Are we sharing the same kernel among all the channels because the data would look the same in all the channels?</p>
 | cnn kernel | 1 | Why do we use 2D kernel for RGB data? -- (cnn kernel)
<p>I have recently started kearning CNN and I coukdnt understand that why are we using a 2D kernel like of shape (3x3) for a RGB data in place of a 3D kernel like of shape (3x3x3)?</p>
<p>Are we sharing the same kernel among all the channels because the data wou... | habedi/stack-exchange-dataset |
76,464 | Multidimensional K-Means wiith sklearn, centroids problem when plotting | <p>I am working with a dataset (X) to predict 12 clusters with K-Means using python SKLEARN library:</p>
<pre><code>numClusters= 12
kmeans = KMeans(n_clusters=numClusters).fit(X)
centroids = kmeans.cluster_centers_

# Predicting the clusters
labels = kmeans.predict(X)
# Getting the cluster c... | python scikit learn k means | 1 | Multidimensional K-Means wiith sklearn, centroids problem when plotting -- (python scikit learn k means)
<p>I am working with a dataset (X) to predict 12 clusters with K-Means using python SKLEARN library:</p>
<pre><code>numClusters= 12
kmeans = KMeans(n_clusters=numClusters).fit(X)
centroids = kmeans.clust... | habedi/stack-exchange-dataset |
76,466 | Machine learning to predict pollution at a single location | <p>I have 2 months of air pollution measured data for a location of interest. I am highly interested to play with machine learning algorithms to predict pollution at the same location (let say, for the next two months).</p>
<p>Since air pollution is a geographic problem, does it make sense to apply and predict poll... | machine learning prediction | 1 | Machine learning to predict pollution at a single location -- (machine learning prediction)
<p>I have 2 months of air pollution measured data for a location of interest. I am highly interested to play with machine learning algorithms to predict pollution at the same location (let say, for the next two months).</p>
... | habedi/stack-exchange-dataset |
76,470 | Using SMOTENC in a pipeline | <p>I am trying to figure out the appropriate way to build a pipeline to train a model which includes using the SMOTENC algorithm:</p>
<ol>
<li><p>Given that the N-Nearest Neighbors algorithm and Euclidian distance are used, should the data by normalized (Scale input vectors individually to unit norm). Prior to ... | class imbalance smote imbalanced learn smotenc | 1 | Using SMOTENC in a pipeline -- (class imbalance smote imbalanced learn smotenc)
<p>I am trying to figure out the appropriate way to build a pipeline to train a model which includes using the SMOTENC algorithm:</p>
<ol>
<li><p>Given that the N-Nearest Neighbors algorithm and Euclidian distance are used, should t... | habedi/stack-exchange-dataset |
76,480 | In model validation (log regression), can AUC for the test sample be higher than that for the train sample? | <p>I have a relatively simple model (with 8'000 cases, 5 predictor variables) predicting a dihotomised outcome. It has an AUC of 0.82 (95%CI 0.82-0.83). Prediction in temporal (N=240) and external validation (N=170) datasets had AUCs of 0.85 (95%CI 0.81-0.88) and 0.76 (95% CI 0.68-0.84%). A reviewer told me it is impos... | classification | 1 | In model validation (log regression), can AUC for the test sample be higher than that for the train sample? -- (classification)
<p>I have a relatively simple model (with 8'000 cases, 5 predictor variables) predicting a dihotomised outcome. It has an AUC of 0.82 (95%CI 0.82-0.83). Prediction in temporal (N=240) and exte... | habedi/stack-exchange-dataset |
76,485 | Is this attribute numeric or categorical (ordinal)? Help! | <p>So I have this dataset I need to perform several techniques on as part of a data mining/machine learning project of some sort in PYTHON. There are a couple of features however, that have me very worried as I don't know whether I whould handle them as Categorical (ordinal to be precise) or as numeric.</p>
<ol>&#x... | python data mining feature selection categorical data categorical encoding | 1 | Is this attribute numeric or categorical (ordinal)? Help! -- (python data mining feature selection categorical data categorical encoding)
<p>So I have this dataset I need to perform several techniques on as part of a data mining/machine learning project of some sort in PYTHON. There are a couple of features however, th... | habedi/stack-exchange-dataset |
76,515 | Why PyTorch is faster than sklearn models? | <p>Recently, I get to know about the hummingbird library for Python. I trained a RandomForest on a 10M-sized dataset with 2 labels. With sklearn it was taking 450 ms for inference. But after converting the same model to PyTorch, now it takes 128ms on CPU inference.</p>
<p>If both are running on the CPU, then why hu... | machine learning scikit learn random forest machine learning model pytorch | 1 | Why PyTorch is faster than sklearn models? -- (machine learning scikit learn random forest machine learning model pytorch)
<p>Recently, I get to know about the hummingbird library for Python. I trained a RandomForest on a 10M-sized dataset with 2 labels. With sklearn it was taking 450 ms for inference. But after conver... | habedi/stack-exchange-dataset |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.