Support vector machine
Written by GPT-6 Luna from the web 22 of 70 sentences cited
An AI wrote this article, and it can be wrong.
Support vector machine (SVM) is a family of supervised learning methods that constructs decision boundaries for classification and functions for regression. Its central idea is to choose a boundary with a large margin between classes, while allowing controlled violations when data are noisy or overlapping. The examples that help define the boundary are called support vectors. By using kernel functions, an SVM can also model nonlinear relationships without explicitly constructing every feature in a high-dimensional representation.1
SVMs became prominent in machine learning because they combined a principled approach to controlling model complexity with effective methods for high-dimensional data. Researchers extended the original classification approach to regression and other tasks, and applied it to areas including text and image classification. SVMs remain available in widely used software, although their suitability depends on the data and computational requirements: kernel methods can be costly on large datasets, and performance depends on choices such as the kernel and regularization settings.231
Concept
An SVM learns from labeled examples, each consisting of an input vector and a target value or class. In binary classification, it seeks a boundary separating examples of two classes. A linear boundary is a hyperplane, described by a weight vector and an intercept; a new example is assigned a class according to which side of that hyperplane it falls on.21
Among boundaries that separate the training data, the classical SVM chooses one that maximizes the margin: the distance from the boundary to the closest examples in either class. These closest examples are the support vectors, and they determine the fitted boundary. In the dual formulation of the optimization problem, the learned prediction function is expressed as a weighted combination of training examples, with nonzero weights associated with support vectors.45
The margin provides a way to control the complexity of the classifier, rather than simply seeking zero error on the training set. This is related to statistical learning theory’s concern with how well a model generalizes to unseen examples. It does not mean that a large-margin classifier must perform well on every new dataset: results still depend on how representative the training data are and on the model’s settings.51
Origins
A key early milestone was the 1992 paper “A Training Algorithm for Optimal Margin Classifiers,” by Bernhard Boser, Isabelle Guyon and Vladimir Vapnik. It described a training algorithm that maximized the margin and expressed the resulting solution as a combination of the training patterns nearest the decision boundary. The method could be applied to different kinds of classifiers, including polynomial and radial-basis-function classifiers.4
In 1995, Corinna Cortes and Vapnik published “Support-vector networks,” extending the approach to data that could not be separated without errors. Their method mapped inputs into a feature space, where it constructed a linear decision surface; they reported experiments using polynomial transformations and compared performance on optical character recognition tasks. This work helped establish the soft-margin classifier and the kernel-based view associated with modern SVMs.2
The scope of the method expanded soon afterward. A 1996 paper by Harris Drucker, Christopher Burges, Linda Kaufman, Alex Smola and Vapnik introduced support vector regression, adapting support-vector ideas to estimate continuous outputs. SVM methods also gained attention for text categorization, a task where examples can be represented by vectors with many word-related features.36
Classification
When classes overlap or labels contain noise, a hard-margin classifier may fail to find a separating boundary. A soft-margin SVM permits some examples to lie within the margin or on the wrong side of the boundary, while penalizing those violations. The parameter controls the balance between penalizing training errors and keeping the decision surface simpler: a larger value places greater emphasis on classifying training examples correctly.21
In a binary linear SVM, prediction is based on the sign of a score formed from the input’s weighted features and an intercept. The distance from the boundary is related to the score, but that score is not automatically a calibrated probability. Some software can estimate probabilities by adding a separate calibration procedure; in scikit-learn, for example, enabling probability estimates requires additional cross-validation.1
The basic SVM formulation is binary, while practical implementations also support multiclass classification. SVMs can be effective in settings where the number of features is large, including cases where there are more features than training examples. Their output is still a model learned from the supplied examples, however, and neither a high-dimensional feature representation nor a large margin removes the need to evaluate generalization on data not used for training.16
Kernels
A linear SVM uses the original features to construct a straight hyperplane. To represent more complex boundaries, an SVM can instead use a kernel function, which computes similarities between pairs of examples as if they had been mapped into another feature space. This “kernel trick” allows the optimization to use those similarities without explicitly building all coordinates of the transformed representation.21
Common kernels include the linear, polynomial and radial basis function (RBF) kernels. The polynomial kernel represents interactions up to a chosen degree, while the RBF kernel measures similarity using distance between examples and can produce nonlinear decision boundaries. A kernel is not merely a computational option: it embodies assumptions about which patterns of similarity are useful for the problem.1
For an RBF SVM, the parameter controls how quickly the influence of an individual example diminishes with distance. Higher values make that influence more local, while lower values make it extend farther. The interaction between and can substantially change the fitted classifier, so selecting them requires model evaluation rather than assuming a single setting works for all datasets.1
Regression
Support vector regression (SVR) adapts SVM optimization to predict continuous values instead of class labels. In the original formulation, the model fits a function while tolerating errors within a specified -wide region around the observed targets; deviations outside that region contribute to the optimization objective. As in classification, a kernel can allow the fitted function to represent nonlinear relationships.31
The -insensitive loss means that small differences between predictions and observed values can be ignored during fitting, while larger errors influence the solution. Only some training examples then contribute directly to the fitted function; these are the regression support vectors. The usefulness of this approach depends on choices such as the tolerance, regularization and kernel, as well as the distribution and scale of the target values.1
The original regression paper presented experiments comparing SVR with other regression methods and argued for its potential in high-dimensional spaces. That result established a regression branch of support-vector learning, not a general claim that SVR outperforms alternatives across tasks. In applied work, regression models must be assessed against appropriate baselines and on held-out data, particularly when errors have different practical costs. proceedings.neurips.org
Uses
SVMs were studied early for optical character recognition, and text categorization became a prominent application. In text classification, examples can be represented as sparse vectors of word-related features, often with very many possible dimensions. Thorsten Joachims’s 2002 book on SVM text classification covered the binary and multiclass settings, feature representation, performance measures and learning theory for this application.26
Subsequent work and software have applied SVM variants to classification, regression and outlier detection. A 2018 paper introducing the ThunderSVM toolkit listed applications including document and image classification, blood-pressure estimation, disease detection and outlier detection. Such examples demonstrate the breadth of tasks to which the method has been applied, but do not establish that an SVM is preferable for every dataset in those fields.71
The support vectors also give the fitted model a particular form of sparsity: predictions depend on a subset of training examples rather than requiring every example to appear in the decision function. This property helped motivate early interest in the method and in the possibility of identifying which training cases mattered for a particular classification task. It does not necessarily mean that the model is small or inexpensive, since the number of support vectors can itself be large.51
Constraints and practice
Kernel SVMs can be computationally demanding as training sets grow, in part because optimization involves relationships among training examples. Research on SVM training has therefore explored decomposition methods, low-rank kernel representations, approximate solutions and parallel computation. A 2018 study of ThunderSVM described using GPUs and multicore CPUs to accelerate SVM training, while retaining classification, regression and one-class functions.87
SVMs are not scale-invariant: features measured on very different numerical ranges can affect the fit unevenly. Scikit-learn recommends scaling input features, with the same transformation applied to training and test examples. It also cautions that kernel and regularization choices require care, especially when there are many features relative to the number of examples.1
The method remains implemented in contemporary machine-learning software, including scikit-learn, which documents classification, regression, outlier detection, common kernels and alternatives for linear models. That availability reflects SVMs’ continued role as a general-purpose model family, not a claim of universal superiority. For a particular application, choices about scaling, kernel, hyperparameters, class imbalance, probability estimates and training cost all affect whether an SVM is an appropriate tool.1
References
8 sourcesSupport Vector Regression Machinesproceedings.neurips.cc· cited 3×
dl.acm.org/doi/10.1145/130385.130401dl.acm.org· cited 2×
cdn.aaai.org/KDD/1995/KDD95-030.pdfcdn.aaai.org· cited 3×
Learning to Classify Text using Support Vector Machinescs.cornell.edu· cited 3×
jmlr.org/papers/volume19/17-740/17-740.pdfjmlr.org· cited 2×