Questions tagged [svm]
Support Vector Machines (SVM) are a popular supervised machine learning algorithm that can be used for classification or regression.
573
questions
1
vote
0
answers
10
views
Boosting the effect of some of the features in SVM
I'm doing text classification with SVM. I'm using Tfidf vectorization. In addition to the text vectors, I have a context data denoting the possible outcomes of the prediction. For example, I have a ...
0
votes
1
answer
25
views
Is Linear kernel SVM always better than Logistic regression?
We know that linear kernel SVM may give better results than logistic regression since maximizing the margin usually leads to more stable results/better displacement of the decision boundary. But is ...
0
votes
0
answers
17
views
Which combination would be more beneficial : Resnet-50 and SVM or Resnet-18 and GANs?
I'm trying to compare the two methods that were used for COVID-19 detection.
Given that both these methods have approximately the same accuracies
which method according to you would be more beneficial(...
2
votes
1
answer
253
views
Is it sensible to use the ROC curve with an KNN model? And if so why?
I am a beginner doing my first ML project. I am doing a binary supervised classification on an unbalanced dataset and want to use the ROC curve as a performance metric of my models. I am using ...
1
vote
1
answer
86
views
Grid_search (RandomizedSearchCV) extremely slow with SVM (SVC)
I'm testing hyperparameters for an SVM, however, when I resort to Gridsearch or RandomizedSearchCV, I haven't been able to get a resolution, because the processing time is exceeding hours.
My dataset ...
1
vote
0
answers
20
views
Force positive coefficients for Logistic Regression and LinearSVC
Do you know what is the best way to force positive coefficients with Logistic Regression and Linear SVC using scikit learn?
for instance
...
0
votes
0
answers
6
views
can I use cross validation for testing my model after using grid search cv?
I want to use a SVM for tissue classification, so I have used Grid Search CV for finding the best hyperparameters for my model. For what I know CV can be used with the entire dataset, so I have used ...
0
votes
0
answers
33
views
Implementing XGBoost with CNN
I am trying to implement XGBoost as a classifier for a pre-trained CNN. The model produces an F1 score of 93, however, when classifying with XGBoost (or with SVM), the F1 drops to 33. It seems to be ...
0
votes
0
answers
16
views
What input does SVM consider when doing the text classification?
I was using SVM for text classification
pipe_lr1 = Pipeline(steps=[('cv',TfidfVectorizer()),
('lr_multi',MultiOutputClassifier(LinearSVC()))])
...
0
votes
1
answer
26
views
How to get model equation/coefficients for SVM in Orange
I have dataset and want to train an SVM model, I have done so in Orange, and the model behaves good, I used the File -> SVM -> 'test and score' widgets, now I want to take that linear model and ...
0
votes
1
answer
56
views
How do I print data after fitting data into a pipeline?
I was using 3 functions form scipy: TFIDF vectorizer, Multioutput classifier and Linear SVC.
The code goes like this.
...
0
votes
0
answers
11
views
SVM produces a constant accuracy when testing with different development set, regardless of features
I posted this question earlier, but I did not post the correct pictures and I was unable to edit it
I am currently doing a class project to use a machine learning algorithm (SVM or Regression) to ...
0
votes
1
answer
16
views
SVM produces a constant accuracy when testing with development set, regardless of features
I am currently doing a class project to use a machine learning algorithm (SVM or Regression) to deduce whether two sentences are paraphrases of one another. We were given training, development, and ...
0
votes
1
answer
21
views
Is it possible to train a Support Vector Machine to a specific accuracy?
From my understanding, support vector machines run on the premise of minimizing some error function, usually with the goal of maximizing accuracy overall. However, there are a lot of contexts, ...
1
vote
1
answer
31
views
Can we train of a binary classifier with "A" to classify "a"?
I have a maybe naive question about the appropriateness of using binary classifications. This is a hypothetical example, so forgive me if it is too coarse.
Let's say I want to train a support vector ...
0
votes
1
answer
19
views
what happens when test data has an instance on the hyperplane. How SVC() classifies it?
What happens when test data has an instance on the hyperplane? How does SVC() of scikit-learn classify it?
3
votes
1
answer
76
views
Official page of Weka for SVM java code
I am using Weka to train a model from few days. I know Weka use Java code to implement a classifier. I also heard that Weka has some github pages to describe the java code for the classifiers. I like ...
0
votes
1
answer
21
views
Finding points in 3D space - SVM
In the SVM classification, we use planes to classify the labels points if the dataset has 3 input features. We need to use planes when input features are 3. I am describing a toy dataset with 3 input ...
0
votes
0
answers
16
views
Parameters of W for the equation $$W^TX$$ in SVM
In support vector machine if there are 2 features then the 2 features can be separated using a line. To decide the position of an unknown point we use the equation $$W^TX$$. If we get the positive ...
0
votes
1
answer
35
views
Which line need to consider when try to separate two class given a feature set in SVM
Suppose I have a toy dataset like following
...
0
votes
1
answer
22
views
Proof of perpendicular distance of an observation from the Maximal Margin Hyperplane
I was reading about Maximal Margin Classifiers in "Introduction to Statistical Learning" and could not understand how is the perpendicular distance of an observation (which is a vector) from ...
0
votes
0
answers
32
views
Sklearn SVM slower than when run in GridSearchCV
Problem:
Running SVM in GridSearchCV is faster than running without it and supplying only 1 value of C and no CV.
The AUC on the test set is lower when SVM is run outside of GridSearchCV.
Background:...
1
vote
1
answer
42
views
working principle of Support Vector Machine
I have a dataset consisting of numerical features and categorical features. I want train the training set using SVM. SVM is a quadratic optimization algorithm. I would like to know the how SVM works ...
2
votes
0
answers
75
views
Feature selection and model performance
Featuretools provides an automated way to generate features from your data, by providing relationships within your data and applying their so-called deep feature synthesis. It generates features like ...
2
votes
1
answer
32
views
memory bound for kernel tricks in machine learning
Based on Andrew Ng's lecture on Kernel,
you use training samples (referred as landmarks l) and use them during prediction to construct the higher dimensional representation of the given sample.
This ...
0
votes
0
answers
18
views
Classification task in Adaface
I have a closed dataset with 15-20 people (10 images per person) and I use Adaface to extract feature embeddings. I was wondering what is the best classifier? Is SVM (linear Kernel) a good one? What ...
1
vote
1
answer
36
views
My model is predicting values for only two labels (instead of 9) how to fix it?
My goal is to predict the count (variable y) based on various features (variable x). My y is most of the time (98.4%) equal to 0, so this data is inflated by 0.
Based on this premise, I thought that ...
0
votes
0
answers
33
views
How to solve soft margin SVM using dual lagrangian problem?
I don't know how to use dual lagrangian problem to solve soft margin SVM. Can anyone help me to solve this example with steps calculations:
X_1=(0,2) | y_1=+1
X_2=(0,1) | y_2=-1
X_3=(0,0) | y_3=+1
...
0
votes
0
answers
9
views
Medical Image Classifier
from a series of medical images I obtain several descriptors that characterize each of the images.
From these descriptors I want to classify them into normal / pathological and then into normal / each ...
1
vote
0
answers
7
views
Precision and AUROC for which class values
I am a newbie in reading research paper and implementing it by myself. I went through the paper Breast Cancer Survival Prediction from Imbalanced Dataset with Machine Learning Algorithms.
Can anyone ...
0
votes
0
answers
12
views
SVM's support vectors decision function representataion
I am currently using SVM for my project with 'rbf' kernel.
What i understand from the theory is that the decision function value ...
0
votes
1
answer
37
views
How to increase the accuracy of 1 class
Hai I am working with blood transfusion data set using SVM classifier.I applied SVC with C=17 and kernel rbf. It is highly imbalanced data set and I balanced it using SMOTE. But class 1 is performing ...
0
votes
1
answer
74
views
Will removing one support vector affect others?
Supppose we have SVM trained on a dataset and the support vectors are $SV=\{x_1,x_2,\cdots,x_n\}$. Then, we know that the decision plan is decided by $SV$. My question is that if we remove one support ...
0
votes
0
answers
43
views
0
votes
1
answer
37
views
Fluctuating accuracy for Naive Bayes Classifier and SVM
I am comparing the classification accuracy between Naive Bayes (NBC), SVM and a Neural Network. I am using a Dataset of ~18K and 26 Labels.
In the current state the Neural Network get always an ...
2
votes
1
answer
248
views
What's the input shape for an SVM classifier?
I have a dataset with tensors (there are 12 classes) of shape (700,2000) - height is 700 and width is 2000. I would like to try to use an SVM classifier (just to ...
0
votes
0
answers
9
views
Combining a BoW vector with other features: effectivity and feature value ranges
I am working with a Support Vector Machine to predict class prevalence in a binary classification problem.
The model will take a sparse representation of an instance as input, where the number of the ...
1
vote
2
answers
29
views
What are some methods to reduce a dataframe so I can pass it as one sample to an SVM?
I need to classify participants in an NLP study into 3 classes, based on multiple sentences spoken by the participant. I performed a feature extraction on each sentence, and so I am left with a matrix ...
0
votes
1
answer
102
views
Why would we add regularization loss to the gradient itself in an SVM?
I'm doing CS 231n on my own. I'm looking at this solution to a question that implements a SVM.
Relevant code:
...
0
votes
0
answers
10
views
SVN understanding decision boundaries when using large vs. small values for gamma
It's said that when using a large value for gamma in SVN, the model will fit the training data better than using a small value thus may lead to overfitting. However, looking into the following ...
1
vote
0
answers
14
views
Strong bias from Linear SVR meta model
I have built nine meta models based on the model stacking principle, which I compare to a reference model for a number of time series. See the results below. The 22 base models that are trained on 70% ...
0
votes
0
answers
3
views
Extracting negative class support vectors (on imbalanced class) and remove them from dataset based on performance
I'm classifying imbalanced dataset using SVM, and I'm trying to prune the support vectors to solve the imbalanced class problem (binary classification). The ideas are, I'm going to first train the ...
1
vote
0
answers
75
views
Why would a Linear SVR model greatly outperform a Linear Regression model on model stacking
I have built nine meta models based on the model stacking principle, which I compare to a reference model for a number of time series. See the results below. The 22 base models that are trained on 70% ...
1
vote
0
answers
257
views
Should I train multiple models or single model with respective data for multiple parameters?
In one of my projects I have 7 output classes. However, while this makes up a baseline set of results, I also want to test the impact of some experimental parameters.
To avoid any information ...
1
vote
1
answer
24
views
Can depth be used as a feature when predicting rock type from well log data?
I am trying to predict the lithofacies, i.e. the rock type, from well log data, a project very similar to the one described in this tutorial.
A well log can be seen as a 1D curve tracking how a given ...
1
vote
1
answer
206
views
Get negative predicted value in Support Vector Regresion (SVR)
I am doing Covid-19 cases prediction using SVR, and getting negative values, while there should be no number of Covid-9 cases negative. Feature input that I was used is mobility factor (where have ...
2
votes
0
answers
159
views
random_state on train_test_split() appears to have large effect in performance metrics?
To summarize the problem: I have a data set with ~1450 samples, 19 features and a binary outcome where classes are fairly balanced (0.51 to 0.49).
I split the data into a train set and a test set ...
0
votes
2
answers
157
views
Training data in sentiment analysis
I'm doing sentiment analysis of tweets related to recent acquisition of Twitter by Elon Musk. I have a corpus of 10 000 tweets and I'd like to use machine learning methods using models like SVM and ...
0
votes
0
answers
13
views
Objective Functions in Twin Support Vector Machines
I'm reading paper Twin Support Vector Machines for Pattern Classification by Jayadeva et al. (2007). In that paper, the authors proposed using two non-parallel hyperplanes for classifying two classes. ...
0
votes
0
answers
96
views
How to get all the parameters of scikit-learn multiclass SVM classifier?
I have trained my multiclass SVM model for MNIST classification in Python using scikit-learn using the following code:
...