{"title": "Adversarial machine learning", "url": "https://en.wikipedia.org/wiki/Adversarial_machine_learning", "summary": "Adversarial machine learning is the study of the attacks on machine learning algorithms, and of the defenses against such attacks.\nMachine learning techniques are mostly designed to work on specific problem sets, under the assumption that the training and test data are generated from the same statistical distribution (IID). However, this assumption is often violated in practical high-stake applications, where users may intentionally supply fabricated data that violates the statistical assumption.\nMost common attacks in adversarial machine learning include evasion attacks, data poisoning attacks, Byzantine attacks and model extraction.", "content": "Adversarial machine learning is the study of the attacks on machine learning algorithms, and of the defenses against such attacks.\nMachine learning techniques are mostly designed to work on specific problem sets, under the assumption that the training and test data are generated from the same statistical distribution (IID). However, this assumption is often violated in practical high-stake applications, where users may intentionally supply fabricated data that violates the statistical assumption.\nMost common attacks in adversarial machine learning include evasion attacks, data poisoning attacks, Byzantine attacks and model extraction.\n\n\nHistory\nAt the MIT Spam Conference in January 2004, John Graham-Cumming showed that a machine-learning spam filters could be used to defeat another machine-learning spam filter by automatically learning which words to add to a spam email to get the email classified as not spam.\nIn 2004, Nilesh Dalvi and others noted that linear classifiers used in spam filters could be defeated by simple \"evasion attacks\" as spammers inserted \"good words\" into their spam emails. (Around 2007, some spammers added random noise to fuzz words within \"image spam\" in order to defeat OCR-based filters.) In 2006, Marco Barreno and others published \"Can Machine Learning Be Secure?\", outlining a broad taxonomy of attacks. As late as 2013 many researchers continued to hope that non-linear classifiers (such as support vector machines and neural networks) might be robust to adversaries, until Battista Biggio and others demonstrated the first gradient-based attacks on such machine-learning models (2012–2013). In 2012, deep neural networks began to dominate computer vision problems; starting in 2014, Christian Szegedy and others demonstrated that deep neural networks could be fooled by adversaries, again using a gradient-based attack to craft adversarial perturbations.\nFurther work would show that adversarial attacks are harder to produce in uncontrolled environments, due to the different environmental constraints that cancel out the effect of noise. For example, any small rotation or slight illumination on an adversarial image can destroy the adversariality. In addition, researchers such as Google Brain's Nick Frosst point out that it is much easier to make self-driving cars miss stop signs by physically removing the sign itself, rather than creating adversarial examples. Frosst also believes that the adversarial machine learning community incorrectly assumes models trained on a certain data distribution will also perform well on a completely different data distribution. He suggests that a new approach to machine learning should be explored, and is currently working on a unique neural network that has characteristics more similar to human perception than state-of-the-art approaches.\nWhile adversarial machine learning continues to be heavily rooted in academia, large tech companies such as Google, Microsoft, and IBM have begun curating documentation and open source code bases to allow others to concretely assess the robustness of machine learning models and minimize the risk of adversarial attacks.\n\n\nExamples\nExamples include attacks in spam filtering, where spam messages are obfuscated through the misspelling of \"bad\" words or the insertion of \"good\" words; attacks in computer security, such as obfuscating malware code within network packets or modifying the characteristics of a network flow to mislead intrusion detection; attacks in biometric recognition where fake biometric traits may be exploited to impersonate a legitimate user; or to compromise users' template galleries that adapt to updated traits over time.\nResearchers showed that by changing only one pixel it was possible to fool deep learning algorithms. Others 3-D printed a toy turtle with a texture engineered to make Google's object detection AI classify it as a rifle regardless of the angle from which the turtle was viewed. Creating the turtle required only low-cost commercially available 3-D printing technology.\nA machine-tweaked image of a dog was shown to look like a cat to both computers and humans. A 2019 study reported that humans can guess how machines will classify adversarial images. Researchers discovered methods for perturbing the appearance of a stop sign such that an autonomous vehicle classified it as a merge or speed limit sign.\nA data poisoning filter called Nightshade was released in 2023 by researchers at the University of Chicago. It was created for use by visual artists to put on their artwork to corrupt the data set of text-to-image models, which usually scrape their data from the internet without the consent of the image creator.\nMcAfee attacked Tesla's former Mobileye system, fooling it into driving 50 mph over the speed limit, simply by adding a two-inch strip of black tape to a speed limit sign.\nAdversarial patterns on glasses or clothing designed to deceive facial-recognition systems or license-plate readers, have led to a niche industry of \"stealth streetwear\".\nAn adversarial attack on a neural network can allow an attacker to inject algorithms into the target system. Researchers can also create adversarial audio inputs to disguise commands to intelligent assistants in benign-seeming audio; a parallel literature explores human perception of such stimuli.\nClustering algorithms are used in security applications. Malware and computer virus analysis aims to identify malware families, and to generate specific detection signatures.\nIn the context of malware detection, researchers have proposed methods for adversarial malware generation that automatically craft binaries to evade learning-based detectors while preserving malicious functionality. Optimization-based attacks such as GAMMA use genetic algorithms to inject benign content (for example, padding or new PE sections) into Windows executables, framing evasion as a constrained optimization problem that balances misclassification success with the size of the injected payload and showing transferability to commercial antivirus products. Complementary work uses generative adversarial networks (GANs) to learn feature-space perturbations that cause malware to be classified as benign; Mal-LSGAN, for instance, replaces the standard GAN loss with a least-squares objective and modified activation functions to improve training stability and produce adversarial malware examples that substantially reduce true positive rates across multiple detectors.\nEmerging adversarial attacks are also highly effective in human-action recognition systems, which are employed widely for real-world applications such as surveillance, autonomous vehicles, and in-house monitoring. In these attacks, attackers introduce noise into the representation of the human features to fool the recognition systems. These attacks do not necessary require the access of the recognition systems themselves, and they can be inperceptible by the human users of such systems, thereby casting a significant security risk.\n\n\nChallenges in applying machine learning to security\nResearchers have observed that the constraints under which machine-learning techniques function in the security domain are different from those of common benchmark domains. Security data may change over time, include mislabeled samples, or reflect adversarial behavior, which complicates evaluation and reproducibility.\n\n\nData collection issues\nSecurity datasets vary across formats, including binaries, network traces, and log files. Studies have reported that the process of converting these sources into features can introduce bias or inconsistencies.\nIn addition, time-based leakage can occur when related malware samples are not properly separated across training and testing splits, which may lead to overly optimistic results.\n\n\nLabeling and ground truth challenges\nMalware labels are often unstable because different antivirus engines may classify the same sample in conflicting ways. Ceschin et al. note that families may be renamed or reorganized over time, causing further discrepancies in ground truth and reducing the reliability of benchmarks.\n\n\nConcept drift\nBecause malware creators continuously adapt their techniques, the statistical properties of malicious samples also change. This form of concept drift has been widely documented and may reduce model performance unless systems are updated regularly or incorporate mechanisms for incremental learning.\n\n\nFeature robustness\nResearchers differentiate between features that can be easily manipulated and those that are more resistant to modification. For example, simple static attributes, such as header fields, may be altered by attackers, while structural features, such as control-flow graphs, are generally more stable but computationally expensive to extract.\n\n\nClass imbalance\nIn realistic deployment environments, the proportion of malicious samples can be extremely low, ranging from 0.01% to 2% of total data. This unbalanced distribution causes models to develop a bias towards the majority class, achieving high accuracy but failing to identify malicious samples.\nPrior approaches to this problem have included both data-level solutions and sequence-specific models. Methods like n-gram and Long Short-Term Memory (LSTM) networks can model sequential data, but their performance has been shown to decline significantly when malware samples are realistically proportioned in the training set, demonstrating the limitations in realistic security contexts.\nTo address this issue, one approach has been to adapt models from natural language processing, such as BERT. This method involves treating sequences of application activities as a form of \"language\" and fine-tuning a pre-trained BERT model on the specific task. A study applying this technique to Android activity sequences reported an F1 score of 0.919 on a dataset with only 0.5% malware samples. This result was a significant improvement over LSTM and n-gram models, demonstrating the potential of pre-trained models to handle class imbalance in malware detection.\n\n\nSystem design and learning\nFeature engineering and training can causes issues. Data snooping is a common pitfall where a model is trained using information that would not be available in a real-world scenario. Spurious correlations result when a model learns to associate artifacts with a label, rather than the underlying security-relevant pattern. For example, a malware classifier might learn to identify a specific compiler artifact instead of malicious behavior itself.\nBiased parameter selection is a form of data snooping where model hyperparameters are tuned using the test set.\n\n\nPerformance evaluation\nThe choice of the evaluation metrics can impact the validity of the results.\nHaving an inappropriate baseline involves failing to compare a new model against simpler, well-established baselines. \nInappropriate performance measures means using metrics that do not align with the practical goals of the system. Reporting only \"accuracy\" is often described as insufficient for an intrusion detection system, where false-positive rates are considered critically important.\nBase rate fallacy is a failure to correctly interpret performance in the context of large class imbalances.\n\n\nDeployment and operation\nDeployment introduces challenges related to the performance and security in live environments.\nLab-only evaluation is the practice of evaluating a system only in a controlled, static laboratory setting, which does not account for real-world challenges like concept drift and performance overhead.\nInappropriate threat model refers to failing to consider the ML system itself as an attack surface.\n\n\nAttack modalities\n\n\nTaxonomy\nAttacks against (supervised) machine learning algorithms have been categorized along three primary axes: influence on the classifier, the security violation and their specificity.\n\nClassifier influence: An attack can influence the classifier by disrupting the classification phase. This may be preceded by an exploration phase to identify vulnerabilities. The attacker's capabilities might be restricted by the presence of data manipulation constraints.\nSecurity violation: An attack can supply malicious data that gets classified as legitimate. Malicious data supplied during training can cause legitimate data to be rejected after training.\nSpecificity: A targeted attack attempts to allow a specific intrusion/disruption. Alternatively, an indiscriminate attack creates general mayhem.\nThis taxonomy has been extended into a more comprehensive threat model that allows explicit assumptions about the adversary's goal, knowledge of the attacked system, capability of manipulating the input data/system components, and on attack strategy. This taxonomy has further been extended to include dimensions for defense strategies against adversarial attacks.\n\n\nStrategies\nBelow are some of the most commonly encountered attack scenarios.\n\n\nData poisoning\nPoisoning consists of contaminating the training dataset with data designed to increase errors in the output. Given that learning algorithms are shaped by their training datasets, poisoning can effectively reprogram algorithms with potentially malicious intent. Concerns have been raised especially for user-generated training data, e.g. for content recommendation or natural language models. The ubiquity of fake accounts offers many opportunities for poisoning. Facebook reportedly removes around 7 billion fake accounts per year. Poisoning has been reported as the leading concern for industrial applications.\nOn social medias, disinformation campaigns attempt to bias recommendation and moderation algorithms, to push certain content over others.\nA particular case of data poisoning is the backdoor attack, which aims to teach a specific behavior for inputs with a given trigger, e.g. a small defect on images, sounds, videos or texts.\n\nFor instance, intrusion detection systems are often trained using collected data. An attacker may poison this data by injecting malicious samples during operation that subsequently disrupt retraining.\nA 2025 study by researchers at the AI Security Institute, Anthropic and the Alan Turing Institute found that the number of poisoned documents needed to introduce a language-model backdoor remained approximately constant across the model and training-set sizes tested. The researchers pretrained models with 600 million to 13 billion parameters on datasets containing 6 billion to 260 billion tokens. Adding 250 poisoned documents was sufficient to introduce a denial-of-service backdoor at every tested scale, causing the models to generate gibberish in response to a trigger phrase. In the 13-billion-parameter model, these documents accounted for approximately 0.00016% of the training tokens. The authors noted that the study had not established whether backdoors introduced during pretraining would survive realistic post-training. Co-author Vasilios Mavroudis suggested that backdoors selectively reducing a model's usefulness to particular groups of users could be harder to detect than overt failures.\nData poisoning techniques can also be applied to text-to-image models to alter their output, which is used by artists to defend their copyrighted works or their artistic style against imitation.\nData poisoning can also happen unintentionally through model collapse, where models are trained on synthetic data.\n\n\nByzantine attacks\nAs machine learning is scaled, it often relies on multiple computing machines. In federated learning, for instance, edge devices collaborate with a central server, typically by sending gradients or model parameters. However, some of these devices may deviate from their expected behavior, e.g. to harm the central server's model or to bias algorithms towards certain behaviors (e.g., amplifying the recommendation of disinformation content). On the other hand, if the training is performed on a single machine, then the model is very vulnerable to a failure of the machine, or an attack on the machine; the machine is a single point of failure. In fact, the machine owner may themselves insert provably undetectable backdoors.\nThe current leading solutions to make (distributed) learning algorithms provably resilient to a minority of malicious (a.k.a. Byzantine) participants are based on robust gradient aggregation rules. The robust aggregation rules do not always work especially when the data across participants has a non-iid distribution. Nevertheless, in the context of heterogeneous honest participants, such as users with different consumption habits for recommendation algorithms or writing styles for language models, there are provable impossibility theorems on what any robust learning algorithm can guarantee.\n\n\nEvasion\nEvasion attacks consist of exploiting the imperfection of a trained model. For instance, spammers and hackers often attempt to evade detection by obfuscating the content of spam emails and malware. Samples are modified to evade detection; that is, to be classified as legitimate. This does not involve influence over the training data. A clear example of evasion is image-based spam in which the spam content is embedded within an attached image to evade textual analysis by anti-spam filters. Another example of evasion is given by spoofing attacks against biometric verification systems.\nEvasion attacks can be generally split into two different categories: black box attacks and white box attacks.\n\n\nModel extraction\nModel extraction involves an adversary probing a black box machine learning system in order to extract the data it was trained on. This can cause issues when either the training data or the model itself is sensitive and confidential. For example, model extraction could be used to extract a proprietary stock trading model which the adversary could then use for their own financial benefit.\nIn the extreme case, model extraction can lead to model stealing, which corresponds to extracting a sufficient amount of data from the model to enable the complete reconstruction of the model.\nOn the other hand, membership inference is a targeted model extraction attack, which infers the owner of a data point, often by leveraging the overfitting resulting from poor machine learning practices. Concerningly, this is sometimes achievable even without knowledge or access to a target model's parameters, raising security concerns for models trained on sensitive data, including but not limited to medical records and/or personally identifiable information. With the emergence of transfer learning and public accessibility of many state of the art machine learning models, tech companies are increasingly drawn to create models based on public ones, giving attackers freely accessible information to the structure and type of model being used.\n\n\nCategories\n\n\nAdversarial attacks and training in linear models\nThere is a growing literature about adversarial attacks in linear models. Indeed, since the seminal work from Goodfellow at al. studying these models in linear models has been an important tool to understand how adversarial attacks affect machine learning models. \nThe analysis of these models is simplified because the computation of adversarial attacks can be simplified in linear regression and classification problems. Moreover, adversarial training is convex in this case.\nLinear models allow for analytical analysis while still reproducing phenomena observed in state-of-the-art models.\nOne prime example of that is how this model can be used to explain the trade-off between robustness and accuracy. \nDiverse work indeed provides analysis of adversarial attacks in linear models, including asymptotic analysis for classification and for linear regression. And, finite-sample analysis based on Rademacher complexity.\nA result from studying adversarial attacks in linear models is that it closely relates to regularization. Under certain conditions, it has been shown that\n\nadversarial training of a linear regression model with input perturbations restricted by the infinity-norm closely resembles Lasso regression, and that\nadversarial training of a linear regression model with input perturbations restricted by the 2-norm closely resembles Ridge regression.\n\n\nAdversarial deep reinforcement learning\nAdversarial deep reinforcement learning is an active area of research in reinforcement learning focusing on vulnerabilities of learned policies. In this research area, some studies initially showed that reinforcement learning policies are susceptible to imperceptible adversarial manipulations. While some methods have been proposed to overcome these susceptibilities, in the most recent studies it has been shown that these proposed solutions are far from providing an accurate representation of current vulnerabilities of deep reinforcement learning policies.\n\n\nAdversarial natural language processing\nAdversarial attacks on speech recognition have been introduced for speech-to-text applications, in particular for Mozilla's implementation of DeepSpeech and Google's Speech Commands model. Various pre-processing techniques have been proposed to defend against such attacks , but these methods may not be resilient to attackers aware of those defenses.\n\n\nSpecific attack types\nThere are a large variety of different adversarial attacks that can be used against machine learning systems. Many of these work on both deep learning systems as well as traditional machine learning models such as SVMs and linear regression. A high level sample of these attack types include:\n\nAdversarial examples\nTrojan and backdoor attacks\nModel inversion\nMembership inference\n\n\nAdversarial examples\nAn adversarial example refers to specially crafted input that is designed to look \"normal\" to humans but causes misclassification to a machine learning model. Often, a form of specially designed \"noise\" is used to elicit the misclassifications. Below are some current techniques for generating adversarial examples in the literature (by no means an exhaustive list).\n\nGradient-based evasion attack\nFast Gradient Sign Method (FGSM)\nProjected Gradient Descent (PGD)\nCarlini and Wagner (C&W) attack\nAdversarial patch attack\n\n\nBlack box attacks\nBlack box attacks in adversarial machine learning assume that the adversary can only get outputs for provided inputs and has no knowledge of the model structure or parameters. In this case, the adversarial example is generated either using a model created from scratch, or without any model at all (excluding the ability to query the original model). In either case, the objective of these attacks is to create adversarial examples that are able to transfer to the black box model in question.\n\n\nSimple black-box adversarial attacks\nSimple black-box adversarial attacks is a query-efficient way to attack black-box image classifiers. Take a random orthonormal basis \n \n \n \n \n v\n \n 1\n \n \n ,\n \n v\n \n 2\n \n \n ,\n …\n ,\n \n v\n \n d\n \n \n \n \n {\\displaystyle v_{1},v_{2},\\dots ,v_{d}}\n \n in \n \n \n \n \n \n R\n \n \n d\n \n \n \n \n {\\displaystyle \\mathbb {R} ^{d}}\n \n. The authors suggested the discrete cosine transform of the standard basis (the pixels).\nFor a correctly classified image \n \n \n \n x\n \n \n {\\displaystyle x}\n \n, try \n \n \n \n x\n +\n ϵ\n \n v\n \n 1\n \n \n ,\n x\n −\n ϵ\n \n v\n \n 1\n \n \n \n \n {\\displaystyle x+\\epsilon v_{1},x-\\epsilon v_{1}}\n \n, and compare the amount of error in the classifier upon \n \n \n \n x\n +\n ϵ\n \n v\n \n 1\n \n \n ,\n x\n ,\n x\n −\n ϵ\n \n v\n \n 1\n \n \n \n \n {\\displaystyle x+\\epsilon v_{1},x,x-\\epsilon v_{1}}\n \n. Pick the one that causes the largest amount of error.\n\nRepeat this for \n \n \n \n \n v\n \n 2\n \n \n ,\n \n v\n \n 3\n \n \n ,\n …\n \n \n {\\displaystyle v_{2},v_{3},\\dots }\n \n until the desired level of error in the classifier is reached.It was discovered when the authors designed a simple baseline to compare with a previous black-box adversarial attack algorithm based on gaussian processes, and were surprised that the baseline worked even better.\n\n\nSquare attack\nSquare attacks were introduced in 2020 as a black-box evasion adversarial attack technique based on querying classification scores without the need for gradient information. As a score based black box attack, this adversarial approach is able to query probability distributions across model output classes, but has no other access to the model itself. According to the paper's authors, the proposed Square Attack required fewer queries than when compared to state-of-the-art score-based black box attacks at the time.\nTo describe the function objective, the attack defines the classifier as \n \n \n \n f\n :\n [\n 0\n ,\n 1\n \n ]\n \n d\n \n \n →\n \n \n R\n \n \n K\n \n \n \n \n {\\textstyle f:[0,1]^{d}\\rightarrow \\mathbb {R} ^{K}}\n \n, with \n \n \n \n d\n \n \n {\\textstyle d}\n \n representing the dimensions of the input and \n \n \n \n K\n \n \n {\\textstyle K}\n \n as the total number of output classes. \n \n \n \n \n f\n \n k\n \n \n (\n x\n )\n \n \n {\\textstyle f_{k}(x)}\n \n returns the score (or a probability between 0 and 1) that the input \n \n \n \n x\n \n \n {\\textstyle x}\n \n belongs to class \n \n \n \n k\n \n \n {\\textstyle k}\n \n, which allows the classifier's class output for any input \n \n \n \n x\n \n \n {\\textstyle x}\n \n to be defined as \n \n \n \n \n \n argmax\n \n \n k\n =\n 1\n ,\n .\n .\n .\n ,\n K\n \n \n \n f\n \n k\n \n \n (\n x\n )\n \n \n {\\textstyle {\\text{argmax}}_{k=1,...,K}f_{k}(x)}\n \n. The goal of this attack is as follows:\n\n \n \n \n \n \n argmax\n \n \n k\n =\n 1\n ,\n .\n .\n .\n ,\n K\n \n \n \n f\n \n k\n \n \n (\n \n \n \n x\n ^\n \n \n \n )\n ≠\n y\n ,\n \n |\n \n \n |\n \n \n \n \n x\n ^\n \n \n \n −\n x\n \n |\n \n \n \n |\n \n \n p\n \n \n ≤\n ϵ\n \n and \n \n \n \n \n x\n ^\n \n \n \n ∈\n [\n 0\n ,\n 1\n \n ]\n \n d\n \n \n \n \n {\\displaystyle {\\text{argmax}}_{k=1,...,K}f_{k}({\\hat {x}})\\neq y,||{\\hat {x}}-x||_{p}\\leq \\epsilon {\\text{ and }}{\\hat {x}}\\in [0,1]^{d}}\n \n\nIn other words, finding some perturbed adversarial example \n \n \n \n \n \n \n x\n ^\n \n \n \n \n \n {\\textstyle {\\hat {x}}}\n \n such that the classifier incorrectly classifies it to some other class under the constraint that \n \n \n \n \n \n \n x\n ^\n \n \n \n \n \n {\\textstyle {\\hat {x}}}\n \n and \n \n \n \n x\n \n \n {\\textstyle x}\n \n are similar. The paper then defines loss \n \n \n \n L\n \n \n {\\textstyle L}\n \n as \n \n \n \n L\n (\n f\n (\n \n \n \n x\n ^\n \n \n \n )\n ,\n y\n )\n =\n \n f\n \n y\n \n \n (\n \n \n \n x\n ^\n \n \n \n )\n −\n \n max\n \n k\n ≠\n y\n \n \n \n f\n \n k\n \n \n (\n \n \n \n x\n ^\n \n \n \n )\n \n \n {\\textstyle L(f({\\hat {x}}),y)=f_{y}({\\hat {x}})-\\max _{k\\neq y}f_{k}({\\hat {x}})}\n \n and proposes the solution to finding adversarial example \n \n \n \n \n \n \n x\n ^\n \n \n \n \n \n {\\textstyle {\\hat {x}}}\n \n as solving the below constrained optimization problem:\n\n \n \n \n \n min\n \n \n \n \n x\n ^\n \n \n \n ∈\n [\n 0\n ,\n 1\n \n ]\n \n d\n \n \n \n \n L\n (\n f\n (\n \n \n \n x\n ^\n \n \n \n )\n ,\n y\n )\n ,\n \n s.t. \n \n \n |\n \n \n |\n \n \n \n \n x\n ^\n \n \n \n −\n x\n \n |\n \n \n \n |\n \n \n p\n \n \n ≤\n ϵ\n \n \n {\\displaystyle \\min _{{\\hat {x}}\\in [0,1]^{d}}L(f({\\hat {x}}),y),{\\text{ s.t. }}||{\\hat {x}}-x||_{p}\\leq \\epsilon }\n \n\nThe result in theory is an adversarial example that is highly confident in the incorrect class but is also very similar to the original image. To find such example, Square Attack utilizes the iterative random search technique to randomly perturb the image in hopes of improving the objective function. In each step, the algorithm perturbs only a small square section of pixels, hence the name Square Attack, which terminates as soon as an adversarial example is found in order to improve query efficiency. Finally, since the attack algorithm uses scores and not gradient information, the authors of the paper indicate that this approach is not affected by gradient masking, a common technique formerly used to prevent evasion attacks.\n\n\nHopSkipJump attack\nThis black box attack was also proposed as a query efficient attack, but one that relies solely on access to any input's predicted output class. In other words, the HopSkipJump attack does not require the ability to calculate gradients or access to score values like the Square Attack, and will require just the model's class prediction output (for any given input). The proposed attack is split into two different settings, targeted and untargeted, but both are built from the general idea of adding minimal perturbations that leads to a different model output. In the targeted setting, the goal is to cause the model to misclassify the perturbed image to a specific target label (that is not the original label). In the untargeted setting, the goal is to cause the model to misclassify the perturbed image to any label that is not the original label. The attack objectives for both are as follows where \n \n \n \n x\n \n \n {\\textstyle x}\n \n is the original image, \n \n \n \n \n x\n \n ′\n \n \n \n \n {\\textstyle x^{\\prime }}\n \n is the adversarial image, \n \n \n \n d\n \n \n {\\textstyle d}\n \n is a distance function between images, \n \n \n \n \n c\n \n ∗\n \n \n \n \n {\\textstyle c^{*}}\n \n is the target label, and \n \n \n \n C\n \n \n {\\textstyle C}\n \n is the model's classification class label function:\n\n \n \n \n \n \n Targeted:\n \n \n \n min\n \n \n x\n \n ′\n \n \n \n \n d\n (\n \n x\n \n ′\n \n \n ,\n x\n )\n \n subject to \n \n C\n (\n \n x\n \n ′\n \n \n )\n =\n \n c\n \n ∗\n \n \n \n \n {\\displaystyle {\\textbf {Targeted:}}\\min _{x^{\\prime }}d(x^{\\prime },x){\\text{ subject to }}C(x^{\\prime })=c^{*}}\n \n\n \n \n \n \n \n Untargeted:\n \n \n \n min\n \n \n x\n \n ′\n \n \n \n \n d\n (\n \n x\n \n ′\n \n \n ,\n x\n )\n \n subject to \n \n C\n (\n \n x\n \n ′\n \n \n )\n ≠\n C\n (\n x\n )\n \n \n {\\displaystyle {\\textbf {Untargeted:}}\\min _{x^{\\prime }}d(x^{\\prime },x){\\text{ subject to }}C(x^{\\prime })\\neq C(x)}\n \n\nTo solve this problem, the attack proposes the following boundary function \n \n \n \n S\n \n \n {\\textstyle S}\n \n for both the untargeted and targeted setting:\n\n \n \n \n S\n (\n \n x\n \n ′\n \n \n )\n :=\n \n \n {\n \n \n \n \n max\n \n c\n ≠\n C\n (\n x\n )\n \n \n \n F\n (\n \n x\n \n ′\n \n \n \n )\n \n c\n \n \n \n −\n F\n (\n \n x\n \n ′\n \n \n \n )\n \n C\n (\n x\n )\n \n \n ,\n \n \n \n (Untargeted)\n \n \n \n \n \n F\n (\n \n x\n \n ′\n \n \n \n )\n \n \n c\n \n ∗\n \n \n \n \n −\n \n max\n \n c\n ≠\n \n c\n \n ∗\n \n \n \n \n \n F\n (\n \n x\n \n ′\n \n \n \n )\n \n c\n \n \n \n ,\n \n \n \n (Targeted)\n \n \n \n \n \n \n \n \n \n {\\displaystyle S(x^{\\prime }):={\\begin{cases}\\max _{c\\neq C(x)}{F(x^{\\prime })_{c}}-F(x^{\\prime })_{C(x)},&{\\text{(Untargeted)}}\\\\F(x^{\\prime })_{c^{*}}-\\max _{c\\neq c^{*}}{F(x^{\\prime })_{c}},&{\\text{(Targeted)}}\\end{cases}}}\n \n\nThis can be further simplified to better visualize the boundary between different potential adversarial examples:\n\n \n \n \n S\n (\n \n x\n \n ′\n \n \n )\n >\n 0\n \n ⟺\n \n \n \n {\n \n \n \n a\n r\n g\n m\n a\n \n x\n \n c\n \n \n F\n (\n \n x\n \n ′\n \n \n )\n ≠\n C\n (\n x\n )\n ,\n \n \n \n (Untargeted)\n \n \n \n \n \n a\n r\n g\n m\n a\n \n x\n \n c\n \n \n F\n (\n \n x\n \n ′\n \n \n )\n =\n \n c\n \n ∗\n \n \n ,\n \n \n \n (Targeted)\n \n \n \n \n \n \n \n \n \n {\\displaystyle S(x^{\\prime })>0\\iff {\\begin{cases}argmax_{c}F(x^{\\prime })\\neq C(x),&{\\text{(Untargeted)}}\\\\argmax_{c}F(x^{\\prime })=c^{*},&{\\text{(Targeted)}}\\end{cases}}}\n \n\nWith this boundary function, the attack then follows an iterative algorithm to find adversarial examples \n \n \n \n \n x\n \n ′\n \n \n \n \n {\\textstyle x^{\\prime }}\n \n for a given image \n \n \n \n x\n \n \n {\\textstyle x}\n \n that satisfies the attack objectives.\n\nInitialize \n \n \n \n x\n \n \n {\\textstyle x}\n \n to some point where \n \n \n \n S\n (\n x\n )\n >\n 0\n \n \n {\\textstyle S(x)>0}\n \n\nIterate below\nBoundary search\nGradient update\nCompute the gradient\nFind the step size\nBoundary search uses a modified binary search to find the point in which the boundary (as defined by \n \n \n \n S\n \n \n {\\textstyle S}\n \n) intersects with the line between \n \n \n \n x\n \n \n {\\textstyle x}\n \n and \n \n \n \n \n x\n \n ′\n \n \n \n \n {\\textstyle x^{\\prime }}\n \n. The next step involves calculating the gradient for \n \n \n \n x\n \n \n {\\textstyle x}\n \n, and update the original \n \n \n \n x\n \n \n {\\textstyle x}\n \n using this gradient and a pre-chosen step size. HopSkipJump authors prove that this iterative algorithm will converge, leading \n \n \n \n x\n \n \n {\\textstyle x}\n \n to a point right along the boundary that is very close in distance to the original image.\nHowever, since HopSkipJump is a proposed black box attack and the iterative algorithm above requires the calculation of a gradient in the second iterative step (which black box attacks do not have access to), the authors propose a solution to gradient calculation that requires only the model's output predictions alone. By generating many random vectors in all directions, denoted as \n \n \n \n \n u\n \n b\n \n \n \n \n {\\textstyle u_{b}}\n \n, an approximation of the gradient can be calculated using the average of these random vectors weighted by the sign of the boundary function on the image \n \n \n \n \n x\n \n ′\n \n \n +\n \n δ\n \n \n u\n \n b\n \n \n \n \n \n \n {\\textstyle x^{\\prime }+\\delta _{u_{b}}}\n \n, where \n \n \n \n \n δ\n \n \n u\n \n b\n \n \n \n \n \n \n {\\textstyle \\delta _{u_{b}}}\n \n is the size of the random vector perturbation:\n\n \n \n \n ∇\n S\n (\n \n x\n \n ′\n \n \n ,\n δ\n )\n ≈\n \n \n 1\n B\n \n \n \n ∑\n \n b\n =\n 1\n \n \n B\n \n \n ϕ\n (\n \n x\n \n ′\n \n \n +\n \n δ\n \n \n u\n \n b\n \n \n \n \n )\n \n u\n \n b\n \n \n \n \n {\\displaystyle \\nabla S(x^{\\prime },\\delta )\\approx {\\frac {1}{B}}\\sum _{b=1}^{B}\\phi (x^{\\prime }+\\delta _{u_{b}})u_{b}}\n \n\nThe result of the equation above gives a close approximation of the gradient required in step 2 of the iterative algorithm, completing HopSkipJump as a black box attack.\n\n\nWhite box attacks\nWhite box attacks assumes that the adversary has access to model parameters on top of being able to get labels for provided inputs.\n\n\nFast gradient sign method\nOne of the first proposed attacks for generating adversarial examples was proposed by Google researchers Ian J. Goodfellow, Jonathon Shlens, and Christian Szegedy. The attack was called fast gradient sign method (FGSM), and it consists of adding a linear amount of in-perceivable noise to the image and causing a model to incorrectly classify it. This noise is calculated by multiplying the sign of the gradient with respect to the image we want to perturb by a small constant epsilon. As epsilon increases, the model is more likely to be fooled, but the perturbations become easier to identify as well. Shown below is the equation to generate an adversarial example where \n \n \n \n x\n \n \n {\\textstyle x}\n \n is the original image, \n \n \n \n ϵ\n \n \n {\\textstyle \\epsilon }\n \n is a very small number, \n \n \n \n \n Δ\n \n x\n \n \n \n \n {\\textstyle \\Delta _{x}}\n \n is the gradient function, \n \n \n \n J\n \n \n {\\textstyle J}\n \n is the loss function, \n \n \n \n θ\n \n \n {\\textstyle \\theta }\n \n is the model weights, and \n \n \n \n y\n \n \n {\\textstyle y}\n \n is the true label.\n\n \n \n \n a\n d\n \n v\n \n x\n \n \n =\n x\n +\n ϵ\n ⋅\n s\n i\n g\n n\n (\n \n Δ\n \n x\n \n \n J\n (\n θ\n ,\n x\n ,\n y\n )\n )\n \n \n {\\displaystyle adv_{x}=x+\\epsilon \\cdot sign(\\Delta _{x}J(\\theta ,x,y))}\n \n\nOne important property of this equation is that the gradient is calculated with respect to the input image since the goal is to generate an image that maximizes the loss for the original image of true label \n \n \n \n y\n \n \n {\\textstyle y}\n \n. In traditional gradient descent (for model training), the gradient is used to update the weights of the model since the goal is to minimize the loss for the model on a ground truth dataset. The Fast Gradient Sign Method was proposed as a fast way to generate adversarial examples to evade the model, based on the hypothesis that neural networks cannot resist even linear amounts of perturbation to the input. FGSM has shown to be effective in adversarial attacks for image classification and skeletal action recognition.\n\n\nCarlini & Wagner\nIn an effort to analyze existing adversarial attacks and defenses, researchers at the University of California, Berkeley, Nicholas Carlini and David Wagner in 2016 propose a faster and more robust method to generate adversarial examples.\nThe attack proposed by Carlini and Wagner begins with trying to solve a difficult non-linear optimization equation:\n\n \n \n \n min\n (\n \n |\n \n \n |\n \n δ\n \n |\n \n \n \n |\n \n \n p\n \n \n )\n \n subject to \n \n C\n (\n x\n +\n δ\n )\n =\n t\n ,\n x\n +\n δ\n ∈\n [\n 0\n ,\n 1\n \n ]\n \n n\n \n \n \n \n {\\displaystyle \\min(||\\delta ||_{p}){\\text{ subject to }}C(x+\\delta )=t,x+\\delta \\in [0,1]^{n}}\n \n\nHere the objective is to minimize the noise (\n \n \n \n δ\n \n \n {\\textstyle \\delta }\n \n), added to the original input \n \n \n \n x\n \n \n {\\textstyle x}\n \n, such that the machine learning algorithm (\n \n \n \n C\n \n \n {\\textstyle C}\n \n) predicts the original input with delta (or \n \n \n \n x\n +\n δ\n \n \n {\\textstyle x+\\delta }\n \n) as some other class \n \n \n \n t\n \n \n {\\textstyle t}\n \n. However instead of directly the above equation, Carlini and Wagner propose using a new function \n \n \n \n f\n \n \n {\\textstyle f}\n \n such that:\n\n \n \n \n C\n (\n x\n +\n δ\n )\n =\n t\n \n ⟺\n \n f\n (\n x\n +\n δ\n )\n ≤\n 0\n \n \n {\\displaystyle C(x+\\delta )=t\\iff f(x+\\delta )\\leq 0}\n \n\nThis condenses the first equation to the problem below:\n\n \n \n \n min\n (\n \n |\n \n \n |\n \n δ\n \n |\n \n \n \n |\n \n \n p\n \n \n )\n \n subject to \n \n f\n (\n x\n +\n δ\n )\n ≤\n 0\n ,\n x\n +\n δ\n ∈\n [\n 0\n ,\n 1\n \n ]\n \n n\n \n \n \n \n {\\displaystyle \\min(||\\delta ||_{p}){\\text{ subject to }}f(x+\\delta )\\leq 0,x+\\delta \\in [0,1]^{n}}\n \n\nand even more to the equation below:\n\n \n \n \n min\n (\n \n |\n \n \n |\n \n δ\n \n |\n \n \n \n |\n \n \n p\n \n \n +\n c\n ⋅\n f\n (\n x\n +\n δ\n )\n )\n ,\n x\n +\n δ\n ∈\n [\n 0\n ,\n 1\n \n ]\n \n n\n \n \n \n \n {\\displaystyle \\min(||\\delta ||_{p}+c\\cdot f(x+\\delta )),x+\\delta \\in [0,1]^{n}}\n \n\nCarlini and Wagner then propose the use of the below function in place of \n \n \n \n f\n \n \n {\\textstyle f}\n \n using \n \n \n \n Z\n \n \n {\\textstyle Z}\n \n, a function that determines class probabilities for given input \n \n \n \n x\n \n \n {\\textstyle x}\n \n. When substituted in, this equation can be thought of as finding a target class that is more confident than the next likeliest class by some constant amount:\n\n \n \n \n f\n (\n x\n )\n =\n (\n [\n \n max\n \n i\n ≠\n t\n \n \n Z\n (\n x\n \n )\n \n i\n \n \n ]\n −\n Z\n (\n x\n \n )\n \n t\n \n \n \n )\n \n +\n \n \n \n \n {\\displaystyle f(x)=([\\max _{i\\neq t}Z(x)_{i}]-Z(x)_{t})^{+}}\n \n\nWhen solved using gradient descent, this equation is able to produce stronger adversarial examples when compared to fast gradient sign method that is also able to bypass defensive distillation, a defense that was once proposed to be effective against adversarial examples.\n\n\nDefenses\n\nResearchers have proposed a multi-step approach to protecting machine learning.\n\nThreat modeling – formalize the attackers goals and capabilities with respect to the target system.\nAttack simulation – formalize the optimization problem the attacker tries to solve according to possible attack strategies.\nAttack impact evaluation\nCountermeasure design\nNoise detection (for evasion-based attack)\nInformation laundering – Alter the information received by adversaries (for model stealing attacks)\n\n\nMechanisms\nA number of defense mechanisms against evasion, poisoning, and privacy attacks have been proposed, including:\n\nSecure learning algorithms\nByzantine-resilient algorithms\nMultiple classifier systems\nAI-written algorithms.\nAIs that explore the training environment; for example, in image recognition, actively navigating a 3D environment rather than passively scanning a fixed set of 2D images.\nPrivacy-preserving learning\nLadder algorithm for Kaggle-style competitions\nGame theoretic models\nSanitizing training data\nAdversarial training\nBackdoor detection algorithms\nGradient masking/obfuscation techniques: to prevent the adversary exploiting the gradient in white-box attacks. This family of defenses is deemed unreliable as these models are still vulnerable to black-box attacks or can be circumvented in other ways.\nEnsembles of models have been proposed in literature, which have shown to be ineffective against evasion attacks but effective against data poisoning attacks.\nMoving target defense\n\n\nSee also\nAnti-computer tactics\nFawkes (image cloaking software)\nPattern recognition\n\n\nReferences\n\n\nExternal links\nMITRE ATLAS: Adversarial Threat Landscape for Artificial-Intelligence Systems\nNIST 8269 Draft: A Taxonomy and Terminology of Adversarial Machine Learning\nLaskov, Pavel; Lippmann, Richard (2010). \"Machine learning in adversarial environments\". Machine Learning. 81 (2): 115–119. doi:10.1007/s10994-010-5207-6. S2CID 12567278.\nWorkshop on Artificial Intelligence and Security, (AISec) Series", "categories": ["AI safety", "All articles with dead external links", "Articles with dead external links from February 2022", "Articles with permanently dead external links", "Articles with short description", "Computer security", "Machine learning", "Short description is different from Wikidata", "Wikipedia articles needing clarification from December 2025"], "references": ["http://pralab.diee.unica.it/en/node/1103", "http://pralab.diee.unica.it/en/node/671", "http://pralab.diee.unica.it/en/node/642", "http://pralab.diee.unica.it/en/node/657", "http://www.stat.purdue.edu/~xbw/research/BoweiXi.AdversarialClassification2010.pdf", "http://cubs.cedar.buffalo.edu/images/pdf/pub/robustness-of-multimodal-biometric-fusion-methods-against-spoof-attacks.pdf", "https://www.microsoft.com/en-us/research/wp-content/uploads/2016/02/DekelShXi09.pdf", "https://www.wired.com/story/ai-has-a-hallucination-problem-thats-proving-tough-to-fix/", "https://link.springer.com/content/pdf/10.1007/s10994-010-5188-5.pdf", "https://link.springer.com/content/pdf/10.1007/s10994-010-5199-2.pdf", "https://www.bbc.com/news/technology-41845878", "https://ui.adsabs.harvard.edu/abs/2019arXiv191013122L", "https://www.wired.com/story/tesla-speed-up-adversarial-example-mgm-breach-ransomware/", "https://www.newyorker.com/magazine/2020/03/16/dressing-for-the-surveillance-age", "https://web.archive.org/web/20180518055115/http://pralab.diee.unica.it/en/node/657"], "images": ["File:AI training data poisoning illustration (Nightshade).png", "File:Proactive arms race.jpg"], "sub_niche": "Adversarial machine learning"} {"title": "Nicholas Carlini", "url": "https://en.wikipedia.org/wiki/Nicholas_Carlini", "summary": "Nicholas Carlini is an American researcher affiliated with Anthropic and previously with Google DeepMind who has published research in the fields of computer security and machine learning. He is known for his work on adversarial machine learning, particularly his work on the Carlini & Wagner attack in 2016. This attack was particularly useful in defeating defensive distillation, a method used to increase model robustness, and has since been effective against other defenses against adversarial input.\nIn 2018, Carlini demonstrated an attack on Mozilla's DeepSpeech model, showing that hidden commands could be embedded in speech inputs, which the model would execute even if they were inaudible to humans. He also led a team at UC Berkeley that successfully broke seven out of nine defenses again", "content": "Nicholas Carlini is an American researcher affiliated with Anthropic and previously with Google DeepMind who has published research in the fields of computer security and machine learning. He is known for his work on adversarial machine learning, particularly his work on the Carlini & Wagner attack in 2016. This attack was particularly useful in defeating defensive distillation, a method used to increase model robustness, and has since been effective against other defenses against adversarial input.\nIn 2018, Carlini demonstrated an attack on Mozilla's DeepSpeech model, showing that hidden commands could be embedded in speech inputs, which the model would execute even if they were inaudible to humans. He also led a team at UC Berkeley that successfully broke seven out of nine defenses against adversarial attacks presented at the 2018 International Conference on Learning Representations. \nIn addition to his work on adversarial attacks, Carlini has made significant contributions to understanding the privacy risks of machine learning models. In 2020, he revealed that large language models, like GPT-2, could memorize and output personally identifiable information. His research demonstrated that this issue worsened with larger models, and he later showed similar vulnerabilities in generative image models, such as Stable Diffusion.\n\n\nLife and career\nNicholas Carlini obtained his Bachelor of Arts in Computer Science and Mathematics from the University of California, Berkeley, in 2013. He then continued his studies at the same university, where he pursued a PhD under the supervision of David Wagner, completing it in 2018. Carlini became known for his work on adversarial machine learning. In 2016, he worked alongside Wagner to develop the Carlini & Wagner attack, a method of generating adversarial examples against machine learning models. The attack was proved to be useful against defensive distillation, a popular mechanism where a student model is trained based on the features of a parent model to increase the robustness and generalizability of student models. The attack gained popularity when it was shown that the methodology was also effective against most other defenses, rendering them ineffective. In 2018, Carlini demonstrated an attack against Mozilla Foundation's DeepSpeech model where he showed that by hiding malicious commands inside normal speech input the speech model would respond to the hidden commands even when the commands were not discernible by humans. In the same year, Carlini and his team at UC Berkeley showed that out of the 11 papers presenting defenses to adversarial attacks accepted in that year's ICLR conference, seven of the defenses could be broken.\nSince 2021, he and his team have been working on large language models, creating a questionnaire where humans typically scored 35% whereas AI models scored in the 40%, with GPT-3 getting 38% which could be improved to 40% through few shot prompting. The best performer in the test was UnifiedQA, a model developed by Google specifically for answer questions and answer sets. Carlini has also developed methods to cause large language models like ChatGPT to answer harmful questions like how to construct bombs.\nHe is also known for his work studying the privacy of machine learning models. In 2020, he showed for the first time that large language models would memorize some of the text data that they were trained on. For example, he found that GPT-2 could output personally identifiable information. He then led an analysis of larger models and studied how memorization increased with model size. Then, in 2022 he showed the same vulnerability in generative image models, and specifically diffusion models, by showing that Stable Diffusion could output images of people's faces that it was trained on. Following on this, Carlini then showed that ChatGPT would also sometimes output exact copies of webpages it was trained on, including personally identifiable information. Some of these studies have since been referenced by the courts in debating the copyright status of AI models.\n\n\nAwards\nBest Student Paper Award, IEEE S&P 2017 (\"Towards Evaluating the Robustness of Neural Networks\")\nBest Paper Award, ICML 2018 (\"Obfuscated Gradients Give a False Sense of Security: Circumventing Defenses to Adversarial Examples\")\nDistinguished Paper Award, USENIX 2021 (\"Poisoning the Unlabeled Dataset of Semi-Supervised Learning\")\nDistinguished Paper Award, USENIX 2023 (\"Tight Auditing of Differentially Private Machine Learning\")\nBest Paper Award, ICML 2024 (\"Stealing Part of a Production Language Model\")\nBest Paper Award, ICML 2024 (\"Considerations for Differentially Private Learning with Large-Scale Public Pretraining\")\nCarlini received the Best of Show award at the 2020 IOCCC for implementing a tic-tac-toe game entirely with calls to printf, expanding on work from a research paper of his from 2015. The judges commented on his submission \"This year's Best of Show (carlini) is such a novel way of obfuscation that it would be worth of a special mention in the (future) Best of IOCCC list!\". [sic]\n\n\nReferences", "categories": ["All Wikipedia articles written in American English", "American computer scientists", "Anthropic people", "Articles with hCards", "Articles with short description", "CS1 maint: periodical has ISBN", "Computer security academics", "Computer security specialists", "Good articles", "Living people", "Machine learning researchers", "Short description is different from Wikidata", "University of California, Berkeley alumni", "Use American English from September 2024", "Use mdy dates from September 2024", "Year of birth missing (living people)"], "references": ["https://nicholas.carlini.com/", "https://aiforgood.itu.int/speaker/nicholas-carlini/", "https://people.eecs.berkeley.edu/~daw/students/", "https://doi.org/10.1109%2FCSR54599.2022.9850306", "https://doi.org/10.1038%2Fd41586-021-00530-0", "https://www.fastcompany.com/90153084/how-to-fool-a-neural-network", "https://www.nytimes.com/2018/05/10/technology/alexa-siri-hidden-command-audio-attacks.html", "https://www.cnet.com/home/smart-home/security-researchers-warn-of-voice-vulnerabilities/", "https://www.wired.com/story/ai-has-a-hallucination-problem-thats-proving-tough-to-fix/", "https://www.nature.com/articles/d41586-021-00530-0", "https://ui.adsabs.harvard.edu/abs/2021Natur.591...22H", "https://pubmed.ncbi.nlm.nih.gov/33658699", "https://www.nytimes.com/2023/07/27/business/ai-chatgpt-safety-research.html", "https://www.wired.com/story/chatgpt-poem-forever-security-roundup/", "https://www.sciencenews.org/article/generative-ai-chatbots-chatgpt-safety-concerns"], "images": ["File:Nicholas Carlini AIME presentation.jpg"], "sub_niche": "Adversarial machine learning"} {"title": "Generative adversarial network", "url": "https://en.wikipedia.org/wiki/Generative_adversarial_network", "summary": "A generative adversarial network (GAN) is a class of machine learning frameworks and a prominent framework for approaching generative AI. The concept was initially developed by Ian Goodfellow and his colleagues in June 2014. In a GAN, two neural networks compete with each other in the form of a zero-sum game, where one agent's gain is another agent's loss.\nGiven a training set, this technique learns to generate new data with the same statistics as the training set. For example, a GAN trained on photographs can generate new photographs that look at least superficially authentic to human observers, having many realistic characteristics. Though originally proposed as a form of generative model for unsupervised learning, GANs have also proved useful for semi-supervised learning, fully supervis", "content": "A generative adversarial network (GAN) is a class of machine learning frameworks and a prominent framework for approaching generative AI. The concept was initially developed by Ian Goodfellow and his colleagues in June 2014. In a GAN, two neural networks compete with each other in the form of a zero-sum game, where one agent's gain is another agent's loss.\nGiven a training set, this technique learns to generate new data with the same statistics as the training set. For example, a GAN trained on photographs can generate new photographs that look at least superficially authentic to human observers, having many realistic characteristics. Though originally proposed as a form of generative model for unsupervised learning, GANs have also proved useful for semi-supervised learning, fully supervised learning, and reinforcement learning.\nThe core idea of a GAN is based on the \"indirect\" training through the discriminator, another neural network that can tell how \"realistic\" the input seems, which itself is also being updated dynamically. This means that the generator is not trained to minimize the distance to a specific image, but rather to fool the discriminator. This enables the model to learn in an unsupervised manner.\nGANs are similar to mimicry in evolutionary biology, with an evolutionary arms race between both networks.\n\n\nDefinition\n\n\nMathematical\nThe original GAN is defined as the following game:\nEach probability space \n \n \n \n (\n Ω\n ,\n \n μ\n \n ref\n \n \n )\n \n \n {\\displaystyle (\\Omega ,\\mu _{\\text{ref}})}\n \n defines a GAN game.\nThere are 2 players: generator and discriminator.\nThe generator's strategy set is \n \n \n \n \n \n P\n \n \n (\n Ω\n )\n \n \n {\\displaystyle {\\mathcal {P}}(\\Omega )}\n \n, the set of all probability measures \n \n \n \n \n μ\n \n G\n \n \n \n \n {\\displaystyle \\mu _{G}}\n \n on \n \n \n \n Ω\n \n \n {\\displaystyle \\Omega }\n \n.\nThe discriminator's strategy set is the set of Markov kernels \n \n \n \n \n μ\n \n D\n \n \n :\n Ω\n →\n \n \n P\n \n \n [\n 0\n ,\n 1\n ]\n \n \n {\\displaystyle \\mu _{D}:\\Omega \\to {\\mathcal {P}}[0,1]}\n \n, where \n \n \n \n \n \n P\n \n \n [\n 0\n ,\n 1\n ]\n \n \n {\\displaystyle {\\mathcal {P}}[0,1]}\n \n is the set of probability measures on \n \n \n \n [\n 0\n ,\n 1\n ]\n \n \n {\\displaystyle [0,1]}\n \n.\nThe GAN game is a zero-sum game, with objective function\n \n \n \n L\n (\n \n μ\n \n G\n \n \n ,\n \n μ\n \n D\n \n \n )\n :=\n \n E\n \n x\n ∼\n \n μ\n \n ref\n \n \n ,\n y\n ∼\n \n μ\n \n D\n \n \n (\n x\n )\n \n \n ⁡\n [\n ln\n ⁡\n y\n ]\n +\n \n E\n \n x\n ∼\n \n μ\n \n G\n \n \n ,\n y\n ∼\n \n μ\n \n D\n \n \n (\n x\n )\n \n \n ⁡\n [\n ln\n ⁡\n (\n 1\n −\n y\n )\n ]\n .\n \n \n {\\displaystyle L(\\mu _{G},\\mu _{D}):=\\operatorname {E} _{x\\sim \\mu _{\\text{ref}},y\\sim \\mu _{D}(x)}[\\ln y]+\\operatorname {E} _{x\\sim \\mu _{G},y\\sim \\mu _{D}(x)}[\\ln(1-y)].}\n \n\nThe generator aims to minimize the objective, and the discriminator aims to maximize the objective.\n\nThe generator's task is to approach \n \n \n \n \n μ\n \n G\n \n \n ≈\n \n μ\n \n ref\n \n \n \n \n {\\displaystyle \\mu _{G}\\approx \\mu _{\\text{ref}}}\n \n, that is, to match its own output distribution as closely as possible to the reference distribution. The discriminator's task is to output a value close to 1 when the input appears to be from the reference distribution, and to output a value close to 0 when the input looks like it came from the generator distribution.\n\n\nIn practice\nThe generative network generates candidates while the discriminative network evaluates them. This creates a contest based on data distributions, where the generator learns to map from a latent space to the true data distribution, aiming to produce candidates that the discriminator cannot distinguish from real data. The discriminator's goal is to correctly identify these candidates, but as the generator improves, its task becomes more challenging, increasing the discriminator's error rate.\nA known dataset serves as the initial training data for the discriminator. Training involves presenting it with samples from the training dataset until it achieves acceptable accuracy. The generator is trained based on whether it succeeds in fooling the discriminator. Typically, the generator is seeded with randomized input that is sampled from a predefined latent space (e.g. a multivariate normal distribution). Thereafter, candidates synthesized by the generator are evaluated by the discriminator. Independent backpropagation procedures are applied to both networks so that the generator produces better samples, while the discriminator becomes more skilled at flagging synthetic samples. When used for image generation, the generator is typically a deconvolutional neural network, and the discriminator is a convolutional neural network.\n\n\nRelation to other statistical machine learning methods\nGANs are implicit generative models, which means that they do not explicitly model the likelihood function nor provide a means for finding the latent variable corresponding to a given sample, unlike alternatives such as flow-based generative model.\n\nCompared to fully visible belief networks such as WaveNet and PixelRNN and autoregressive models in general, GANs can generate one complete sample in one pass, rather than multiple passes through the network.\nCompared to Boltzmann machines and linear ICA, there is no restriction on the type of function used by the network.\nSince neural networks are universal approximators, GANs are asymptotically consistent. As of 2026, variational autoencoders have been proven to be universal approximators.\n\n\nMathematical properties\n\n\nMeasure-theoretic considerations\nThis section provides some of the mathematical theory behind these methods.\n\nIn modern probability theory based on measure theory, a probability space also needs to be equipped with a σ-algebra. As a result, a more rigorous definition of the GAN game would make the following changes:Each probability space \n \n \n \n (\n Ω\n ,\n \n \n B\n \n \n ,\n \n μ\n \n ref\n \n \n )\n \n \n {\\displaystyle (\\Omega ,{\\mathcal {B}},\\mu _{\\text{ref}})}\n \n defines a GAN game.\nThe generator's strategy set is \n \n \n \n \n \n P\n \n \n (\n Ω\n ,\n \n \n B\n \n \n )\n \n \n {\\displaystyle {\\mathcal {P}}(\\Omega ,{\\mathcal {B}})}\n \n, the set of all probability measures \n \n \n \n \n μ\n \n G\n \n \n \n \n {\\displaystyle \\mu _{G}}\n \n on the measure-space \n \n \n \n (\n Ω\n ,\n \n \n B\n \n \n )\n \n \n {\\displaystyle (\\Omega ,{\\mathcal {B}})}\n \n.\n\nThe discriminator's strategy set is the set of Markov kernels \n \n \n \n \n μ\n \n D\n \n \n :\n (\n Ω\n ,\n \n \n B\n \n \n )\n →\n \n \n P\n \n \n (\n [\n 0\n ,\n 1\n ]\n ,\n \n \n B\n \n \n (\n [\n 0\n ,\n 1\n ]\n )\n )\n \n \n {\\displaystyle \\mu _{D}:(\\Omega ,{\\mathcal {B}})\\to {\\mathcal {P}}([0,1],{\\mathcal {B}}([0,1]))}\n \n, where \n \n \n \n \n \n B\n \n \n (\n [\n 0\n ,\n 1\n ]\n )\n \n \n {\\displaystyle {\\mathcal {B}}([0,1])}\n \n is the Borel σ-algebra on \n \n \n \n [\n 0\n ,\n 1\n ]\n \n \n {\\displaystyle [0,1]}\n \n.Since issues of measurability never arise in practice, these will not concern us further.\n\n\nChoice of the strategy set\nIn the most generic version of the GAN game described above, the strategy set for the discriminator contains all Markov kernels \n \n \n \n \n μ\n \n D\n \n \n :\n Ω\n →\n \n \n P\n \n \n [\n 0\n ,\n 1\n ]\n \n \n {\\displaystyle \\mu _{D}:\\Omega \\to {\\mathcal {P}}[0,1]}\n \n, and the strategy set for the generator contains arbitrary probability distributions \n \n \n \n \n μ\n \n G\n \n \n \n \n {\\displaystyle \\mu _{G}}\n \n on \n \n \n \n Ω\n \n \n {\\displaystyle \\Omega }\n \n.\nHowever, as shown below, the optimal discriminator strategy against any \n \n \n \n \n μ\n \n G\n \n \n \n \n {\\displaystyle \\mu _{G}}\n \n is deterministic, so there is no loss of generality in restricting the discriminator's strategies to deterministic functions \n \n \n \n D\n :\n Ω\n →\n [\n 0\n ,\n 1\n ]\n \n \n {\\displaystyle D:\\Omega \\to [0,1]}\n \n. In most applications, \n \n \n \n D\n \n \n {\\displaystyle D}\n \n is a deep neural network function.\nAs for the generator, while \n \n \n \n \n μ\n \n G\n \n \n \n \n {\\displaystyle \\mu _{G}}\n \n could theoretically be any computable probability distribution, in practice, it is usually implemented as a pushforward: \n \n \n \n \n μ\n \n G\n \n \n =\n \n μ\n \n Z\n \n \n ∘\n \n G\n \n −\n 1\n \n \n \n \n {\\displaystyle \\mu _{G}=\\mu _{Z}\\circ G^{-1}}\n \n. That is, start with a random variable \n \n \n \n z\n ∼\n \n μ\n \n Z\n \n \n \n \n {\\displaystyle z\\sim \\mu _{Z}}\n \n, where \n \n \n \n \n μ\n \n Z\n \n \n \n \n {\\displaystyle \\mu _{Z}}\n \n is a probability distribution that is easy to compute (such as the uniform distribution, or the Gaussian distribution), then define a function \n \n \n \n G\n :\n \n Ω\n \n Z\n \n \n →\n Ω\n \n \n {\\displaystyle G:\\Omega _{Z}\\to \\Omega }\n \n. Then the distribution \n \n \n \n \n μ\n \n G\n \n \n \n \n {\\displaystyle \\mu _{G}}\n \n is the distribution of \n \n \n \n G\n (\n z\n )\n \n \n {\\displaystyle G(z)}\n \n.\nConsequently, the generator's strategy is usually defined as just \n \n \n \n G\n \n \n {\\displaystyle G}\n \n, leaving \n \n \n \n z\n ∼\n \n μ\n \n Z\n \n \n \n \n {\\displaystyle z\\sim \\mu _{Z}}\n \n implicit. In this formalism, the GAN game objective is\n \n \n \n L\n (\n G\n ,\n D\n )\n :=\n \n E\n \n x\n ∼\n \n μ\n \n ref\n \n \n \n \n ⁡\n [\n ln\n ⁡\n D\n (\n x\n )\n ]\n +\n \n E\n \n z\n ∼\n \n μ\n \n Z\n \n \n \n \n ⁡\n [\n ln\n ⁡\n (\n 1\n −\n D\n (\n G\n (\n z\n )\n )\n )\n ]\n .\n \n \n {\\displaystyle L(G,D):=\\operatorname {E} _{x\\sim \\mu _{\\text{ref}}}[\\ln D(x)]+\\operatorname {E} _{z\\sim \\mu _{Z}}[\\ln(1-D(G(z)))].}\n \n\n\nGenerative reparametrization\nThe GAN architecture has two main components. One is casting optimization into a game, of form \n \n \n \n \n min\n \n G\n \n \n \n max\n \n D\n \n \n L\n (\n G\n ,\n D\n )\n \n \n {\\displaystyle \\min _{G}\\max _{D}L(G,D)}\n \n, which is different from the usual kind of optimization, of form \n \n \n \n \n min\n \n θ\n \n \n L\n (\n θ\n )\n \n \n {\\displaystyle \\min _{\\theta }L(\\theta )}\n \n. The other is the decomposition of \n \n \n \n \n μ\n \n G\n \n \n \n \n {\\displaystyle \\mu _{G}}\n \n into \n \n \n \n \n μ\n \n Z\n \n \n ∘\n \n G\n \n −\n 1\n \n \n \n \n {\\displaystyle \\mu _{Z}\\circ G^{-1}}\n \n, which can be understood as a reparametrization trick.\nTo see its significance, one must compare GAN with previous methods for learning generative models, which were plagued with \"intractable probabilistic computations that arise in maximum likelihood estimation and related strategies\".\nAt the same time, Kingma and Welling and Rezende et al. developed the same idea of reparametrization into a general stochastic backpropagation method. Among its first applications was the variational autoencoder.\n\n\nMove order and strategic equilibria\nIn the original paper, as well as most subsequent papers, it is usually assumed that the generator moves first, and the discriminator moves second, thus giving the following minimax game:\n \n \n \n \n min\n \n \n μ\n \n G\n \n \n \n \n \n max\n \n \n μ\n \n D\n \n \n \n \n L\n (\n \n μ\n \n G\n \n \n ,\n \n μ\n \n D\n \n \n )\n :=\n \n E\n \n x\n ∼\n \n μ\n \n ref\n \n \n ,\n y\n ∼\n \n μ\n \n D\n \n \n (\n x\n )\n \n \n ⁡\n [\n ln\n ⁡\n y\n ]\n +\n \n E\n \n x\n ∼\n \n μ\n \n G\n \n \n ,\n y\n ∼\n \n μ\n \n D\n \n \n (\n x\n )\n \n \n ⁡\n [\n ln\n ⁡\n (\n 1\n −\n y\n )\n ]\n .\n \n \n {\\displaystyle \\min _{\\mu _{G}}\\max _{\\mu _{D}}L(\\mu _{G},\\mu _{D}):=\\operatorname {E} _{x\\sim \\mu _{\\text{ref}},y\\sim \\mu _{D}(x)}[\\ln y]+\\operatorname {E} _{x\\sim \\mu _{G},y\\sim \\mu _{D}(x)}[\\ln(1-y)].}\n \n\nIf both the generator's and the discriminator's strategy sets are spanned by a finite number of strategies, then by the minimax theorem,\n \n \n \n \n min\n \n \n μ\n \n G\n \n \n \n \n \n max\n \n \n μ\n \n D\n \n \n \n \n L\n (\n \n μ\n \n G\n \n \n ,\n \n μ\n \n D\n \n \n )\n =\n \n max\n \n \n μ\n \n D\n \n \n \n \n \n min\n \n \n μ\n \n G\n \n \n \n \n L\n (\n \n μ\n \n G\n \n \n ,\n \n μ\n \n D\n \n \n )\n \n \n {\\displaystyle \\min _{\\mu _{G}}\\max _{\\mu _{D}}L(\\mu _{G},\\mu _{D})=\\max _{\\mu _{D}}\\min _{\\mu _{G}}L(\\mu _{G},\\mu _{D})}\n \nthat is, the move order does not matter.\nHowever, since the strategy sets are both not finitely spanned, the minimax theorem does not apply, and the idea of an \"equilibrium\" becomes delicate. To wit, there are the following different concepts of equilibrium:\n\nEquilibrium when generator moves first, and discriminator moves second:\n \n \n \n \n \n \n \n μ\n ^\n \n \n \n \n G\n \n \n ∈\n arg\n ⁡\n \n min\n \n \n μ\n \n G\n \n \n \n \n \n max\n \n \n μ\n \n D\n \n \n \n \n L\n (\n \n μ\n \n G\n \n \n ,\n \n μ\n \n D\n \n \n )\n ,\n \n \n \n \n \n μ\n ^\n \n \n \n \n D\n \n \n ∈\n arg\n ⁡\n \n max\n \n \n μ\n \n D\n \n \n \n \n L\n (\n \n \n \n \n μ\n ^\n \n \n \n \n G\n \n \n ,\n \n μ\n \n D\n \n \n )\n ,\n \n \n \n {\\displaystyle {\\hat {\\mu }}_{G}\\in \\arg \\min _{\\mu _{G}}\\max _{\\mu _{D}}L(\\mu _{G},\\mu _{D}),\\quad {\\hat {\\mu }}_{D}\\in \\arg \\max _{\\mu _{D}}L({\\hat {\\mu }}_{G},\\mu _{D}),\\quad }\n \n\nEquilibrium when discriminator moves first, and generator moves second:\n \n \n \n \n \n \n \n μ\n ^\n \n \n \n \n D\n \n \n ∈\n arg\n ⁡\n \n max\n \n \n μ\n \n D\n \n \n \n \n \n min\n \n \n μ\n \n G\n \n \n \n \n L\n (\n \n μ\n \n G\n \n \n ,\n \n μ\n \n D\n \n \n )\n ,\n \n \n \n \n \n μ\n ^\n \n \n \n \n G\n \n \n ∈\n arg\n ⁡\n \n min\n \n \n μ\n \n G\n \n \n \n \n L\n (\n \n μ\n \n G\n \n \n ,\n \n \n \n \n μ\n ^\n \n \n \n \n D\n \n \n )\n ,\n \n \n {\\displaystyle {\\hat {\\mu }}_{D}\\in \\arg \\max _{\\mu _{D}}\\min _{\\mu _{G}}L(\\mu _{G},\\mu _{D}),\\quad {\\hat {\\mu }}_{G}\\in \\arg \\min _{\\mu _{G}}L(\\mu _{G},{\\hat {\\mu }}_{D}),}\n \n\nNash equilibrium \n \n \n \n (\n \n \n \n \n μ\n ^\n \n \n \n \n D\n \n \n ,\n \n \n \n \n μ\n ^\n \n \n \n \n G\n \n \n )\n \n \n {\\displaystyle ({\\hat {\\mu }}_{D},{\\hat {\\mu }}_{G})}\n \n, which is stable under simultaneous move order:\n \n \n \n \n \n \n \n μ\n ^\n \n \n \n \n D\n \n \n ∈\n arg\n ⁡\n \n max\n \n \n μ\n \n D\n \n \n \n \n L\n (\n \n \n \n \n μ\n ^\n \n \n \n \n G\n \n \n ,\n \n μ\n \n D\n \n \n )\n ,\n \n \n \n \n \n μ\n ^\n \n \n \n \n G\n \n \n ∈\n arg\n ⁡\n \n min\n \n \n μ\n \n G\n \n \n \n \n L\n (\n \n μ\n \n G\n \n \n ,\n \n \n \n \n μ\n ^\n \n \n \n \n D\n \n \n )\n \n \n {\\displaystyle {\\hat {\\mu }}_{D}\\in \\arg \\max _{\\mu _{D}}L({\\hat {\\mu }}_{G},\\mu _{D}),\\quad {\\hat {\\mu }}_{G}\\in \\arg \\min _{\\mu _{G}}L(\\mu _{G},{\\hat {\\mu }}_{D})}\n \n\nFor general games, these equilibria do not have to agree, or even to exist. For the original GAN game, these equilibria all exist, and are all equal. However, for more general GAN games, these do not necessarily exist, or agree.\n\n\nMain theorems for GAN game\nThe original GAN paper proved the density-based optimal-discriminator formula and global minimax optimum. A measure-theoretic treatment gives the same binary adversarial calculation using Radon–Nikodym derivatives.\nInterpretation: For any fixed generator strategy \n \n \n \n \n μ\n \n G\n \n \n \n \n {\\displaystyle \\mu _{G}}\n \n, the optimal discriminator keeps track of the likelihood ratio between the reference distribution and the generator distribution. Since \n \n \n \n \n D\n \n ∗\n \n \n =\n \n ρ\n \n ref\n \n \n \n \n {\\displaystyle D^{*}=\\rho _{\\text{ref}}}\n \n and \n \n \n \n 1\n −\n \n D\n \n ∗\n \n \n =\n \n ρ\n \n G\n \n \n \n \n {\\displaystyle 1-D^{*}=\\rho _{G}}\n \n,\n\n \n \n \n \n \n \n \n D\n \n ∗\n \n \n (\n x\n )\n \n \n 1\n −\n \n D\n \n ∗\n \n \n (\n x\n )\n \n \n \n =\n \n \n \n \n ρ\n \n ref\n \n \n (\n x\n )\n \n \n \n ρ\n \n G\n \n \n (\n x\n )\n \n \n \n \n μ\n \n -almost everywhere on \n \n {\n \n ρ\n \n G\n \n \n >\n 0\n }\n .\n \n \n {\\displaystyle {\\frac {D^{*}(x)}{1-D^{*}(x)}}={\\frac {\\rho _{\\text{ref}}(x)}{\\rho _{G}(x)}}\\quad \\mu {\\text{-almost everywhere on }}\\{\\rho _{G}>0\\}.}\n \n\nOn \n \n \n \n {\n \n ρ\n \n G\n \n \n =\n 0\n }\n \n \n {\\displaystyle \\{\\rho _{G}=0\\}}\n \n, \n \n \n \n \n D\n \n ∗\n \n \n =\n 1\n \n \n {\\displaystyle D^{*}=1}\n \n; on \n \n \n \n {\n \n ρ\n \n ref\n \n \n =\n 0\n }\n \n \n {\\displaystyle \\{\\rho _{\\text{ref}}=0\\}}\n \n, \n \n \n \n \n D\n \n ∗\n \n \n =\n 0\n \n \n {\\displaystyle D^{*}=0}\n \n, in each case \n \n \n \n μ\n \n \n {\\displaystyle \\mu }\n \n-almost everywhere. If \n \n \n \n \n μ\n \n ref\n \n \n ≪\n \n μ\n \n G\n \n \n \n \n {\\displaystyle \\mu _{\\text{ref}}\\ll \\mu _{G}}\n \n, the displayed ratio is a version of \n \n \n \n d\n \n μ\n \n ref\n \n \n \n /\n \n d\n \n μ\n \n G\n \n \n \n \n {\\displaystyle d\\mu _{\\text{ref}}/d\\mu _{G}}\n \n \n \n \n \n \n μ\n \n G\n \n \n \n \n {\\displaystyle \\mu _{G}}\n \n-almost everywhere. Where both densities are positive,\n\n \n \n \n \n D\n \n ∗\n \n \n (\n x\n )\n =\n σ\n \n (\n \n ln\n ⁡\n \n ρ\n \n ref\n \n \n (\n x\n )\n −\n ln\n ⁡\n \n ρ\n \n G\n \n \n (\n x\n )\n \n )\n \n \n μ\n \n -almost everywhere\n \n ,\n \n \n {\\displaystyle D^{*}(x)=\\sigma \\left(\\ln \\rho _{\\text{ref}}(x)-\\ln \\rho _{G}(x)\\right)\\quad \\mu {\\text{-almost everywhere}},}\n \n\nwhere \n \n \n \n σ\n \n \n {\\displaystyle \\sigma }\n \n is the logistic function.\nIn the equal-prior mixture model \n \n \n \n M\n =\n (\n \n μ\n \n ref\n \n \n +\n \n μ\n \n G\n \n \n )\n \n /\n \n 2\n \n \n {\\displaystyle M=(\\mu _{\\text{ref}}+\\mu _{G})/2}\n \n, \n \n \n \n \n D\n \n ∗\n \n \n \n \n {\\displaystyle D^{*}}\n \n is a version of the posterior probability that an observation came from the reference distribution, \n \n \n \n M\n \n \n {\\displaystyle M}\n \n-almost everywhere.\n\n\nTraining and evaluating GAN\n\n\nTraining\n\n\nUnstable convergence\nWhile the GAN game has a unique global equilibrium point when both the generator and discriminator have access to their entire strategy sets, the equilibrium is no longer guaranteed when they have a restricted strategy set.\nIn practice, the generator has access only to measures of form \n \n \n \n \n μ\n \n Z\n \n \n ∘\n \n G\n \n θ\n \n \n −\n 1\n \n \n \n \n {\\displaystyle \\mu _{Z}\\circ G_{\\theta }^{-1}}\n \n, where \n \n \n \n \n G\n \n θ\n \n \n \n \n {\\displaystyle G_{\\theta }}\n \n is a function computed by a neural network with parameters \n \n \n \n θ\n \n \n {\\displaystyle \\theta }\n \n, and \n \n \n \n \n μ\n \n Z\n \n \n \n \n {\\displaystyle \\mu _{Z}}\n \n is an easily sampled distribution, such as the uniform or normal distribution. Similarly, the discriminator has access only to functions of form \n \n \n \n \n D\n \n ζ\n \n \n \n \n {\\displaystyle D_{\\zeta }}\n \n, a function computed by a neural network with parameters \n \n \n \n ζ\n \n \n {\\displaystyle \\zeta }\n \n. These restricted strategy sets take up a vanishingly small proportion of their entire strategy sets.\nFurther, even if an equilibrium still exists, it can only be found by searching in the high-dimensional space of all possible neural network functions. The standard strategy of using gradient descent to find the equilibrium often does not work for GAN, and often the game \"collapses\" into one of several failure modes. To improve the convergence stability, some training strategies start with an easier task, such as generating low-resolution images or simple images (one object with uniform background), and gradually increase the difficulty of the task during training. This essentially translates to applying a curriculum learning scheme.\n\n\nMode collapse\n\nGANs often suffer from mode collapse where they fail to generalize properly, missing entire modes from the input data. For example, a GAN trained on the MNIST dataset containing many samples of each digit might only generate pictures of digit 0. This was termed \"the Helvetica scenario\".\nA typical mechanism for mode collapse is the generator only generating one or a few of the likely values, or a very incomplete picture of the target distribution. As the discriminator is only trained to distinguish real from fake samples, it will correctly identify the generated samples as real, but no penalty is imposed on the GAN's ability to generate data that represents the full range of the target distribution.\nWeak discriminators, for instance underparametrized ones, or ones trained too slow compared to the generator, may as well be unable to fully discriminate over the entire support of the distribution, and only become able to correctly discriminate a very incomplete part of the target distribution.\nSome researchers perceive the root problem to be a weak discriminative network that fails to notice the pattern of omission, while others assign blame to a bad choice of objective function. Many solutions have been proposed, but it is still an open problem.\nEven the state-of-the-art architecture, BigGAN (2019), could not avoid mode collapse. The authors resorted to \"allowing collapse to occur at the later stages of training, by which time a model is sufficiently trained to achieve good results\".\n\n\nTwo time-scale update rule\nThe two time-scale update rule (TTUR) is proposed to make GAN convergence more stable by making the learning rate of the generator lower than that of the discriminator. They prove that when trained this way, GANs \"converge, under mild assumptions to a stationary local Nash equilibrium\". They further show that this property extends to the use of the Adam optimizer, which is commonly used in stochastic gradient descent.\nA local Nash equilibrium in no way signifies an absence of mode collapse - for instance, a GAN trained on MNIST collapsed to generating a single digit may satisfy the hypotheses of the paper, while still presenting mode collapse.\n\n\nVanishing gradient\nConversely, if the discriminator learns too fast compared to the generator, then the discriminator could almost perfectly distinguish \n \n \n \n \n μ\n \n \n G\n \n θ\n \n \n \n \n ,\n \n μ\n \n ref\n \n \n \n \n {\\displaystyle \\mu _{G_{\\theta }},\\mu _{\\text{ref}}}\n \n. In such case, the generator \n \n \n \n \n G\n \n θ\n \n \n \n \n {\\displaystyle G_{\\theta }}\n \n could be stuck with a very high loss no matter which direction it changes its \n \n \n \n θ\n \n \n {\\displaystyle \\theta }\n \n, meaning that the gradient \n \n \n \n \n ∇\n \n θ\n \n \n L\n (\n \n G\n \n θ\n \n \n ,\n \n D\n \n ζ\n \n \n )\n \n \n {\\displaystyle \\nabla _{\\theta }L(G_{\\theta },D_{\\zeta })}\n \n would be close to zero. In such case, the generator cannot learn, a case of the vanishing gradient problem.\nIntuitively speaking, the discriminator is too good, and since the generator cannot take any small step (only small steps are considered in gradient descent) to improve its payoff, it does not even try.\nOne important method for solving this problem is the Wasserstein GAN.\n\n\nEvaluation\nGANs are usually evaluated by Inception score (IS), which measures how varied the generator's outputs are (as classified by an image classifier, usually Inception-v3), or Fréchet inception distance (FID), which measures how similar the generator's outputs are to a reference set (as classified by a learned image featurizer, such as Inception-v3 without its final layer). Many papers that propose new GAN architectures for image generation report how their architectures break the state of the art on FID or IS.\nAnother evaluation method is the Learned Perceptual Image Patch Similarity (LPIPS), which starts with a learned image featurizer \n \n \n \n \n f\n \n θ\n \n \n :\n \n Image\n \n →\n \n \n R\n \n \n n\n \n \n \n \n {\\displaystyle f_{\\theta }:{\\text{Image}}\\to \\mathbb {R} ^{n}}\n \n, and finetunes it by supervised learning on a set of \n \n \n \n (\n x\n ,\n \n x\n ′\n \n ,\n \n p\n e\n r\n c\n e\n p\n t\n u\n a\n l\n \n d\n i\n f\n f\n e\n r\n e\n n\n c\n e\n \n ⁡\n (\n x\n ,\n \n x\n ′\n \n )\n )\n \n \n {\\displaystyle (x,x',\\operatorname {perceptual~difference} (x,x'))}\n \n, where \n \n \n \n x\n \n \n {\\displaystyle x}\n \n is an image, \n \n \n \n \n x\n ′\n \n \n \n {\\displaystyle x'}\n \n is a perturbed version of it, and \n \n \n \n \n p\n e\n r\n c\n e\n p\n t\n u\n a\n l\n \n d\n i\n f\n f\n e\n r\n e\n n\n c\n e\n \n ⁡\n (\n x\n ,\n \n x\n ′\n \n )\n \n \n {\\displaystyle \\operatorname {perceptual~difference} (x,x')}\n \n is how much they differ, as reported by human subjects. The model is finetuned so that it can approximate \n \n \n \n ‖\n \n f\n \n θ\n \n \n (\n x\n )\n −\n \n f\n \n θ\n \n \n (\n \n x\n ′\n \n )\n ‖\n ≈\n \n p\n e\n r\n c\n e\n p\n t\n u\n a\n l\n \n d\n i\n f\n f\n e\n r\n e\n n\n c\n e\n \n ⁡\n (\n x\n ,\n \n x\n ′\n \n )\n \n \n {\\displaystyle \\|f_{\\theta }(x)-f_{\\theta }(x')\\|\\approx \\operatorname {perceptual~difference} (x,x')}\n \n. This finetuned model is then used to define \n \n \n \n LPIPS\n ⁡\n (\n x\n ,\n \n x\n ′\n \n )\n :=\n ‖\n \n f\n \n θ\n \n \n (\n x\n )\n −\n \n f\n \n θ\n \n \n (\n \n x\n ′\n \n )\n ‖\n \n \n {\\displaystyle \\operatorname {LPIPS} (x,x'):=\\|f_{\\theta }(x)-f_{\\theta }(x')\\|}\n \n.\nOther evaluation methods are reviewed in.\n\n\nVariants\nThere is a veritable zoo of GAN variants. Some of the most prominent are as follows:\n\n\nConditional GAN\nConditional GANs are similar to standard GANs except they allow the model to conditionally generate samples based on additional information. For example, if we want to generate a cat face given a dog picture, we could use a conditional GAN.\nThe generator in a GAN game generates \n \n \n \n \n μ\n \n G\n \n \n \n \n {\\displaystyle \\mu _{G}}\n \n, a probability distribution on the probability space \n \n \n \n Ω\n \n \n {\\displaystyle \\Omega }\n \n. This leads to the idea of a conditional GAN, where instead of generating one probability distribution on \n \n \n \n Ω\n \n \n {\\displaystyle \\Omega }\n \n, the generator generates a different probability distribution \n \n \n \n \n μ\n \n G\n \n \n (\n c\n )\n \n \n {\\displaystyle \\mu _{G}(c)}\n \n on \n \n \n \n Ω\n \n \n {\\displaystyle \\Omega }\n \n, for each given class label \n \n \n \n c\n \n \n {\\displaystyle c}\n \n.\nFor example, for generating images that look like ImageNet, the generator should be able to generate a picture of cat when given the class label \"cat\".\nIn the original paper, the authors noted that GAN can be trivially extended to conditional GAN by providing the labels to both the generator and the discriminator.\nConcretely, the conditional GAN game is just the GAN game with class labels provided:\n \n \n \n L\n (\n \n μ\n \n G\n \n \n ,\n D\n )\n :=\n \n E\n \n c\n ∼\n \n μ\n \n C\n \n \n ,\n x\n ∼\n \n μ\n \n ref\n \n \n (\n c\n )\n \n \n ⁡\n [\n ln\n ⁡\n D\n (\n x\n ,\n c\n )\n ]\n +\n \n E\n \n c\n ∼\n \n μ\n \n C\n \n \n ,\n x\n ∼\n \n μ\n \n G\n \n \n (\n c\n )\n \n \n ⁡\n [\n ln\n ⁡\n (\n 1\n −\n D\n (\n x\n ,\n c\n )\n )\n ]\n \n \n {\\displaystyle L(\\mu _{G},D):=\\operatorname {E} _{c\\sim \\mu _{C},x\\sim \\mu _{\\text{ref}}(c)}[\\ln D(x,c)]+\\operatorname {E} _{c\\sim \\mu _{C},x\\sim \\mu _{G}(c)}[\\ln(1-D(x,c))]}\n \nwhere \n \n \n \n \n μ\n \n C\n \n \n \n \n {\\displaystyle \\mu _{C}}\n \n is a probability distribution over classes, \n \n \n \n \n μ\n \n ref\n \n \n (\n c\n )\n \n \n {\\displaystyle \\mu _{\\text{ref}}(c)}\n \n is the probability distribution of real images of class \n \n \n \n c\n \n \n {\\displaystyle c}\n \n, and \n \n \n \n \n μ\n \n G\n \n \n (\n c\n )\n \n \n {\\displaystyle \\mu _{G}(c)}\n \n the probability distribution of images generated by the generator when given class label \n \n \n \n c\n \n \n {\\displaystyle c}\n \n.\nIn 2017, a conditional GAN learned to generate 1000 image classes of ImageNet.\n\n\nGANs with alternative architectures\nThe GAN game is a general framework and can be run with any reasonable parametrization of the generator \n \n \n \n G\n \n \n {\\displaystyle G}\n \n and discriminator \n \n \n \n D\n \n \n {\\displaystyle D}\n \n. In the original paper, the authors demonstrated it using multilayer perceptron networks and convolutional neural networks. Many alternative architectures have been tried.\nDeep convolutional GAN (DCGAN): For both generator and discriminator, uses only deep networks consisting entirely of convolution-deconvolution layers, that is, fully convolutional networks.\nSelf-attention GAN (SAGAN): Starts with the DCGAN, then adds residually-connected standard self-attention modules to the generator and discriminator.\nVariational autoencoder GAN (VAEGAN): Uses a variational autoencoder (VAE) for the generator.\nTransformer GAN (TransGAN): Uses the pure transformer architecture for both the generator and discriminator, entirely devoid of convolution-deconvolution layers.\nFlow-GAN: Uses flow-based generative model for the generator, allowing efficient computation of the likelihood function.\n\n\nGANs with alternative objectives\nMany GAN variants are merely obtained by changing the loss functions for the generator and discriminator.\nOriginal GAN:\nWe recast the original GAN objective into a form more convenient for comparison:\n \n \n \n \n \n {\n \n \n \n \n min\n \n D\n \n \n \n L\n \n D\n \n \n (\n D\n ,\n \n μ\n \n G\n \n \n )\n =\n −\n \n E\n \n x\n ∼\n \n μ\n \n G\n \n \n \n \n ⁡\n [\n ln\n ⁡\n D\n (\n x\n )\n ]\n −\n \n E\n \n x\n ∼\n \n μ\n \n ref\n \n \n \n \n ⁡\n [\n ln\n ⁡\n (\n 1\n −\n D\n (\n x\n )\n )\n ]\n \n \n \n \n \n min\n \n G\n \n \n \n L\n \n G\n \n \n (\n D\n ,\n \n μ\n \n G\n \n \n )\n =\n −\n \n E\n \n x\n ∼\n \n μ\n \n G\n \n \n \n \n ⁡\n [\n ln\n ⁡\n (\n 1\n −\n D\n (\n x\n )\n )\n ]\n \n \n \n \n \n \n \n \n {\\displaystyle {\\begin{cases}\\min _{D}L_{D}(D,\\mu _{G})=-\\operatorname {E} _{x\\sim \\mu _{G}}[\\ln D(x)]-\\operatorname {E} _{x\\sim \\mu _{\\text{ref}}}[\\ln(1-D(x))]\\\\\\min _{G}L_{G}(D,\\mu _{G})=-\\operatorname {E} _{x\\sim \\mu _{G}}[\\ln(1-D(x))]\\end{cases}}}\n \n\nOriginal GAN, non-saturating loss:\nThis objective for generator was recommended in the original paper for faster convergence.\n \n \n \n \n L\n \n G\n \n \n =\n \n E\n \n x\n ∼\n \n μ\n \n G\n \n \n \n \n ⁡\n [\n ln\n ⁡\n D\n (\n x\n )\n ]\n \n \n {\\displaystyle L_{G}=\\operatorname {E} _{x\\sim \\mu _{G}}[\\ln D(x)]}\n \nThe effect of using this objective is analyzed in Section 2.2.2 of Arjovsky et al.\nOriginal GAN, maximum likelihood:\n\n \n \n \n \n L\n \n G\n \n \n =\n \n E\n \n x\n ∼\n \n μ\n \n G\n \n \n \n \n ⁡\n [\n (\n \n exp\n \n ∘\n \n σ\n \n −\n 1\n \n \n ∘\n D\n )\n (\n x\n )\n ]\n \n \n {\\displaystyle L_{G}=\\operatorname {E} _{x\\sim \\mu _{G}}[({\\exp }\\circ \\sigma ^{-1}\\circ D)(x)]}\n \nwhere \n \n \n \n σ\n \n \n {\\displaystyle \\sigma }\n \n is the logistic function. When the discriminator is optimal, the generator gradient is the same as in maximum likelihood estimation, even though GAN cannot perform maximum likelihood estimation itself.\nHinge loss GAN:\n \n \n \n \n L\n \n D\n \n \n =\n −\n \n E\n \n x\n ∼\n \n p\n \n ref\n \n \n \n \n ⁡\n \n [\n \n min\n \n (\n \n 0\n ,\n −\n 1\n +\n D\n (\n x\n )\n \n )\n \n \n ]\n \n −\n \n E\n \n x\n ∼\n \n μ\n \n G\n \n \n \n \n ⁡\n \n [\n \n min\n \n (\n \n 0\n ,\n −\n 1\n −\n D\n \n (\n x\n )\n \n \n )\n \n \n ]\n \n \n \n {\\displaystyle L_{D}=-\\operatorname {E} _{x\\sim p_{\\text{ref}}}\\left[\\min \\left(0,-1+D(x)\\right)\\right]-\\operatorname {E} _{x\\sim \\mu _{G}}\\left[\\min \\left(0,-1-D\\left(x\\right)\\right)\\right]}\n \n\n \n \n \n \n L\n \n G\n \n \n =\n −\n \n E\n \n x\n ∼\n \n μ\n \n G\n \n \n \n \n ⁡\n [\n D\n (\n x\n )\n ]\n \n \n {\\displaystyle L_{G}=-\\operatorname {E} _{x\\sim \\mu _{G}}[D(x)]}\n \nLeast squares GAN:\n \n \n \n \n L\n \n D\n \n \n =\n \n E\n \n x\n ∼\n \n μ\n \n ref\n \n \n \n \n ⁡\n [\n (\n D\n (\n x\n )\n −\n b\n \n )\n \n 2\n \n \n ]\n +\n \n E\n \n x\n ∼\n \n μ\n \n G\n \n \n \n \n ⁡\n [\n (\n D\n (\n x\n )\n −\n a\n \n )\n \n 2\n \n \n ]\n \n \n {\\displaystyle L_{D}=\\operatorname {E} _{x\\sim \\mu _{\\text{ref}}}[(D(x)-b)^{2}]+\\operatorname {E} _{x\\sim \\mu _{G}}[(D(x)-a)^{2}]}\n \n\n \n \n \n \n L\n \n G\n \n \n =\n \n E\n \n x\n ∼\n \n μ\n \n G\n \n \n \n \n ⁡\n [\n (\n D\n (\n x\n )\n −\n c\n \n )\n \n 2\n \n \n ]\n \n \n {\\displaystyle L_{G}=\\operatorname {E} _{x\\sim \\mu _{G}}[(D(x)-c)^{2}]}\n \nwhere \n \n \n \n a\n ,\n b\n ,\n c\n \n \n {\\displaystyle a,b,c}\n \n are parameters to be chosen. The authors recommended \n \n \n \n a\n =\n −\n 1\n ,\n b\n =\n 1\n ,\n c\n =\n 0\n \n \n {\\displaystyle a=-1,b=1,c=0}\n \n.\n\n\nWasserstein GAN (WGAN)\n\nThe Wasserstein GAN modifies the GAN game at two points:\n\nThe discriminator's strategy set is the set of measurable functions of type \n \n \n \n D\n :\n Ω\n →\n \n R\n \n \n \n {\\displaystyle D:\\Omega \\to \\mathbb {R} }\n \n with bounded Lipschitz norm: \n \n \n \n ‖\n D\n \n ‖\n \n L\n \n \n ≤\n K\n \n \n {\\displaystyle \\|D\\|_{L}\\leq K}\n \n, where \n \n \n \n K\n \n \n {\\displaystyle K}\n \n is a fixed positive constant.\nThe objective is\n \n \n \n \n L\n \n W\n G\n A\n N\n \n \n (\n \n μ\n \n G\n \n \n ,\n D\n )\n :=\n \n E\n \n x\n ∼\n \n μ\n \n G\n \n \n \n \n ⁡\n [\n D\n (\n x\n )\n ]\n −\n \n \n E\n \n \n x\n ∼\n \n μ\n \n ref\n \n \n \n \n [\n D\n (\n x\n )\n ]\n \n \n {\\displaystyle L_{WGAN}(\\mu _{G},D):=\\operatorname {E} _{x\\sim \\mu _{G}}[D(x)]-\\mathbb {E} _{x\\sim \\mu _{\\text{ref}}}[D(x)]}\n \n\nOne of its purposes is to solve the problem of mode collapse (see above). The authors claim \"In no experiment did we see evidence of mode collapse for the WGAN algorithm\".\n\n\nGANs with more than two players\n\n\nAdversarial autoencoder\nAn adversarial autoencoder (AAE) is more autoencoder than GAN. The idea is to start with a plain autoencoder, but train a discriminator to discriminate the latent vectors from a reference distribution (often the normal distribution).\n\n\nInfoGAN\nIn conditional GAN, the generator receives both a noise vector \n \n \n \n z\n \n \n {\\displaystyle z}\n \n and a label \n \n \n \n c\n \n \n {\\displaystyle c}\n \n, and produces an image \n \n \n \n G\n (\n z\n ,\n c\n )\n \n \n {\\displaystyle G(z,c)}\n \n. The discriminator receives image-label pairs \n \n \n \n (\n x\n ,\n c\n )\n \n \n {\\displaystyle (x,c)}\n \n, and computes \n \n \n \n D\n (\n x\n ,\n c\n )\n \n \n {\\displaystyle D(x,c)}\n \n.\nWhen the training dataset is unlabeled, conditional GAN does not work directly.\nThe idea of InfoGAN is to decree that every latent vector in the latent space can be decomposed as \n \n \n \n (\n z\n ,\n c\n )\n \n \n {\\displaystyle (z,c)}\n \n: an incompressible noise part \n \n \n \n z\n \n \n {\\displaystyle z}\n \n, and an informative label part \n \n \n \n c\n \n \n {\\displaystyle c}\n \n, and encourage the generator to comply with the decree, by encouraging it to maximize \n \n \n \n I\n (\n c\n ,\n G\n (\n z\n ,\n c\n )\n )\n \n \n {\\displaystyle I(c,G(z,c))}\n \n, the mutual information between \n \n \n \n c\n \n \n {\\displaystyle c}\n \n and \n \n \n \n G\n (\n z\n ,\n c\n )\n \n \n {\\displaystyle G(z,c)}\n \n, while making no demands on the mutual information \n \n \n \n z\n \n \n {\\displaystyle z}\n \n between \n \n \n \n G\n (\n z\n ,\n c\n )\n \n \n {\\displaystyle G(z,c)}\n \n.\nUnfortunately, \n \n \n \n I\n (\n c\n ,\n G\n (\n z\n ,\n c\n )\n )\n \n \n {\\displaystyle I(c,G(z,c))}\n \n is intractable in general, The key idea of InfoGAN is Variational Mutual Information Maximization: indirectly maximize it by maximizing a lower bound\n \n \n \n \n \n \n I\n ^\n \n \n \n (\n G\n ,\n Q\n )\n =\n \n \n E\n \n \n z\n ∼\n \n μ\n \n Z\n \n \n ,\n c\n ∼\n \n μ\n \n C\n \n \n \n \n [\n ln\n ⁡\n Q\n (\n c\n ∣\n G\n (\n z\n ,\n c\n )\n )\n ]\n ;\n \n I\n (\n c\n ,\n G\n (\n z\n ,\n c\n )\n )\n ≥\n \n sup\n \n Q\n \n \n \n \n \n I\n ^\n \n \n \n (\n G\n ,\n Q\n )\n \n \n {\\displaystyle {\\hat {I}}(G,Q)=\\mathbb {E} _{z\\sim \\mu _{Z},c\\sim \\mu _{C}}[\\ln Q(c\\mid G(z,c))];\\quad I(c,G(z,c))\\geq \\sup _{Q}{\\hat {I}}(G,Q)}\n \nwhere \n \n \n \n Q\n \n \n {\\displaystyle Q}\n \n ranges over all Markov kernels of type \n \n \n \n Q\n :\n \n Ω\n \n Y\n \n \n →\n \n \n P\n \n \n (\n \n Ω\n \n C\n \n \n )\n \n \n {\\displaystyle Q:\\Omega _{Y}\\to {\\mathcal {P}}(\\Omega _{C})}\n \n.\n\nThe InfoGAN game is defined as follows:Three probability spaces define an InfoGAN game:\n\n \n \n \n (\n \n Ω\n \n X\n \n \n ,\n \n μ\n \n ref\n \n \n )\n \n \n {\\displaystyle (\\Omega _{X},\\mu _{\\text{ref}})}\n \n, the space of reference images.\n\n \n \n \n (\n \n Ω\n \n Z\n \n \n ,\n \n μ\n \n Z\n \n \n )\n \n \n {\\displaystyle (\\Omega _{Z},\\mu _{Z})}\n \n, the fixed random noise generator.\n\n \n \n \n (\n \n Ω\n \n C\n \n \n ,\n \n μ\n \n C\n \n \n )\n \n \n {\\displaystyle (\\Omega _{C},\\mu _{C})}\n \n, the fixed random information generator.\nThere are 3 players in 2 teams: generator, Q, and discriminator. The generator and Q are on one team, and the discriminator on the other team.\nThe objective function is\n \n \n \n L\n (\n G\n ,\n Q\n ,\n D\n )\n =\n \n L\n \n G\n A\n N\n \n \n (\n G\n ,\n D\n )\n −\n λ\n \n \n \n I\n ^\n \n \n \n (\n G\n ,\n Q\n )\n \n \n {\\displaystyle L(G,Q,D)=L_{GAN}(G,D)-\\lambda {\\hat {I}}(G,Q)}\n \nwhere \n \n \n \n \n L\n \n G\n A\n N\n \n \n (\n G\n ,\n D\n )\n =\n \n E\n \n x\n ∼\n \n μ\n \n ref\n \n \n ,\n \n \n ⁡\n [\n ln\n ⁡\n D\n (\n x\n )\n ]\n +\n \n E\n \n z\n ∼\n \n μ\n \n Z\n \n \n \n \n ⁡\n [\n ln\n ⁡\n (\n 1\n −\n D\n (\n G\n (\n z\n ,\n c\n )\n )\n )\n ]\n \n \n {\\displaystyle L_{GAN}(G,D)=\\operatorname {E} _{x\\sim \\mu _{\\text{ref}},}[\\ln D(x)]+\\operatorname {E} _{z\\sim \\mu _{Z}}[\\ln(1-D(G(z,c)))]}\n \n is the original GAN game objective, and \n \n \n \n \n \n \n I\n ^\n \n \n \n (\n G\n ,\n Q\n )\n =\n \n \n E\n \n \n z\n ∼\n \n μ\n \n Z\n \n \n ,\n c\n ∼\n \n μ\n \n C\n \n \n \n \n [\n ln\n ⁡\n Q\n (\n c\n ∣\n G\n (\n z\n ,\n c\n )\n )\n ]\n \n \n {\\displaystyle {\\hat {I}}(G,Q)=\\mathbb {E} _{z\\sim \\mu _{Z},c\\sim \\mu _{C}}[\\ln Q(c\\mid G(z,c))]}\n \n\nGenerator-Q team aims to minimize the objective, and discriminator aims to maximize it:\n \n \n \n \n min\n \n G\n ,\n Q\n \n \n \n max\n \n D\n \n \n L\n (\n G\n ,\n Q\n ,\n D\n )\n \n \n {\\displaystyle \\min _{G,Q}\\max _{D}L(G,Q,D)}\n \n\n\nBidirectional GAN (BiGAN)\nThe standard GAN generator is a function of type \n \n \n \n G\n :\n \n Ω\n \n Z\n \n \n →\n \n Ω\n \n X\n \n \n \n \n {\\displaystyle G:\\Omega _{Z}\\to \\Omega _{X}}\n \n, that is, it is a mapping from a latent space \n \n \n \n \n Ω\n \n Z\n \n \n \n \n {\\displaystyle \\Omega _{Z}}\n \n to the image space \n \n \n \n \n Ω\n \n X\n \n \n \n \n {\\displaystyle \\Omega _{X}}\n \n. This can be understood as a \"decoding\" process, whereby every latent vector \n \n \n \n z\n ∈\n \n Ω\n \n Z\n \n \n \n \n {\\displaystyle z\\in \\Omega _{Z}}\n \n is a code for an image \n \n \n \n x\n ∈\n \n Ω\n \n X\n \n \n \n \n {\\displaystyle x\\in \\Omega _{X}}\n \n, and the generator performs the decoding. This naturally leads to the idea of training another network that performs \"encoding\", creating an autoencoder out of the encoder-generator pair.\nAlready in the original paper, the authors noted that \"Learned approximate inference can be performed by training an auxiliary network to predict \n \n \n \n z\n \n \n {\\displaystyle z}\n \n given \n \n \n \n x\n \n \n {\\displaystyle x}\n \n\". The bidirectional GAN architecture performs exactly this.\n\nThe BiGAN is defined as follows: Two probability spaces define a BiGAN game:\n\n \n \n \n (\n \n Ω\n \n X\n \n \n ,\n \n μ\n \n X\n \n \n )\n \n \n {\\displaystyle (\\Omega _{X},\\mu _{X})}\n \n, the space of reference images.\n\n \n \n \n (\n \n Ω\n \n Z\n \n \n ,\n \n μ\n \n Z\n \n \n )\n \n \n {\\displaystyle (\\Omega _{Z},\\mu _{Z})}\n \n, the latent space.\nThere are 3 players in 2 teams: generator, encoder, and discriminator. The generator and encoder are on one team, and the discriminator on the other team.\nThe generator's strategies are functions \n \n \n \n G\n :\n \n Ω\n \n Z\n \n \n →\n \n Ω\n \n X\n \n \n \n \n {\\displaystyle G:\\Omega _{Z}\\to \\Omega _{X}}\n \n, and the encoder's strategies are functions \n \n \n \n E\n :\n \n Ω\n \n X\n \n \n →\n \n Ω\n \n Z\n \n \n \n \n {\\displaystyle E:\\Omega _{X}\\to \\Omega _{Z}}\n \n. The discriminator's strategies are functions \n \n \n \n D\n :\n \n Ω\n \n X\n \n \n →\n [\n 0\n ,\n 1\n ]\n \n \n {\\displaystyle D:\\Omega _{X}\\to [0,1]}\n \n.\nThe objective function is\n \n \n \n L\n (\n G\n ,\n E\n ,\n D\n )\n =\n \n \n E\n \n \n x\n ∼\n \n μ\n \n X\n \n \n \n \n [\n ln\n ⁡\n D\n (\n x\n ,\n E\n (\n x\n )\n )\n ]\n +\n \n \n E\n \n \n z\n ∼\n \n μ\n \n Z\n \n \n \n \n [\n ln\n ⁡\n (\n 1\n −\n D\n (\n G\n (\n z\n )\n ,\n z\n )\n )\n ]\n \n \n {\\displaystyle L(G,E,D)=\\mathbb {E} _{x\\sim \\mu _{X}}[\\ln D(x,E(x))]+\\mathbb {E} _{z\\sim \\mu _{Z}}[\\ln(1-D(G(z),z))]}\n \n\nGenerator-encoder team aims to minimize the objective, and discriminator aims to maximize it:\n \n \n \n \n min\n \n G\n ,\n E\n \n \n \n max\n \n D\n \n \n L\n (\n G\n ,\n E\n ,\n D\n )\n \n \n {\\displaystyle \\min _{G,E}\\max _{D}L(G,E,D)}\n \n In the paper, they gave a more abstract definition of the objective as:\n \n \n \n L\n (\n G\n ,\n E\n ,\n D\n )\n =\n \n \n E\n \n \n (\n x\n ,\n z\n )\n ∼\n \n μ\n \n E\n ,\n X\n \n \n \n \n [\n ln\n ⁡\n D\n (\n x\n ,\n z\n )\n ]\n +\n \n \n E\n \n \n (\n x\n ,\n z\n )\n ∼\n \n μ\n \n G\n ,\n Z\n \n \n \n \n [\n ln\n ⁡\n (\n 1\n −\n D\n (\n x\n ,\n z\n )\n )\n ]\n \n \n {\\displaystyle L(G,E,D)=\\mathbb {E} _{(x,z)\\sim \\mu _{E,X}}[\\ln D(x,z)]+\\mathbb {E} _{(x,z)\\sim \\mu _{G,Z}}[\\ln(1-D(x,z))]}\n \nwhere \n \n \n \n \n μ\n \n E\n ,\n X\n \n \n (\n d\n x\n ,\n d\n z\n )\n =\n \n μ\n \n X\n \n \n (\n d\n x\n )\n ⋅\n \n δ\n \n E\n (\n x\n )\n \n \n (\n d\n z\n )\n \n \n {\\displaystyle \\mu _{E,X}(dx,dz)=\\mu _{X}(dx)\\cdot \\delta _{E(x)}(dz)}\n \n is the probability distribution on \n \n \n \n \n Ω\n \n X\n \n \n ×\n \n Ω\n \n Z\n \n \n \n \n {\\displaystyle \\Omega _{X}\\times \\Omega _{Z}}\n \n obtained by pushing \n \n \n \n \n μ\n \n X\n \n \n \n \n {\\displaystyle \\mu _{X}}\n \n forward via \n \n \n \n x\n ↦\n (\n x\n ,\n E\n (\n x\n )\n )\n \n \n {\\displaystyle x\\mapsto (x,E(x))}\n \n, and \n \n \n \n \n μ\n \n G\n ,\n Z\n \n \n (\n d\n x\n ,\n d\n z\n )\n =\n \n δ\n \n G\n (\n z\n )\n \n \n (\n d\n x\n )\n ⋅\n \n μ\n \n Z\n \n \n (\n d\n z\n )\n \n \n {\\displaystyle \\mu _{G,Z}(dx,dz)=\\delta _{G(z)}(dx)\\cdot \\mu _{Z}(dz)}\n \n is the probability distribution on \n \n \n \n \n Ω\n \n X\n \n \n ×\n \n Ω\n \n Z\n \n \n \n \n {\\displaystyle \\Omega _{X}\\times \\Omega _{Z}}\n \n obtained by pushing \n \n \n \n \n μ\n \n Z\n \n \n \n \n {\\displaystyle \\mu _{Z}}\n \n forward via \n \n \n \n z\n ↦\n (\n G\n (\n x\n )\n ,\n z\n )\n \n \n {\\displaystyle z\\mapsto (G(x),z)}\n \n.\nApplications of bidirectional models include semi-supervised learning, interpretable machine learning, and neural machine translation.\n\n\nCycleGAN\nCycleGAN is an architecture for performing translations between two domains, such as between photos of horses and photos of zebras, or photos of night cities and photos of day cities.\n\nThe CycleGAN game is defined as follows:There are two probability spaces \n \n \n \n (\n \n Ω\n \n X\n \n \n ,\n \n μ\n \n X\n \n \n )\n ,\n (\n \n Ω\n \n Y\n \n \n ,\n \n μ\n \n Y\n \n \n )\n \n \n {\\displaystyle (\\Omega _{X},\\mu _{X}),(\\Omega _{Y},\\mu _{Y})}\n \n, corresponding to the two domains needed for translations fore-and-back.\nThere are 4 players in 2 teams: generators \n \n \n \n \n G\n \n X\n \n \n :\n \n Ω\n \n X\n \n \n →\n \n Ω\n \n Y\n \n \n ,\n \n G\n \n Y\n \n \n :\n \n Ω\n \n Y\n \n \n →\n \n Ω\n \n X\n \n \n \n \n {\\displaystyle G_{X}:\\Omega _{X}\\to \\Omega _{Y},G_{Y}:\\Omega _{Y}\\to \\Omega _{X}}\n \n, and discriminators \n \n \n \n \n D\n \n X\n \n \n :\n \n Ω\n \n X\n \n \n →\n [\n 0\n ,\n 1\n ]\n ,\n \n D\n \n Y\n \n \n :\n \n Ω\n \n Y\n \n \n →\n [\n 0\n ,\n 1\n ]\n \n \n {\\displaystyle D_{X}:\\Omega _{X}\\to [0,1],D_{Y}:\\Omega _{Y}\\to [0,1]}\n \n.\nThe objective function is\n \n \n \n L\n (\n \n G\n \n X\n \n \n ,\n \n G\n \n Y\n \n \n ,\n \n D\n \n X\n \n \n ,\n \n D\n \n Y\n \n \n )\n =\n \n L\n \n G\n A\n N\n \n \n (\n \n G\n \n X\n \n \n ,\n \n D\n \n X\n \n \n )\n +\n \n L\n \n G\n A\n N\n \n \n (\n \n G\n \n Y\n \n \n ,\n \n D\n \n Y\n \n \n )\n +\n λ\n \n L\n \n c\n y\n c\n l\n e\n \n \n (\n \n G\n \n X\n \n \n ,\n \n G\n \n Y\n \n \n )\n \n \n {\\displaystyle L(G_{X},G_{Y},D_{X},D_{Y})=L_{GAN}(G_{X},D_{X})+L_{GAN}(G_{Y},D_{Y})+\\lambda L_{cycle}(G_{X},G_{Y})}\n \n\nwhere \n \n \n \n λ\n \n \n {\\displaystyle \\lambda }\n \n is a positive adjustable parameter, \n \n \n \n \n L\n \n G\n A\n N\n \n \n \n \n {\\displaystyle L_{GAN}}\n \n is the GAN game objective, and \n \n \n \n \n L\n \n c\n y\n c\n l\n e\n \n \n \n \n {\\displaystyle L_{cycle}}\n \n is the cycle consistency loss:\n \n \n \n \n L\n \n c\n y\n c\n l\n e\n \n \n (\n \n G\n \n X\n \n \n ,\n \n G\n \n Y\n \n \n )\n =\n \n E\n \n x\n ∼\n \n μ\n \n X\n \n \n \n \n ‖\n \n G\n \n X\n \n \n (\n \n G\n \n Y\n \n \n (\n x\n )\n )\n −\n x\n ‖\n +\n \n E\n \n y\n ∼\n \n μ\n \n Y\n \n \n \n \n ‖\n \n G\n \n Y\n \n \n (\n \n G\n \n X\n \n \n (\n y\n )\n )\n −\n y\n ‖\n \n \n {\\displaystyle L_{cycle}(G_{X},G_{Y})=E_{x\\sim \\mu _{X}}\\|G_{X}(G_{Y}(x))-x\\|+E_{y\\sim \\mu _{Y}}\\|G_{Y}(G_{X}(y))-y\\|}\n \nThe generators aim to minimize the objective, and the discriminators aim to maximize it:\n \n \n \n \n min\n \n \n G\n \n X\n \n \n ,\n \n G\n \n Y\n \n \n \n \n \n max\n \n \n D\n \n X\n \n \n ,\n \n D\n \n Y\n \n \n \n \n L\n (\n \n G\n \n X\n \n \n ,\n \n G\n \n Y\n \n \n ,\n \n D\n \n X\n \n \n ,\n \n D\n \n Y\n \n \n )\n \n \n {\\displaystyle \\min _{G_{X},G_{Y}}\\max _{D_{X},D_{Y}}L(G_{X},G_{Y},D_{X},D_{Y})}\n \n Unlike previous work like pix2pix, which requires paired training data, cycleGAN requires no paired data. For example, to train a pix2pix model to turn a summer scenery photo to winter scenery photo and back, the dataset must contain pairs of the same place in summer and winter, shot at the same angle; cycleGAN would only need a set of summer scenery photos, and an unrelated set of winter scenery photos.\n\n\nGANs with particularly large or small scales\n\n\nBigGAN\nThe BigGAN is essentially a self-attention GAN trained on a large scale (up to 80 million parameters) to generate large images of ImageNet (up to 512 x 512 resolution), with numerous engineering tricks to make it converge.\n\n\nInvertible data augmentation\nWhen there is insufficient training data, the reference distribution \n \n \n \n \n μ\n \n ref\n \n \n \n \n {\\displaystyle \\mu _{\\text{ref}}}\n \n cannot be well-approximated by the empirical distribution given by the training dataset. In such cases, data augmentation can be applied, to allow training GAN on smaller datasets. Naïve data augmentation, however, brings its problems.\nConsider the original GAN game, slightly reformulated as follows:\n \n \n \n \n \n {\n \n \n \n \n min\n \n D\n \n \n \n L\n \n D\n \n \n (\n D\n ,\n \n μ\n \n G\n \n \n )\n =\n −\n \n E\n \n x\n ∼\n \n μ\n \n ref\n \n \n \n \n ⁡\n [\n ln\n ⁡\n D\n (\n x\n )\n ]\n −\n \n E\n \n x\n ∼\n \n μ\n \n G\n \n \n \n \n ⁡\n [\n ln\n ⁡\n (\n 1\n −\n D\n (\n x\n )\n )\n ]\n \n \n \n \n \n min\n \n G\n \n \n \n L\n \n G\n \n \n (\n D\n ,\n \n μ\n \n G\n \n \n )\n =\n −\n \n E\n \n x\n ∼\n \n μ\n \n G\n \n \n \n \n ⁡\n [\n ln\n ⁡\n (\n 1\n −\n D\n (\n x\n )\n )\n ]\n \n \n \n \n \n \n \n \n {\\displaystyle {\\begin{cases}\\min _{D}L_{D}(D,\\mu _{G})=-\\operatorname {E} _{x\\sim \\mu _{\\text{ref}}}[\\ln D(x)]-\\operatorname {E} _{x\\sim \\mu _{G}}[\\ln(1-D(x))]\\\\\\min _{G}L_{G}(D,\\mu _{G})=-\\operatorname {E} _{x\\sim \\mu _{G}}[\\ln(1-D(x))]\\end{cases}}}\n \nNow we use data augmentation by randomly sampling semantic-preserving transforms \n \n \n \n T\n :\n Ω\n →\n Ω\n \n \n {\\displaystyle T:\\Omega \\to \\Omega }\n \n and applying them to the dataset, to obtain the reformulated GAN game:\n \n \n \n \n \n {\n \n \n \n \n min\n \n D\n \n \n \n L\n \n D\n \n \n (\n D\n ,\n \n μ\n \n G\n \n \n )\n =\n −\n \n E\n \n x\n ∼\n \n μ\n \n ref\n \n \n ,\n T\n ∼\n \n μ\n \n trans\n \n \n \n \n ⁡\n [\n ln\n ⁡\n D\n (\n T\n (\n x\n )\n )\n ]\n −\n \n E\n \n x\n ∼\n \n μ\n \n G\n \n \n \n \n ⁡\n [\n ln\n ⁡\n (\n 1\n −\n D\n (\n x\n )\n )\n ]\n \n \n \n \n \n min\n \n G\n \n \n \n L\n \n G\n \n \n (\n D\n ,\n \n μ\n \n G\n \n \n )\n =\n −\n \n E\n \n x\n ∼\n \n μ\n \n G\n \n \n \n \n ⁡\n [\n ln\n ⁡\n (\n 1\n −\n D\n (\n x\n )\n )\n ]\n \n \n \n \n \n \n \n \n {\\displaystyle {\\begin{cases}\\min _{D}L_{D}(D,\\mu _{G})=-\\operatorname {E} _{x\\sim \\mu _{\\text{ref}},T\\sim \\mu _{\\text{trans}}}[\\ln D(T(x))]-\\operatorname {E} _{x\\sim \\mu _{G}}[\\ln(1-D(x))]\\\\\\min _{G}L_{G}(D,\\mu _{G})=-\\operatorname {E} _{x\\sim \\mu _{G}}[\\ln(1-D(x))]\\end{cases}}}\n \nThis is equivalent to a GAN game with a different distribution \n \n \n \n \n μ\n \n ref\n \n ′\n \n \n \n {\\displaystyle \\mu _{\\text{ref}}'}\n \n, sampled by \n \n \n \n T\n (\n x\n )\n \n \n {\\displaystyle T(x)}\n \n, with \n \n \n \n x\n ∼\n \n μ\n \n ref\n \n \n ,\n T\n ∼\n \n μ\n \n trans\n \n \n \n \n {\\displaystyle x\\sim \\mu _{\\text{ref}},T\\sim \\mu _{\\text{trans}}}\n \n. For example, if \n \n \n \n \n μ\n \n ref\n \n \n \n \n {\\displaystyle \\mu _{\\text{ref}}}\n \n is the distribution of images in ImageNet, and \n \n \n \n \n μ\n \n trans\n \n \n \n \n {\\displaystyle \\mu _{\\text{trans}}}\n \n samples identity-transform with probability 0.5, and horizontal-reflection with probability 0.5, then \n \n \n \n \n μ\n \n ref\n \n ′\n \n \n \n {\\displaystyle \\mu _{\\text{ref}}'}\n \n is the distribution of images in ImageNet and horizontally-reflected ImageNet, combined.\nThe result of such training would be a generator that mimics \n \n \n \n \n μ\n \n ref\n \n ′\n \n \n \n {\\displaystyle \\mu _{\\text{ref}}'}\n \n. For example, it would generate images that look like they are randomly cropped, if the data augmentation uses random cropping.\nThe solution is to apply data augmentation to both generated and real images:\n \n \n \n \n \n {\n \n \n \n \n min\n \n D\n \n \n \n L\n \n D\n \n \n (\n D\n ,\n \n μ\n \n G\n \n \n )\n =\n −\n \n E\n \n x\n ∼\n \n μ\n \n ref\n \n \n ,\n T\n ∼\n \n μ\n \n trans\n \n \n \n \n ⁡\n [\n ln\n ⁡\n D\n (\n T\n (\n x\n )\n )\n ]\n −\n \n E\n \n x\n ∼\n \n μ\n \n G\n \n \n ,\n T\n ∼\n \n μ\n \n trans\n \n \n \n \n ⁡\n [\n ln\n ⁡\n (\n 1\n −\n D\n (\n T\n (\n x\n )\n )\n )\n ]\n \n \n \n \n \n min\n \n G\n \n \n \n L\n \n G\n \n \n (\n D\n ,\n \n μ\n \n G\n \n \n )\n =\n −\n \n E\n \n x\n ∼\n \n μ\n \n G\n \n \n ,\n T\n ∼\n \n μ\n \n trans\n \n \n \n \n ⁡\n [\n ln\n ⁡\n (\n 1\n −\n D\n (\n T\n (\n x\n )\n )\n )\n ]\n \n \n \n \n \n \n \n \n {\\displaystyle {\\begin{cases}\\min _{D}L_{D}(D,\\mu _{G})=-\\operatorname {E} _{x\\sim \\mu _{\\text{ref}},T\\sim \\mu _{\\text{trans}}}[\\ln D(T(x))]-\\operatorname {E} _{x\\sim \\mu _{G},T\\sim \\mu _{\\text{trans}}}[\\ln(1-D(T(x)))]\\\\\\min _{G}L_{G}(D,\\mu _{G})=-\\operatorname {E} _{x\\sim \\mu _{G},T\\sim \\mu _{\\text{trans}}}[\\ln(1-D(T(x)))]\\end{cases}}}\n \nThe authors demonstrated high-quality generation using just 100-picture-large datasets.\nThe StyleGAN-2-ADA paper points out a further point on data augmentation: it must be invertible. Continue with the example of generating ImageNet pictures. If the data augmentation is \"randomly rotate the picture by 0, 90, 180, 270 degrees with equal probability\", then there is no way for the generator to know which is the true orientation: Consider two generators \n \n \n \n G\n ,\n \n G\n ′\n \n \n \n {\\displaystyle G,G'}\n \n, such that for any latent \n \n \n \n z\n \n \n {\\displaystyle z}\n \n, the generated image \n \n \n \n G\n (\n z\n )\n \n \n {\\displaystyle G(z)}\n \n is a 90-degree rotation of \n \n \n \n \n G\n ′\n \n (\n z\n )\n \n \n {\\displaystyle G'(z)}\n \n. They would have exactly the same expected loss, and so neither is preferred over the other.\nThe solution is to only use invertible data augmentation: instead of \"randomly rotate the picture by 0, 90, 180, 270 degrees with equal probability\", use \"randomly rotate the picture by 90, 180, 270 degrees with 0.1 probability, and keep the picture as it is with 0.7 probability\". This way, the generator is still rewarded to keep images oriented the same way as un-augmented ImageNet pictures.\nAbstractly, the effect of randomly sampling transformations \n \n \n \n T\n :\n Ω\n →\n Ω\n \n \n {\\displaystyle T:\\Omega \\to \\Omega }\n \n from the distribution \n \n \n \n \n μ\n \n trans\n \n \n \n \n {\\displaystyle \\mu _{\\text{trans}}}\n \n is to define a Markov kernel \n \n \n \n \n K\n \n trans\n \n \n :\n Ω\n →\n \n \n P\n \n \n (\n Ω\n )\n \n \n {\\displaystyle K_{\\text{trans}}:\\Omega \\to {\\mathcal {P}}(\\Omega )}\n \n. Then, the data-augmented GAN game pushes the generator to find some \n \n \n \n \n \n \n \n μ\n ^\n \n \n \n \n G\n \n \n ∈\n \n \n P\n \n \n (\n Ω\n )\n \n \n {\\displaystyle {\\hat {\\mu }}_{G}\\in {\\mathcal {P}}(\\Omega )}\n \n, such that \n \n \n \n \n K\n \n trans\n \n \n ∗\n \n μ\n \n ref\n \n \n =\n \n K\n \n trans\n \n \n ∗\n \n \n \n \n μ\n ^\n \n \n \n \n G\n \n \n \n \n {\\displaystyle K_{\\text{trans}}*\\mu _{\\text{ref}}=K_{\\text{trans}}*{\\hat {\\mu }}_{G}}\n \nwhere \n \n \n \n ∗\n \n \n {\\displaystyle *}\n \n is the Markov kernel convolution.\nA data-augmentation method is defined to be invertible if its Markov kernel \n \n \n \n \n K\n \n trans\n \n \n \n \n {\\displaystyle K_{\\text{trans}}}\n \n satisfies\n \n \n \n \n K\n \n trans\n \n \n ∗\n μ\n =\n \n K\n \n trans\n \n \n ∗\n \n μ\n ′\n \n \n ⟹\n \n μ\n =\n \n μ\n ′\n \n \n ∀\n μ\n ,\n \n μ\n ′\n \n ∈\n \n \n P\n \n \n (\n Ω\n )\n \n \n {\\displaystyle K_{\\text{trans}}*\\mu =K_{\\text{trans}}*\\mu '\\implies \\mu =\\mu '\\quad \\forall \\mu ,\\mu '\\in {\\mathcal {P}}(\\Omega )}\n \nImmediately by definition, we see that composing multiple invertible data-augmentation methods results in yet another invertible method. Also by definition, if the data-augmentation method is invertible, then using it in a GAN game does not change the optimal strategy \n \n \n \n \n \n \n \n μ\n ^\n \n \n \n \n G\n \n \n \n \n {\\displaystyle {\\hat {\\mu }}_{G}}\n \n for the generator, which is still \n \n \n \n \n μ\n \n ref\n \n \n \n \n {\\displaystyle \\mu _{\\text{ref}}}\n \n.\nThere are two prototypical examples of invertible Markov kernels:\nDiscrete case: Invertible stochastic matrices, when \n \n \n \n Ω\n \n \n {\\displaystyle \\Omega }\n \n is finite.\nFor example, if \n \n \n \n Ω\n =\n {\n ↑\n ,\n ↓\n ,\n ←\n ,\n →\n }\n \n \n {\\displaystyle \\Omega =\\{\\uparrow ,\\downarrow ,\\leftarrow ,\\rightarrow \\}}\n \n is the set of four images of an arrow, pointing in 4 directions, and the data augmentation is \"randomly rotate the picture by 90, 180, 270 degrees with probability \n \n \n \n p\n \n \n {\\displaystyle p}\n \n, and keep the picture as it is with probability \n \n \n \n (\n 1\n −\n 3\n p\n )\n \n \n {\\displaystyle (1-3p)}\n \n\", then the Markov kernel \n \n \n \n \n K\n \n trans\n \n \n \n \n {\\displaystyle K_{\\text{trans}}}\n \n can be represented as a stochastic matrix:\n \n \n \n [\n \n K\n \n trans\n \n \n ]\n =\n \n \n [\n \n \n \n (\n 1\n −\n 3\n p\n )\n \n \n p\n \n \n p\n \n \n p\n \n \n \n \n p\n \n \n (\n 1\n −\n 3\n p\n )\n \n \n p\n \n \n p\n \n \n \n \n p\n \n \n p\n \n \n (\n 1\n −\n 3\n p\n )\n \n \n p\n \n \n \n \n p\n \n \n p\n \n \n p\n \n \n (\n 1\n −\n 3\n p\n )\n \n \n \n ]\n \n \n \n \n {\\displaystyle [K_{\\text{trans}}]={\\begin{bmatrix}(1-3p)&p&p&p\\\\p&(1-3p)&p&p\\\\p&p&(1-3p)&p\\\\p&p&p&(1-3p)\\end{bmatrix}}}\n \n and \n \n \n \n \n K\n \n trans\n \n \n \n \n {\\displaystyle K_{\\text{trans}}}\n \n is an invertible kernel iff \n \n \n \n [\n \n K\n \n trans\n \n \n ]\n \n \n {\\displaystyle [K_{\\text{trans}}]}\n \n is an invertible matrix, that is, \n \n \n \n p\n ≠\n 1\n \n /\n \n 4\n \n \n {\\displaystyle p\\neq 1/4}\n \n.\nContinuous case: The gaussian kernel, when \n \n \n \n Ω\n =\n \n \n R\n \n \n n\n \n \n \n \n {\\displaystyle \\Omega =\\mathbb {R} ^{n}}\n \n for some \n \n \n \n n\n ≥\n 1\n \n \n {\\displaystyle n\\geq 1}\n \n.\nFor example, if \n \n \n \n Ω\n =\n \n \n R\n \n \n \n 256\n \n 2\n \n \n \n \n \n \n {\\displaystyle \\Omega =\\mathbb {R} ^{256^{2}}}\n \n is the space of 256x256 images, and the data-augmentation method is \"generate a gaussian noise \n \n \n \n z\n ∼\n \n \n N\n \n \n (\n 0\n ,\n \n I\n \n \n 256\n \n 2\n \n \n \n \n )\n \n \n {\\displaystyle z\\sim {\\mathcal {N}}(0,I_{256^{2}})}\n \n, then add \n \n \n \n ϵ\n z\n \n \n {\\displaystyle \\epsilon z}\n \n to the image\", then \n \n \n \n \n K\n \n trans\n \n \n \n \n {\\displaystyle K_{\\text{trans}}}\n \n is just convolution by the density function of \n \n \n \n \n \n N\n \n \n (\n 0\n ,\n \n ϵ\n \n 2\n \n \n \n I\n \n \n 256\n \n 2\n \n \n \n \n )\n \n \n {\\displaystyle {\\mathcal {N}}(0,\\epsilon ^{2}I_{256^{2}})}\n \n. This is invertible, because convolution by a gaussian is just convolution by the heat kernel, so given any \n \n \n \n μ\n ∈\n \n \n P\n \n \n (\n \n \n R\n \n \n n\n \n \n )\n \n \n {\\displaystyle \\mu \\in {\\mathcal {P}}(\\mathbb {R} ^{n})}\n \n, the convolved distribution \n \n \n \n \n K\n \n trans\n \n \n ∗\n μ\n \n \n {\\displaystyle K_{\\text{trans}}*\\mu }\n \n can be obtained by heating up \n \n \n \n \n \n R\n \n \n n\n \n \n \n \n {\\displaystyle \\mathbb {R} ^{n}}\n \n precisely according to \n \n \n \n μ\n \n \n {\\displaystyle \\mu }\n \n, then wait for time \n \n \n \n \n ϵ\n \n 2\n \n \n \n /\n \n 4\n \n \n {\\displaystyle \\epsilon ^{2}/4}\n \n. With that, we can recover \n \n \n \n μ\n \n \n {\\displaystyle \\mu }\n \n by running the heat equation backwards in time for \n \n \n \n \n ϵ\n \n 2\n \n \n \n /\n \n 4\n \n \n {\\displaystyle \\epsilon ^{2}/4}\n \n.\nMore examples of invertible data augmentations are found in the paper.\n\n\nSinGAN\nSinGAN pushes data augmentation to the limit, by using only a single image as training data and performing data augmentation on it. The GAN architecture is adapted to this training method by using a multi-scale pipeline.\nThe generator \n \n \n \n G\n \n \n {\\displaystyle G}\n \n is decomposed into a pyramid of generators \n \n \n \n G\n =\n \n G\n \n 1\n \n \n ∘\n \n G\n \n 2\n \n \n ∘\n ⋯\n ∘\n \n G\n \n N\n \n \n \n \n {\\displaystyle G=G_{1}\\circ G_{2}\\circ \\cdots \\circ G_{N}}\n \n, with the lowest one generating the image \n \n \n \n \n G\n \n N\n \n \n (\n \n z\n \n N\n \n \n )\n \n \n {\\displaystyle G_{N}(z_{N})}\n \n at the lowest resolution, then the generated image is scaled up to \n \n \n \n r\n (\n \n G\n \n N\n \n \n (\n \n z\n \n N\n \n \n )\n )\n \n \n {\\displaystyle r(G_{N}(z_{N}))}\n \n, and fed to the next level to generate an image \n \n \n \n \n G\n \n N\n −\n 1\n \n \n (\n \n z\n \n N\n −\n 1\n \n \n +\n r\n (\n \n G\n \n N\n \n \n (\n \n z\n \n N\n \n \n )\n )\n )\n \n \n {\\displaystyle G_{N-1}(z_{N-1}+r(G_{N}(z_{N})))}\n \n at a higher resolution, and so on. The discriminator is decomposed into a pyramid as well.\n\n\nStyleGAN series\n\nThe StyleGAN family is a series of architectures published by Nvidia's research division.\n\n\nProgressive GAN\nProgressive GAN is a method for training GAN for large-scale image generation stably, by growing a GAN generator from small to large scale in a pyramidal fashion. Like SinGAN, it decomposes the generator as\n \n \n \n G\n =\n \n G\n \n 1\n \n \n ∘\n \n G\n \n 2\n \n \n ∘\n ⋯\n ∘\n \n G\n \n N\n \n \n \n \n {\\displaystyle G=G_{1}\\circ G_{2}\\circ \\cdots \\circ G_{N}}\n \n, and the discriminator as \n \n \n \n D\n =\n \n D\n \n 1\n \n \n ∘\n \n D\n \n 2\n \n \n ∘\n ⋯\n ∘\n \n D\n \n N\n \n \n \n \n {\\displaystyle D=D_{1}\\circ D_{2}\\circ \\cdots \\circ D_{N}}\n \n.\nDuring training, at first only \n \n \n \n \n G\n \n N\n \n \n ,\n \n D\n \n N\n \n \n \n \n {\\displaystyle G_{N},D_{N}}\n \n are used in a GAN game to generate 4x4 images. Then \n \n \n \n \n G\n \n N\n −\n 1\n \n \n ,\n \n D\n \n N\n −\n 1\n \n \n \n \n {\\displaystyle G_{N-1},D_{N-1}}\n \n are added to reach the second stage of GAN game, to generate 8x8 images, and so on, until we reach a GAN game to generate 1024x1024 images.\nTo avoid shock between stages of the GAN game, each new layer is \"blended in\" (Figure 2 of the paper). For example, this is how the second stage GAN game starts:\n\nJust before, the GAN game consists of the pair \n \n \n \n \n G\n \n N\n \n \n ,\n \n D\n \n N\n \n \n \n \n {\\displaystyle G_{N},D_{N}}\n \n generating and discriminating 4x4 images.\nJust after, the GAN game consists of the pair \n \n \n \n (\n (\n 1\n −\n α\n )\n +\n α\n ⋅\n \n G\n \n N\n −\n 1\n \n \n )\n ∘\n u\n ∘\n \n G\n \n N\n \n \n ,\n \n D\n \n N\n \n \n ∘\n d\n ∘\n (\n (\n 1\n −\n α\n )\n +\n α\n ⋅\n \n D\n \n N\n −\n 1\n \n \n )\n \n \n {\\displaystyle ((1-\\alpha )+\\alpha \\cdot G_{N-1})\\circ u\\circ G_{N},D_{N}\\circ d\\circ ((1-\\alpha )+\\alpha \\cdot D_{N-1})}\n \n generating and discriminating 8x8 images. Here, the functions \n \n \n \n u\n ,\n d\n \n \n {\\displaystyle u,d}\n \n are image up- and down-sampling functions, and \n \n \n \n α\n \n \n {\\displaystyle \\alpha }\n \n is a blend-in factor (much like an alpha in image composing) that smoothly glides from 0 to 1.\n\n\nStyleGAN-1\n\nStyleGAN-1 is designed as a combination of Progressive GAN with neural style transfer.\nThe key architectural choice of StyleGAN-1 is a progressive growth mechanism, similar to Progressive GAN. Each generated image starts as a constant \n \n \n \n 4\n ×\n 4\n ×\n 512\n \n \n {\\displaystyle 4\\times 4\\times 512}\n \n array, and repeatedly passed through style blocks. Each style block applies a \"style latent vector\" via affine transform (\"adaptive instance normalization\"), similar to how neural style transfer uses Gramian matrix. It then adds noise, and normalize (subtract the mean, then divide by the variance).\nAt training time, usually only one style latent vector is used per image generated, but sometimes two (\"mixing regularization\") in order to encourage each style block to independently perform its stylization without expecting help from other style blocks (since they might receive an entirely different style latent vector).\nAfter training, multiple style latent vectors can be fed into each style block. Those fed to the lower layers control the large-scale styles, and those fed to the higher layers control the fine-detail styles.\nStyle-mixing between two images \n \n \n \n x\n ,\n \n x\n ′\n \n \n \n {\\displaystyle x,x'}\n \n can be performed as well. First, run a gradient descent to find \n \n \n \n z\n ,\n \n z\n ′\n \n \n \n {\\displaystyle z,z'}\n \n such that \n \n \n \n G\n (\n z\n )\n ≈\n x\n ,\n G\n (\n \n z\n ′\n \n )\n ≈\n \n x\n ′\n \n \n \n {\\displaystyle G(z)\\approx x,G(z')\\approx x'}\n \n. This is called \"projecting an image back to style latent space\". Then, \n \n \n \n z\n \n \n {\\displaystyle z}\n \n can be fed to the lower style blocks, and \n \n \n \n \n z\n ′\n \n \n \n {\\displaystyle z'}\n \n to the higher style blocks, to generate a composite image that has the large-scale style of \n \n \n \n x\n \n \n {\\displaystyle x}\n \n, and the fine-detail style of \n \n \n \n \n x\n ′\n \n \n \n {\\displaystyle x'}\n \n. Multiple images can also be composed this way.\n\n\nStyleGAN-2\nStyleGAN-2 improves upon StyleGAN-1, by using the style latent vector to transform the convolution layer's weights instead, thus solving the \"blob\" problem.\nThis was updated by the StyleGAN-2-ADA (\"ADA\" stands for \"adaptive\"), which uses invertible data augmentation as described above. It also tunes the amount of data augmentation applied by starting at zero, and gradually increasing it until an \"overfitting heuristic\" reaches a target level, thus the name \"adaptive\".\n\n\nStyleGAN-3\nStyleGAN-3 improves upon StyleGAN-2 by solving the \"texture sticking\" problem, which can be seen in the official videos. They analyzed the problem by the Nyquist–Shannon sampling theorem, and argued that the layers in the generator learned to exploit the high-frequency signal in the pixels they operate upon.\nTo solve this, they proposed imposing strict lowpass filters between each generator's layers, so that the generator is forced to operate on the pixels in a way faithful to the continuous signals they represent, rather than operate on them as merely discrete signals. They further imposed rotational and translational invariance by using more signal filters. The resulting StyleGAN-3 is able to solve the texture sticking problem, as well as generating images that rotate and translate smoothly.\n\n\nOther uses\nOther than for generative and discriminative modelling of data, GANs have been used for other things.\nGANs have been used for transfer learning to enforce the alignment of the latent feature space, such as in deep reinforcement learning. This works by feeding the embeddings of the source and target task to the discriminator which tries to guess the context. The resulting loss is then (inversely) backpropagated through the encoder.\n\n\nApplications\n\n\nScience\nIteratively reconstruct astronomical images\nSimulate gravitational lensing for dark matter research.\nModel the distribution of dark matter in a particular direction in space and to predict the gravitational lensing that will occur.\nModel high energy jet formation and showers through calorimeters of high-energy physics experiments.\nApproximate bottlenecks in computationally expensive simulations of particle physics experiments. Applications in the context of present and proposed CERN experiments have demonstrated the potential of these methods for accelerating simulation and/or improving simulation fidelity.\nReconstruct velocity and scalar fields in turbulent flows.\nGAN-generated molecules were validated experimentally in mice.\n\n\nMedical\nGAN has been used for generating synthetic medical images, such as MRI and PET images.\nGAN can be used to detect glaucomatous images helping the early diagnosis which is essential to avoid partial or total loss of vision.\nGANs have been used to create forensic facial reconstructions of deceased historical figures.\n\n\nMalicious\n\nConcerns have been raised about the potential use of GAN-based human image synthesis for sinister purposes, e.g., to produce fake, possibly incriminating, photographs and videos.\nGANs can be used to generate unique, realistic profile photos of people who do not exist, in order to automate creation of fake social media profiles.\nIn 2019 the state of California considered and passed on October 3, 2019, the bill AB-602, which bans the use of human image synthesis technologies to make fake pornography without the consent of the people depicted, and bill AB-730, which prohibits distribution of manipulated videos of a political candidate within 60 days of an election. Both bills were authored by Assembly member Marc Berman and signed by Governor Gavin Newsom. The laws went into effect in 2020.\nDARPA's Media Forensics program studies ways to counteract fake media, including fake media produced using GANs.\n\n\nFashion, art and advertising\nGANs can be used to generate art; The Verge wrote in March 2019 that \"The images created by GANs have become the defining look of contemporary AI art.\" GANs can also be used to\n\ninpaint photographs\ngenerate fashion models, shadows, photorealistic renders of interior design, industrial design, shoes, etc. Such networks were reported to be used by Facebook.\nSome have worked with using GAN for artistic creativity, as \"creative adversarial network\". A GAN, trained on a set of 15,000 portraits from WikiArt from the 14th to the 19th century, created the 2018 painting Edmond de Belamy, which sold for US$432,500.\nGANs were used by the video game modding community to up-scale low-resolution 2D textures in old video games by recreating them in 4k or higher resolutions via image training, and then down-sampling them to fit the game's native resolution (resembling supersampling anti-aliasing).\nIn 2020, Artbreeder was used to create the main antagonist in the sequel to the psychological web horror series Ben Drowned. The author would later go on to praise GAN applications for their ability to help generate assets for independent artists who are short on budget and manpower.\nIn May 2020, Nvidia researchers taught an AI system (termed \"GameGAN\") to recreate the game of Pac-Man simply by watching it being played.\nIn August 2019, a large dataset consisting of 12,197 MIDI songs each with paired lyrics and melody alignment was created for neural melody generation from lyrics using conditional GAN-LSTM (refer to sources at GitHub AI Melody Generation from Lyrics).\n\n\nMiscellaneous\nGANs have been used to \n\nshow how an individual's appearance might change with age.\nreconstruct 3D models of objects from images,\ngenerate novel objects as 3D point clouds,\nmodel patterns of motion in video.\ninpaint missing features in maps, transfer map styles in cartography or augment street view imagery.\nuse feedback to generate images and replace image search systems.\nvisualize the effect that climate change will have on specific houses.\nreconstruct an image of a person's face after listening to their voice.\nproduces videos of a person speaking, given only a single photo of that person.\nrecurrent sequence generation.\n\n\nHistory\nIn 1991, Juergen Schmidhuber published \"artificial curiosity\", neural networks in a zero-sum game. The first network is a generative model that models a probability distribution over output patterns. The second network learns by gradient descent to predict the reactions of the environment to these patterns. GANs can be regarded as a case where the environmental reaction is 1 or 0 depending on whether the first network's output is in a given set.\nOther people had similar ideas but did not develop them similarly. An idea involving adversarial networks was published in a 2010 blog post by Olli Niemitalo. This idea was never implemented and did not involve stochasticity in the generator and thus was not a generative model. An idea similar to GANs was used to model animal behavior by Wei Li, Melvin Gauci and Roderich Gross in 2013.\nAnother inspiration for GANs was noise-contrastive estimation, which uses the same loss function as GANs and which Goodfellow studied during his PhD in 2010–2014.\nAdversarial machine learning has other uses besides generative modeling and can be applied to models other than neural networks. In control theory, adversarial learning based on neural networks was used in 2006 to train robust controllers in a game theoretic sense, by alternating the iterations between a minimizer policy, the controller, and a maximizer policy, the disturbance.\nIn 2017, a GAN was used for image enhancement focusing on realistic textures rather than pixel-accuracy, producing a higher image quality at high magnification. In 2017, the first faces were generated. These were exhibited in February 2018 at the Grand Palais. Faces generated by StyleGAN in 2019 drew comparisons with Deepfakes.\n\n\nSee also\nArtificial intelligence art – Visual content generation through artificial intelligencePages displaying short descriptions of redirect targets\nDeepfake – Realistic artificially generated media\nDeep learning – Branch of machine learning\nDiffusion model – Technique for the generative modeling of a continuous probability distribution\nGenerative AI – AI that generates content\nSynthetic media – Artificial production of media by automated means\n\n\nReferences\n\n\nExternal links\n\nKnight, Will. \"5 Big Predictions for Artificial Intelligence in 2017\". MIT Technology Review. Retrieved January 5, 2017.\nKarras, Tero; Laine, Samuli; Aila, Timo (2018). \"A Style-Based Generator Architecture for Generative Adversarial Networks\". arXiv:1812.04948 [cs.NE].\nThis Person Does Not Exist – photorealistic images of people who do not exist, generated by StyleGAN\nThis Cat Does Not Exist Archived March 5, 2019, at the Wayback Machine – photorealistic images of cats who do not exist, generated by StyleGAN\nWang, Zhengwei; She, Qi; Ward, Tomas E. (2019). \"Generative Adversarial Networks in Computer Vision: A Survey and Taxonomy\". arXiv:1906.01529 [cs.LG].", "categories": ["2014 in artificial intelligence", "Articles with short description", "CS1 maint: multiple names: authors list", "CS1 maint: numeric names: authors list", "Cognitive science", "Generative AI", "Neural network architectures", "Pages displaying short descriptions of redirect targets via Module:Annotated link", "Short description is different from Wikidata", "Unsupervised learning", "Use mdy dates from April 2021", "Webarchive template wayback links"], "references": ["http://3dgan.csail.mit.edu/", "https://www.nytimes.com/2018/10/25/arts/design/ai-art-sold-christies.html", "https://www.lyrn.ai/2018/12/26/a-style-based-generator-architecture-for-generative-adversarial-networks/", "https://www.inverse.com/article/53280-this-person-does-not-exist-gans-website=website=Inverse", "https://boingboing.net/2019/02/15/this-person-does-not-exist.html", "https://tech.slashdot.org/story/19/02/14/199200/this-person-does-not-exist-website-uses-ai-to-create-realistic-yet-horrifying-faces", "https://github.com/NVlabs/stylegan", "https://link.medium.com/MYqBrGHIKV", "https://www.scientificamerican.com/article/when-will-computers-have-common-sense-ask-facebook/", "https://www.thispersondoesnotexist.com/", "https://medium.com/@alagraphy/this-person-does-not-exist-neither-will-anything-if-artificial-intelligence-keeps-learning-1a9fcba728f", "https://www.issuewire.com/artificial-intelligence-enters-the-history-of-art-1620667772563815", "https://www.technologyreview.com/s/603216/5-big-predictions-for-artificial-intelligence-in-2017/", "https://geods.geography.wisc.edu/archives/1192", "http://proceedings.mlr.press/v9/gutmann10a/gutmann10a.pdf"], "images": ["File:Ballerina-icon.jpg", "File:GAN deepfake white girl.jpg", "File:StyleGAN-1 and StyleGAN-2.png"], "sub_niche": "Adversarial machine learning"} {"title": "Artificial intelligence", "url": "https://en.wikipedia.org/wiki/Artificial_intelligence", "summary": "Artificial intelligence (AI) is the capability of computational systems to perform tasks typically associated with human intelligence, such as learning, reasoning, problem-solving, perception, and decision-making. It is a field of research in engineering, mathematics, and computer science that develops and studies methods and software that enable machines to perceive their environment and use learning and intelligence to take actions that maximise their chances of achieving defined goals.\nHigh-profile applications of AI include advanced web search engines, chatbots, virtual assistants, autonomous vehicles, play and analysis in strategy games (e.g., chess and Go), and content generation (e.g. images, audio, and videos).\nThe traditional goals of AI research include learning, reasoning, knowl", "content": "Artificial intelligence (AI) is the capability of computational systems to perform tasks typically associated with human intelligence, such as learning, reasoning, problem-solving, perception, and decision-making. It is a field of research in engineering, mathematics, and computer science that develops and studies methods and software that enable machines to perceive their environment and use learning and intelligence to take actions that maximise their chances of achieving defined goals.\nHigh-profile applications of AI include advanced web search engines, chatbots, virtual assistants, autonomous vehicles, play and analysis in strategy games (e.g., chess and Go), and content generation (e.g. images, audio, and videos).\nThe traditional goals of AI research include learning, reasoning, knowledge representation, planning, natural language processing, and perception, as well as support for robotics. To reach these goals, AI researchers use techniques including state space search and mathematical optimisation, formal logic, artificial neural networks, and methods based on statistics, operations research, and economics. AI also draws upon psychology, linguistics, philosophy, neuroscience, and other fields. Some companies, such as OpenAI, Google DeepMind, and Meta, aim to create artificial general intelligence (AGI)—AI that can complete nearly any cognitive task at least as well as a human.\nArtificial intelligence was founded as an academic discipline in 1956. The field went through multiple cycles of optimism throughout its history, followed by periods of disappointment and loss of funding, known as AI winters. Funding and interest increased substantially after 2012, when graphics processing units (GPUs) started being used to accelerate neural networks, and deep learning outperformed previous AI techniques. This growth accelerated further after 2017 with the transformer architecture. In the 2020s, an AI boom coincided with advances in generative AI, which became widespread and allowed for the creation and modification of media. In addition to AI safety and unintended consequences and harms from the use of AI, ethical concerns, AI's long-term effects, environmental effects, and potential existential risks have prompted discussions of AI regulation.\n\n\nGoals\nThe general problem of simulating (or creating) intelligence has been broken down into subproblems. These consist of specific traits or capabilities that researchers expect an intelligent system to display. The traits described below have received the most attention and cover the scope of AI research.\n\n\nReasoning and problem-solving\nEarly researchers developed algorithms that imitated step-by-step reasoning that humans use when solving puzzles or making logical deductions. By the late 1980s and 1990s, methods were developed for dealing with uncertain or incomplete information, employing concepts from probability and economics.\nMany of these algorithms were insufficient for solving large reasoning problems because they experienced a \"combinatorial explosion\", meaning they become exponentially slower as the problems grow. Even humans rarely use the step-by-step deduction that early AI research could model. Humans solve most of their problems using fast, intuitive judgments.\nReasoning models, a type of large language model (LLM) trained to generate intermediate chains-of-thought, emerged in 2024 and allowed improved performance on complex problems in mathematics and coding. These models can produce incorrect outputs or \"hallucinations,\" unlike symbolic reasoning systems.\n\n\nKnowledge representation\n\nAI programs use knowledge to answer questions intelligently and make deductions about real-world facts.\nFormal knowledge representation and knowledge engineering use symbols to represent words, concepts and things in the world. A knowledge base is a body of knowledge represented in a form that can be used by a program. An ontology is the set of objects, relations, concepts, and properties used by a particular domain of knowledge. Formal knowledge has been studied extensively since the 1970s and researchers have developed formalisms for a wide variety of difficult domains.\nThe symbolic approach has difficulty with several problems: the breadth of commonsense knowledge (the set of atomic facts the average person knows is enormous), the sub-symbolic form of most commonsense knowledge (much of what people know is not represented as \"facts\" or \"statements\" they can express verbally), and knowledge acquisition (the problem of obtaining knowledge for AI applications).\nLarge language models (and some other AI programs developed since 2012) do not require explicit, symbolic knowledge. They acquire knowledge by being trained on the combined text of millions of books and billions of websites. Modern AI can also learn about a domain by running experiments (as when AlphaZero learns game strategy by playing against itself). Machine learning solves the problems of general knowledge, commonsense knowledge and knowledge acquisition, however, this approach has struggled with accurate recall and valid reasoning.\n\n\nPlanning and decision-making\nAn \"agent\" is any entity (artificial or not) that perceives and takes actions in the world. A rational agent has goals or preferences and takes actions to make them happen. In automated planning, the agent has a specific goal. In automated decision-making, the agent has preferences—there are some situations it would prefer to be in, and some situations it is trying to avoid. The decision-making agent assigns a number to each situation (called its \"utility\") that measures how much the agent prefers it. For each possible action, it can calculate the \"expected utility\": the utility of all possible outcomes of the action, weighted by the probability that the outcome will occur. It can then choose the action with the maximum expected utility.\nIn classical planning, the agent knows exactly what the effect of any action will be. In most real-world problems, however, the agent may not be certain about the situation it is in (it is \"unknown\" or \"unobservable\") and it may not know for certain what will happen after each possible action (it is not \"deterministic\"). It must choose an action by making a probabilistic guess and then reassess the situation to see if the action worked. \nAlongside thorough testing and improvement based on previous decisions, having an explanation for why the agent took certain decisions is a way to build trust, especially when the decisions have to be relied upon.\nIn some problems, the agent's preferences may be uncertain, especially if there are other agents or humans involved. These preferences may be learned (e.g., with inverse reinforcement learning), or the agent can seek information to improve them. Information value theory can be used to weigh the value of exploratory or experimental actions. The space of possible future actions and situations is typically intractably large, so the agents must take actions and evaluate situations while being uncertain of the outcome.\nA Markov decision process has a transition model that describes the probability that a particular action will change the state in a particular way and a reward function that supplies the utility of each state and the cost of each action. A policy associates a decision with each possible state. The policy could be calculated (e.g., by policy iteration), determined by a heuristic, or learned.\nGame theory describes the rational behaviour of multiple interacting agents and is used in AI programs that make decisions involving other agents.\n\n\nLearning\nMachine learning is the study of programs that can improve their performance on a given task automatically. It has been a part of AI from the beginning.\n\nThere are several kinds of machine learning: \n\nUnsupervised learning analyses a stream of data, finds patterns, and makes predictions without any other guidance.\nSupervised learning requires labelling the training data with the expected answers, and comes in two main varieties: classification (where the program must learn to predict what category the input belongs in) and regression (where the program must deduce a numeric function based on numeric input).\nReinforcement learning is when the agent is rewarded for good responses and punished for bad ones. The agent learns to choose responses that are classified as \"good\".\nTransfer learning is when the knowledge gained from one problem is applied to a new problem.\nDeep learning is a type of machine learning that runs inputs through biologically inspired artificial neural networks for all of these types of learning.\nComputational learning theory can assess learners by computational complexity, sample complexity (how much data is required), or other notions of optimisation.\n\n\nNatural language processing\nNatural language processing (NLP) allows programs to read, write, and communicate in human languages. Specific problems include speech recognition, speech synthesis, machine translation, information extraction, information retrieval, and question answering.\nEarly work, based on Noam Chomsky's generative grammar and semantic networks, had difficulty with word-sense disambiguation unless restricted to small domains called \"micro-worlds\" (due to the common sense knowledge problem). British linguist and philosopher Margaret Masterman believed it was meaning and not grammar that was the key to understanding languages, and that dictionaries and especially thesauri should be the basis of computational language structure.\nModern deep learning techniques for NLP include word embedding (representing words, typically as vectors encoding their meaning), transformers (a deep learning architecture using an attention mechanism), and others. In 2019, generative pre-trained transformer (or \"GPT\") language models began to generate coherent text. By 2023, these models were able to get human-level scores on the bar exam, SAT (Scholastic Assessment Test), GRE (Graduate Record Examination), and many other real-world applications.\n\n\nPerception\nMachine perception is the ability to use input from sensors (such as cameras, microphones, wireless signals, active lidar, sonar, radar, and tactile sensors) to deduce aspects of the world. Computer vision is the ability to analyse visual input.\nThe field includes speech recognition, image classification, facial recognition, object recognition, object tracking, and robotic perception.\n\n\nSocial intelligence\n\nAffective computing is a field that comprises systems that recognise, interpret, process, or simulate human affect (feeling, emotion, and mood). For example, some virtual assistants are programmed to speak conversationally or even banter humorously; it makes them appear more sensitive to the emotional dynamics of human interaction, or to otherwise facilitate human–computer interaction.\nHowever, this tends to give naïve users an unrealistic conception of the intelligence of existing computer agents. Moderate successes related to affective computing include textual sentiment analysis and, more recently, multimodal sentiment analysis, wherein AI classifies the effects displayed by a videotaped subject.\n\n\nGeneral intelligence\nA machine with artificial general intelligence (AGI) would be able to solve a wide variety of problems with breadth and versatility similar to human intelligence.\n\n\nTechniques\nAI research uses a wide variety of techniques to accomplish the goals above.\n\n\nSearch and optimisation\nThere are two different kinds of search used in AI: state space search and local search:\n\n\nState space search\nState space search searches through a tree of possible states to try to find a goal state. For example, planning algorithms search through trees of goals and subgoals, attempting to find a path to a target goal, a process called means-ends analysis.\nSimple exhaustive searches are rarely sufficient for most real-world problems: the search space (the number of places to search) quickly grows to astronomical numbers. The result is a search that is too slow or never completes. \"Heuristics\" or \"rules of thumb\" can help prioritise choices that are more likely to reach a goal.\nAdversarial search is used for game-playing programs, such as chess or Go. It searches through a tree of possible moves and countermoves, looking for a winning position.\n\n\nLocal search\n\nLocal search uses mathematical optimisation to find a solution to a problem. It begins with some form of guess and refines it incrementally.\nGradient descent is a type of local search that optimises a set of numerical parameters by incrementally adjusting them to minimise a loss function. Variants of gradient descent are commonly used to train neural networks, through the backpropagation algorithm.\nAnother type of local search is evolutionary computation, which aims to iteratively improve a set of candidate solutions by \"mutating\" and \"recombining\" them, selecting only the fittest to survive each generation.\nDistributed search processes can coordinate via swarm intelligence algorithms. Two popular swarm algorithms used in search are particle swarm optimisation (inspired by bird flocking) and ant colony optimisation (inspired by ant trails).\n\n\nLogic\nFormal logic is used for reasoning and knowledge representation.\nFormal logic comes in two main forms: propositional logic (which operates on statements that are true or false and uses logical connectives such as \"and\", \"or\", \"not\" and \"implies\") and predicate logic (which also operates on objects, predicates and relations and uses quantifiers such as \"Every X is a Y\" and \"There are some Xs that are Ys\").\nDeductive reasoning in logic is the process of proving a new statement (conclusion) from other statements that are given and assumed to be true (the premises). Proofs can be structured as proof trees, in which nodes are labelled by sentences, and children nodes are connected to parent nodes by inference rules.\nGiven a problem and a set of premises, problem-solving reduces to searching for a proof tree whose root node is labelled by a solution of the problem and whose leaf nodes are labelled by premises or axioms. In the case of Horn clauses, problem-solving search can be performed by reasoning forwards from the premises or backwards from the problem. In the more general case of the clausal form of first-order logic, resolution is a single, axiom-free rule of inference, in which a problem is solved by proving a contradiction from premises that include the negation of the problem to be solved.\nInference in both Horn clause logic and first-order logic is undecidable, and therefore intractable. However, backward reasoning with Horn clauses, which underpins computation in the logic programming language Prolog, is Turing complete. Moreover, its efficiency is competitive with computation in other symbolic programming languages.\nFuzzy logic assigns a \"degree of truth\" between 0 and 1. It can therefore handle propositions that are vague and partially true.\nNon-monotonic logics, including logic programming with negation as failure, are designed to handle default reasoning. Other specialised versions of logic have been developed to describe many complex domains.\n\n\nProbabilistic methods for uncertain reasoning\n\nMany problems in AI (including reasoning, planning, learning, perception, and robotics) require the agent to operate with incomplete or uncertain information. AI researchers have devised a number of tools to solve these problems using methods from probability theory and economics. Precise mathematical tools have been developed that analyse how an agent can make choices and plan, using decision theory, decision analysis, and information value theory. These tools include models such as Markov decision processes, dynamic decision networks, game theory and mechanism design.\nBayesian networks are a tool that can be used for reasoning (using the Bayesian inference algorithm), learning (using the expectation–maximisation algorithm), planning (using decision networks) and perception (using dynamic Bayesian networks).\nProbabilistic algorithms can also be used for filtering, prediction, smoothing, and finding explanations for streams of data, thus helping perception systems analyse processes that occur over time (e.g., hidden Markov models or Kalman filters).\n\n\nClassifiers and statistical learning methods\nThe simplest AI applications can be divided into two types: classifiers (e.g., \"if shiny then diamond\"), on one hand, and controllers (e.g., \"if diamond then pick up\"), on the other hand. Classifiers are functions that use pattern matching to determine the closest match. They can be fine-tuned based on chosen examples using supervised learning. Each pattern (also called an \"observation\") is labeled with a certain predefined class. All the observations combined with their class labels are known as a data set. When a new observation is received, that observation is classified based on previous experience.\nThere are many kinds of classifiers in use. The decision tree is the simplest and most widely used symbolic machine learning algorithm. K-nearest neighbour algorithm was the most widely used analogical AI until the mid-1990s, and Kernel methods such as the support vector machine (SVM) displaced k-nearest neighbour in the 1990s.\nThe naive Bayes classifier is reportedly the \"most widely used learner\" at Google, due in part to its scalability.\nNeural networks are also used as classifiers.\n\n\nArtificial neural networks\n\nAn artificial neural network is based on a collection of nodes also known as artificial neurons, which loosely model the neurons in a biological brain. It is trained to recognise patterns; once trained, it can recognise those patterns in fresh data. There is an input, at least one hidden layer of nodes and an output. Each node applies a function and once the weight crosses its specified threshold, the data is transmitted to the next layer. A network is typically called a deep neural network if it has at least 2 hidden layers.\nLearning algorithms for neural networks use local search to choose the weights that will get the right output for each input during training. The most common training technique is the backpropagation algorithm. Neural networks learn to model complex relationships between inputs and outputs and find patterns in data. In theory, a neural network can learn any function.\nIn feedforward neural networks the signal passes in only one direction. The term perceptron typically refers to a single-layer neural network. In contrast, deep learning uses many layers. Recurrent neural networks (RNNs) feed the output signal back into the input, which allows short-term memories of previous input events. Long short-term memory networks (LSTMs) are recurrent neural networks that better preserve longterm dependencies and are less sensitive to the vanishing gradient problem. Convolutional neural networks (CNNs) use layers of kernels to more efficiently process local patterns. This local processing is especially important in image processing, where the early CNN layers typically identify simple local patterns such as edges and curves, with subsequent layers detecting more complex patterns like textures, and eventually whole objects.\n\n\nDeep learning\n\nDeep learning uses several layers of neurons between the network's inputs and outputs. The multiple layers can progressively extract higher-level features from the raw input. For example, in image processing, lower layers may identify edges, while higher layers may identify the concepts relevant to a human such as digits, letters, or faces.\nDeep learning has profoundly improved the performance of programs in many important subfields of artificial intelligence, including computer vision, speech recognition, natural language processing, image classification, and others. The sudden success of deep learning in 2012–2015 did not occur because of some new discovery or theoretical breakthrough (deep neural networks and backpropagation had been described by many people, as far back as the 1950s) but because of two factors: the increase in computer power (including the hundred-fold increase in speed by switching to GPUs) and the availability of vast amounts of training data, especially the giant curated datasets used for benchmark testing, such as ImageNet.\n\n\nGPT\nGenerative pre-trained transformers (GPTs) are large language models (LLMs) that generate text based on the semantic relationships between words in sentences. Text-based GPT models are pre-trained on a large corpus of text that can be from the Internet. The pretraining consists of predicting the next token (a token being usually a word, subword, or punctuation). Throughout this pretraining, GPT models accumulate knowledge about the world and can then generate human-like text by repeatedly predicting the next token. Typically, a subsequent training phase makes the model more truthful, useful, and harmless, usually with a technique called reinforcement learning from human feedback (RLHF). Current GPT models are prone to generating falsehoods called \"hallucinations\". These can be reduced with RLHF and quality data, but the problem has been getting worse for reasoning systems. Such systems are used in chatbots, which allow people to ask a question or request a task in simple text.\nCurrent models and services include ChatGPT, Claude, Gemini, Copilot, and Meta AI. Multimodal GPT models can process different types of data (modalities) such as images, videos, sound, and text.\n\n\nHardware and software\n\nIn the late 2010s, graphics processing units (GPUs) that were increasingly designed with AI-specific enhancements and used with specialised TensorFlow software had replaced previously used central processing unit (CPUs) as the dominant means for large-scale (commercial and academic) machine learning models' training. Specialised programming languages such as Prolog were used in early AI research, but general-purpose programming languages like Python have become predominant.\nThe transistor density in integrated circuits has been observed to roughly double every 18 months—a trend known as Moore's law, named after the Intel co-founder Gordon Moore, who first identified it. Improvements in GPUs have been even faster, a trend sometimes called Huang's law, named after Nvidia co-founder and CEO Jensen Huang.\n\n\nApplications\n\nAI and machine learning technology is used in most of the essential applications of the 2020s, including:\n\nsearch engines (such as Google Search)\ntargeting online advertisements\nrecommendation systems (offered by Netflix, YouTube or Amazon) driving internet traffic\ntargeted advertising (AdSense, Facebook)\nvirtual assistants (such as Siri or Alexa)\nautonomous vehicles (including drones, ADAS and self-driving cars)\nautomatic language translation (Microsoft Translator, Google Translate)\nfacial recognition (Apple's FaceID or Facebook's DeepFace and Google's FaceNet)\nimage labelling (used by Facebook, Apple's Photos and TikTok).\n\n\nAI-assisted software development\n\n\nChatbots\n\n\nPhysical AI\n\n\nHealth and medicine\n\nAlphaFold 2 (2021) demonstrated the ability to approximate, in hours rather than months, the 3D structure of a protein. In 2023, it was reported that AI-guided drug discovery helped find a class of antibiotics capable of killing two different types of drug-resistant bacteria. In 2024, researchers used machine learning to accelerate the search for Parkinson's disease drug treatments. Their aim was to identify compounds that block the clumping, or aggregation, of alpha-synuclein (the protein that characterises Parkinson's disease). They were able to speed up the initial screening process ten-fold and reduce the cost by a thousand-fold.\nA 2026 Nature article titled \"Dozens of AI disease-prediction models were trained on dubious data\" highlighted the use of unreliable data being used to train AI medical prediction models for stroke and diabetes in 125 research articles. Evidence suggested some of the AI tools that were developed on unreliable data had been used on patients, although it was not clear if there were adverse outcomes.\n\n\nGaming\n\nGame playing programs have been used since the 1950s to demonstrate and test AI's most advanced techniques. Deep Blue became the first computer chess-playing system to beat a reigning world chess champion, Garry Kasparov, on 11 May 1997. In 2011, in a Jeopardy! quiz show exhibition match, IBM's question answering system, Watson, defeated the two greatest Jeopardy! champions, Brad Rutter and Ken Jennings, by a significant margin. In March 2016, AlphaGo won 4 out of 5 games of Go in a match with Go champion Lee Sedol, becoming the first computer Go-playing system to beat a professional Go player without handicaps. Then, in 2017, it defeated Ke Jie, who was the best Go player in the world. Other programs handle imperfect-information games, such as the poker-playing program Pluribus. DeepMind developed increasingly generalistic reinforcement learning models, such as with MuZero, which could be trained to play chess, Go, or Atari games. In 2019, DeepMind's AlphaStar achieved grandmaster level in StarCraft II, a particularly challenging real-time strategy game that involves incomplete knowledge of what happens on the map. In 2021, an AI agent competed in a PlayStation Gran Turismo competition, winning against four of the world's best Gran Turismo drivers using deep reinforcement learning. In 2024, Google DeepMind introduced SIMA, a type of AI capable of autonomously playing nine previously unseen open-world video games by observing screen output, as well as executing short, specific tasks in response to natural language instructions.\n\n\nMathematics\n\nIn January 2025, Microsoft proposed the technique rStar-Math that leverages Monte Carlo tree search and step-by-step reasoning, enabling a relatively small language model like Qwen-7B to solve 53% of the AIME 2024 and 90% of the MATH benchmark problems. Google DeepMind has developed models for solving mathematical problems: AlphaDev, AlphaEvolve, AlphaGeometry, AlphaProof, AlphaTensor, and FunSearch.\nWhen natural language is used to describe mathematical problems, converters can transform such prompts into a formal language such as Lean to define mathematical tasks. The experimental model Gemini Deep Think accepts natural language prompts directly and achieved gold medal results in the International Math Olympiad of 2025.\nIn June 2026, an international group of mathematicians published a statement calling on mathematicians, professional organizations, and policymakers to disclose the use of AI, uphold peer review, and protect the openness and values of the discipline.\nIn September 2026, OpenAI announced that one of their models had produced a counter-example to the Navier–Stokes existence and smoothness problem, a Millennium Prize Problem in mathematics. As of 2026, the claim has not been verified by any external mathematicians and is the subject of a priority dispute.\n\n\nFinance\nAccording to Nicolas Firzli, director of the World Pensions & Investments Forum, it may be too early to see the emergence of highly innovative AI-informed financial products and services. He argues that \"the deployment of AI tools will simply further automatise things: destroying tens of thousands of jobs in banking, financial planning, and pension advice in the process, but I'm not sure it will unleash a new wave of [e.g., sophisticated] pension innovation.\"\n\n\nMilitary\n\nMilitary AI usage attempts to enhance command and control, communications, sensors, integration and interoperability. Intelligence collection and analysis, logistics, cyber operations, information operations, and semiautonomous and autonomous vehicles are being researched. AI technologies are used in coordination of sensors and effectors, threat detection and identification, marking of enemy positions, target acquisition, coordination and deconfliction of distributed Joint Fires between networked combat vehicles, both human-operated and autonomous.\nAI has been used in military operations in Iraq, Syria, Israel and Ukraine.\n\n\nGenerative AI\n\n\nAgents\n\nAI agents are software entities designed to perceive their environment, make decisions, and take actions autonomously to achieve specific goals. These agents can interact with users, their environment, or other agents. AI agents are used in various applications, including virtual assistants, chatbots, autonomous vehicles, game-playing systems, and industrial robotics. AI agents operate within the constraints of their programming, available computational resources, and hardware limitations. This means they are restricted to performing tasks within their defined scope and have finite memory and processing capabilities. In real-world applications, AI agents often face time constraints for decision-making and action execution. Many AI agents incorporate learning algorithms, enabling them to improve their performance over time through experience or training. Using machine learning, AI agents can adapt to new situations and optimise their behaviour for their designated tasks.\n\n\nWeb search\nMicrosoft introduced Copilot Search in February 2023 under the name Bing Chat. Copilot Search provides AI-generated summaries.\nGenerative AI features added to Google Search include AI Overviews in May 2024 and AI Mode in May 2025.\n\n\nSexuality\nApplications of AI in this domain include AI-enabled menstruation and fertility trackers that analyse user data to offer predictions, AI-integrated sex toys (e.g., teledildonics), AI-generated sexual education content, and AI agents that simulate sexual and romantic partners (e.g., Replika). AI is also used for the production of non-consensual deepfake pornography, raising significant ethical and legal concerns.\nAI technologies have also been used to attempt to identify online gender-based violence and online sexual grooming of minors.\n\n\nOther industry-specific tasks\nIn a 2017 survey, one in five companies reported having incorporated \"AI\" in some offerings or processes. \nIn the field of evacuation and disaster management, AI has been used to investigate patterns in large-scale and small-scale evacuations using historical data from GPS, videos or social media.\nDuring the 2024 Indian elections, US$50 million was spent on authorised AI-generated content, notably by creating deepfakes of allied (including sometimes deceased) politicians to better engage with voters, and by translating speeches to various local languages.\nThe use of generative AI by law firms for legal research resulted in the creation of the global \"AI Hallucination Cases\" database, in April 2025, established by HEC Paris and Sciences Po legal data analysis lecturer Damien Charlotin. By 2026, judges had issued sanctions and bar associations had issued warnings due to attorney submissions to the courts containing fabricated case law citations hallucinated by AI tools.\n\n\nEthics\nAI has potential benefits and potential risks. AI may be able to advance science and find solutions for serious problems: Demis Hassabis of DeepMind hopes to \"solve intelligence, and then use that to solve everything else\". However, as the use of AI has become widespread, several unintended consequences and risks have been identified. In-production systems can sometimes not factor ethics and bias into their AI training processes, especially when the AI algorithms are inherently unexplainable in deep learning.\n\n\nRisks and harm\n\n\nPrivacy and copyright\n\nMachine learning algorithms require large amounts of data. The techniques used to acquire this data have raised concerns about privacy, surveillance and copyright.\nAI-powered devices and services, such as virtual assistants and IoT products, continuously collect personal information, raising concerns about intrusive data gathering and unauthorised access by third parties. The loss of privacy is further exacerbated by AI's ability to process and combine vast amounts of data, potentially leading to a surveillance society where individual activities are constantly monitored and analysed without adequate safeguards or transparency.\nSensitive user data collected may include online activity records, geolocation data, video, or audio. For example, in order to build speech recognition algorithms, Amazon has recorded millions of private conversations and allowed temporary workers to listen to and transcribe some of them. Opinions about this widespread surveillance range from those who see it as a necessary evil to those for whom it is clearly unethical and a violation of the right to privacy.\nAI developers argue that this is the only way to deliver valuable applications and have developed several techniques that attempt to preserve privacy while still obtaining the data, such as data aggregation, de-identification and differential privacy. Since 2016, some privacy experts, such as Cynthia Dwork, have begun to view privacy in terms of fairness. Brian Christian wrote that experts have pivoted \"from the question of 'what they know' to the question of 'what they're doing with it'.\"\nGenerative AI is often trained on unlicensed copyrighted works, including in domains such as images or computer code; the output is then used under the rationale of \"fair use\". Experts disagree about how well and under what circumstances this rationale will hold up in courts of law; relevant factors may include \"the purpose and character of the use of the copyrighted work\" and \"the effect upon the potential market for the copyrighted work\". Website owners can indicate that they do not want their content scraped via a \"robots.txt\" file. However, some companies will scrape content regardless because the robots.txt file has no real authority. In 2023, leading authors (including John Grisham and Jonathan Franzen) sued AI companies for using their work to train generative AI. Another discussed approach is to envision a separate sui generis system of protection for creations generated by AI to ensure fair attribution and compensation for human authors.\n\n\nDominance by tech giants\nThe commercial AI scene is dominated by Big Tech companies such as Alphabet Inc., Amazon, Apple Inc., Meta Platforms, and Microsoft. Some of these companies already own the vast majority of existing cloud infrastructure and computing power from data centres, allowing them to entrench further in the marketplace. For most of 2025-2026, AI-related companies have also dominated stock market returns. According to a July 2024 report from S&P Global, investors had started questioning whether the enormous spending on AI infrastructure and data centers would generate sufficient profits, leading to increased volatility in technology and semiconductor stocks and to concerns about a potential AI bubble. In a 2025 Economic Policy article, economists Anton Korinek and Jai Vipra described some AI related market sectors as highly concentrated.\n\n\nPower needs and environmental impacts\n\nTechnology companies have built electricity and artificial intelligence infrastructure to facilitate the AI boom of the 2020s. A 2025 report from the consulting firm McKinsey & Company estimated that by 2030, $2.7 trillion would be invested into AI infrastructure and data centres in the US, surpassing World War II's Manhattan Project every month.\nIn January 2024, the International Energy Agency (IEA) released Electricity 2024, Analysis and Forecast to 2026. This is the first IEA report to make projections for data centres and power consumption by AI and cryptocurrency. The report states that power demand for these uses might double by 2026, with the additional power consumption equaling that of Japan.\nPower consumption by AI is responsible for an increase in fossil fuel use, and has delayed closings of obsolete, carbon-emitting coal energy facilities. A ChatGPT search involves 10 times as much electrical energy as a Google search.\nA 2024 Goldman Sachs research paper, AI Data Centers and the Coming US Power Demand Surge, found \"US power demand (is) likely to experience growth not seen in a generation....\" and forecasts that, by 2030, US data centres will consume 8% of US power, as opposed to 3% in 2022, presaging growth for the electrical power generation industry by a variety of means. Data centres' need for more and more electrical power is such that they might max out the electrical grid. The Big Tech companies counter that AI can be used to maximise the utilisation of the grid by all.\nIn 2024, The Wall Street Journal reported that big AI companies have begun negotiations with the US nuclear power providers to provide electricity to the data centres. In March 2024, Amazon purchased a Pennsylvania nuclear-powered data centre for US$650 million.\nIn September 2024, Microsoft announced an agreement with Constellation Energy to re-open the Three Mile Island nuclear power plant to provide Microsoft with 100% of all electric power produced by the plant for 20 years. Reopening the plant, which suffered a partial nuclear meltdown of its Unit 2 reactor in 1979, will require Constellation to get through strict regulatory processes which will include extensive safety scrutiny from the US Nuclear Regulatory Commission. If approved (this will be the first ever US re-commissioning of a nuclear plant), over 835 megawatts of power – enough for 800,000 homes – will be produced. The cost for re-opening and upgrading is estimated at US$1.6 billion and is dependent on tax breaks for nuclear power contained in the 2022 US Inflation Reduction Act. As of 2024, the US government and the state of Michigan have been investing almost US$2 billion to reopen the Palisades nuclear reactor on Lake Michigan. Closed since 2022, the plant was scheduled to be reopened in October 2025.\nAfter the last approval in September 2023, Taiwan suspended the approval of data centres north of Taoyuan with a capacity of more than 5 MW in 2024, due to power supply shortages. Taiwan aims to phase out nuclear power by 2025. \nSingapore imposed a ban on the opening of data centres in 2019 due to electric power, but lifted it in 2022.\nAlthough most nuclear plants in Japan have been shut down after the 2011 Fukushima nuclear accident, according to an October 2024 Bloomberg article in Japanese, cloud gaming services company Ubitus, in which Nvidia has a stake, is looking for land in Japan near a nuclear power plant for a new data centre for generative AI.\nOn 1 November 2024, the Federal Energy Regulatory Commission (FERC) rejected an application submitted by Talen Energy for approval to supply some electricity from the nuclear power station Susquehanna to Amazon's data centre.\nAccording to the Commission Chairman Willie L. Phillips, it is a burden on the electricity grid as well as a significant cost-shifting concern to households and other business sectors.\nIn 2025, a report prepared by the IEA estimated the greenhouse gas emissions from the energy consumption of AI at 180 million tons. By 2035, these emissions could rise to 300–500 million tonnes depending on what measures will be taken. This is below 1.5% of the energy sector emissions. The emissions reduction potential of AI was estimated at 5% of the energy sector emissions, but rebound effects (for example if people switch from public transport to autonomous cars) can reduce it.\nIn June 2026, the United Nations University Institute for Water, Environment and Health released a report about cumulative environmental impacts of AI, not only carbon. The report found that AI has significant negative impacts on land, water, and climate, as it uses large amounts of electricity, requires mining of minerals, and generates large amounts of electronic waste. In 2025, data centres consumed more electricity than Saudi Arabia, and ChatGPT alone consumed an amount of water equivalent to the needs of 500,000 people in Sub-Saharan Africa. The negative impacts are not distributed equally across the planet but are concentrated in some places. Data centres are often built in places already suffering from water deficit. For example, AI deployment has already led to an increase in water scarcity in Mexico and Uruguay. It created problems with energy supply in Ireland, which forbade construction of new data centres near Dublin until 2028. Measures can involve tradeoffs, for example, transitioning from coal to bioenergy reduces carbon footprint but increases the impact on land and water. Energy efficiency might not reduce environmental impact, because as AI becomes more efficient, it also becomes cheaper and more widely used.\n\n\nMisinformation\n\nYouTube, Facebook and others use recommender systems to guide users to more content. These AI programs were given the goal of maximising user engagement (that is, the only goal was to keep people watching). The AI learned that users tended to choose misinformation, conspiracy theories, and extreme partisan content, and, to keep them watching, the AI recommended more of it. Users also tended to watch more content on the same subject, so the AI led people into filter bubbles where they received multiple versions of the same misinformation. This convinced many users that the misinformation was true, and ultimately undermined trust in institutions, the media and the government. The AI program had correctly learned to maximise its goal, but the result was harmful to society. After the U.S. election in 2016, major technology companies took some steps to mitigate the problem.\nIn the early 2020s, generative AI began to create images, audio, and texts that are virtually indistinguishable from real photographs, recordings, or human writing, while realistic AI-generated videos became feasible in the mid-2020s. It is possible for bad actors to use this technology to create massive amounts of misinformation and computational propaganda through techniques such as deepfakes. AI pioneer and Nobel Prize-winning computer scientist Geoffrey Hinton expressed concern about AI enabling \"authoritarian leaders to manipulate their electorates\" on a large scale, among other risks. The ability to influence electorates has been proved in at least one study. This same study shows more inaccurate statements from the models when they advocate for candidates of the political right.\nAI researchers at Microsoft, OpenAI, universities and other organisations have suggested using \"personhood credentials\" as a way to overcome online deception enabled by AI models.\n\n\nAlgorithmic bias and fairness\n\nMachine learning applications can be biased if they learn from biased data. The developers may not be aware that the bias exists. Discriminatory behaviour by some LLMs can be observed in their output. Bias can be introduced by the way training data is selected and by the way a model is deployed. If a biased algorithm is used to make decisions that can seriously harm people (as it can in medicine, finance, recruitment, housing or policing) then the algorithm may cause discrimination. The field of fairness studies how to prevent harms from algorithmic biases.\nOn 28 June 2015, Google Photos's new image labelling feature mistakenly identified Jacky Alcine and a friend as \"gorillas\" because they were black. The system was trained on a dataset that contained very few images of black people, a problem called \"sample size disparity\". Google \"fixed\" this problem by preventing the system from labelling anything as a \"gorilla\". Eight years later, in 2023, Google Photos still could not identify a gorilla, and neither could similar products from Apple, Facebook, Microsoft and Amazon.\nCOMPAS is a commercial program widely used by U.S. courts to assess the likelihood of a defendant becoming a recidivist. In 2016, Julia Angwin at ProPublica discovered that COMPAS exhibited racial bias, despite the fact that the program was not told the races of the defendants. Although the error rate for both whites and blacks was calibrated equal at exactly 61%, the errors for each race were different—the system consistently overestimated the chance that a black person would re-offend and would underestimate the chance that a white person would not re-offend. In 2017, several researchers showed that it was mathematically impossible for COMPAS to accommodate all possible measures of fairness when the base rates of re-offence were different for whites and blacks in the data.\nA program can make biased decisions even if the data does not explicitly mention a problematic feature (such as \"race\" or \"gender\"). The feature will correlate with other features (like \"address\", \"shopping history\" or \"first name\"), and the program will make the same decisions based on these features as it would on \"race\" or \"gender\". Moritz Hardt said \"the most robust fact in this research area is that fairness through blindness doesn't work.\"\nCriticism of COMPAS highlighted that machine learning models are designed to make \"predictions\" that are only valid if we assume that the future will resemble the past. If they are trained on data that includes the results of racist decisions in the past, machine learning models must predict that racist decisions will be made in the future. If an application then uses these predictions as recommendations, some of these \"recommendations\" will likely be racist. Thus, machine learning is not well suited to help make decisions in areas where there is hope that the future will be better than the past. It is descriptive rather than prescriptive.\nBias and unfairness may go undetected because the developers are overwhelmingly white and male: among AI engineers, about 4% are black and 20% are women.\nThere are various conflicting definitions and mathematical models of fairness. These notions depend on ethical assumptions, and are influenced by beliefs about society. One broad category is distributive fairness, which focuses on the outcomes, often identifying groups and seeking to compensate for statistical disparities. Representational fairness tries to ensure that AI systems do not reinforce negative stereotypes or render certain groups invisible. Procedural fairness focuses on the decision process rather than the outcome. The most relevant notions of fairness may depend on the context, notably the type of AI application and the stakeholders. The subjectivity in the notions of bias and fairness makes it difficult for companies to operationalise them. Having access to sensitive attributes such as race or gender is also considered by many AI ethicists to be necessary in order to compensate for biases, but it may conflict with anti-discrimination laws.\nAt the 2022 ACM Conference on Fairness, Accountability, and Transparency a paper reported that a CLIP‑based (Contrastive Language-Image Pre-training) robotic system reproduced harmful gender‑ and race‑linked stereotypes in a simulated manipulation task. The authors recommended robot‑learning methods which physically manifest such harms be \"paused, reworked, or even wound down when appropriate, until outcomes can be proven safe, effective, and just.\"\n\n\nLack of transparency\n\nMany AI systems are so complex that their designers cannot explain how they reach their decisions. Particularly with deep neural networks, in which there are many non-linear relationships between inputs and outputs. But some popular explainability techniques exist.\nIt is impossible to be certain that a program is operating correctly if no one knows how exactly it works. There have been many cases where a machine learning program passed rigorous tests, but nevertheless learned something different from what the programmers intended. For example, a system that could identify skin diseases better than medical professionals was found to actually have a strong tendency to classify images with a ruler as \"cancerous\", because pictures of malignancies typically include a ruler to show the scale. Another machine learning system designed to help effectively allocate medical resources was found to classify patients with asthma as being at \"low risk\" of dying from pneumonia. Having asthma is actually a severe risk factor, but since the patients having asthma would usually get much more medical care, they were relatively unlikely to die according to the training data. The correlation between asthma and low risk of dying from pneumonia was real, but misleading.\nPeople who have been harmed by an algorithm's decision have a right to an explanation. Doctors, for example, are expected to clearly and completely explain to their colleagues the reasoning behind any decision they make. Early drafts of the European Union's General Data Protection Regulation in 2016 included an explicit statement that this right exists. Industry experts noted that this is an unsolved problem with no solution in sight. Regulators argued that nevertheless the harm is real: if the problem has no solution, the tools should not be used.\nDARPA established the XAI (\"Explainable Artificial Intelligence\") program in 2014 to try to solve these problems.\nSeveral approaches aim to address the transparency problem. SHAP enables to visualise the contribution of each feature to the output. LIME can locally approximate a model's outputs with a simpler, interpretable model. Multitask learning provides a large number of outputs in addition to the target classification. These other outputs can help developers deduce what the network has learned. Deconvolution, DeepDream and other generative methods can allow developers to see what different layers of a deep network for computer vision have learned, and produce output that can suggest what the network is learning. For generative pre-trained transformers, Anthropic developed a technique based on dictionary learning that associates patterns of neuron activations with human-understandable concepts.\n\n\nBad actors\n\nArtificial intelligence provides a number of tools that are useful to bad actors, such as authoritarian governments, terrorists, criminals or rogue states. There are many ways in which AI is expected to help bad actors, some of which can not be foreseen. For example, machine-learning AI is able to design tens of thousands of toxic molecules in a matter of hours.\n\n\nAuthoritarian governance\nAI tools make it easier for governments to efficiently control their citizens and can increase digital authoritarianism and political repression. Face and voice recognition allow widespread surveillance. Machine learning, operating this data, can classify potential enemies of the state and prevent them from hiding. Recommendation systems can precisely target propaganda and misinformation for maximum effect. Deepfakes and generative AI aid in producing misinformation. Advanced AI can make authoritarian centralised decision-making more competitive than liberal and decentralised systems such as markets. It lowers the cost and difficulty of digital warfare and advanced spyware. AI facial recognition systems are already being used for mass surveillance in China.\n\n\nTechnological unemployment\n\nEconomists have frequently highlighted the risks of redundancies from AI, and speculated about unemployment if there is no adequate social policy for full employment.\nThe Economist said in 2015 that \"the worry that AI could do to white-collar jobs what steam power did to blue-collar ones during the Industrial Revolution\" is \"worth taking seriously\". Jobs at extreme risk range from paralegals to fast food cooks, while job demand is likely to increase for care-related professions ranging from personal healthcare to the clergy. In July 2025, Ford CEO Jim Farley predicted that \"artificial intelligence is going to replace literally half of all white-collar workers in the U.S.\"\nAccording to the Stanford Digital Economy Lab in 2026, early-career workers showed decreasing employment rates in some AI-exposed occupations.\nIn April 2023, Rest of World reported that 70% of the jobs for Chinese video game illustrators had been eliminated by generative artificial intelligence.\n\n\nSubstitution for human–human interaction\n\nWith the increase of loneliness in the early 21st century, AI is sometimes identified as a potential source of relief to this problem. It would be possible, via human-like qualities built into AI products, for individuals to assume that this need can be met by artificial means. In some cases, people approach artificial intelligence for companionship when they believe that they would not find acceptance due to feeling outcast. Examples of harm coming to humans from advanced chatbots have been reported in courts in the United States, with AI companies accused of creating products that endanger humans through emotional confusion or deception.\n\n\nWeaponised AI\n\nA lethal autonomous weapon is a machine that locates, selects and engages human targets without human supervision. Widely available AI tools can be used by bad actors to develop inexpensive autonomous weapons and, if produced at scale, they are potentially weapons of mass destruction. Even when used in conventional warfare, they currently cannot reliably choose targets and could potentially kill an innocent person. In 2014, 30 nations (including China) supported a ban on autonomous weapons under the United Nations' Convention on Certain Conventional Weapons, however the United States and others disagreed. By 2015, over fifty countries were reported to be researching battlefield robots.\n\n\nExistential risk\n\nRecent public debates in artificial intelligence have increasingly focused on its broader societal and ethical implications. It has been argued AI will become so powerful that humanity may irreversibly lose control of it. This could, as physicist Stephen Hawking stated, \"spell the end of the human race\". This scenario has been common in science fiction, when a computer or robot suddenly develops a human-like \"self-awareness\" (or \"sentience\" or \"consciousness\") and becomes a malevolent character. These sci-fi scenarios are misleading in several ways.\nFirst, AI does not require human-like sentience to be an existential risk. Modern AI programs are given specific goals and use learning and intelligence to achieve them. Philosopher Nick Bostrom argued that if one gives almost any goal to a sufficiently powerful AI, it may choose to destroy humanity to achieve it (he used the example of an automated paperclip factory that destroys the world to get more iron for paperclips). Stuart Russell gives the example of household robot that tries to find a way to kill its owner to prevent it from being unplugged, reasoning that \"you can't fetch the coffee if you're dead.\" (These are examples of \"instrumental convergence\".) In order to be safe for humanity, a superintelligence would have to be genuinely aligned with humanity's morality and values so that it is \"fundamentally on our side\".\nSecond, Yuval Noah Harari argues that AI does not require a robot body or physical control to pose an existential risk. The essential parts of civilisation are not physical. Things like ideologies, law, government, money and the economy are built on language; they exist because there are stories that billions of people believe. The current prevalence of misinformation suggests that an AI could use language to convince people to believe anything, even to take actions that are destructive. Geoffrey Hinton said in 2025 that modern AI is particularly \"good at persuasion\" and getting better all the time. He asks, \"Suppose you wanted to invade the capital of the US. Do you have to go there and do it yourself? No. You just have to be good at persuasion.\"\nThe opinions amongst experts and industry insiders are mixed, with sizeable fractions both concerned and unconcerned by risk from eventual superintelligent AI. Personalities such as Stephen Hawking, Bill Gates, and Elon Musk, as well as AI pioneers such as Geoffrey Hinton, Yoshua Bengio, Stuart Russell, Demis Hassabis, and Sam Altman, have expressed concerns about existential risk from AI.\nIn May 2023, Geoffrey Hinton announced his resignation from Google in order to be able to \"freely speak out about the risks of AI\" without \"considering how this impacts Google\". He notably mentioned risks of an AI takeover, and stressed that in order to avoid the worst outcomes, establishing safety guidelines will require cooperation among those competing in use of AI.\nIn 2023, many leading AI experts endorsed the joint statement that \"Mitigating the risk of extinction from AI should be a global priority alongside other societal-scale risks such as pandemics and nuclear war\".\nSome other researchers were more optimistic. AI pioneer Jürgen Schmidhuber did not sign the joint statement, emphasising that in 95% of all cases, AI research is about making \"human lives longer and healthier and easier.\" While the tools that are now being used to improve lives can also be used by bad actors, \"they can also be used against the bad actors.\" Andrew Ng also argued that \"it's a mistake to fall for the doomsday hype on AI—and that regulators who do will only benefit vested interests.\" Yann LeCun, a Turing Award winner, disagreed with the idea that AI will subordinate humans \"simply because they are smarter, let alone destroy [us]\", \"scoff[ing] at his peers' dystopian scenarios of supercharged misinformation and even, eventually, human extinction.\" In contrast, he claimed that \"intelligent machines will usher in a new renaissance for humanity, a new era of enlightenment.\" In the early 2010s, experts argued that the risks are too distant in the future to warrant research or that humans will be valuable from the perspective of a superintelligent machine. However, after 2016, the study of current and future risks and possible solutions became a serious area of research. Some have argued that concerns about existential risks of AI could draw attention away from other AI risks.\n\n\nEthical machines and alignment\n\nFriendly AI are machines that have been designed from the beginning to minimise risks and to make choices that benefit humans. Eliezer Yudkowsky, who coined the term, argues that developing friendly AI should be a higher research priority: it may require a large investment and it must be completed before AI becomes an existential risk.\nMachines with intelligence have the potential to use their intelligence to make ethical decisions. The field of machine ethics provides machines with ethical principles and procedures for resolving ethical dilemmas.\nThe field of machine ethics is also called computational morality,\nand was founded at an AAAI symposium in 2005.\nGeoffrey Hinton has suggested researchers explore instilling human-aligned values, such as compassion, into AI systems as a safeguard, speculating about the possibility of building \"maternal instincts\" into AI models, so “they really care about people”.\nOther approaches include Wendell Wallach's \"artificial moral agents\" and Stuart J. Russell's three principles for developing provably beneficial machines.\n\n\nOpen source\n\nActive organisations in the AI open-source community include Hugging Face, Google, EleutherAI and Meta. Various AI models, such as Llama 2, Mistral or Stable Diffusion, have been made open-weight, meaning that their architecture and trained parameters (the \"weights\") are publicly available. Open-weight models can be freely fine-tuned, which allows companies to specialise them with their own data and for their own use-case. Open-weight models are useful for research and innovation but can also be misused. Since they can be fine-tuned, any built-in security measure, such as objecting to harmful requests, can be trained away until it becomes ineffective. Some researchers warn that future AI models may develop dangerous capabilities (such as the potential to drastically facilitate bioterrorism) and that once released on the Internet, they cannot be deleted everywhere if needed. They recommend pre-release audits and cost-benefit analyses.\n\n\nFrameworks\nArtificial intelligence projects can be guided by ethical considerations during the design, development, and implementation of an AI system. An AI framework such as the Care and Act Framework, developed by the Alan Turing Institute and based on the SUM values, outlines four main ethical dimensions, defined as follows:\n\nRespect the dignity of individual people\nConnect with other people sincerely, openly, and inclusively\nCare for the wellbeing of everyone\nProtect social values, justice, and the public interest\nOther developments in ethical frameworks include those decided upon during the Asilomar Conference, the Montreal Declaration for Responsible AI, and the IEEE's Ethics of Autonomous Systems initiative, among others; however, these principles are not without criticism, especially regarding the people chosen to contribute to these frameworks.\nPromotion of the wellbeing of the people and communities that these technologies affect requires consideration of the social and ethical implications at all stages of AI system design, development and implementation, and collaboration between job roles such as data scientists, product managers, data engineers, domain experts, and delivery managers.\nThe UK AI Safety Institute released in 2024 a testing toolset called 'Inspect' for AI safety evaluations available under an MIT open-source licence which is freely available on GitHub and can be improved with third-party packages. It can be used to evaluate AI models in a range of areas including core knowledge, ability to reason, and autonomous capabilities.\n\n\nRegulation\n\nThe regulation of artificial intelligence is the development of public sector policies and laws for promoting and regulating AI; it is therefore related to the broader regulation of algorithms. The regulatory and policy landscape for AI is an emerging issue in jurisdictions globally. According to AI Index at Stanford, the annual number of AI-related laws passed in the 127 survey countries jumped from one passed in 2016 to 37 passed in 2022 alone. Between 2016 and 2020, more than 30 countries adopted dedicated strategies for AI. Most EU member states had released national AI strategies, as had Canada, China, India, Japan, Mauritius, the Russian Federation, Saudi Arabia, United Arab Emirates, U.S., and Vietnam. Others were in the process of elaborating their own AI strategy, including Bangladesh, Malaysia and Tunisia. The Global Partnership on Artificial Intelligence was launched in June 2020, stating a need for AI to be developed in accordance with human rights and democratic values, to ensure public confidence and trust in the technology. Henry Kissinger, Eric Schmidt, and Daniel Huttenlocher published a joint statement in November 2021 calling for a government commission to regulate AI. In 2023, OpenAI leaders published recommendations for the governance of superintelligence, which they believe may happen in less than 10 years. In 2023, the United Nations also launched an advisory body to provide recommendations on AI governance; the body comprises technology company executives, government officials and academics. On 1 August 2024, the EU Artificial Intelligence Act entered into force, establishing the first comprehensive EU-wide AI regulation. In 2024, the Council of Europe created the first international legally binding treaty on AI, called the \"Framework Convention on Artificial Intelligence and Human Rights, Democracy and the Rule of Law\". It was adopted by the European Union, the United States, the United Kingdom, and other signatories.\nIn a 2022 Ipsos survey, attitudes towards AI varied greatly by country; 78% of Chinese citizens, but only 35% of Americans, agreed that \"products and services using AI have more benefits than drawbacks\". A 2023 Reuters/Ipsos poll found that 61% of Americans agree, and 22% disagree, that AI poses risks to humanity. In a 2023 Fox News poll, 35% of Americans thought it \"very important\", and an additional 41% thought it \"somewhat important\", for the federal government to regulate AI, versus 13% responding \"not very important\" and 8% responding \"not at all important\". A 2026 NBC News Decision Desk poll powered by SurveyMonkey found that 52% of American adults used AI tools very often or sometimes, but only 18% said they could trust AI-generated information most or almost all of the time, and 70% were more worried than excited about AI. Polls in the United States found the main public concerns were job losses, impersonation, misinformation and information privacy.\nIn November 2023, the first global AI Safety Summit was held in Bletchley Park in the UK to discuss the near and far term risks of AI and the possibility of mandatory and voluntary regulatory frameworks. 28 countries including the United States, China, and the European Union issued a declaration at the start of the summit, calling for international co-operation to manage the challenges and risks of artificial intelligence. In May 2024 at the AI Seoul Summit, 16 global AI tech companies agreed to safety commitments on the development of AI.\nIn March 2026, the United Nations convened the inaugural meeting of the Independent International Scientific Panel on AI, a 40-member expert body established under the Global Digital Compact to produce annual evidence-based reports on AI's societal impacts.\n\n\nHistory\n\nThe study of mechanical or \"formal\" reasoning began with philosophers and mathematicians in antiquity. The study of logic led directly to Alan Turing's theory of computation, which suggested that a machine, by shuffling symbols as simple as \"0\" and \"1\", could simulate any conceivable form of mathematical reasoning. This, along with concurrent discoveries in cybernetics, information theory and neurobiology, led researchers to consider the possibility of building an \"electronic brain\". They developed several areas of research that would become part of AI, such as McCulloch and Pitts design for \"artificial neurons\" in 1943, and Turing's influential 1950 paper 'Computing Machinery and Intelligence', which introduced the Turing test and showed that \"machine intelligence\" was plausible.\nThe field of AI research was founded at a workshop at Dartmouth College in 1956. The first AI program, Logic Theorist, was presented at the workshop, created by future Turing Award winner Allen Newell and future Nobel Laureate Herbert A. Simon, in collaboration with J. C. Shaw. Many of the workshop attendees became the leaders of AI research in the 1960s. They and their students produced programs that the press described as \"astonishing\": computers were learning checkers strategies, solving word problems in algebra, proving logical theorems and speaking English. Artificial intelligence laboratories were set up at a number of British and U.S. universities in the latter 1950s and early 1960s.\nResearchers in the 1960s and the 1970s were convinced that their methods would eventually succeed in creating a machine with general intelligence and considered this the goal of their field. In 1965 Herbert Simon predicted, \"machines will be capable, within twenty years, of doing any work a man can do\".In 1967 Marvin Minsky agreed, writing that \"within a generation ... the problem of creating 'artificial intelligence' will substantially be solved\". They had, however, underestimated the difficulty of the problem. In 1974, both the U.S. and British governments cut off exploratory research in response to the criticism of Sir James Lighthill and ongoing pressure from the U.S. Congress to fund more productive projects. Minsky and Papert's book Perceptrons was understood as proving that artificial neural networks would never be useful for solving real-world tasks, thus discrediting the approach altogether. The \"AI winter\", a period when obtaining funding for AI projects was difficult, followed.\nIn the early 1980s, AI research was revived by the commercial success of expert systems, a form of AI program that simulated the knowledge and analytical skills of human experts. By 1985, the market for AI had reached over a billion dollars. At the same time, Japan's fifth generation computer project inspired the U.S. and British governments to restore funding for academic research. However, beginning with the collapse of the Lisp Machine market in 1987, AI once again fell into disrepute, and a second, longer-lasting winter began.\nUp to this point, most of AI's funding had gone to projects that used high-level symbols to represent mental objects like plans, goals, beliefs, and known facts. In the 1980s, some researchers began to doubt that this approach would be able to imitate all the processes of human cognition, especially perception, robotics, learning and pattern recognition, and began to look into \"sub-symbolic\" approaches. Rodney Brooks rejected \"representation\" in general and focussed directly on engineering machines that move and survive. Judea Pearl, Lotfi Zadeh, and others developed methods that handled incomplete and uncertain information by making reasonable guesses rather than precise logic. But the most important development was the revival of \"connectionism\", including neural network research, by Geoffrey Hinton and others. In 1990, Yann LeCun successfully showed that convolutional neural networks can recognise handwritten digits, the first of many successful applications of neural networks.\nAI gradually restored its reputation in the late 1990s and early 21st century by exploiting formal mathematical methods and by finding specific solutions to specific problems. This \"narrow\" and \"formal\" focus allowed researchers to produce verifiable results and collaborate with other fields (such as statistics, economics and mathematics). By 2000, solutions developed by AI researchers were being widely used, although in the 1990s they were rarely described as \"artificial intelligence\" (a tendency known as the AI effect).\nHowever, several academic researchers became concerned that AI was no longer pursuing its original goal of creating versatile, fully intelligent machines. Beginning around 2002, they founded the subfield of artificial general intelligence (or \"AGI\"), which had several well-funded institutions by the 2010s.\nDeep learning began to dominate industry benchmarks in 2012 and was adopted throughout the field.\nFor many specific tasks, other methods were abandoned.\nDeep learning's success was based on both hardware improvements (faster computers, graphics processing units, cloud computing) and access to large amounts of data (including curated datasets, such as ImageNet). Neural-network approaches also advanced natural language processing. In 2013, word2vec introduced efficient methods for learning distributed word representations. In 2014–2015, sequence-to-sequence and attention mechanisms advanced neural machine translation.\nDeep learning's success led to an enormous increase in interest and funding in AI. The amount of machine learning research (measured by total publications) increased by 50% in the years 2015–2019.\n\nIn 2016, issues of fairness and the misuse of technology were catapulted into centre stage at machine learning conferences, publications vastly increased, funding became available, and many researchers re-focussed their careers on these issues. The alignment problem became a serious field of academic study.\nIn 2015, AlphaGo, developed by DeepMind, beat the world champion Go player. The program taught only the game's rules and developed a strategy by itself. GPT-3 is a large language model that was released in 2020 by OpenAI and is capable of generating high-quality human-like text. ChatGPT, launched on 30 November 2022, became the fastest-growing consumer software application in history, gaining over 100 million users in two months. It marked what is widely regarded as AI's breakout year, bringing it into the public consciousness. These programs, and others, inspired an aggressive AI boom, where large companies began investing billions of dollars in AI research. According to AI Impacts, about US$50 billion annually was invested in \"AI\" around 2022 in the U.S. alone and about 20% of the new U.S. computer science PhD graduates have specialised in \"AI\". About 800,000 \"AI\"-related U.S. job openings existed in 2022. According to PitchBook research, 22% of newly funded startups in 2024 claimed to be AI companies.\n\n\nPhilosophy\n\nPhilosophical debates have historically sought to determine the nature of intelligence and how to make intelligent machines. Another major focus has been whether machines can be conscious, and the associated ethical implications. Many other topics in philosophy are relevant to AI, such as epistemology and free will. Rapid advancements have intensified public discussions on the philosophy and ethics of AI.\n\n\nDefining artificial intelligence\n\nAlan Turing investigated whether machines can show intelligent behaviour and think. In 1950, he proposed the Turing test, which measures the ability of a machine to simulate human conversation. Since we can only observe the behaviour of the machine, it does not matter if it is \"actually\" thinking or literally has a \"mind\". Turing notes that we can not determine these things about other people but \"it is usual to have a polite convention that everyone thinks.\"\n\nRussell and Norvig agree with Turing that intelligence must be defined in terms of external behaviour, not internal structure. However, they are critical that the test requires the machine to imitate humans. \"Aeronautical engineering texts\", they wrote, \"do not define the goal of their field as making 'machines that fly so exactly like pigeons that they can fool other pigeons.'\" AI founder John McCarthy agreed, writing that \"Artificial intelligence is not, by definition, simulation of human intelligence\".\nMcCarthy defines intelligence as \"the computational part of the ability to achieve goals in the world\". Another AI founder, Marvin Minsky, similarly describes it as \"the ability to solve hard problems\". Artificial Intelligence: A Modern Approach defines it as the study of agents that perceive their environment and take actions that maximise their chances of achieving defined goals. \nThe many differing definitions of AI have been critically analysed. During the 2020s AI boom, the term has been used as a marketing buzzword to promote products and services which do not use AI.\n\n\nLegal definitions\nThe International Organization for Standardization describes an AI system as a \"an engineered system that generates outputs such as content, forecasts, recommendations, or decisions for a given set of human‑defined objectives, and can operate with varying levels of automation\". The EU AI Act defines an AI system as \"a machine-based system that is designed to operate with varying levels of autonomy and that may exhibit adaptiveness after deployment, and that, for explicit or implicit objectives, infers, from the input it receives, how to generate outputs such as predictions, content, recommendations, or decisions that can influence physical or virtual environments\". In the United States, influential but non‑binding guidance such as the National Institute of Standards and Technology's AI Risk Management Framework describes an AI system as \"an engineered or machine-based system that can, for a given set of objectives, generate outputs such as predictions, recommendations, or decisions influencing real or virtual environments. AI systems are designed to operate with varying levels of autonomy\".\n\n\nEvaluating approaches to AI\nNo established unifying theory or paradigm has guided AI research for most of its history. The unprecedented success of statistical machine learning in the 2010s eclipsed all other approaches (so much so that some sources, especially in the business world, use the term \"artificial intelligence\" to mean \"machine learning with neural networks\"). This approach is mostly sub-symbolic, soft and narrow.\n\n\nSymbolic AI and its limits\nSymbolic AI (or \"GOFAI\") simulated the high-level conscious reasoning that people use when they solve puzzles, express legal reasoning and do mathematics. It was highly successful at some \"intelligent\" tasks such as algebra or IQ tests. In 1976, Newell and Simon proposed the physical symbol systems hypothesis: \"A physical symbol system has the necessary and sufficient means of general intelligent action.\"\nHowever, the symbolic approach failed on many tasks that humans solve easily, such as learning, recognising an object or commonsense reasoning. Moravec's paradox is the discovery that high-level \"intelligent\" tasks were easy for AI, but low level \"instinctive\" tasks were extremely difficult. Philosopher Hubert Dreyfus had argued since the 1960s that human expertise depends on embodied, situational know-how that is not representable as explicit symbolic rules rather than conscious symbol manipulation, and on having a \"feel\" for the situation, rather than explicit symbolic knowledge. Although his arguments had been ridiculed and ignored when they were first presented, eventually, AI research came to agree with him.\nThe issue is not resolved: sub-symbolic reasoning can make many of the same inscrutable mistakes that human intuition does, such as algorithmic bias. Critics such as Noam Chomsky argue continuing research into symbolic AI will still be necessary to attain general intelligence, in part because sub-symbolic AI is a move away from explainable AI: it can be difficult or impossible to understand why a modern statistical AI program made a particular decision. The emerging field of neuro-symbolic artificial intelligence attempts to bridge the two approaches.\n\n\nNeat vs. scruffy\n\n\"Neats\" hope that intelligent behaviour is described using simple, elegant principles (such as logic or optimisation). \"Scruffies\" expect that it necessarily requires solving a large number of unrelated problems. Neats defend their programs with theoretical rigour, scruffies rely mainly on incremental testing to see if they work. This issue was actively discussed in the 1970s and 1980s. The rise of deep learning may represent a shift toward the scruffies. \n\n\nSoft vs. hard computing\n\nFinding a provably correct or optimal solution is intractable for many important problems. Soft computing is a set of techniques, including genetic algorithms, fuzzy logic and neural networks, that are tolerant of imprecision, uncertainty, partial truth and approximation. Soft computing was introduced in the late 1980s and most successful AI programs in the 21st century are examples of soft computing with neural networks.\n\n\nNarrow vs. general AI\n\nAI researchers are divided as to whether to pursue the goals of artificial general intelligence and superintelligence directly or to solve as many specific problems as possible (narrow AI) in hopes these solutions will lead indirectly to the field's long-term goals. General intelligence is difficult to define and difficult to measure, and modern AI has had more verifiable successes by focusing on specific problems with specific solutions. The sub-field of artificial general intelligence studies this area exclusively.\n\n\nMachine consciousness, sentience, and mind\n\nThere is no settled consensus in philosophy of mind on whether a machine can have a mind, consciousness or subjective experiences in the same sense that human beings do. This issue considers the internal experiences of the machine, rather than its external behaviour. Mainstream AI research considers this issue irrelevant because it does not affect the goals of the field: to build machines that can solve problems using intelligence. Russell and Norvig add that \"[t]he additional project of making a machine conscious in exactly the way humans are is not one that we are equipped to take on.\" However, the question has become central to the philosophy of mind. It is also typically the central question at issue in artificial intelligence in fiction.\n\n\nConsciousness\n\nDavid Chalmers identified two problems in understanding the mind, which he named the \"hard\" and \"easy\" problems of consciousness. The easy problem is understanding how the brain processes signals, makes plans and controls behaviour. The hard problem is explaining how this feels or why it should feel like anything at all, assuming we are right in thinking that it truly does feel like something (Dennett's consciousness illusionism says this is an illusion). While human information processing is easy to explain, human subjective experience is difficult to explain. For example, it is easy to imagine a colour-blind person who has learned to identify which objects in their field of view are red, but it is not clear what would be required for the person to know what red looks like.\n\n\nComputationalism and functionalism\n\nComputationalism is the position in the philosophy of mind that the human mind is an information processing system and that thinking is a form of computing. Computationalism argues that the relationship between mind and body is similar or identical to the relationship between software and hardware and thus may be a solution to the mind–body problem. This philosophical position was inspired by the work of AI researchers and cognitive scientists in the 1960s and was originally proposed by philosophers Jerry Fodor and Hilary Putnam.\nPhilosopher John Searle characterised this position as \"strong AI\": \"The appropriately programmed computer with the right inputs and outputs would thereby have a mind in exactly the same sense human beings have minds.\" Searle challenges this claim with his Chinese room argument, which attempts to show that even a computer capable of perfectly simulating human behaviour would not have a mind.\n\n\nAI welfare and rights\n\nIt is difficult or impossible to reliably evaluate whether an advanced AI is sentient (has the ability to feel), and if so, to what degree. But if there is a significant chance that a given machine can feel and suffer, then it may be entitled to certain rights or welfare protection measures, similarly to animals. Sapience (a set of capacities related to high intelligence, such as discernment or self-awareness) may provide another moral basis for AI rights. Robot rights are also sometimes proposed as a practical way to integrate autonomous agents into society.\nIn 2017, the European Union considered granting \"electronic personhood\" to some of the most capable AI systems. Similarly to the legal status of companies, it would have conferred rights but also responsibilities. Critics argued in 2018 that granting rights to AI systems would downplay the importance of human rights, and that legislation should focus on user needs rather than speculative futuristic scenarios. They also noted that robots lacked the autonomy to take part in society on their own.\nProgress in AI increased interest in the topic. Proponents of AI welfare and rights often argue that AI sentience, if it emerges, would be particularly easy to deny. They warn that this may be a moral blind spot analogous to slavery or factory farming, which could lead to large-scale suffering if sentient AI is created and carelessly exploited.\n\n\nFuture\n\n\nSuperintelligence and the singularity\nA superintelligence is a hypothetical agent that would possess intelligence far surpassing that of the brightest and most gifted human mind. If research into artificial general intelligence produced sufficiently intelligent software, it might be able to reprogram and improve itself. The improved software would be even better at improving itself, leading to what I. J. Good called an \"intelligence explosion\" and Vernor Vinge called a \"singularity\".\nIn Artificial Intelligence: A Modern Approach, Russel and Norvig cast doubt on the possibility of a singularity, arguing that \"so far, every technology has followed an S-shaped curve\", and that \"sometimes it is not possible to keep the growth going.\"\n\n\nTranshumanism\n\nRobot designer Hans Moravec, cyberneticist Kevin Warwick and inventor Ray Kurzweil have predicted that humans and machines may merge in the future into cyborgs that are more capable and powerful than either. This idea, called transhumanism, has roots in the writings of Aldous Huxley and Robert Ettinger.\nEdward Fredkin argues that \"artificial intelligence is the next step in evolution\", an idea first proposed by Samuel Butler's \"Darwin among the Machines\" as far back as 1863, and expanded upon by George Dyson in his 1998 book Darwin Among the Machines: The Evolution of Global Intelligence.\n\n\nIn fiction\n\nThought-capable artificial beings have appeared as storytelling devices since antiquity, and have been a persistent theme in science fiction.\nA common trope in these works began with Mary Shelley's Frankenstein, where a human creation becomes a threat to its masters. This includes such works as Arthur C. Clarke's and Stanley Kubrick's 2001: A Space Odyssey (both 1968), with HAL 9000, the murderous computer in charge of the Discovery One spaceship, as well as Blade Runner (1982), The Terminator (1984) and The Matrix (1999). In contrast, the rare loyal robots such as Gort from The Day the Earth Stood Still (1951) and Bishop from Aliens (1986) are less prominent in popular culture.\nIsaac Asimov introduced the Three Laws of Robotics in many stories, most notably with the \"Multivac\" super-intelligent computer. Asimov's laws are often brought up during lay discussions of machine ethics; while almost all artificial intelligence researchers are familiar with Asimov's laws through popular culture, they generally consider the laws useless for many reasons, one of which is their ambiguity.\nSeveral works use AI to force us to confront the fundamental question of what makes us human, showing us artificial beings that have the ability to feel, and thus to suffer. This appears in Karel Čapek's R.U.R., the films A.I. Artificial Intelligence and Ex Machina, as well as the novel Do Androids Dream of Electric Sheep?, by Philip K. Dick. Dick considers the idea that our understanding of human subjectivity is altered by technology created with artificial intelligence.\nIn the manga and anime franchise Doraemon, there are many gadgets associated with Artificial Inteligence and Machine Learning technologies and it's consequences if used in the wrong way were depicted by Fujiko F. Fujio in manga.\nDoraemon: Nobita and the Tin Labyrinth movie depicted consequences of making a AI robot, which can think on it's own and innovate technologies but instead it puts the humans in jail. \n\n\nSee also\n\n\nExplanatory notes\n\n\nNotes\n\n\nReferences\n\n\nTextbooks\n\n\nHistory of AI\n\n\nOther sources\n\n\nExternal links\n\nHauser, Larry. \"Artificial Intelligence\". In Fieser, James; Dowden, Bradley (eds.). Internet Encyclopedia of Philosophy. ISSN 2161-0002. OCLC 37741658.", "categories": ["Articles that may contain original research from September 2026", "Articles with Internet Encyclopedia of Philosophy links", "Articles with excerpts", "Articles with short description", "Artificial intelligence", "CS1: long volume value", "CS1 German-language sources (de)", "CS1 Japanese-language sources (ja)", "CS1 maint: url-status", "Computational fields of study", "Computational neuroscience", "Cybernetics", "Data science", "Formal sciences", "Intelligence by type", "Pages displaying short descriptions of redirect targets via Module:Annotated link", "Pages using Sister project links with hidden wikidata", "Short description is different from Wikidata", "Use dmy dates from October 2025", "Webarchive template wayback links"], "references": ["https://www.wsj.com/articles/being-human-artifical-intelligence-ai-chess-antibiotic-philosophy-ethics-bill-of-rights-11635795271", "https://archive.org/details/artificialintell0000luge", "https://web.archive.org/web/20200726220613/https://archive.org/details/artificialintell0000luge", "https://archive.org/details/artificialintell0000nils", "https://web.archive.org/web/20200726131654/https://archive.org/details/artificialintell0000nils", "http://aima.cs.berkeley.edu/", "https://archive.org/details/computationalint00pool", "https://web.archive.org/web/20200726131436/https://archive.org/details/computationalint00pool", "http://artint.info/index.html", "http://research.microsoft.com/pubs/209355/DeepLearning-NowPublishing-Vol7-SIG-039.pdf", "https://web.archive.org/web/20160314152112/http://research.microsoft.com/pubs/209355/DeepLearning-NowPublishing-Vol7-SIG-039.pdf", "https://www.economist.com/news/special-report/21700756-artificial-intelligence-boom-based-old-idea-modern-twist-not", "https://web.archive.org/web/20161231203934/https://www.economist.com/news/special-report/21700756-artificial-intelligence-boom-based-old-idea-modern-twist-not", "http://www.deeplearningbook.org/", "https://ui.adsabs.harvard.edu/abs/2012ISPM...29...82H"], "images": ["File:AI Overviews result for What is Wikipedia, 2 March 2026.png"], "sub_niche": "Adversarial machine learning"} {"title": "Adversarial stylometry", "url": "https://en.wikipedia.org/wiki/Adversarial_stylometry", "summary": "Adversarial stylometry is the practice of altering writing style to reduce the potential for stylometry to discover the author's identity or their characteristics. This task is also known as authorship obfuscation or authorship anonymisation. Stylometry poses a significant privacy challenge in its ability to unmask anonymous authors or to link pseudonyms to an author's other identities, which, for example, creates difficulties for whistleblowers, activists, and hoaxers and fraudsters. The privacy risk is expected to grow as machine learning techniques and text corpora develop.\nAll adversarial stylometry shares the core idea of faithfully paraphrasing the source text so that the meaning is unchanged but the stylistic signals are obscured. Such a faithful paraphrase is an adversarial example", "content": "Adversarial stylometry is the practice of altering writing style to reduce the potential for stylometry to discover the author's identity or their characteristics. This task is also known as authorship obfuscation or authorship anonymisation. Stylometry poses a significant privacy challenge in its ability to unmask anonymous authors or to link pseudonyms to an author's other identities, which, for example, creates difficulties for whistleblowers, activists, and hoaxers and fraudsters. The privacy risk is expected to grow as machine learning techniques and text corpora develop.\nAll adversarial stylometry shares the core idea of faithfully paraphrasing the source text so that the meaning is unchanged but the stylistic signals are obscured. Such a faithful paraphrase is an adversarial example for a stylometric classifier. Several broad approaches to this exist, with some overlap: imitation, substituting the author's own style for another's; translation, applying machine translation with the hope that this eliminates characteristic style in the source text; and obfuscation, deliberately modifying a text's style to make it not resemble the author's own.\nManually obscuring style is possible, but laborious; in some circumstances, it is preferable or necessary. Automated tooling, either semi- or fully-automatic, could assist an author. How best to perform the task and the design of such tools is an open research question. While some approaches have been shown to be able to defeat particular stylometric analyses, particularly those that do not account for the potential of adversariality, establishing safety in the face of unknown analyses is an issue. Ensuring the faithfulness of the paraphrase is a critical challenge for automated tools.\nIt is uncertain if the practice of adversarial stylometry is detectable in itself. Some studies have found that particular methods produced signals in the output text, but a stylometrist who is uncertain of what methods may have been used may not be able to reliably detect them.\n\n\nHistory\nRao & Rohatgi (2000), an early work in adversarial stylometry, identified machine translation as a possibility, but noted that the quality of translators available at the time presented severe challenges. Kacmarcik & Gamon (2006) is another early work. Brennan, Afroz & Greenstadt (2012) performed the first evaluation of adversarial stylometric methods on actual texts.\nBrennan & Greenstadt (2009) introduced the first corpus of adversarially authored texts specifically for evaluating stylometric methods; other corpora include the International Imitation Hemingway Competition, the Faux Faulkner contest, and the hoax blog A Gay Girl in Damascus.\n\n\nMotivations\nRao & Rohatgi (2000) suggest that short, unattributed documents (i.e., anonymous posts) are not at risk of stylometric identification, but pseudonymous authors who have not practiced adversarial stylometry in producing corpuses of thousands of words may be vulnerable. Narayanan et al. (2012) attempted large-scale deanonymisation of 100,000 blog authors with mixed results: the identifications were significantly better than chance, but only accurately matched the blog and author a fifth of the time; identification improved with the number of posts written by the author in the corpus. Even if an author is not identified, some of their characteristics may still be deduced stylometrically, or stylometry may narrow the anonymity set of potential authors sufficiently for other information to complete the identification. Detecting author characteristics (e.g., gender or age) is often simpler than identifying an author from a large, possibly open, set of candidates.\nModern machine learning techniques offer powerful tools for identification; further development of corpora and computational stylometric techniques are likely to raise further privacy issues. Gröndahl & Asokan (2020a) say that the general validity of the hypothesis underlying stylometry—that authors have invariant, content-independent 'style fingerprints'—is uncertain, but \"the deanonymisation attack is a real privacy concern\".\nThose interested in practicing adversarial stylometry and stylistic deception include whistleblowers avoiding retribution; journalists and activists; perpetrators of frauds and hoaxes; authors of fake reviews; literary forgers; criminals disguising their identity from investigators; and, generally, anyone with a desire for anonymity or pseudonymity. Authors, or agents acting on behalf of authors, may also attempt to remove stylistic clues to author characteristics (e.g., race or gender) so that knowledge of those characteristics cannot be used for discrimination (e.g., through algorithmic bias). Another possible use for adversarial stylometry is in disguising automatically generated text as human-authored.\n\n\nMethods\nWith imitation, the author attempts to mislead stylometry by matching their style to another author's. An incomplete imitation, where some of the true author's unique characteristics appear alongside the imitated author's, can be a detectable signal for the use of adversarial stylometry. Imitation can be performed automatically with style transfer systems, though this typically requires a large corpus in the target style for the system to learn from.\nAnother approach is translation, which employs machine translation of a source text to eliminate characteristic style, often through multiple translators in sequence to produce a round-trip translation. Such chained translation can lead to texts being significantly altered, even to the point of incomprehensibility; improved translation tools reduce this risk. More simply-structured texts can be easier to machine translate without losing the original meaning. Machine translation blurs into direct stylistic imitation or obfuscation achieved through automated style transfer, which can be viewed as a \"translation\" with the same language as input and output. With low-quality translation tools, an author can be required to manually correct major translation errors while avoiding the hazard of re-introducing stylistic characteristics. Wang, Juola & Riddell (2022) found that gross errors introduced by Google Translate were rare, but more common with several intermediate translations—however, occasional simple or short sentences and misspellings in the source text appeared verbatim in the output, potentially providing an identifying signal. Chain translation can leave characteristic traces of its application in a document, which may allow reconstruction of the intermediate languages used and the number of translation steps performed.\nObfuscation involves deliberately changing the style of a text to reduce its similarity to other texts by some metric; this may be performed at the time of writing by conscious modification, or as part of a revision process with feedback from the metric being targeted as an input to decide when the text has been sufficiently obfuscated. In contrast to translation, complex texts can offer more opportunities for effective obfuscation without altering meaning, and likewise genres with more permissible variation allow more obfuscation. However, longer texts are harder to thoroughly obfuscate. Obfuscation can blend into imitation if the author develops a novel target style, distinct from their original style. With respect to masking author characteristics, obfuscation may aim to achieve a union (adding signals for imitated characteristics) or an intersection (removing signals and normalising) of other authors' styles. Avoiding the author's own idiosyncrasies and producing a \"normalised\" text is a critical obfuscatory step: an author may have a unique tendency to misspell certain words, use particular variants, or to format a document in a characteristic way. Stylometric signals vary in how simply they can be adversarially masked; an author may easily change their vocabulary by conscious choice, but altering the pattern of grammar or the letter frequency in their text may be harder to achieve, though Juola & Vescovi (2011) report that imitation typically succeeds at masking more characteristics than obfuscation. Automated obfuscation may require large amounts of training data written by the author.\nConcerning automated implementations of adversarial stylometry, two possible implementations are rule-based systems for paraphrasing; and encoder–decoder architectures, where the text passes through an intermediate format that is (intended to be) style-neutral. Another division in automated methods is whether there is feedback from an identification system or not. With such feedback, finding paraphrases for author masking has been characterised as a heuristic search problem, exploring textual variants until the result is stylistically sufficiently far (in the case of obfuscation) or near (in the case of imitation), which then constitutes an adversarial example for that identification system.\n\n\nEvaluation\nHow to best mask stylometric characteristics in practice, and what tasks to perform manually, what with tool assistance, and what fully automatically, is an open field of research, especially in short documents with limited potential variability. Manual adversarial stylometry can be preferred or even required if the author does not trust available computers with the task (as may be the case for a whistleblower, for example). Software tools require maintenance; Wang, Juola & Riddell (2022) report that there is no maintained obfuscatory software suitable for general use. Zhai et al. (2022) identify DS-PAN (Castro-Castro, Ortega Bueno & Muñoz 2017) and Mutant-X (Mahmood et al. 2019) as the 2022 state of the art in automated obfuscation. Manual stylistic modulation is a significant effort, with poor scalability properties; tool assistance can reduce the burden to varying degrees. Deterministic automated methods can lose effectiveness against a classifier trained adversarially, where output from the style transfer program is used in the classifier's training set.\nPotthast, Hagen & Stein (2016) give three criteria for use in evaluation of adversarial stylometry methods: safety, meaning that stylistic characteristics are reliably eliminated; soundness, meaning that the semantic content of the text is not unacceptably altered; and sensible, meaning that the output is \"well-formed and inconspicuous\". Compromising any too deeply is typically an unacceptable result, and the three trade off against each other in practice. Potthast, Hagen & Stein (2016) find that automatically evaluating sensibility, and specifically whether output is acceptably grammatical and well-formed, is difficult; automated evaluation of soundness is somewhat more promising, but manual review is the best method.\nDespite safety being an important property of an adversarial stylometry method, it can still be usefully traded away if the conceded stylometric identification potential is otherwise possible by non-stylometric analysis—for example, an author discussing their own upbringing in Britain is unlikely to care if stylometry can reveal that their text is typical of British English.\nEvaluating the safety of different approaches is complicated by how identification-resistance fundamentally depends on the methods of identification under consideration. The property of being resilient to unknown analyses is called transferability. Gröndahl & Asokan (2020b) identify four different threat models for authors, varying with their knowledge of how their text will be analysed and what training data will be used: query access, with the weakest analyst and the strongest author who knows both the methods of analysis and the training data; architecture access, where the author knows the analysis methods but not the training data; data access, where the author knows the training data but not the analysis methods; and surrogate access, with the weakest author and the strongest analyst, where the author does not know the methods of analysis nor the training data. Further, when an author chooses a method, they must rely on their threat model and trust that it is valid, and that unknown analyses able to detect remaining stylistic signals cannot or will not be performed, or that the masking successfully transfers; a stylometrist with knowledge of how the author attempted to mask their style, however, may be able to exploit some weakness in the method and render it unsafe. Much of the research into automated methods has assumed that the author has query access, which may not generalise to other settings. Masking methods that internally use an ensemble of different analyses as a model for its adversary may transfer better against unseen analyses.\nA thorough soundness loss defeats the purpose of communication, though some degree of meaning change may be tolerable if the core message is preserved; requiring only textual entailment or allowing automatic summarisation are other options to lose some meaning in a possibly-tolerable way. Rewriting an input text to defeat stylometry, as opposed to consciously removing stylistic characteristics during composition, poses challenges in retaining textual meaning. Gröndahl & Asokan (2020a) assess the problem of unsoundness as \"the most important challenge\" for research into fully automatic approaches.\nFor sensibility, if a text is so ungrammatical as to be incomprehensible or so ill-formed that it cannot fit in to its genre then the method has failed, but compromises short of that point may be useful. If inconspicuity is partially lost, then there is the possibility that more expensive and less scalable analyses will be performed (e.g., consulting a forensic linguist) to confirm suspicions or gather further evidence. The impact of a total inconspicuity failure varies depending on the motivation for performing adversarial stylometry: for someone simply attempting to stay anonymous (e.g., a whistleblower), detection may not be an issue; for a literary forger, however, detection would be disastrous. Adversarial stylometry can leave evidence of its practice, which is an inconspicuity failure. In the Brennan–Greenstadt corpus, the texts have been found to share a common \"style\" of their own. However, Gröndahl & Asokan (2020a) assess existing evidence as insufficient to prove that adversarial stylometry is always detectable, with only limited methods having been studied. Improving the smoothness of the output text may reduce the detectability of automated tools. The overall detectability of adversarial authorship has not been thoroughly studied; if the methods available to be used by the author are unknown to the stylometrist, it may be impossible.\nThe problems of author identification and verification in an adversarial setting are greatly different from recognising naïve or cooperative authors. Deliberate attempts to mask authorship are described by Juola & Vescovi (2011) as a \"problem for the current state of stylometric art\", and Brennan, Afroz & Greenstadt (2012) state that, despite stylometry's high performance in identifying non-adversarial authors, manual application of adversarial methods render it unreliable.\nKacmarcik & Gamon (2006) observe that low-dimensional stylometric models which operate on small numbers of features are less resistant to adversarial stylometry. Research has found that authors vary in how well they are able to modulate their style, with some able to successfully perform the task even without training. Wang, Juola & Riddell (2022), a replication and reproduction of Brennan, Afroz & Greenstadt (2012), found that all three of imitation, translation and obfuscation meaningfully reduced the effectiveness of authorship attribution, with manual obfuscation being somewhat more effective than manual imitation or translation, which performed similarly to each other; the original study found that imitation was superior. Potthast, Hagen & Stein (2016) reported that even simple automated methods of adversarial stylometry caused major difficulties for state-of-the-art authorship identification systems, though at significant soundness and sensibility cost. Adversarially-aware identification systems can perform much better against adversarial stylometry provided that they know which potential obfuscation methods were used, even if the identifier makes mistakes in analysing which anonymisation method was used.\n\n\nSee also\nAdversarial machine learning\nAuthor profiling\nDe-identification\nDigital watermarking\nOnline identity management\nOperational security\nSteganography\n\n\nReferences\n\n\nBibliography\nAdelani, David; Zhang, Miaoran; Shen, Xiaoyu; Davody, Ali; Kleinbauer, Thomas; Klakow, Dietrich (2021). \"Preventing Author Profiling through Zero-Shot Multilingual Back-Translation\". Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing. pp. 8687–8695. arXiv:2109.09133. doi:10.18653/v1/2021.emnlp-main.684.\nAfroz, Sadia; Brennan, Michael; Greenstadt, Rachel (2012). \"Detecting Hoaxes, Frauds, and Deception in Writing Style Online\". 2012 IEEE Symposium on Security and Privacy. pp. 461–475. doi:10.1109/SP.2012.34. ISBN 978-1-4673-1244-8.\nAlmishari, Mishari; Oguz, Ekin; Tsudik, Gene (2014). \"Fighting Authorship Linkability with Crowdsourcing\". Proceedings of the second edition of the ACM conference on Online social networks - COSN '14. pp. 69–82. arXiv:1405.4918. doi:10.1145/2660460.2660486. ISBN 9781450331982. S2CID 7741036.\nBevendorff, Janek; Potthast, Martin; Hagen, Matthias; Stein, Benno (2019). \"Heuristic Authorship Obfuscation\". Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics. pp. 1098–1108. doi:10.18653/v1/P19-1104.\nBrennan, Michael; Afroz, Sadia; Greenstadt, Rachel (2012). \"Adversarial stylometry: Circumventing Authorship Recognition to Preserve Privacy and Anonymity\" (PDF). ACM Transactions on Information and System Security. 15 (3): 1–22. doi:10.1145/2382448.2382450. S2CID 16176436. Archived from the original (PDF) on 11 February 2024. Retrieved 13 January 2023.\nBrennan, Michael Robert; Greenstadt, Rachel (2009). Practical Attacks Against Authorship Recognition Techniques. Innovative Applications of Artificial Intelligence.\nCastro-Castro, Daniel; Ortega Bueno, Reynier; Muñoz, Rafael (2017). \"Author Masking by Sentence Transformation—Notebook for PAN at CLEF 2017\" (PDF). CLEF 2017 Evaluation Labs and Workshop – Working Notes Papers, 11-14 September, Dublin, Ireland. ISSN 1613-0073.\nEmmery, Chris; Kádár, Ákos; Chrupała, Grzegorz (2021). \"Adversarial Stylometry in the Wild: Transferable Lexical Substitution Attacks on Author Profiling\". Proceedings of the 16th Conference of the European Chapter of the Association for Computational Linguistics: Main Volume. pp. 2388–2402. arXiv:2101.11310. doi:10.18653/v1/2021.eacl-main.203. S2CID 231719026.\nGröndahl, Tommi; Asokan, N. (2020a). \"Text Analysis in Adversarial Settings: Does Deception Leave a Stylistic Trace?\". ACM Computing Surveys. 52 (3): 1–36. arXiv:1902.08939. doi:10.1145/3310331. S2CID 67856540.\nGröndahl, Tommi; Asokan, N. (2020b). \"Effective writing style imitation via combinatorial paraphrasing\". The Annual Privacy Enhancing Technologies Symposium. arXiv:1905.13464. doi:10.2478/popets-2020-0068.\nHaroon, Muhammad; Zaffar, Fareed; Srinivasan, Padmini; Shafiq, Zubair (2021). Avengers Ensemble! Improving Transferability of Authorship Obfuscation (Technical report). arXiv:2109.07028.\nJuola, Patrick; Vescovi, Darren (2011). \"Analyzing Stylometric Approaches to Author Obfuscation\". Advances in Digital Forensics VII. IFIP Advances in Information and Communication Technology. Vol. 361. pp. 115–125. doi:10.1007/978-3-642-24212-0_9. ISBN 978-3-642-24211-3.\nJuola, Patrick (April 2012). \"Detecting Stylistic Deception\". Proceedings of the Workshop on Computational Approaches to Deception Detection. pp. 91–96.\nKacmarcik, Gary; Gamon, Michael (17 July 2006). \"Obfuscating document stylometry to preserve author anonymity\". Proceedings of the COLING/ACL 2006 Main Conference Poster Sessions. pp. 444–451.\nMahmood, Asad; Ahmad, Faizan; Shafiq, Zubair; Srinivasan, Padmini; Zaffar, Fareed (2019). \"A Girl Has No Name: Automated Authorship Obfuscation using Mutant-X\". Proceedings on Privacy Enhancing Technologies. 2019 (4): 54–71. doi:10.2478/popets-2019-0058. S2CID 197621394.\nMahmood, Asad; Shafiq, Zubair; Srinivasan, Padmini (2020). \"A Girl Has a Name: Detecting Authorship Obfuscation\". Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics. pp. 2235–2245. arXiv:2005.00702. doi:10.18653/v1/2020.acl-main.203. S2CID 218486757.\nMcDonald, Andrew W. E.; Afroz, Sadia; Caliskan, Aylin; Stolerman, Ariel; Greenstadt, Rachel (2012). \"Use Fewer Instances of the Letter \"i\": Toward Writing Style Anonymization\" (PDF). Privacy Enhancing Technologies. Lecture Notes in Computer Science. Vol. 7384. pp. 299–318. doi:10.1007/978-3-642-31680-7_16. ISBN 978-3-642-31679-1. S2CID 15715170.\nMireshghallah, Fatemehsadat; Berg-Kirkpatrick, Taylor (2021). \"Style Pooling: Automatic Text Style Obfuscation for Improved Classification Fairness\". Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing. pp. 2009–2022. arXiv:2109.04624. doi:10.18653/v1/2021.emnlp-main.152.\nNarayanan, Arvind; Paskov, Hristo; Gong, Neil Zhenqiang; Bethencourt, John; Stefanov, Emil; Shin, Eui Chul Richard; Song, Dawn (2012). \"On the Feasibility of Internet-Scale Author Identification\". 2012 IEEE Symposium on Security and Privacy. pp. 300–314. doi:10.1109/SP.2012.46. ISBN 978-1-4673-1244-8. S2CID 6733582.\nNeal, Tempestt; Sundararajan, Kalaivani; Fatima, Aneez; Yan, Yiming; Xiang, Yingfei; Woodard, Damon (2018). \"Surveying Stylometry Techniques and Applications\". ACM Computing Surveys. 50 (6): 1–36. doi:10.1145/3132039. S2CID 21360798.\nPotthast, Martin; Hagen, Matthias; Stein, Benno (2016). Author Obfuscation: Attacking the State of the Art in Authorship Verification (PDF). Conference and Labs of the Evaluation Forum.\nRao, Josyula R.; Rohatgi, Pankaj (2000). Can Pseudonymity Really Guarantee Privacy?. USENIX Security Symposium.\nSaedi, Chakaveh; Dras, Mark (December 2020). \"Large Scale Author Obfuscation Using Siamese Variational Auto-Encoder: The SiamAO System\". Proceedings of the Ninth Joint Conference on Lexical and Computational Semantics. pp. 179–189.\nShetty, Rakshith; Schiele, Bernt; Fritz, Mario (2018). \"A4NT: Author Attribute Anonymity by Adversarial Training of Neural Machine Translation\". Proceedings of the 27th USENIX Security Symposium. ISBN 978-1-939133-04-5.\nUchendu, Adaku; Le, Thai; Lee, Dongwon (2022). \"Attribution and Obfuscation of Neural Text Authorship: A Data Mining Perspective\" (PDF). SIGKDD Explorations. arXiv:2210.10488.\nWang, Haining; Juola, Patrick; Riddell, Allen (2022). Reproduction and Replication of an Adversarial Stylometry Experiment (Technical report). arXiv:2208.07395.\nXu, Qiongkai; Qu, Lizhen; Xu, Chenchen; Cui, Ran (2019). \"Privacy-Aware Text Rewriting\". Proceedings of the 12th International Conference on Natural Language Generation. pp. 247–257. doi:10.18653/v1/W19-8633. hdl:1885/317479.\nZhai, Wanyue; Rusert, Jonathan; Shafiq, Zubair; Srinivasan, Padmini (2022). \"A Girl Has A Name, And It's ... Adversarial Authorship Attribution for Deobfuscation\". Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers). pp. 7372–7384. arXiv:2203.11849. doi:10.18653/v1/2022.acl-long.509. S2CID 248780012.", "categories": ["All Wikipedia articles written in British English", "Articles with short description", "Computational fields of study", "Computational linguistics", "Counter-forensics", "Data anonymization techniques", "Digital humanities", "Information privacy", "Natural language processing", "Personal identification", "Quantitative linguistics", "Short description matches Wikidata", "Stylistics", "Use British English from February 2023", "Use dmy dates from February 2023"], "references": ["https://api.semanticscholar.org/CorpusID:7741036", "https://www1.icsi.berkeley.edu/~sadia/papers/adversarial_stylometry.pdf", "https://api.semanticscholar.org/CorpusID:16176436", "https://www.aaai.org/ocs/index.php/IAAI/IAAI09/paper/view/257", "https://ceur-ws.org/Vol-1866/paper_170.pdf", "https://api.semanticscholar.org/CorpusID:231719026", "https://api.semanticscholar.org/CorpusID:67856540", "https://aclanthology.org/W12-0414/", "https://aclanthology.org/P06-2058/", "https://api.semanticscholar.org/CorpusID:197621394", "https://api.semanticscholar.org/CorpusID:218486757", "http://www.stolerman.net/papers/anonymouth_pets2012.pdf", "https://api.semanticscholar.org/CorpusID:6733582", "https://api.semanticscholar.org/CorpusID:21360798", "https://ceur-ws.org/Vol-1609/16090716.pdf"], "images": [], "sub_niche": "Adversarial machine learning"} {"title": "Machine learning in video games", "url": "https://en.wikipedia.org/wiki/Machine_learning_in_video_games", "summary": "Artificial intelligence and machine learning techniques are used in video games for a wide variety of applications such as non-player character (NPC) control, procedural content generation (PCG) and deep learning-based content generation. Machine learning is a subset of artificial intelligence that uses historical data to build predictive and analytical models. This is in sharp contrast to traditional methods of artificial intelligence such as search trees and expert systems.\nInformation on machine learning techniques in the field of games is mostly known to public through research projects as most gaming companies choose not to publish specific information about their intellectual property. The most publicly known application of machine learning in games is likely the use of deep learning", "content": "Artificial intelligence and machine learning techniques are used in video games for a wide variety of applications such as non-player character (NPC) control, procedural content generation (PCG) and deep learning-based content generation. Machine learning is a subset of artificial intelligence that uses historical data to build predictive and analytical models. This is in sharp contrast to traditional methods of artificial intelligence such as search trees and expert systems.\nInformation on machine learning techniques in the field of games is mostly known to public through research projects as most gaming companies choose not to publish specific information about their intellectual property. The most publicly known application of machine learning in games is likely the use of deep learning agents that compete with professional human players in complex strategy games. There has been a significant application of machine learning on games such as Atari/ALE, Doom, Minecraft, StarCraft, and car racing. Other games that did not originally exists as video games, such as chess and Go have also been affected by the machine learning.\n\n\nOverview of relevant machine learning techniques\n\n\nDeep learning\nDeep learning is a subset of machine learning which focuses heavily on the use of artificial neural networks (ANN) that learn to solve complex tasks. Deep learning uses multiple layers of ANN and other techniques to progressively extract information from an input. Due to this complex layered approach, deep learning models often require powerful machines to train and run on.\n\n\nConvolutional neural networks\nConvolutional neural networks (CNN) are specialized ANNs that are often used to analyze image data. These types of networks are able to learn translation invariant patterns, which are patterns that are not dependent on location. CNNs are able to learn these patterns in a hierarchy, meaning that earlier convolutional layers will learn smaller local patterns while later layers will learn larger patterns based on the previous patterns. A CNN's ability to learn visual data has made it a commonly used tool for deep learning in games.\n\n\nRecurrent neural network\nRecurrent neural networks are a type of ANN that are designed to process sequences of data in order, one part at a time rather than all at once. An RNN runs over each part of a sequence, using the current part of the sequence along with memory of previous parts of the current sequence to produce an output. These types of ANN are highly effective at tasks such as speech recognition and other problems that depend heavily on temporal order. There are several types of RNNs with different internal configurations; the basic implementation suffers from a lack of long term memory due to the vanishing gradient problem, thus it is rarely used over newer implementations.\n\n\nLong short-term memory\nA long short-term memory (LSTM) network is a specific implementation of a RNN that is designed to deal with the vanishing gradient problem seen in simple RNNs, which would lead to them gradually \"forgetting\" about previous parts of an inputted sequence when calculating the output of a current part. LSTMs solve this problem with the addition of an elaborate system that uses an additional input/output to keep track of long term data. LSTMs have achieved very strong results across various fields, and were used by several monumental deep learning agents in games.\n\n\nReinforcement learning\nReinforcement learning is the process of training an agent using rewards and/or punishments. The way an agent is rewarded or punished depends heavily on the problem; such as giving an agent a positive reward for winning a game or a negative one for losing. Reinforcement learning is used heavily in the field of machine learning and can be seen in methods such as Q-learning, policy search, Deep Q-networks and others. It has seen strong performance in both the field of games and robotics.\n\n\nNeuroevolution\nNeuroevolution involves the use of both neural networks and evolutionary algorithms. Instead of using gradient descent like most neural networks, neuroevolution models make use of evolutionary algorithms to update neurons in the network. Researchers claim that this process is less likely to get stuck in a local minimum and is potentially faster than state of the art deep learning techniques.\n\n\nDeep learning agents\nMachine learning agents have been used to take the place of a human player rather than function as NPCs, which are deliberately added into video games as part of designed gameplay. Deep learning agents have achieved impressive results when used in competition with both humans and other artificial intelligence agents.\n\n\nChess\nChess is a turn-based strategy game that is considered a difficult AI problem due to the computational complexity of its board space. Similar strategy games are often solved with some form of a Minimax Tree Search. These types of AI agents have been known to beat professional human players, such as the historic 1997 Deep Blue versus Garry Kasparov match. Since then, machine learning agents have shown ever greater success than previous AI agents.\n\n\nGo\nGo is another turn-based strategy game which is considered an even more difficult AI problem than chess. The state space of is Go is around 10^170 possible board states compared to the 10^120 board states for Chess. Prior to recent deep learning models, AI Go agents were only able to play at the level of a human amateur.\n\n\nAlphaGo\nGoogle's 2015 AlphaGo was the first AI agent to beat a professional Go player. AlphaGo used a deep learning model to train the weights of a Monte Carlo tree search (MCTS). The deep learning model consisted of 2 ANN, a policy network to predict the probabilities of potential moves by opponents, and a value network to predict the win chance of a given state. The deep learning model allows the agent to explore potential game states more efficiently than a vanilla MCTS. The network were initially trained on games of humans players and then were further trained by games against itself.\n\n\nAlphaGo Zero\nAlphaGo Zero, another implementation of AlphaGo, was able to train entirely by playing against itself. It was able to quickly train up to the capabilities of the previous agent.\n\n\nStarCraft series\nStarCraft and its sequel StarCraft II are real-time strategy (RTS) video games that have become popular environments for AI research. Blizzard and DeepMind have worked together to release a public StarCraft 2 environment for AI research to be done on. Various deep learning methods have been tested on both games, though most agents usually have trouble outperforming the default AI with cheats enabled or skilled players of the game.\n\n\nAlphastar\nAlphastar was the first AI agent to beat professional StarCraft 2 players without any in-game advantages. The deep learning network of the agent initially received input from a simplified zoomed out version of the gamestate, but was later updated to play using a camera like other human players. The developers have not publicly released the code or architecture of their model, but have listed several state of the art machine learning techniques such as relational deep reinforcement learning, long short-term memory, auto-regressive policy heads, pointer networks, and centralized value baseline. Alphastar was initially trained with supervised learning, it watched replays of many human games in order to learn basic strategies. It then trained against different versions of itself and was improved through reinforcement learning. The final version was hugely successful, but only trained to play on a specific map in a protoss mirror matchup.\n\n\nDota 2\nDota 2 is a multiplayer online battle arena (MOBA) game. Like other complex games, traditional AI agents have not been able to compete on the same level as professional human player. The only widely published information on AI agents attempted on Dota 2 is OpenAI's deep learning Five agent.\n\n\nOpenAI Five\nOpenAI Five utilized separate long short-term memory networks to learn each hero. It trained using a reinforcement learning technique known as Proximal Policy Learning running on a system containing 256 GPUs and 128,000 CPU cores. Five trained for months, accumulating 180 years of game experience each day, before facing off with professional players. It was eventually able to beat the 2018 Dota 2 esports champion team in a 2019 series of games.\n\n\nPlanetary Annihilation\nPlanetary Annihilation is a real-time strategy game which focuses on massive scale war. The developers use ANNs in their default AI agent.\n\n\nSupreme Commander 2\nSupreme Commander 2 is a real-time strategy (RTS) video game. \nThe game uses Multilayer Perceptrons (MLPs) to control a platoon's reaction to encountered enemy units. Total of four MLPs are used, one for each platoon type: land, naval, bomber, and fighter.\n\n\nGran Turismo\nGran Turismo is a PlayStation game franchise that simulates realistic racing and driving experiences. In 2022, Sony AI researchers presented Sophy, an agent which can play Gran Turismo with performance on par with or superior to the world's best e-sports drivers. The implemented solution is based on model-free deep reinforcement learning.\n\n\nGeneralized games\nThere have been attempts to make machine learning agents that are able to play more than one game. These \"general\" gaming agents are trained to understand games based on shared properties between them.\n\n\nAlphaZero\nAlphaZero is a modified version of AlphaGo Zero which is able to play Shogi, chess, and Go. The modified agent starts with only basic rules of the game, and is also trained entirely through self-learning. DeepMind was able to train this generalized agent to be competitive with previous versions of itself on Go, as well as top agents in the other two games.\n\n\nStrengths and weaknesses of deep learning agents\nMachine learning agents are often not covered in many game design courses. Previous use of machine learning agents in games may not have been very practical, as even the 2015 version of AlphaGo took hundreds of CPUs and GPUs to train to a strong level. This potentially limits the creation of highly effective deep learning agents to large corporations or extremely wealthy individuals. The extensive training time of neural network based approaches can also take weeks on these powerful machines.\nThe problem of effectively training ANN based models extends beyond powerful hardware environments; finding a good way to represent data and learn meaningful things from it is also often a difficult problem. ANN models often overfit to very specific data and perform poorly in more generalized cases. AlphaStar shows this weakness, despite being able to beat professional players, it is only able to do so on a single map when playing a mirror protoss matchup. OpenAI Five also shows this weakness, it was only able to beat professional player when facing a very limited hero pool out of the entire game. This example show how difficult it can be to train a deep learning agent to perform in more generalized situations.\nMachine learning agents have shown great success in a variety of different games. However, agents that are too competent also risk making games too difficult for new or casual players. Research has shown that challenge that is too far above a player's skill level will ruin lower player enjoyment. These highly trained agents are likely only desirable against very skilled human players who have many of hours of experience in a given game. Given these factors, highly effective deep learning agents are likely only a desired choice in games that have a large competitive scene, where they can function as an alternative practice option to a skilled human player.\n\n\nComputer vision-based players\nComputer vision focuses on training computers to gain a high-level understanding of digital images or videos. Many computer vision techniques also incorporate forms of machine learning, and have been applied on various video games. This application of computer vision focuses on interpreting game events using visual data. In some cases, artificial intelligence agents have used model-free techniques to learn to play games without any direct connection to internal game logic, solely using video data as input.\n\n\nPong\nAndrej Karpathy has demonstrated that relatively trivial neural network with just one hidden layer is capable of being trained to play Pong based on screen data alone.\n\n\nAtari games\nIn 2013, a team at DeepMind demonstrated the use of deep Q-learning to play a variety of Atari video games — Beamrider, Breakout, Enduro, Pong, Q*bert, Seaquest, and Space Invaders — from screen data. The team expanded their work to create a learning algorithm called MuZero that was able to \"learn\" the rules and develop winning strategies for over 50 different Atari games based on screen data.\n\n\nDoom\nDoom (1993) is a first-person shooter (FPS) game. Student researchers from Carnegie Mellon University used computer vision techniques to create an agent that could play the game using only image pixel input from the game. The students used convolutional neural network (CNN) layers to interpret incoming image data and output valid information to a recurrent neural network which was responsible for outputting game moves.\n\n\nSuper Mario\nOther uses of vision-based deep learning techniques for playing games have included playing Super Mario Bros. only using image input, using deep Q-learning for training.\n\n\nMinecraft\nResearchers with OpenAI created about 2000 hours of video plays of Minecraft coded with the necessary human inputs, and then trained a machine learning model to comprehend the video feedback from the input. The researchers then used that model with 70,000 hours of Minecraft playthroughs offered on YouTube to see how well the model could create the input to match that behavior and learn further from it, such as being able to learn the steps and process of creating a diamond pickaxe tool. In 2023, the algorithm DreamerV3 trained a policy capable of autonomously obtaining diamonds.\n\n\nMachine learning for procedural content generation in games\nMachine learning has seen research for use in content recommendation and generation. Procedural content generation is the process of creating data algorithmically rather than manually. This type of content is used to add replayability to games without relying on constant additions by human developers. PCG has been used in various games for different types of content generation, examples of which include weapons in Borderlands 2, all world layouts in Minecraft and entire universes in No Man's Sky. Common approaches to PCG include techniques that involve grammars, search-based algorithms, and logic programming. These approaches require humans to manually define the range of content possible, meaning that a human developer decides what features make up a valid piece of generated content. Machine learning is theoretically capable of learning these features when given examples to train off of, thus greatly reducing the complicated step of developers specifying the details of content design. Machine learning techniques used for content generation include Long Short-Term Memory (LSTM) Recurrent Neural Networks (RNN), Generative Adversarial networks (GAN), and K-means clustering. Not all of these techniques make use of ANNs, but the rapid development of deep learning has greatly increased the potential of techniques that do.\n\n\nGalactic Arms Race\nGalactic Arms Race is a space shooter video game that uses neuroevolution powered PCG to generate unique weapons for the player. This game was a finalist in the 2010 Indie Game Challenge and its related research paper won the Best Paper Award at the 2009 IEEE Conference on Computational Intelligence and Games. The developers use a form of neuroevolution called cgNEAT to generate new content based on each player's personal preferences.\nEach generated item is represented by a special ANN known as a Compositional Pattern Producing Network (CPPNs). During the evolutionary phase of the game cgNEAT calculates the fitness of current items based on player usage and other gameplay metrics, this fitness score is then used decide which CPPNs will reproduce to create a new item. The ending result is the generation of new weapon effects based on the player's preference.\n\n\nSuper Mario Bros.\nSuper Mario Bros. has been used by several researchers to simulate PCG level creation. Various attempts having used different methods. A version in 2014 used n-grams to generate levels similar to the ones it trained on, which was later improved by making use of MCTS to guide generation. These generations were often not optimal when taking gameplay metrics such as player movement into account, a separate research project in 2017 tried to resolve this problem by generating levels based on player movement using Markov Chains. These projects were not subjected to human testing and may not meet human playability standards.\n\n\nThe Legend of Zelda\nPCG level creation for The Legend of Zelda has been attempted by researchers at the University of California, Santa Cruz. This attempt made use of a Bayesian Network to learn high level knowledge from existing levels, while Principal Component Analysis (PCA) was used to represent the different low level features of these levels. The researchers used PCA to compare generated levels to human made levels and found that they were considered very similar. This test did not include playability or human testing of the generated levels.\n\n\nDeep learning for content generation in games\nThe introduction of Generative Adversarial Networks first, and then of diffusion models allows for generating in-game content at runtime using non-procedural approaches. Examples include:\n\nThe 3D printer available in InZOI (available in early access), a life simulation game developed by InZOI Studio and published by Krafton. Given a 2D image file provided by the user, the 3D printer generates the corresponding 3D object, which the user can then place in the game or use to decorate its avatar.\nThe terrain generation solution implemented in Prologue: Go Wayback! (early access: to be announced, with play tests undergoing in early 2025), a survival game developed by PlayerUnknown Productions. The approach allows to generate a new game map every time the game is launched.\n\n\nMusic generation\nMusic is often seen in video games and can be a crucial element for influencing the mood of different situations and story points. Machine learning has seen use in the experimental field of music generation; it is uniquely suited to processing raw unstructured data and forming high level representations that could be applied to the diverse field of music. Most attempted methods have involved the use of ANN in some form. Methods include the use of basic feedforward neural networks, autoencoders, restricted boltzmann machines, recurrent neural networks, convolutional neural networks, generative adversarial networks (GANs), and compound architectures that use multiple methods.\n\n\nVRAE video game melody symbolic music generation system\nThe 2014 research paper on \"Variational Recurrent Auto-Encoders\" attempted to generate music based on songs from 8 different video games. This project is one of the few conducted purely on video game music. The neural network in the project was able to generate data that was very similar to the data of the games it trained off of. The generated data did not translate into good quality music.\n\n\nReferences\n\n\nExternal links", "categories": ["Articles with short description", "CS1 maint: location missing publisher", "CS1 maint: periodical has ISBN", "Game artificial intelligence", "Machine learning", "Short description is different from Wikidata"], "references": ["https://deepmind.com/blog/alphastar-mastering-real-time-strategy-game-starcraft-ii/", "https://openai.com/five/", "https://openai.com/blog/how-to-train-your-openai-five/", "https://www.engadget.com/2014/06/06/meet-the-computer-thats-learning-to-kill-and-the-man-who-progra/", "http://dl.acm.org/citation.cfm?id=3298483.3298548", "https://www.eurogamer.net/articles/2012-07-16-how-many-weapons-are-in-borderlands-2", "https://notch.tumblr.com/post/3746989361/terrain-generation-part-1", "https://www.technologyreview.com/s/529136/no-mans-sky-a-vast-game-crafted-by-algorithms/", "https://www.aaai.org/ocs/index.php/AIIDE/AIIDE15/paper/view/11569", "https://www.aaai.org/ocs/index.php/AIIDE/AIIDE15/paper/view/11570", "https://openai.com/blog/openai-five/", "https://developer.ibm.com/technologies/artificial-intelligence/articles/machine-learning-and-gaming/", "http://karpathy.github.io/2016/05/31/rl/", "https://ui.adsabs.harvard.edu/abs/2018Sci...362.1140S", "https://ui.adsabs.harvard.edu/abs/2016Natur.529..484S"], "images": [], "sub_niche": "Adversarial machine learning"} {"title": "Model inversion attack", "url": "https://en.wikipedia.org/wiki/Model_inversion_attack", "summary": "Model inversion attack is a type of adversarial machine learning attack where an attacker tries to reconstruct or infer sensitive information about a model's training data by analyzing the outputs of a trained machine learning model. Instead of directly querying the underlying dataset, attackers query the model (usually via APIs or prediction interfaces), and leverage patterns in the model responses to infer properties of the original inputs. These attacks leverage the fact that machine learning models encode statistical information about their training data in their parameters and outputs, which can unintentionally leak private or proprietary information.\nDepending on the access level to the target model, model inversion attacks can be performed in both black-box and white-box settings. I", "content": "Model inversion attack is a type of adversarial machine learning attack where an attacker tries to reconstruct or infer sensitive information about a model's training data by analyzing the outputs of a trained machine learning model. Instead of directly querying the underlying dataset, attackers query the model (usually via APIs or prediction interfaces), and leverage patterns in the model responses to infer properties of the original inputs. These attacks leverage the fact that machine learning models encode statistical information about their training data in their parameters and outputs, which can unintentionally leak private or proprietary information.\nDepending on the access level to the target model, model inversion attacks can be performed in both black-box and white-box settings. In a generic attack, an adversary makes several queries to a model and leverages the responses (e.g. confidence scores, predictions) to train a surrogate or inversion model that learns to approximate the inverse mapping from outputs to inputs. This process may enable the reconstruction of sensitive attributes, e.g., facial features, medical data, or user behavior patterns, from models trained on such data. The technique has been demonstrated against various models like deep neural networks, classification systems etc. The technique has significant privacy risks in areas like healthcare, finance, biometric identification etc. Mitigation strategies include restricting model access, reducing output granularity, using differential privacy and monitoring anomalous query patterns.\n\n\nSee also\nAdversarial machine learning\nDifferential privacy\n\n\nReferences", "categories": ["All orphaned articles", "All stub articles", "Articles with short description", "Data security", "Machine learning stubs", "Orphaned articles from April 2026", "Privacy", "Short description matches Wikidata"], "references": ["https://doi.org/10.1145%2F2810103.2813677", "https://doi.org/10.1109%2FTKDE.2021.3065936", "https://doi.org/10.1109%2FSP.2017.41", "https://doi.org/10.1561%2F0400000042"], "images": ["File:Hey Machine Learning Logo.png"], "sub_niche": "Adversarial machine learning"} {"title": "Machine learning", "url": "https://en.wikipedia.org/wiki/Machine_learning", "summary": "Machine learning (ML) is a field of study in artificial intelligence concerned with the development and study of statistical algorithms that can learn from data and generalize to unseen data, and thus perform tasks without being explicitly programmed.\nStatistics and mathematical optimisation methods compose the foundations of machine learning. Data mining is a related field of study, focusing on exploratory data analysis (EDA) through unsupervised learning.\nFrom a theoretical viewpoint, probably approximately correct learning provides a mathematical and statistical framework for describing machine learning. Most traditional machine learning and deep learning algorithms can be described as empirical risk minimisation under this framework.\nAdvances in the field of deep learning have allowed", "content": "Machine learning (ML) is a field of study in artificial intelligence concerned with the development and study of statistical algorithms that can learn from data and generalize to unseen data, and thus perform tasks without being explicitly programmed.\nStatistics and mathematical optimisation methods compose the foundations of machine learning. Data mining is a related field of study, focusing on exploratory data analysis (EDA) through unsupervised learning.\nFrom a theoretical viewpoint, probably approximately correct learning provides a mathematical and statistical framework for describing machine learning. Most traditional machine learning and deep learning algorithms can be described as empirical risk minimisation under this framework.\nAdvances in the field of deep learning have allowed neural networks, a class of statistical algorithms, to surpass many previous machine learning approaches in performance. The resulting dominance of machine learning within the field of AI from the late 2000s and early 2010s onwards was such that the terms \"machine learning\" and \"artificial intelligence\" are now often used interchangeably, even though they are not synonymous.\n\n\nHistory\n\nThe term machine learning was coined in 1959 by Arthur Samuel, an IBM employee and pioneer in the field of computer gaming and artificial intelligence. The synonym self-teaching computers was also used during this time period.\nThe earliest machine learning program was introduced in the 1950s, when Samuel invented a computer program that calculated the chance of winning in checkers for each side, but the history of machine learning is rooted in decades of efforts to study human cognitive processes. In 1949, Canadian psychologist Donald Hebb published the book The Organization of Behavior, in which he introduced a theoretical neural structure formed by certain interactions among nerve cells. The Hebbian theory of neuron interaction set the groundwork for how many machine learning algorithms work, with connected artificial neurons changing the strength of their connections based on data. Other researchers who have studied human cognitive systems contributed to the modern machine learning technologies as well, including Walter Pitts and Warren McCulloch, who proposed the first mathematical model of neural networks including algorithms that mirror human thought processes.\nBy the early 1960s, an experimental \"learning machine\" with punched tape memory, called Cybertron, had been developed by Raytheon Company to analyse sonar signals, electrocardiograms, and speech patterns using rudimentary reinforcement learning. It was repetitively \"trained\" by a human operator/teacher to recognise patterns and equipped with a \"goof\" button to cause it to reevaluate incorrect decisions. A representative book on research into machine learning during the 1960s was Nils Nilsson's book \"Learning Machines\", dealing mostly with machine learning for pattern classification. Interest related to pattern recognition continued into the 1970s, as described by Duda and Hart in 1973. In 1981, a report was given on using teaching strategies so that an artificial neural network learns to recognise 40 characters (26 letters, 10 digits, and 4 special symbols) from a computer terminal.\nTom M. Mitchell provided a widely quoted, more formal definition of the algorithms studied in the machine learning field: \"A computer program is said to learn from experience E with respect to some class of tasks T and performance measure P if its performance at tasks in T, as measured by P, improves with experience E.\" This definition of the tasks in which machine learning is concerned is fundamentally operational rather than defining the field in cognitive terms. This follows Alan Turing's proposal in his paper \"Computing Machinery and Intelligence\", in which the question, \"Can machines think?\", is replaced by asking whether machines can convincingly imitate a human in its responses to human-posed questions.\nIn 2012, AlexNet, developed by Alex Krizhevsky, Ilya Sutskever, and Geoffrey Hinton, achieved substantially improved results in the ImageNet image recognition competition, contributing to the wider adoption of deep neural networks. In 2013, Tomáš Mikolov and colleagues introduced word2vec, techniques for efficiently learning distributed vector representations of words from large text corpora. In 2014, Ian Goodfellow and colleagues introduced generative adversarial networks (GANs), a framework for training generative models through an adversarial process. In 2016, AlphaGo became the first computer program to defeat a professional human Go player without handicaps on a full-sized board, using deep neural networks and reinforcement learning. In 2017, Ashish Vaswani and colleagues introduced the Transformer, a neural network architecture based primarily on attention rather than recurrence or convolution.\n\n\nRelationships to other fields\n\n\nArtificial intelligence\n\nAs a scientific endeavour, machine learning grew out of the quest for artificial intelligence (AI). In the early days of AI as an academic discipline, some researchers were interested in having machines learn from data. They attempted to approach the problem with various symbolic methods, as well as what were then termed \"neural networks\"; these were mostly perceptrons and other models that were later found to be reinventions of the generalised linear models of statistics. Probabilistic reasoning was also employed, especially in automated medical diagnosis.\nHowever, an increasing emphasis on the logical, knowledge-based approach caused a rift between AI and machine learning. Probabilistic systems were plagued by theoretical and practical problems of data acquisition and representation. By 1980, expert systems had come to dominate AI, and statistics was out of favour. Work on symbolic/knowledge-based learning continued within AI, leading to inductive logic programming (ILP), but the more statistical line of research was now outside the field of AI proper, in pattern recognition and information retrieval. Neural network research was abandoned by AI and computer science around the same time. This subfield, termed \"connectionism\", was continued by researchers from other disciplines, including John Hopfield, David Rumelhart, and Geoffrey Hinton. Their main success came in the mid-1980s with the reinvention of backpropagation.\nMachine learning (ML), reorganised and recognised as its own field, started to flourish in the 1990s. The field changed its goal from achieving artificial intelligence to tackling solvable problems of a practical nature. It shifted focus away from the symbolic approaches it had inherited from AI, and toward methods and models borrowed from statistics, fuzzy logic, and probability theory.\n\n\nData compression\n\n\nData mining\nMachine learning and data mining often employ the same methods and overlap significantly, but while machine learning focuses on prediction based on known properties learned from the training data, data mining focuses on the discovery of previously unknown properties in the data (this is the analysis step of knowledge discovery in databases). Data mining uses many machine learning methods, but with different goals; on the other hand, machine learning also employs data mining methods as \"unsupervised learning\" or as a preprocessing step to improve learner accuracy. Much of the confusion between these two research communities comes from the basic assumptions they work with: in machine learning, performance is usually evaluated with respect to the ability to reproduce known knowledge, while in knowledge discovery and data mining (KDD) the key task is the discovery of previously unknown knowledge. Evaluated with respect to known knowledge, an uninformed (unsupervised) method will easily be outperformed by other supervised methods, while in a typical KDD task, supervised methods cannot be used due to the unavailability of training data.\nMachine learning also has intimate ties to optimization: Many learning problems are formulated as minimisation of some loss function on a training set of examples. Loss functions express the discrepancy between the predictions of the model being trained and the actual problem instances (for example, in classification, one wants to assign a label to instances, and models are trained to correctly predict the preassigned labels of a set of examples).\n\n\nGeneralization\nCharacterizing the generalisation of various learning algorithms is an active topic of current research, especially for deep learning algorithms.\n\n\nStatistics\nMachine learning and statistics are closely related fields in terms of methods, but distinct in their principal goal: statistics draws population inferences from a sample, while machine learning finds generalisable predictive patterns.\nConventional statistical analyses require the a priori selection of a model most suitable for the study data set. In addition, only significant or theoretically relevant variables based on previous experience are included for analysis. In contrast, machine learning is not built on a pre-structured model; rather, the data shape the model by detecting underlying patterns. The more variables (input) used to train the model, the more accurate the ultimate model will be.\nLeo Breiman distinguished two statistical modelling paradigms: the data model and the algorithmic model, wherein \"algorithmic model\" means more or less the machine learning algorithms like Random forest.\nSome statisticians have adopted methods from machine learning, producing the field of statistical learning.\n\n\nStatistical physics\nAnalytical and computational techniques derived from deep-rooted physics of disordered systems can be extended to large-scale problems, including machine learning, e.g., to analyse the weight space of deep neural networks. Statistical physics is thus finding applications in the area of medical diagnostics.\n\n\nTheory\n\nA core objective of a learner is to generalise from its experience. Generalisation in this context is the ability of a learning machine to perform accurately on new, unseen examples/tasks after having experienced a learning data set. The training examples come from some generally unknown probability distribution (considered representative of the space of occurrences) and the learner has to build a general model about this space that enables it to produce sufficiently accurate predictions in new cases.\nThe computational analysis of machine learning algorithms and their performance is a branch of theoretical computer science known as computational learning theory. One major framework is the probably approximately correct learning model. Because training sets are finite and the future is uncertain, learning theory usually does not yield guarantees of the performance of algorithms. Instead, probabilistic bounds on the performance are quite common. The bias–variance decomposition is one way to quantify generalisation error.\nFor the best performance in the context of generalisation, the complexity of the hypothesis should match the complexity of the function underlying the data. If the hypothesis is less complex than the function, then the model has underfitted the data. If the complexity of the model is increased in response, then the training error decreases. But if the hypothesis is too complex, then the model is subject to overfitting and generalisation will be poorer.\nIn addition to performance bounds, learning theorists study the time complexity and feasibility of learning. In computational learning theory, a computation is considered feasible if it can be done in polynomial time. There are two kinds of time complexity results: Positive results show that a certain class of functions can be learned in polynomial time. Negative results show that certain classes cannot be learned in polynomial time.\n\n\nApproaches\n\nMachine learning approaches are traditionally divided into three broad categories, which correspond to learning paradigms, depending on the nature of the \"signal\" or \"feedback\" available to the learning system:\n\nSupervised learning: The computer is presented with example inputs and their desired outputs, given by a \"teacher\", and the goal is to learn a general rule that maps inputs to outputs.\nUnsupervised learning: No labels are given to the learning algorithm, leaving it on its own to find structure in its input. Unsupervised learning can be a goal in itself (discovering hidden patterns in data) or a means towards an end (feature learning).\nReinforcement learning: A computer program interacts with a dynamic environment in which it must perform a certain goal (such as driving a vehicle or playing a game against an opponent). As it navigates its problem space, the program is provided rewards as feedback, which it tries to maximize, thus resulting in the program learning from experience.\nAlthough each algorithm has advantages and limitations, no single algorithm works for all problems.\n\n\nSupervised learning\n\nSupervised learning algorithms build a mathematical model of a set of data that contains both the inputs and the desired outputs. The data, known as training data, consists of a set of training examples. Each training example has one or more inputs and the desired output, also known as a supervisory signal. In the mathematical model, each training example is represented by an array or vector, sometimes called a feature vector, and the training data is represented by a matrix. Through iterative optimisation of an objective function, supervised learning algorithms learn a function that can be used to predict the output associated with new inputs. An optimal function allows the algorithm to correctly determine the output for inputs that were not a part of the training data. An algorithm that improves the accuracy of its outputs or predictions over time is said to have learned to perform that task.\nTypes of supervised-learning algorithms include active learning, classification and regression. Classification algorithms are used when the outputs are restricted to a limited set of values, while regression algorithms are used when the outputs can take any numerical value within a range. For example, in a classification algorithm that filters emails, the input is an incoming email, and the output is the folder in which to file the email. In contrast, regression is used for tasks such as predicting a person's height based on factors like age and genetics or forecasting future temperatures based on historical data.\nSimilarity learning is an area of supervised machine learning closely related to regression and classification, but the goal is to learn from examples using a similarity function that measures how similar or related two objects are. It has applications in ranking, recommendation systems, visual identity tracking, face verification, and speaker verification.\n\n\nUnsupervised learning\n\nUnsupervised learning algorithms find structures in data that has not been labelled, classified or categorised. Instead of responding to feedback, unsupervised learning algorithms identify commonalities in the data and react based on the presence or absence of such commonalities in each new piece of data. Central applications of unsupervised machine learning include clustering, dimensionality reduction, and density estimation.\nCluster analysis is the assignment of a set of observations into subsets (called clusters) so that observations within the same cluster are similar according to one or more predesignated criteria, while observations drawn from different clusters are dissimilar. Different clustering techniques make different assumptions on the structure of the data, often defined by some similarity metric and evaluated, for example, by internal compactness, or the similarity between members of the same cluster, and separation, the difference between clusters. Other methods are based on estimated density and graph connectivity.\nA special type of unsupervised learning called self-supervised learning involves training a model by generating the supervisory signal from the data itself.\n\n\nDimensionality reduction\nDimensionality reduction is a process of reducing the number of random variables under consideration by obtaining a set of principal variables. In other words, it is a process of reducing the dimension of the feature set, also called the \"number of features\". Most of the dimensionality reduction techniques can be considered as either feature elimination or extraction. One of the popular methods of dimensionality reduction is principal component analysis (PCA). PCA involves changing higher-dimensional data (e.g., 3D) to a smaller space (e.g., 2D).\nThe manifold hypothesis proposes that high-dimensional data sets lie along low-dimensional manifolds, and many dimensionality reduction techniques make this assumption, leading to the areas of manifold learning and manifold regularisation.\n\n\nSemi-supervised learning\n\nSemi-supervised learning falls between unsupervised learning (without any labelled training data) and supervised learning (with completely labelled training data). Some of the training examples are missing training labels, yet many machine-learning researchers have found that unlabelled data, when used in conjunction with a small amount of labelled data, can produce a considerable improvement in learning accuracy.\nIn weakly supervised learning, the training labels are noisy, limited, or imprecise; however, these labels are often cheaper to obtain, resulting in larger effective training sets.\n\n\nReinforcement learning\n\nReinforcement learning is an area of machine learning concerned with how software agents ought to take actions in an environment to maximise some notion of cumulative reward. Due to its generality, the field is studied in many other disciplines, such as game theory, control theory, operations research, information theory, simulation-based optimisation, multi-agent systems, swarm intelligence, statistics and genetic algorithms. In reinforcement learning, the environment is typically represented as a Markov decision process (MDP). Many reinforcement learning algorithms use dynamic programming techniques. Reinforcement learning algorithms do not assume knowledge of an exact mathematical model of the MDP and are used when exact models are infeasible. Reinforcement learning algorithms are used in autonomous vehicles or in learning to play a game against a human opponent.\n\n\nOther types\nOther approaches have been developed which do not fit neatly into this three-fold categorisation, and sometimes more than one is used by the same machine learning system. For example, topic modelling, meta-learning.\n\n\nSelf-learning\nSelf-learning, as a machine learning paradigm, was introduced in 1982 along with a neural network capable of self-learning, named crossbar adaptive array (CAA). It gives a solution to the problem learning without any external reward, by introducing emotion as an internal reward. Emotion is used as a state evaluation of a self-learning agent. The CAA self-learning algorithm computes, in a crossbar fashion, both decisions about actions and emotions (feelings) about consequence situations. The system is driven by the interaction between cognition and emotion.\nThe self-learning algorithm updates a memory matrix W =||w(a,s)|| such that in each iteration executes the following machine learning routine: \n\nin situation s act a\nreceive a consequence situation s'\ncompute emotion of being in the consequence situation v(s')\nupdate crossbar memory w'(a,s) = w(a,s) + v(s')\nIt is a system with only one input, situation, and only one output, action (or behaviour) a. There is neither a separate reinforcement input nor an advice input from the environment. The backpropagated value (secondary reinforcement) is the emotion toward the consequence situation. The CAA exists in two environments, one is the behavioural environment where it behaves, and the other is the genetic environment, wherefrom it initially and only once receives initial emotions about situations to be encountered in the behavioural environment. After receiving the genome (species) vector from the genetic environment, the CAA learns a goal-seeking behaviour in an environment that contains both desirable and undesirable situations.\n\n\nFeature learning\n\nSeveral learning algorithms aim at discovering better representations of the inputs provided during training. Classic examples include principal component analysis and cluster analysis. Feature learning algorithms, also called representation learning algorithms, often attempt to preserve the information in their input but also transform it in a way that makes it useful, often as a pre-processing step before performing classification or predictions. This technique allows reconstruction of the inputs coming from the unknown data-generating distribution, while not being necessarily faithful to configurations that are implausible under that distribution. This replaces manual feature engineering, and allows a machine to both learn the features and use them to perform a specific task.\nFeature learning can be either supervised or unsupervised. In supervised feature learning, features are learned using labelled input data. Examples include artificial neural networks, multilayer perceptrons, and supervised dictionary learning. In unsupervised feature learning, features are learned with unlabelled input data. Examples include dictionary learning, independent component analysis, autoencoders, matrix factorisation and various forms of clustering.\nManifold learning algorithms attempt to do so under the constraint that the learned representation is low-dimensional. Sparse coding algorithms attempt to do so under the constraint that the learned representation is sparse, meaning that the mathematical model has many zeros. Multilinear subspace learning algorithms aim to learn low-dimensional representations directly from tensor representations for multidimensional data, without reshaping them into higher-dimensional vectors. Deep learning algorithms discover multiple levels of representation, or a hierarchy of features, with higher-level, more abstract features defined in terms of (or generating) lower-level features. It has been argued that an intelligent machine learns a representation that disentangles the underlying factors of variation that explain the observed data.\nFeature learning is motivated by the fact that machine learning tasks such as classification often require input that is mathematically and computationally convenient to process. However, real-world data such as images, video, and sensory data have not yielded attempts to algorithmically define specific features. An alternative is to discover such features or representations through examination, without relying on explicit algorithms.\n\n\nSparse dictionary learning\n\nSparse dictionary learning is a feature learning method where a training example is represented as a linear combination of basis functions and assumed to be a sparse matrix. The method is strongly NP-hard and difficult to solve approximately. A popular heuristic method for sparse dictionary learning is the k-SVD algorithm. Sparse dictionary learning has been applied in several contexts. In classification, the problem is to determine the class to which a previously unseen training example belongs. For a dictionary where each class has already been built, a new training example is associated with the class that is best sparsely represented by the corresponding dictionary. Sparse dictionary learning has also been applied in image denoising. The key idea is that a clean image patch can be sparsely represented by an image dictionary, but the noise cannot.\n\n\nAnomaly detection\n\nIn data mining, anomaly detection, also known as outlier detection, is the identification of rare items, events or observations that raise suspicions by differing significantly from the majority of the data. Typically, the anomalous items represent an issue such as bank fraud, a structural defect, medical problems or errors in a text. Anomalies are referred to as outliers, novelties, noise, deviations and exceptions.\nIn particular, in the context of abuse and network intrusion detection, the interesting objects are often not rare, but unexpected bursts of inactivity. This pattern does not adhere to the common statistical definition of an outlier as a rare object. Many outlier detection methods (in particular, unsupervised algorithms) will fail on such data unless aggregated appropriately. Instead, a cluster analysis algorithm may be able to detect the micro-clusters formed by these patterns.\nThree broad categories of anomaly detection techniques exist. Unsupervised anomaly detection techniques detect anomalies in an unlabelled test data set under the assumption that the majority of the instances in the data set are normal, by looking for instances that seem to fit the least to the remainder of the data set. Supervised anomaly detection techniques require a data set that has been labelled as \"normal\" and \"abnormal\" and involves training a classifier (the key difference from many other statistical classification problems is the inherently unbalanced nature of outlier detection). Semi-supervised anomaly detection techniques construct a model representing normal behaviour from a given normal training data set and then test the likelihood of a test instance being generated by the model.\n\n\nRobot learning\nRobot learning is inspired by a multitude of machine learning methods, starting from supervised learning, reinforcement learning, and finally meta-learning (e.g. MAML).\n\n\nAssociation rules\n\nAssociation rule learning is a rule-based machine learning method for discovering relationships between variables in large databases. It is intended to identify strong rules discovered in databases using some measure of \"interestingness\".\nRule-based machine learning is a general term for any machine learning method that identifies, learns, or evolves \"rules\" to store, manipulate or apply knowledge. The defining characteristic of a rule-based machine learning algorithm is the identification and utilisation of a set of relational rules that collectively represent the knowledge captured by the system. This is in contrast to other machine learning algorithms that commonly identify a singular model that can be universally applied to any instance in order to make a prediction. Rule-based machine learning approaches include learning classifier systems, association rule learning, and artificial immune systems.\nBased on the concept of strong rules, Rakesh Agrawal, Tomasz Imieliński and Arun Swami introduced association rules for discovering regularities between products in large-scale transaction data recorded by point-of-sale (POS) systems in supermarkets. For example, the rule \n \n \n \n {\n \n o\n n\n i\n o\n n\n s\n ,\n p\n o\n t\n a\n t\n o\n e\n s\n \n }\n ⇒\n {\n \n b\n u\n r\n g\n e\n r\n \n }\n \n \n {\\displaystyle \\{\\mathrm {onions,potatoes} \\}\\Rightarrow \\{\\mathrm {burger} \\}}\n \n found in the sales data of a supermarket would indicate that if a customer buys onions and potatoes together, they are likely to also buy hamburger meat. Such information can be used as the basis for decisions about marketing activities such as promotional pricing or product placements. In addition to market basket analysis, association rules are employed today in application areas including Web usage mining, intrusion detection, continuous production, and bioinformatics. In contrast with sequence mining, association rule learning typically does not consider the order of items either within a transaction or across transactions.\nLearning classifier systems (LCS) are a family of rule-based machine learning algorithms that combine a discovery component, typically a genetic algorithm, with a learning component, performing either supervised learning, reinforcement learning, or unsupervised learning. They seek to identify a set of context-dependent rules that collectively store and apply knowledge in a piecewise manner to make predictions.\nInductive logic programming (ILP) is an approach to rule learning using logic programming as a uniform representation for input examples, background knowledge, and hypotheses. Given an encoding of the known background knowledge and a set of examples represented as a logical database of facts, an ILP system will derive a hypothesized logic program that entails all positive and no negative examples. Inductive programming is a related field that considers any kind of programming language for representing hypotheses (and not only logic programming), such as functional programs.\nInductive logic programming is particularly useful in bioinformatics and natural language processing. Gordon Plotkin and Ehud Shapiro laid the initial theoretical foundation for inductive machine learning in a logical setting. Shapiro built their first implementation (Model Inference System) in 1981: a Prolog program that inductively inferred logic programs from positive and negative examples. The term inductive here refers to philosophical induction, suggesting a theory to explain observed facts, rather than mathematical induction, proving a property for all members of a well-ordered set.\n\n\nModels\nA machine learning model is a type of mathematical model that, once \"trained\" on a given dataset, can be used to make predictions or classifications on new data. During training, a learning algorithm iteratively adjusts the model's internal parameters to minimise errors in its predictions. By extension, the term \"model\" can refer to several levels of specificity, from a general class of models and their associated learning algorithms to a fully trained model with all its internal parameters tuned.\nVarious types of models have been used and researched for machine learning systems, picking the best model for a task is called model selection.\n\n\nArtificial neural networks\n\nArtificial neural networks (ANNs), or connectionist systems, are computing systems vaguely inspired by the biological neural networks that constitute animal brains. Such systems \"learn\" to perform tasks by considering examples, generally without being programmed with any task-specific rules.\nAn ANN is a model based on a collection of connected units or nodes called \"artificial neurons\", which loosely model the neurons in a biological brain. Each connection, like the synapses in a biological brain, can transmit information, a \"signal\", from one artificial neuron to another. An artificial neuron that receives a signal can process it and then signal additional artificial neurons connected to it. In common ANN implementations, the signal at a connection between artificial neurons is a real number, and the output of each artificial neuron is computed by some non-linear function of the sum of its inputs. The connections between artificial neurons are called \"edges\". Artificial neurons and edges typically have a weight that adjusts as learning proceeds. The weight increases or decreases the strength of the signal at a connection. Artificial neurons may have a threshold such that the signal is only sent if the aggregate signal crosses that threshold. Typically, artificial neurons are aggregated into layers. Different layers may perform different kinds of transformations on their inputs. Signals travel from the first layer (the input layer) to the last layer (the output layer), possibly after traversing the layers multiple times.\nThe original goal of the ANN approach was to solve problems in the same way that a human brain would. However, over time, ANNs have diverged from biology ,as they have been optimized for engineering performance on specific tasks and implemented on digital hardware whose physical substrate and signaling mechanisms differ from those of biological neural tissue. These implementation-level differences may not preclude brain-inspired design at more abstract levels, including computational objectives, learning rules, network architectures, as well as broader principles, such as predictive or generative world models, biologically plausible credit assignment, and complementary fast- and slow-learning memory systems. Artificial neural networks have been used on a variety of tasks, including computer vision, speech recognition, machine translation, social network filtering, playing board and video games and medical diagnosis.\nDeep learning consists of multiple hidden layers in an artificial neural network. This approach tries to model the way the human brain processes light and sound into vision and hearing. Some successful applications of deep learning are computer vision and speech recognition.\n\n\nDecision trees\n\nDecision tree learning uses a decision tree as a predictive model to go from observations about an item (represented in the branches) to conclusions about the item's target value (represented in the leaves). It is one of the predictive modelling approaches used in statistics, data mining, and machine learning. Tree models where the target variable can take a discrete set of values are called classification trees; in these tree structures, leaves represent class labels, and branches represent conjunctions of features that lead to those class labels. Decision trees where the target variable can take continuous values (typically real numbers) are called regression trees. In decision analysis, a decision tree can be used to visually and explicitly represent decisions and decision making. In data mining, a decision tree describes data, but the resulting classification tree can be an input for decision-making.\n\n\nRandom forest regression\nRandom forest regression (RFR) falls under the umbrella of decision tree-based models. RFR is an ensemble learning method that builds multiple decision trees and averages their predictions to improve accuracy and to avoid overfitting. To build decision trees, RFR uses bootstrapped sampling; for instance, each decision tree is trained on random data from the training set. This random selection of RFR for training enables the model to reduce biased predictions and achieve a higher degree of accuracy. RFR generates independent decision trees, and it can work on single-output data as well as multiple regressor tasks. This makes RFR compatible to be use in various applications.\n\n\nSupport-vector machines\n\nSupport-vector machines (SVMs), also known as support-vector networks, are a set of related supervised learning methods used for classification and regression. Given a set of training examples, each marked as belonging to one of two categories, an SVM training algorithm builds a model that predicts whether a new example falls into one category. An SVM training algorithm is a non-probabilistic, binary, linear classifier, although methods such as Platt scaling exist to use SVM in a probabilistic classification setting. In addition to performing linear classification, SVMs can efficiently perform a non-linear classification using what is called the kernel trick, implicitly mapping their inputs into high-dimensional feature spaces.\n\n\nRegression analysis\n\nRegression analysis encompasses a large variety of statistical methods to estimate the relationship between input variables and their associated features. Its most common form is linear regression, where a single line is drawn to best fit the given data according to a mathematical criterion such as ordinary least squares. The latter is often extended by regularisation methods to mitigate overfitting and bias, as in ridge regression. When dealing with non-linear problems, go-to models include polynomial regression (for example, used for trendline fitting in Microsoft Excel), logistic regression (often used in statistical classification) or even kernel regression, which introduces non-linearity by taking advantage of the kernel trick to implicitly map input variables to higher-dimensional space.\nMultivariate linear regression extends the concept of linear regression to handle multiple dependent variables simultaneously. This approach estimates the relationships between a set of input variables and several output variables by fitting a multidimensional linear model. It is particularly useful in scenarios where outputs are interdependent or share underlying patterns, such as predicting multiple economic indicators or reconstructing images, which are inherently multi-dimensional.\n\n\nBayesian networks\n\nA Bayesian network, belief network, or directed acyclic graphical model is a probabilistic graphical model that represents a set of random variables and their conditional independence with a directed acyclic graph (DAG). For example, a Bayesian network could represent the probabilistic relationships between diseases and symptoms. Given symptoms, the network can be used to compute the probabilities of the presence of various diseases. Efficient algorithms exist that perform inference and learning. Bayesian networks that model sequences of variables, like speech signals or protein sequences, are called dynamic Bayesian networks. Generalisations of Bayesian networks that can represent and solve decision problems under uncertainty are called influence diagrams.\n\n\nGaussian processes\n\nA Gaussian process is a stochastic process in which every finite collection of the random variables in the process has a multivariate normal distribution, and it relies on a pre-defined covariance function, or kernel, that models how pairs of points relate to each other depending on their locations.\nGiven a set of observed points, or input–output examples, the distribution of the (unobserved) output of a new point as a function of its input data can be directly computed by looking at the observed points and the covariances between those points and the new, unobserved point.\nGaussian processes are popular surrogate models in Bayesian optimisation used to do hyperparameter optimisation.\n\n\nGenetic algorithms\n\nA genetic algorithm (GA) is a search algorithm and heuristic technique that mimics the process of natural selection, using methods such as mutation and crossover to generate new genotypes in the hope of finding good solutions to a given problem. In machine learning, genetic algorithms were used in the 1980s and 1990s. Conversely, machine learning techniques have been used to improve the performance of genetic and evolutionary algorithms.\n\n\nBelief functions\n\nThe theory of belief functions, also referred to as evidence theory or Dempster–Shafer theory, is a general framework for reasoning with uncertainty, with understood connections to other frameworks such as probability, possibility and imprecise probability theories. These theoretical frameworks can be thought of as a kind of learner and have some analogous properties of how evidence is combined (e.g., Dempster's rule of combination), just like how in a pmf-based Bayesian approach would combine probabilities. However, there are many caveats to these beliefs functions when compared to Bayesian approaches to incorporate ignorance and uncertainty quantification. These belief function approaches that are implemented within the machine learning domain typically leverage a fusion approach of various ensemble methods to better handle the learner's decision boundary, low samples, and ambiguous class issues that standard machine learning approach tend to have difficulty resolving. However, the computational complexity of these algorithms is dependent on the number of propositions (classes), and can lead to a much higher computation time when compared to other machine learning approaches.\n\n\nRule-based models\n\nRule-based machine learning (RBML) is a branch of machine learning that automatically discovers and learns 'rules' from data. It provides interpretable models, making it useful for decision-making in fields like healthcare, fraud detection, and cybersecurity. Key RBML techniques includes learning classifier systems, association rule learning, artificial immune systems, and other similar models. These methods extract patterns from data and evolve rules over time.\n\n\nTraining models\nTypically, machine learning models require a high quantity of reliable data to perform accurate predictions. When training a machine learning model, machine learning engineers need to target and collect a large and representative sample of data. Data from the training set can be as varied as a corpus of text, a collection of images, sensor data, and data collected from individual users of a service. Overfitting is something to watch out for when training a machine learning model. Trained models derived from biased or non-evaluated data can result in skewed or undesired predictions. Biased models may result in detrimental outcomes, thereby furthering the negative impacts on society or objectives. Algorithmic bias is a potential result of data not being fully prepared for training. Machine learning ethics is becoming a field of study and, notably, becoming integrated within machine learning engineering teams.\n\n\nFederated learning\n\nFederated learning is an adapted form of distributed artificial intelligence to train machine learning models that decentralises the training process, allowing for users' privacy to be maintained by not needing to send their data to a centralised server. This also increases efficiency by decentralising the training process to many devices. For example, Gboard uses federated machine learning to train search query prediction models on users' mobile phones without having to send individual searches back to Google.\n\n\nApplications\nThere are many applications for machine learning, including:\n\nIn 2006, the media-services provider Netflix held the first \"Netflix Prize\" competition to find a program to better predict user preferences and improve the accuracy of its existing Cinematch movie recommendation algorithm by at least 10%. A joint team made up of researchers from AT&T Labs-Research in collaboration with the teams Big Chaos and Pragmatic Theory built an ensemble model to win the Grand Prize in 2009 for $1 million. Shortly after the prize was awarded, Netflix realised that viewers' ratings were not the best indicators of their viewing patterns (\"everything is a recommendation\") and they changed their recommendation engine accordingly. In 2010, an article in The Wall Street Journal noted the use of machine learning by Rebellion Research to predict the 2008 financial crisis. In 2012, co-founder of Sun Microsystems, Vinod Khosla, predicted that 80% of medical doctors jobs would be lost in the next two decades to automated machine learning medical diagnostic software. In 2014, it was reported that a machine learning algorithm had been applied in the field of art history to study fine art paintings and that it may have revealed previously unrecognised influences among artists. In 2019 Springer Nature published the first research book created using machine learning. In 2020, machine learning technology was used to help make diagnoses and aid researchers in developing a cure for COVID-19. Machine learning was recently applied to predict the pro-environmental behaviour of travellers. Recently, machine learning technology was also applied to optimise smartphone's performance and thermal behaviour based on the user's interaction with the phone. When applied correctly, machine learning algorithms (MLAs) can utilise a wide range of company characteristics to predict stock returns without overfitting. By employing effective feature engineering and combining forecasts, MLAs can generate results that far surpass those obtained from basic linear techniques like OLS.\nRecent advancements in machine learning have extended into the field of quantum chemistry, where novel algorithms now enable the prediction of solvent effects on chemical reactions, thereby offering new tools for chemists to tailor experimental conditions for optimal outcomes.\nMachine Learning is becoming a useful tool to investigate and predict evacuation decision-making in large-scale and small-scale disasters. Different solutions have been tested to predict if and when householders decide to evacuate during wildfires and hurricanes. Other applications have been focusing on pre evacuation decisions in building fires.\n\n\nLimitations\nAlthough machine learning has been transformative in some fields, machine-learning programs often fail to deliver expected results. Reasons for this are numerous: lack of (suitable) data, lack of access to the data, data bias, privacy problems, badly chosen tasks and algorithms, wrong tools and people, lack of resources, and evaluation problems.\nThe \"black box theory\" poses another yet significant challenge. Black box refers to a situation where the algorithm producing an output is entirely opaque, meaning that even the designers of an application cannot audit the pattern that the machine extracted from the data. The House of Lords Select Committee, which claimed that such an \"intelligence system\" that could have a \"substantial impact on an individual's life\" would not be considered acceptable unless it provided \"a full and satisfactory explanation for the decisions\" it makes.\nIn 2018, a self-driving car from Uber failed to detect a pedestrian, who was killed after a collision. Attempts to use machine learning in healthcare with the IBM Watson system failed to deliver even after years of time and billions of dollars invested. Microsoft's Bing Chat chatbot has been reported to produce hostile and offensive response against its users.\nMachine learning has been used as a strategy to update the evidence related to a systematic review and increased reviewer burden related to the growth of biomedical literature. While it has improved with training sets, it has not yet developed sufficiently to reduce the workload burden without limiting the necessary sensitivity for the findings research itself.\n\n\nExplainability\n\nExplainable AI (XAI), or Interpretable AI, or Explainable Machine Learning (XML), is artificial intelligence (AI) in which humans can understand the decisions or predictions made by the AI. It contrasts with the \"black box\" concept in machine learning where even its designers cannot explain why an AI arrived at a specific decision. By refining the mental models of users of AI-powered systems and dismantling their misconceptions, XAI promises to help users perform more effectively. XAI may be an implementation of the social right to explanation.\n\n\nOverfitting\n\nSettling on a bad, overly complex theory gerrymandered to fit all the past training data is known as overfitting. Many systems attempt to reduce overfitting by rewarding a theory in accordance with how well it fits the data but penalising the theory in accordance with how complex the theory is.\n\n\nModel collapse\n\n\nHallucinations\n\n\nOther limitations and vulnerabilities\nLearners can also be disappointed by \"learning the wrong lesson\". A toy example is that an image classifier trained only on pictures of brown horses and black cats might conclude that all brown patches are likely to be horses. A real-world example is that, unlike humans, current image classifiers often do not primarily make judgments from the spatial relationship between components of the picture, and they learn relationships between pixels that humans are oblivious to, but that still correlate with images of certain types of real objects. Modifying these patterns on a legitimate image can result in \"adversarial\" images that the system misclassifies.\nAdversarial vulnerabilities can also result in nonlinear systems or from non-pattern perturbations. For some systems, it is possible to change the output by only changing a single adversarially chosen pixel. Machine learning models are often vulnerable to manipulation or evasion via adversarial machine learning.\nResearchers have demonstrated how backdoors can be placed undetectably into classifying (e.g., for categories \"spam\" and \"not spam\" of posts) machine learning models that are often developed or trained by third parties. Parties can change the classification of any input, including in cases for which a type of data/software transparency is provided, possibly including white-box access.\n\n\nModel assessments\nClassification of machine learning models can be validated by accuracy estimation techniques like the holdout method, which splits the data into a training and test set (conventionally 2/3 training set and 1/3 test set designation) and evaluates the performance of the training model on the test set. In comparison, the K-fold-cross-validation method randomly partitions the data into K subsets and then K experiments are performed each considering 1 subset for evaluation and the remaining K-1 subsets for training the model. In addition to the holdout and cross-validation methods, bootstrap, which samples n instances with replacement from the dataset, can be used to assess model accuracy.\nIn addition to overall accuracy, investigators frequently report sensitivity and specificity, meaning true positive rate (TPR) and true negative rate (TNR), respectively. Similarly, investigators sometimes report the false positive rate (FPR) as well as the false negative rate (FNR). However, these rates are ratios that fail to reveal their numerators and denominators. Receiver operating characteristic (ROC), along with the accompanying Area Under the ROC Curve (AUC), offer additional tools for classification model assessment. Higher AUC is associated with a better performing model.\n\n\nEthics\n\n\nBias\n\nDifferent machine learning approaches can suffer from different data biases. A machine learning system trained specifically on current customers may not be able to predict the needs of new customer groups that are not represented in the training data. When trained on human-made data, machine learning is likely to pick up the constitutional and unconscious biases already present in society.\nSystems that are trained on datasets collected with biases may exhibit these biases upon use (algorithmic bias), thus digitising cultural prejudices. For example, in 1988, the UK's Commission for Racial Equality found that St. George's Medical School had been using a computer program trained from data of previous admissions staff and this program had denied nearly 60 candidates who were found to either be women or have non-European-sounding names. Using job hiring data from a firm with racist hiring policies may lead to a machine learning system duplicating the bias by scoring job applicants by similarity to previous successful applicants. Another example includes predictive policing company Geolitica's predictive algorithm that resulted in \"disproportionately high levels of over-policing in low-income and minority communities\" after being trained with historical crime data.\nWhile responsible collection of data and documentation of algorithmic rules used by a system is considered a critical part of machine learning, some researchers blame the lack of participation and representation of minority populations in the field of AI for machine learning's vulnerability to biases. In fact, according to research carried out by the Computing Research Association in 2021, \"female faculty make up just 16.1%\" of all faculty members who focus on AI among several universities around the world. Furthermore, among the group of \"new U.S. resident AI PhD graduates,\" 45% identified as white, 22.4% as Asian, 3.2% as Hispanic, and 2.4% as African American, which further demonstrates a lack of diversity in the field of AI.\nLanguage models learned from data have been shown to contain human-like biases. Because human languages contain biases, machines trained on language corpora will necessarily also learn these biases. In 2016, Microsoft tested Tay, a chatbot that learned from Twitter, and it quickly picked up racist and sexist language.\nIn an experiment carried out by ProPublica, a machine learning algorithm's insight into the recidivism rates among prisoners falsely flagged \"black defendants high risk twice as often as white defendants\". In 2015, Google Photos once tagged a couple of black people as gorillas, which caused controversy. The gorilla label was subsequently removed, and in 2023, it still cannot recognise gorillas. Similar issues with recognising non-white people have been found in many other systems.\n\n\nFinancial incentives\nThere are concerns among health care professionals that these systems might not be designed in the public's interest but as income-generating machines. This is especially true in the United States, where there is a long-standing ethical dilemma of improving health care, but also increasing profits. For example, the algorithms could be designed to provide patients with unnecessary tests or medication in which the algorithm's proprietary owners hold stakes. There is potential for machine learning in health care to provide professionals with an additional tool to diagnose, medicate, and plan recovery paths for patients, but this requires these biases to be mitigated.\n\n\nHardware\nSince the 2010s, advances in both machine learning algorithms and computer hardware have led to more efficient methods for training deep neural networks (a particular narrow subdomain of machine learning) that contain many layers of nonlinear hidden units. By 2019, graphics processing units (GPUs), often with AI-specific enhancements, had displaced CPUs as the dominant method of training large-scale commercial cloud AI. OpenAI estimated the hardware compute used in the largest deep learning projects from AlexNet (2012) to AlphaZero (2017), and found a 300,000-fold increase in the amount of compute required, with a doubling-time trendline of 3.4 months.\n\n\nTensor Processing Units (TPUs)\nTensor Processing Units (TPUs) are specialised hardware accelerators developed by Google specifically for machine learning workloads. Unlike general-purpose GPUs and FPGAs, TPUs are optimised for tensor computations, making them particularly efficient for deep learning tasks such as training and inference. They are widely used in Google Cloud AI services and large-scale machine learning models like Google's DeepMind AlphaFold and large language models. TPUs leverage matrix multiplication units and high-bandwidth memory to accelerate computations while maintaining energy efficiency. Since their introduction in 2016, TPUs have become a key component of AI infrastructure, especially in cloud-based environments.\n\n\nNeuromorphic computing\nNeuromorphic computing refers to a class of computing systems designed to emulate the structure and functionality of biological neural networks. These systems may be implemented through software-based simulations on conventional hardware or through specialised hardware architectures.\n\n\nPhysical neural networks\nA physical neural network is a specific type of neuromorphic hardware that relies on electrically adjustable materials, such as memristors, to emulate the function of neural synapses. The term \"physical neural network\" highlights the use of physical hardware for computation, as opposed to software-based implementations. It broadly refers to artificial neural networks that use materials with adjustable resistance to replicate neural synapses.\n\n\nEmbedded machine learning\nEmbedded machine learning is a sub-field of machine learning where models are deployed on embedded systems with limited computing resources, such as wearable computers, edge devices and microcontrollers. Running models directly on these devices eliminates the need to transfer and store data on cloud servers for further processing, thereby reducing the risk of data breaches, privacy leaks and theft of intellectual property, personal data and business secrets. Embedded machine learning can be achieved through various techniques, such as hardware acceleration, approximate computing, and model optimization. Common optimization techniques include pruning, quantisation, knowledge distillation, low-rank factorisation, network architecture search, and parameter sharing.\n\n\nSoftware\n\n\nFree and open-source software\n\n\nProprietary software with free and open-source editions\nKNIME\nRapidMiner\n\n\nProprietary software\n\n\nJournals\nJournal of Machine Learning Research\nMachine Learning\nNature Machine Intelligence\nNeural Computation\nIEEE Transactions on Pattern Analysis and Machine Intelligence\n\n\nConferences\nAAAI Conference on Artificial Intelligence\nAssociation for Computational Linguistics (ACL)\nEuropean Conference on Machine Learning and Principles and Practice of Knowledge Discovery in Databases (ECML PKDD)\nInternational Conference on Computational Intelligence Methods for Bioinformatics and Biostatistics (CIBB)\nInternational Conference on Machine Learning (ICML)\nInternational Conference on Learning Representations (ICLR)\nInternational Conference on Intelligent Robots and Systems (IROS)\nConference on Knowledge Discovery and Data Mining (KDD)\nConference on Neural Information Processing Systems (NeurIPS)\n\n\nSee also\nAutomated machine learning – Process of automating the application of machine learning\nBig data – Extremely large or complex datasets\nDeep learning — branch of ML concerned with artificial neural networks\nDifferentiable programming – Programming paradigm\nGoogle Colab – no setup online IDE for machine learning in Python and Julia\nList of datasets for machine-learning research\nList of machine learning algorithms and List of algorithms for machine learning and statistical classification\nM-theory (learning framework) – Framework in machine learning\nMachine unlearning – Field of study in artificial intelligence\nOutline of machine learning\nSolomonoff's theory of inductive inference – Mathematical theory\nTinyML — Machine learning on low-power embedded systems\n\n\nReferences\n\n\nSources\nDomingos, Pedro (22 September 2015). The Master Algorithm: How the Quest for the Ultimate Learning Machine Will Remake Our World. Basic Books. ISBN 978-0-465-06570-7.\nNilsson, Nils (1998). Artificial Intelligence: A New Synthesis. Morgan Kaufmann. ISBN 978-1-55860-467-4. Archived from the original on 26 July 2020. Retrieved 18 November 2019.\nPoole, David; Mackworth, Alan; Goebel, Randy (1998). Computational Intelligence: A Logical Approach. New York: Oxford University Press. ISBN 978-0-19-510270-3. Archived from the original on 26 July 2020. Retrieved 22 August 2020.\nRussell, Stuart J.; Norvig, Peter (2003), Artificial Intelligence: A Modern Approach (2nd ed.), Upper Saddle River, New Jersey: Prentice Hall, ISBN 0-13-790395-2.\n\n\nFurther reading\n\n\nExternal links\nInternational Machine Learning Society\nMLOSS page at JMLR - an academic database of open-source machine learning software.", "categories": ["All Wikipedia articles written in British English", "All articles with incomplete citations", "All articles with unsourced statements", "All pages needing factual verification", "Articles with excerpts", "Articles with incomplete citations from August 2026", "Articles with short description", "Articles with unsourced statements from April 2026", "Articles with unsourced statements from March 2026", "Articles with unsourced statements from October 2025", "CS1 errors: deprecated parameters", "Cybernetics", "Data science", "Definition", "Learning", "Machine learning", "Short description is different from Wikidata", "Use British English from October 2025", "Use dmy dates from April 2025", "Webarchive template wayback links"], "references": ["https://web.archive.org/web/20171230081341/http://machinelearning.org/", "https://d-nb.info/gnd/4193754-5", "https://id.ndl.go.jp/auth/ndlna/001210569", "https://aleph.nkp.cz/F/?func=find-c&local_base=aut&ccl_term=ica=ph126143&CON_LNG=ENG", "https://books.google.com/books?id=7f5bBAAAQBAJ", "https://archive.org/details/introductiontoma00alpa_0", "https://web.archive.org/web/20190606043931/https://hazyresearch.github.io/snorkel/blog/ws_blog_post.html", "https://hazyresearch.github.io/snorkel/blog/ws_blog_post.html", "https://api.semanticscholar.org/CorpusID:393948", "https://web.archive.org/web/20170813153615/http://machinelearning.wustl.edu/mlpapers/paper_files/AISTATS2011_CoatesNL11.pdf", "http://machinelearning.wustl.edu/mlpapers/paper_files/AISTATS2011_CoatesNL11.pdf", "https://www.cs.cmu.edu/~efros/courses/LBMV07/Papers/csurka-eccv-04.pdf", "http://www.dsp.utoronto.ca/~haiping/Publication/SurveyMSL_PR2011.pdf", "https://ui.adsabs.harvard.edu/abs/2011PatRe..44.1540L", "https://books.google.com/books?id=cq5ewg7FniMC&pg=PA3"], "images": ["File:AI Overviews result for Joaquin Correa brother, 10 August 2025.jpg", "File:Complex-adaptive-system.jpg"], "sub_niche": "Adversarial machine learning"} {"title": "Ensemble learning", "url": "https://en.wikipedia.org/wiki/Ensemble_learning", "summary": "In statistics and machine learning, ensemble methods use multiple learning algorithms to obtain better predictive performance than could be obtained from any of the constituent learning algorithms alone.\nUnlike a statistical ensemble in statistical mechanics, which is usually infinite, a machine learning ensemble consists of only a concrete finite set of alternative models, but typically allows for much more flexible structure to exist among those alternatives.", "content": "In statistics and machine learning, ensemble methods use multiple learning algorithms to obtain better predictive performance than could be obtained from any of the constituent learning algorithms alone.\nUnlike a statistical ensemble in statistical mechanics, which is usually infinite, a machine learning ensemble consists of only a concrete finite set of alternative models, but typically allows for much more flexible structure to exist among those alternatives.\n\n\nOverview\nSupervised learning algorithms search through a hypothesis space to find a suitable hypothesis that will make good predictions with a particular problem. Even if this space contains hypotheses that are very well-suited for a particular problem, it may be very difficult to find a good one. Ensembles combine multiple hypotheses to form one which should be theoretically better.\nEnsemble learning trains two or more machine learning algorithms on a specific classification or regression task. The algorithms within the ensemble model are generally referred as \"base models\", \"base learners\", or \"weak learners\" in literature. These base models can be constructed using a single modelling algorithm, or several different algorithms. The idea is to train a diverse set of weak models on the same modelling task, such that the outputs of each weak learner have poor predictive ability (i.e., high bias), and among all weak learners, the outcome and error values exhibit high variance. Fundamentally, an ensemble learning model trains at least two high-bias (weak) and high-variance (diverse) models to be combined into a better-performing model. The set of weak models — which would not produce satisfactory predictive results individually — are combined or averaged to produce a single, high performing, accurate, and low-variance model to fit the task as required.\nEnsemble learning typically refers to bagging (bootstrap aggregating), boosting or stacking/blending techniques to induce high variance among the base models. Bagging creates diversity by generating random samples from the training observations and fitting the same model to each different sample — also known as homogeneous parallel ensembles. Boosting follows an iterative process by sequentially training each base model on the up-weighted errors of the previous base model, producing an additive model to reduce the final model errors — also known as sequential ensemble learning. Stacking or blending consists of different base models, each trained independently (i.e. diverse/high variance) to be combined into the ensemble model — producing a heterogeneous parallel ensemble. Common applications of ensemble learning include random forests (an extension of bagging), Boosted Tree models, and Gradient Boosted Tree Models. Models in applications of stacking are generally more task-specific — such as combining clustering techniques with other parametric and/or non-parametric techniques.\nEvaluating the prediction of an ensemble typically requires more computation than evaluating the prediction of a single model. In one sense, ensemble learning may be thought of as a way to compensate for poor learning algorithms by performing a lot of extra computation. On the other hand, the alternative is to do a lot more learning with one non-ensemble model. An ensemble may be more efficient at improving overall accuracy for the same increase in compute, storage, or communication resources by using that increase on two or more methods, than would have been improved by increasing resource use for a single method. Fast algorithms such as decision trees are commonly used in ensemble methods (e.g., random forests), although slower algorithms can benefit from ensemble techniques as well.\nBy analogy, ensemble techniques have been used also in unsupervised learning scenarios, for example in consensus clustering or in anomaly detection.\n\n\nEnsemble theory\nEmpirically, ensembles tend to yield better results when there is a significant diversity among the models. Many ensemble methods, therefore, seek to promote diversity among the models they combine. Although perhaps non-intuitive, more random algorithms (like random decision trees) can be used to produce a stronger ensemble than very deliberate algorithms (like entropy-reducing decision trees). Using a variety of strong learning algorithms, however, has been shown to be more effective than using techniques that attempt to dumb-down the models in order to promote diversity. It is possible to increase diversity in the training stage of the model using correlation for regression tasks or using information measures such as cross entropy for classification tasks.\n\nTheoretically, one can justify the diversity concept because the lower bound of the error rate of an ensemble system can be decomposed into accuracy, diversity, and the other term.\n\n\nThe geometric framework\nEnsemble learning, including both regression and classification tasks, can be explained using a geometric framework. Within this framework, the output of each individual classifier or regressor for the entire dataset can be viewed as a point in a multi-dimensional space. Additionally, the target result is also represented as a point in this space, referred to as the \"ideal point.\"\nThe Euclidean distance is used as the metric to measure both the performance of a single classifier or regressor (the distance between its point and the ideal point) and the dissimilarity between two classifiers or regressors (the distance between their respective points). This perspective transforms ensemble learning into a deterministic problem.\nFor example, within this geometric framework, it can be proved that the averaging of the outputs (scores) of all base classifiers or regressors can lead to equal or better results than the average of all the individual models. It can also be proved that if the optimal weighting scheme is used, then a weighted averaging approach can outperform any of the individual classifiers or regressors that make up the ensemble or as good as the best performer at least.\n\n\nEnsemble size\nWhile the number of component classifiers of an ensemble has a great impact on the accuracy of prediction, there is a limited number of studies addressing this problem. A priori determining of ensemble size and the volume and velocity of big data streams make this even more crucial for online ensemble classifiers. Mostly statistical tests were used for determining the proper number of components. More recently, a theoretical framework suggested that there is an ideal number of component classifiers for an ensemble such that having more or less than this number of classifiers would deteriorate the accuracy. It is called \"the law of diminishing returns in ensemble construction.\" Their theoretical framework shows that using the same number of independent component classifiers as class labels gives the highest accuracy.\n\n\nCommon types of ensembles\n\n\nBayes optimal classifier\n\nThe Bayes optimal classifier is a classification technique. It is an ensemble of all the hypotheses in the hypothesis space. On average, no other ensemble can outperform it. The Naive Bayes classifier is a version of this that assumes that the data is conditionally independent on the class and makes the computation more feasible. Each hypothesis is given a vote proportional to the likelihood that the training dataset would be sampled from a system if that hypothesis were true. To facilitate training data of finite size, the vote of each hypothesis is also multiplied by the prior probability of that hypothesis. The Bayes optimal classifier can be expressed with the following equation:\n\n \n \n \n y\n =\n \n \n \n a\n r\n g\n m\n a\n x\n \n \n \n c\n \n j\n \n \n ∈\n C\n \n \n \n \n ∑\n \n \n h\n \n i\n \n \n ∈\n H\n \n \n \n P\n (\n \n c\n \n j\n \n \n \n |\n \n \n h\n \n i\n \n \n )\n P\n (\n T\n \n |\n \n \n h\n \n i\n \n \n )\n P\n (\n \n h\n \n i\n \n \n )\n \n \n \n {\\displaystyle y={\\underset {c_{j}\\in C}{\\mathrm {argmax} }}\\sum _{h_{i}\\in H}{P(c_{j}|h_{i})P(T|h_{i})P(h_{i})}}\n \n\nwhere \n \n \n \n y\n \n \n {\\displaystyle y}\n \n is the predicted class, \n \n \n \n C\n \n \n {\\displaystyle C}\n \n is the set of all possible classes, \n \n \n \n H\n \n \n {\\displaystyle H}\n \n is the hypothesis space, \n \n \n \n P\n \n \n {\\displaystyle P}\n \n refers to a probability, and \n \n \n \n T\n \n \n {\\displaystyle T}\n \n is the training data. As an ensemble, the Bayes optimal classifier represents a hypothesis that is not necessarily in \n \n \n \n H\n \n \n {\\displaystyle H}\n \n. The hypothesis represented by the Bayes optimal classifier, however, is the optimal hypothesis in ensemble space (the space of all possible ensembles consisting only of hypotheses in \n \n \n \n H\n \n \n {\\displaystyle H}\n \n).\nThis formula can be restated using Bayes' theorem, which says that the posterior is proportional to the likelihood times the prior:\n\n \n \n \n P\n (\n \n h\n \n i\n \n \n \n |\n \n T\n )\n ∝\n P\n (\n T\n \n |\n \n \n h\n \n i\n \n \n )\n P\n (\n \n h\n \n i\n \n \n )\n \n \n {\\displaystyle P(h_{i}|T)\\propto P(T|h_{i})P(h_{i})}\n \n\nhence,\n\n \n \n \n y\n =\n \n \n \n a\n r\n g\n m\n a\n x\n \n \n \n c\n \n j\n \n \n ∈\n C\n \n \n \n \n ∑\n \n \n h\n \n i\n \n \n ∈\n H\n \n \n \n P\n (\n \n c\n \n j\n \n \n \n |\n \n \n h\n \n i\n \n \n )\n P\n (\n \n h\n \n i\n \n \n \n |\n \n T\n )\n \n \n \n {\\displaystyle y={\\underset {c_{j}\\in C}{\\mathrm {argmax} }}\\sum _{h_{i}\\in H}{P(c_{j}|h_{i})P(h_{i}|T)}}\n \n\n\nBootstrap aggregating (bagging)\nBootstrap aggregation (bagging) involves training an ensemble on bootstrapped data sets. A bootstrapped set is created by selecting from original training data set with replacement. Thus, a bootstrap set may contain a given example zero, one, or multiple times. Ensemble members can also have limits on the features (e.g., nodes of a decision tree), to encourage exploring of diverse features. The variance of local information in the bootstrap sets and feature considerations promote diversity in the ensemble, and can strengthen the ensemble. To reduce overfitting, a member can be validated using the out-of-bag set (the examples that are not in its bootstrap set).\nInference is done by voting of predictions of ensemble members, called aggregation. It is illustrated below with an ensemble of four decision trees. The query example is classified by each tree. Because three of the four predict the positive class, the ensemble's overall classification is positive. Random forests like the one shown are a common application of bagging.\n\n\nBoosting\n\nBoosting involves training successive models by emphasizing training data mis-classified by previously learned models. Initially, all data (D1) has equal weight and is used to learn a base model M1. The examples mis-classified by M1 are assigned a weight greater than correctly classified examples. This boosted data (D2) is used to train a second base model M2, and so on. Inference is done by voting.\nIn some cases, boosting has yielded better accuracy than bagging, but tends to over-fit more. The most common implementation of boosting is Adaboost, but some newer algorithms are reported to achieve better results.\n\n\nBayesian model averaging\nBayesian model averaging (BMA) makes predictions by averaging the predictions of models weighted by their posterior probabilities given the data. BMA is known to generally give better answers than a single model, obtained, e.g., via stepwise regression, especially where very different models have nearly identical performance in the training set but may otherwise perform quite differently.\nThe question with any use of Bayes' theorem is the prior, i.e., the probability (perhaps subjective) that each model is the best to use for a given purpose. Conceptually, BMA can be used with any prior. R packages ensembleBMA and BMA use the prior implied by the Bayesian information criterion, (BIC), following Raftery (1995). R package BAS supports the use of the priors implied by Akaike information criterion (AIC) and other criteria over the alternative models as well as priors over the coefficients.\nThe difference between BIC and AIC is the strength of preference for parsimony. BIC's penalty for model complexity is \n \n \n \n ln\n ⁡\n (\n n\n )\n k\n \n \n {\\displaystyle \\ln(n)k}\n \n , while AIC's is \n \n \n \n 2\n k\n \n \n {\\displaystyle 2k}\n \n. Large-sample asymptotic theory establishes that if there is a best model, then with increasing sample sizes, BIC is strongly consistent, i.e., will almost certainly find it, while AIC may not, because AIC may continue to place excessive posterior probability on models that are more complicated than they need to be. On the other hand, AIC and AICc are asymptotically \"efficient\" (i.e., minimum mean square prediction error), while BIC is not .\nHaussler et al. (1994) showed that when BMA is used for classification, its expected error is at most twice the expected error of the Bayes optimal classifier. Burnham and Anderson (1998, 2002) contributed greatly to introducing a wider audience to the basic ideas of Bayesian model averaging and popularizing the methodology. The availability of software, including other free open-source packages for R beyond those mentioned above, helped make the methods accessible to a wider audience.\n\n\nBayesian model combination\nBayesian model combination (BMC) is an algorithmic correction to Bayesian model averaging (BMA). Instead of sampling each model in the ensemble individually, it samples from the space of possible ensembles (with model weights drawn randomly from a Dirichlet distribution having uniform parameters). This modification overcomes the tendency of BMA to converge toward giving all the weight to a single model. Although BMC is somewhat more computationally expensive than BMA, it tends to yield dramatically better results. BMC has been shown to be better on average (with statistical significance) than BMA and bagging.\nUse of Bayes' law to compute model weights requires computing the probability of the data given each model. Typically, none of the models in the ensemble are exactly the distribution from which the training data were generated, so all of them correctly receive a value close to zero for this term. This would work well if the ensemble were big enough to sample the entire model-space, but this is rarely possible. Consequently, each pattern in the training data will cause the ensemble weight to shift toward the model in the ensemble that is closest to the distribution of the training data. It essentially reduces to an unnecessarily complex method for doing model selection.\nThe possible weightings for an ensemble can be visualized as lying on a simplex. At each vertex of the simplex, all of the weight is given to a single model in the ensemble. BMA converges toward the vertex that is closest to the distribution of the training data. By contrast, BMC converges toward the point where this distribution projects onto the simplex. In other words, instead of selecting the one model that is closest to the generating distribution, it seeks the combination of models that is closest to the generating distribution.\nThe results from BMA can often be approximated by using cross-validation to select the best model from a bucket of models. Likewise, the results from BMC may be approximated by using cross-validation to select the best ensemble combination from a random sampling of possible weightings.\n\n\nBucket of models\nA \"bucket of models\" is an ensemble technique in which a model selection algorithm is used to choose the best model for each problem. When tested with only one problem, a bucket of models can produce no better results than the best model in the set, but when evaluated across many problems, it will typically produce much better results, on average, than any model in the set.\nThe most common approach used for model-selection is cross-validation selection (sometimes called a \"bake-off contest\"). It is described with the following pseudo-code:\n\nFor each model m in the bucket:\n Do c times: (where 'c' is some constant)\n Randomly divide the training dataset into two sets: A and B\n Train m with A\n Test m with B\nSelect the model that obtains the highest average score\n\nCross-Validation Selection can be summed up as: \"try them all with the training set, and pick the one that works best\".\nGating is a generalization of Cross-Validation Selection. It involves training another learning model to decide which of the models in the bucket is best-suited to solve the problem. Often, a perceptron is used for the gating model. It can be used to pick the \"best\" model, or it can be used to give a linear weight to the predictions from each model in the bucket.\nWhen a bucket of models is used with a large set of problems, it may be desirable to avoid training some of the models that take a long time to train. Landmark learning is a meta-learning approach that seeks to solve this problem. It involves training only the fast (but imprecise) algorithms in the bucket, and then using the performance of these algorithms to help determine which slow (but accurate) algorithm is most likely to do best.\n\n\nAmended Cross-Entropy Cost: An Approach for Encouraging Diversity in Classification Ensemble\nThe most common approach for training classifier is using Cross-entropy cost function. However, one would like to train an ensemble of models that have diversity so when we combine them it would provide best results.\nAssuming we use a simple ensemble of averaging \n \n \n \n K\n \n \n {\\displaystyle K}\n \n classifiers. Then the Amended Cross-Entropy Cost is\n\n \n \n \n \n e\n \n k\n \n \n =\n H\n (\n p\n ,\n \n q\n \n k\n \n \n )\n −\n \n \n λ\n K\n \n \n \n ∑\n \n j\n ≠\n k\n \n \n H\n (\n \n q\n \n j\n \n \n ,\n \n q\n \n k\n \n \n )\n \n \n {\\displaystyle e^{k}=H(p,q^{k})-{\\frac {\\lambda }{K}}\\sum _{j\\neq k}H(q^{j},q^{k})}\n \n\nwhere \n \n \n \n \n e\n \n k\n \n \n \n \n {\\displaystyle e^{k}}\n \n is the cost function of the \n \n \n \n \n k\n \n t\n h\n \n \n \n \n {\\displaystyle k^{th}}\n \n classifier, \n \n \n \n \n q\n \n k\n \n \n \n \n {\\displaystyle q^{k}}\n \n is the probability of the \n \n \n \n \n k\n \n t\n h\n \n \n \n \n {\\displaystyle k^{th}}\n \n classifier, \n \n \n \n p\n \n \n {\\displaystyle p}\n \n is the true probability that we need to estimate and \n \n \n \n λ\n \n \n {\\displaystyle \\lambda }\n \n is a parameter between 0 and 1 that define the diversity that we would like to establish. When \n \n \n \n λ\n =\n 0\n \n \n {\\displaystyle \\lambda =0}\n \n we want each classifier to do its best regardless of the ensemble and when \n \n \n \n λ\n =\n 1\n \n \n {\\displaystyle \\lambda =1}\n \n we would like the classifier to be as diverse as possible.\n\n\nStacking\nStacking (sometimes called stacked generalization) involves training a model to combine the predictions of several other learning algorithms. First, all of the other algorithms are trained using the available data, then a combiner algorithm (final estimator) is trained to make a final prediction using all the predictions of the other algorithms (base estimators) as additional inputs or using cross-validated predictions from the base estimators which can prevent overfitting. If an arbitrary combiner algorithm is used, then stacking can theoretically represent any of the ensemble techniques described in this article, although, in practice, a logistic regression model is often used as the combiner.\nStacking typically yields performance better than any single one of the trained models. It has been successfully used on both supervised learning tasks (regression, classification and distance learning ) and unsupervised learning (density estimation). It has also been used to estimate bagging's error rate. It has been reported to out-perform Bayesian model-averaging. The two top-performers in the Netflix competition utilized blending, which may be considered a form of stacking.\nBayesian predictive stacking generalizes the idea of stacking from the statistical estimation literature to the combination of posterior predictive distributions. These ideas have also been developed and investigated for Gaussian process models, especially for spatial data analysis and can be used to construct transfer learning frameworks for massive spatial data sets.\n\n\nVoting\nVoting is another form of ensembling. See e.g. Weighted majority algorithm (machine learning).\n\n\nImplementations in statistics packages\nR: Several packages offer Bayesian model averaging tools, including the BMS (an acronym for Bayesian Model Selection) package, the BAS (an acronym for Bayesian Adaptive Sampling) package, and the BMA package. Other packages implementing predictive stacking for Gaussian process models include the spStack package.\nPython: scikit-learn, a package for machine learning in Python offers packages for ensemble learning including packages for bagging, voting and averaging methods.\nMATLAB: classification ensembles are implemented in Statistics and Machine Learning Toolbox.\n\n\nEnsemble learning applications\nIn recent years, due to growing computational power, which allows for training in large ensemble learning in a reasonable time frame, the number of ensemble learning applications has grown increasingly. Some of the applications of ensemble classifiers include:\n\n\nRemote sensing\n\n\nLand cover mapping\nLand cover mapping is one of the major applications of Earth observation satellite sensors, using remote sensing and geospatial data, to identify the materials and objects which are located on the surface of target areas. Generally, the classes of target materials include roads, buildings, rivers, lakes, and vegetation. Some different ensemble learning approaches based on artificial neural networks, kernel principal component analysis (KPCA), decision trees with boosting, random forest and automatic design of multiple classifier systems, are proposed to efficiently identify land cover objects.\n\n\nChange detection\nChange detection is an image analysis problem, consisting of the identification of places where the land cover has changed over time. Change detection is widely used in fields such as urban growth, forest and vegetation dynamics, land use and disaster monitoring.\nThe earliest applications of ensemble classifiers in change detection are designed with the majority voting, Bayesian model averaging, and the maximum posterior probability. Given the growth of satellite data over time, the past decade sees more use of time series methods for continuous change detection from image stacks. One example is a Bayesian ensemble changepoint detection method called BEAST, with the software available as a package Rbeast in R, Python, and Matlab.\n\n\nComputer security\n\n\nDistributed denial of service\nDistributed denial of service is one of the most threatening cyber-attacks that may happen to an internet service provider. By combining the output of single classifiers, ensemble classifiers reduce the total error of detecting and discriminating such attacks from legitimate flash crowds.\n\n\nMalware Detection\nClassification of malware codes such as computer viruses, computer worms, trojans, ransomware and spywares with the usage of machine learning techniques, is inspired by the document categorization problem. Ensemble learning systems have shown a proper efficacy in this area.\nModel Hardening\nMalware detection models, like all machine learning models, are vulnerable to adversarial machine learning attacks where an attacker pushes the boundary of what is classified as malware. By rotating through an ensemble of models using moving target defense, the attacker has a diminished knowledge advantage.\n\n\nIntrusion detection\nAn intrusion detection system monitors computer network or computer systems to identify intruder codes like an anomaly detection process. Ensemble learning successfully aids such monitoring systems to reduce their total error.\n\n\nFace recognition\n\nFace recognition, which recently has become one of the most popular research areas of pattern recognition, copes with identification or verification of a person by their digital images.\nHierarchical ensembles based on Gabor Fisher classifier and independent component analysis preprocessing techniques are some of the earliest ensembles employed in this field.\n\n\nEmotion recognition\n\nWhile speech recognition is mainly based on deep learning because most of the industry players in this field like Google, Microsoft and IBM reveal that the core technology of their speech recognition is based on this approach, speech-based emotion recognition can also have a satisfactory performance with ensemble learning. It is also being successfully used in facial emotion recognition.\n\n\nFraud detection\n\nFraud detection deals with the identification of bank fraud, such as money laundering, credit card fraud and telecommunication fraud, which have vast domains of research and applications of machine learning. Because ensemble learning improves the robustness of the normal behavior modelling, it has been proposed as an efficient technique to detect such fraudulent cases and activities in banking and credit card systems.\n\n\nFinancial decision-making\nEnsemble learning methods have been widely adopted in finance for tasks such as credit scoring, bankruptcy prediction, and risk management. By combining multiple base models, ensembles can exploit nonlinear relationships, handle high-dimensional and noisy data, and often deliver more stable out-of-sample performance than single models or traditional statistical baselines such as logistic regression and linear factor models. This approach aligns with the broader trend in financial machine learning described by Marcos López de Prado, who argues that combining diverse learners can improve robustness, mitigate overfitting, and extract persistent patterns from noisy financial time series.\nIn retail and corporate credit scoring, ensemble classifiers such as random forests, gradient boosting machines and stacked models are frequently used to assess default risk. A recent systematic literature review of machine-learning credit-scoring studies published between 2018 and 2024 reports that tree-based ensembles and boosting methods are among the most commonly applied techniques and typically achieve higher predictive accuracy than traditional scorecards or single classifiers.\nEnsemble methods have also been applied to corporate failure and bankruptcy prediction. Studies comparing different ensemble constructions (such as bagging, boosting and heterogeneous classifier pools) report that well-tuned ensembles tend to achieve higher classification accuracy and more robust performance across industries than individual models. The accuracy of prediction of business failure is a very crucial issue in financial decision-making. Therefore, different ensemble classifiers are proposed to predict financial crises and financial distress. Also, in the trade-based manipulation problem, where traders attempt to manipulate stock prices by buying and selling activities, ensemble classifiers are required to analyze the changes in the stock market data and detect suspicious symptom of stock price manipulation.\nImplementation of ensemble learning not only with machine learning models but also with mathematical frameworks such as hidden Markov models for applications in trading, regime detection, and asset pricing remains a rapidly developing area of research.\n\n\nMedicine\nEnsemble classifiers have been successfully applied in neuroscience, proteomics and medical diagnosis like in neuro-cognitive disorder (i.e. Alzheimer or myotonic dystrophy) detection based on MRI datasets, cervical cytology classification.\nBesides, ensembles have been successfully applied in medical segmentation tasks, for example brain tumor and hyperintensities segmentation.\n\n\nSee also\nEnsemble averaging (machine learning)\nBayesian structural time series (BSTS)\nMixture of experts\n\n\nReferences\n\n\nFurther reading\nZhou Zhihua (2012). Ensemble Methods: Foundations and Algorithms. Chapman and Hall/CRC. ISBN 978-1-439-83003-1.\nRobert Schapire; Yoav Freund (2012). Boosting: Foundations and Algorithms. MIT. ISBN 978-0-262-01718-3.\n\n\nExternal links\nRobi Polikar (ed.). \"Ensemble learning\". Scholarpedia.\nThe Waffles (machine learning) toolkit contains implementations of Bagging, Boosting, Bayesian Model Averaging, Bayesian Model Combination, Bucket-of-models, and other ensemble techniques", "categories": ["All articles with unsourced statements", "Articles with short description", "Articles with unsourced statements from January 2012", "CS1 maint: DOI inactive as of July 2025", "Ensemble learning", "Short description is different from Wikidata"], "references": ["http://citeseerx.ist.psu.edu/viewdoc/summary?doi=10.1.1.108.6096", "https://doi.org/10.3390%2Fe23020200", "https://doi.org/10.1029%2F2020WR027184", "https://doi.org/10.1007%2FBF00058655", "https://link.springer.com/content/pdf/10.1023/A:1022859003006.pdf", "https://proceedings.neurips.cc/paper/1995/file/1019c8091693ef5c5f55970346633f92-Paper.pdf", "http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.421.349&rep=rep1&type=pdf", "https://www.jmlr.org/papers/volume4/clarke03a/clarke03a.pdf", "https://proceedings.mlr.press/v162/morishita22a.html", "https://doi.org/10.1007%2FS10994-023-06406-W", "https://doi.org/10.1613%2Fjair.614", "https://doi.org/10.1109%2FMCAS.2006.1688199", "https://doi.org/10.1007%2Fs10462-009-9124-7", "https://doi.org/10.1007%2F978-0-387-30164-8_373", "https://doi.org/10.19153%2Fcleiej.8.2.1"], "images": ["File:Bootstrap set generation.png", "File:Ensemble Aggregation.png"], "sub_niche": "Adversarial machine learning"} {"title": "Outline of machine learning", "url": "https://en.wikipedia.org/wiki/Outline_of_machine_learning", "summary": "The following outline is provided as an overview of, and topical guide to, machine learning:\nMachine learning (ML) is a subfield of artificial intelligence within computer science that evolved from the study of pattern recognition and computational learning theory. In 1959, Arthur Samuel defined machine learning as a \"field of study that gives computers the ability to learn without being explicitly programmed\". ML involves the study and construction of algorithms that can learn from and make predictions on data. These algorithms operate by building a model from a training set of example observations to make data-driven predictions or decisions expressed as outputs, rather than following strictly static program instructions.", "content": "The following outline is provided as an overview of, and topical guide to, machine learning:\nMachine learning (ML) is a subfield of artificial intelligence within computer science that evolved from the study of pattern recognition and computational learning theory. In 1959, Arthur Samuel defined machine learning as a \"field of study that gives computers the ability to learn without being explicitly programmed\". ML involves the study and construction of algorithms that can learn from and make predictions on data. These algorithms operate by building a model from a training set of example observations to make data-driven predictions or decisions expressed as outputs, rather than following strictly static program instructions.\n\n\nHow can machine learning be categorized?\nAn academic discipline\nA branch of science\nAn applied science\nA subfield of computer science\nA branch of artificial intelligence\nA subfield of soft computing\nApplication of statistics\n\n\nParadigms of machine learning\nSupervised learning, where the model is trained on labeled data\nUnsupervised learning, where the model tries to identify patterns in unlabeled data\nReinforcement learning, where the model learns to make decisions by receiving rewards or penalties.\n\n\nApplications of machine learning\nApplications of machine learning\nBioinformatics\nBiomedical informatics\nComputer vision\nCustomer relationship management\nData mining\nEarth sciences\nEmail filtering\nInverted pendulum (balance and equilibrium system)\nNatural language processing\nNamed Entity Recognition\nAutomatic summarization\nAutomatic taxonomy construction\nDialog system\nGrammar checker\nLanguage recognition\nHandwriting recognition\nOptical character recognition\nSpeech recognition\nText to Speech Synthesis\nSpeech Emotion Recognition\nMachine translation\nQuestion answering\nSpeech synthesis\nText mining\nTerm frequency–inverse document frequency\nText simplification\nPattern recognition\nFacial recognition system\nHandwriting recognition\nImage recognition\nOptical character recognition\nSpeech recognition\nRecommendation system\nCollaborative filtering\nContent-based filtering\nHybrid recommender systems\nSearch engine\nSearch engine optimization\nSocial engineering\n\n\nMachine learning hardware\nGraphics processing unit\nTensor processing unit\nVision processing unit\n\n\nMachine learning tools\nComparison of machine learning software\nComparison of deep learning software\n\n\nMachine learning frameworks\n\n\nProprietary machine learning frameworks\nAmazon Machine Learning\nMicrosoft Azure Machine Learning Studio\nDistBelief (replaced by TensorFlow)\n\n\nOpen source machine learning frameworks\nApache Singa\nApache MXNet\nCaffe\nPyTorch\nmlpack\nTensorFlow\nTorch\nCNTK\nAccord.Net\nJax\nMLJ.jl – A machine learning framework for Julia\n\n\nMachine learning libraries\nDeeplearning4j\nTheano\nscikit-learn\nKeras\n\n\nMachine learning algorithms\n\n\nMachine learning methods\n\n\nInstance-based algorithm\nK-nearest neighbors algorithm (KNN)\nLearning vector quantization (LVQ)\nSelf-organizing map (SOM)\n\n\nRegression analysis\nLogistic regression\nOrdinary least squares regression (OLSR)\nLinear regression\nStepwise regression\nMultivariate adaptive regression splines (MARS)\nRegularization algorithm\nRidge regression\nLeast Absolute Shrinkage and Selection Operator (LASSO)\nElastic net\nLeast-angle regression (LARS)\nClassifiers\nProbabilistic classifier\nNaive Bayes classifier\nBinary classifier\nLinear classifier\nHierarchical classifier\n\n\nDimensionality reduction\nDimensionality reduction\n\nCanonical correlation analysis (CCA)\nFactor analysis\nFeature extraction\nFeature selection\nIndependent component analysis (ICA)\nLinear discriminant analysis (LDA)\nMultidimensional scaling (MDS)\nNon-negative matrix factorization (NMF)\nPartial least squares regression (PLSR)\nPrincipal component analysis (PCA)\nPrincipal component regression (PCR)\nProjection pursuit\nSammon mapping\nt-distributed stochastic neighbor embedding (t-SNE)\n\n\nEnsemble learning\nEnsemble learning\n\nAdaBoost\nBoosting\nBootstrap aggregating (also \"bagging\" or \"bootstrapping\")\nEnsemble averaging\nGradient boosted decision tree (GBDT)\nGradient boosting\nRandom Forest\nStacked Generalization\n\n\nMeta-learning\nMeta-learning\n\nInductive bias\nMetadata\n\n\nReinforcement learning\nReinforcement learning\n\nQ-learning\nState–action–reward–state–action (SARSA)\nTemporal difference learning (TD)\nLearning Automata\n\n\nSupervised learning\nSupervised learning\n\nAveraged one-dependence estimators (AODE)\nArtificial neural network\nCase-based reasoning\nGaussian process regression\nGene expression programming\nGroup method of data handling (GMDH)\nInductive logic programming\nInstance-based learning\nLazy learning\nLearning Automata\nLearning Vector Quantization\nLogistic Model Tree\nMinimum message length (decision trees, decision graphs, etc.)\nNearest Neighbor Algorithm\nAnalogical modeling\nProbably approximately correct learning (PAC) learning\nRipple down rules, a knowledge acquisition methodology\nSymbolic machine learning algorithms\nSupport vector machines\nRandom Forests\nEnsembles of classifiers\nBootstrap aggregating (bagging)\nBoosting (meta-algorithm)\nOrdinal classification\nConditional Random Field\nANOVA\nQuadratic classifiers\nk-nearest neighbor\nBoosting\nSPRINT\nBayesian networks\nNaive Bayes\nHidden Markov models\nHierarchical hidden Markov model\n\n\nBayesian\nBayesian statistics\n\nBayesian knowledge base\nNaive Bayes\nGaussian Naive Bayes\nMultinomial Naive Bayes\nAveraged One-Dependence Estimators (AODE)\nBayesian Belief Network (BBN)\nBayesian Network (BN)\n\n\nDecision tree algorithms\nDecision tree algorithm\n\nDecision tree\nClassification and regression tree (CART)\nIterative Dichotomiser 3 (ID3)\nC4.5 algorithm\nC5.0 algorithm\nChi-squared Automatic Interaction Detection (CHAID)\nDecision stump\nConditional decision tree\nID3 algorithm\nRandom forest\nSLIQ\n\n\nLinear classifier\nLinear classifier\n\nFisher's linear discriminant\nLinear regression\nLogistic regression\nMultinomial logistic regression\nNaive Bayes classifier\nPerceptron\nSupport vector machine\n\n\nUnsupervised learning\nUnsupervised learning\n\nExpectation-maximization algorithm\nVector Quantization\nGenerative topographic map\nInformation bottleneck method\nAssociation rule learning algorithms\nApriori algorithm\nEclat algorithm\n\n\nArtificial neural networks\nArtificial neural network\n\nFeedforward neural network\nExtreme learning machine\nConvolutional neural network\nRecurrent neural network\nLong short-term memory (LSTM)\nLogic learning machine\nSelf-organizing map\n\n\nAssociation rule learning\nAssociation rule learning\n\nApriori algorithm\nEclat algorithm\nFP-growth algorithm\n\n\nHierarchical clustering\nHierarchical clustering\n\nSingle-linkage clustering\nConceptual clustering\n\n\nCluster analysis\nCluster analysis\n\nBIRCH\nDBSCAN\nExpectation–maximization (EM)\nFuzzy clustering\nHierarchical clustering\nk-means clustering\nk-medians\nMean-shift\nOPTICS algorithm\n\n\nAnomaly detection\nAnomaly detection\n\nk-nearest neighbors algorithm (k-NN)\nLocal outlier factor\n\n\nSemi-supervised learning\nSemi-supervised learning\n\nActive learning\nGenerative models\nLow-density separation\nGraph-based methods\nCo-training\nTransduction\n\n\nDeep learning\nDeep learning\n\nDeep belief networks\nDeep Boltzmann machines\nDeep Convolutional neural networks\nDeep Recurrent neural networks\nHierarchical temporal memory\nGenerative Adversarial Network\nStyle transfer\nTransformer\nStacked Auto-Encoders\n\n\nOther machine learning methods and problems\nAnomaly detection\nAssociation rules\nBias-variance dilemma\nClassification\nMulti-label classification\nClustering\nData Pre-processing\nEmpirical risk minimization\nFeature engineering\nFeature learning\nLearning to rank\nOccam learning\nOnline machine learning\nPAC learning\nRegression\nReinforcement Learning\nSemi-supervised learning\nStatistical learning\nStructured prediction\nGraphical models\nBayesian network\nConditional random field (CRF)\nHidden Markov model (HMM)\nUnsupervised learning\nVC theory\n\n\nMachine learning research\nList of artificial intelligence projects\nList of datasets for machine learning research\n\n\nHistory of machine learning\nHistory of machine learning\n\nTimeline of machine learning\n\n\nMachine learning projects\nMachine learning projects:\n\nDeepMind\nGoogle Brain\nOpenAI\nMeta AI\nHugging Face\n\n\nMachine learning organizations\n\n\nMachine learning conferences and workshops\nArtificial Intelligence and Security (AISec) (co-located workshop with CCS)\nConference on Neural Information Processing Systems (NIPS)\nECML PKDD\nInternational Conference on Machine Learning (ICML)\nML4ALL (Machine Learning For All)\n\n\nMachine learning publications\n\n\nBooks on machine learning\nMathematics for Machine Learning\nHands-On Machine Learning Scikit-Learn, Keras, and TensorFlow\nThe Hundred-Page Machine Learning Book\n\n\nMachine learning journals\nMachine Learning\nJournal of Machine Learning Research (JMLR)\nNeural Computation\n\n\nPersons influential in machine learning\nAlberto Broggi\nAndrei Knyazev\nAndrew McCallum\nAndrew Ng\nAnuraag Jain\nArmin B. Cremers\nAyanna Howard\nBarney Pell\nBen Goertzel\nBen Taskar\nBernhard Schölkopf\nBrian D. Ripley\nChristopher G. Atkeson\nCorinna Cortes\nDemis Hassabis\nDouglas Lenat\nEric Xing\nErnst Dickmanns\nGeoffrey Hinton\nHans-Peter Kriegel\nHartmut Neven\nHeikki Mannila\nIan Goodfellow\nJacek M. Zurada\nJaime Carbonell\nJeremy Slovak\nJerome H. Friedman\nJohn D. Lafferty\nJohn Platt\nJulie Beth Lovins\nJürgen Schmidhuber\nKarl Steinbuch\nKatia Sycara\nLeo Breiman\nLise Getoor\nLuca Maria Gambardella\nLéon Bottou\nMarcus Hutter\nMehryar Mohri\nMichael Collins\nMichael I. Jordan\nMichael L. Littman\nNando de Freitas\nOfer Dekel\nOren Etzioni\nPedro Domingos\nPeter Flach\nPierre Baldi\nPushmeet Kohli\nRay Kurzweil\nRayid Ghani\nRoss Quinlan\nSalvatore J. Stolfo\nSebastian Thrun\nSelmer Bringsjord\nSepp Hochreiter\nShane Legg\nStephen Muggleton\nSteve Omohundro\nTom M. Mitchell\nTrevor Hastie\nVasant Honavar\nVladimir Vapnik\nYann LeCun\nYasuo Matsuyama\nYoshua Bengio\nZoubin Ghahramani\n\n\nSee also\nOutline of artificial intelligence\nOutline of computer vision\nOutline of deep learning\nOutline of robotics\nAccuracy paradox\nAction model learning\nActivation function\nActivity recognition\nADALINE\nAdaptive neuro fuzzy inference system\nAdaptive resonance theory\nAdditive smoothing\nAdjusted mutual information\nAIVA\nAIXI\nAlchemyAPI\nAlexNet\nAlgorithm selection\nAlgorithmic inference\nAlgorithmic learning theory\nAlphaGo\nAlphaGo Zero\nAlternating decision tree\nApprenticeship learning\nCausal Markov condition\nCompetitive learning\nConcept learning\nDecision tree learning\nDifferentiable programming\nDistribution learning theory\nEager learning\nEnd-to-end reinforcement learning\nError tolerance (PAC learning)\nExplanation-based learning\nFeature\nGloVe\nHyperparameter\nInferential theory of learning\nLearning automata\nLearning classifier system\nLearning rule\nLearning with errors\nM-Theory (learning framework)\nMachine learning control\nMachine learning in bioinformatics\nMargin\nMarkov chain geostatistics\nMarkov chain Monte Carlo (MCMC)\nMarkov information source\nMarkov logic network\nMarkov model\nMarkov random field\nMarkovian discrimination\nMaximum-entropy Markov model\nMulti-armed bandit\nMulti-task learning\nMultilinear subspace learning\nMultimodal learning\nMultiple instance learning\nMultiple-instance learning\nNever-Ending Language Learning\nOffline learning\nParity learning\nPopulation-based incremental learning\nPredictive learning\nPreference learning\nProactive learning\nProximal gradient methods for learning\nSemantic analysis\nSimilarity learning\nSparse dictionary learning\nStability (learning theory)\nStatistical learning theory\nStatistical relational learning\nTanagra\nTransfer learning\nVariable-order Markov model\nVersion space learning\nWaffles\nWeka\nLoss function\nLoss functions for classification\nMean squared error (MSE)\nMean squared prediction error (MSPE)\nTaguchi loss function\nLow-energy adaptive clustering hierarchy\n\n\nOther\nAnne O'Tate\nAnt colony optimization algorithms\nAnthony Levandowski\nAnti-unification (computer science)\nApache Flume\nApache Giraph\nApache Mahout\nApache SINGA\nApache Spark\nApache SystemML\nAphelion (software)\nArabic Speech Corpus\nArchetypal analysis\nArthur Zimek\nArtificial ants\nArtificial bee colony algorithm\nArtificial development\nArtificial immune system\nAstrostatistics\nAveraged one-dependence estimators\nBag-of-words model\nBalanced clustering\nBall tree\nBase rate\nBat algorithm\nBaum–Welch algorithm\nBayesian hierarchical modeling\nBayesian interpretation of kernel regularization\nBayesian optimization\nBayesian structural time series\nBees algorithm\nBehavioral clustering\nBernoulli scheme\nBias–variance tradeoff\nBiclustering\nBigML\nBinary classification\nBing Predicts\nBio-inspired computing\nBiogeography-based optimization\nBiplot\nBondy's theorem\nBongard problem\nBradley–Terry model\nBrownBoost\nBrown clustering\nBurst error\nCBCL (MIT)\nCIML community portal\nCMA-ES\nCURE data clustering algorithm\nCache language model\nCalibration (statistics)\nCanonical correspondence analysis\nCanopy clustering algorithm\nCascading classifiers\nCategory utility\nCellCognition\nCellular evolutionary algorithm\nChi-square automatic interaction detection\nChromosome (genetic algorithm)\nClassifier chains\nCleverbot\nClonal selection algorithm\nCluster-weighted modeling\nClustering high-dimensional data\nClustering illusion\nCoBoosting\nCobweb (clustering)\nCognitive computer\nCognitive robotics\nCollostructional analysis\nCommon-method variance\nComplete-linkage clustering\nComputer-automated design\nConcept class\nConcept drift\nConference on Artificial General Intelligence\nConference on Knowledge Discovery and Data Mining\nConfirmatory factor analysis\nConfusion matrix\nCongruence coefficient\nConnect (computer system)\nConsensus clustering\nConstrained clustering\nConstrained conditional model\nConstructive cooperative coevolution\nCorrelation clustering\nCorrespondence analysis\nCoupled pattern learner\nCross-entropy method\nCross-validation (statistics)\nCrossover (genetic algorithm)\nCuckoo search\nCultural algorithm\nCultural consensus theory\nCurse of dimensionality\nDADiSP\nDARPA LAGR Program\nDarkforest\nDartmouth workshop\nDarwinTunes\nData Mining Extensions\nData exploration\nData pre-processing\nData stream clustering\nDataiku\nDavies–Bouldin index\nDecision boundary\nDecision list\nDecision tree model\nDeductive classifier\nDeepArt\nDeepDream\nDeep Web Technologies\nDefining length\nDendrogram\nDependability state model\nDetailed balance\nDetermining the number of clusters in a data set\nDetrended correspondence analysis\nDevelopmental robotics\nDiffbot\nDifferential evolution\nDiscrete phase-type distribution\nDiscriminative model\nDissociated press\nDistributed R\nDlib\nDocument classification\nDocumenting Hate\nDomain adaptation\nDoubly stochastic model\nDual-phase evolution\nDunn index\nDynamic Bayesian network\nDynamic Markov compression\nDynamic topic model\nDynamic unobserved effects model\nEDLUT\nELKI\nEdge recombination operator\nEffective fitness\nElastic map\nElastic matching\nElbow method (clustering)\nEmergent (software)\nEncog\nEntropy rate\nErkki Oja\nEurisko\nEuropean Conference on Artificial Intelligence\nEvaluation of binary classifiers\nEvolution strategy\nEvolution window\nEvolutionary Algorithm for Landmark Detection\nEvolutionary algorithm\nEvolutionary art\nEvolutionary music\nEvolutionary programming\nEvolvability (computer science)\nEvolved antenna\nEvolver (software)\nEvolving classification function\nExpectation propagation\nExploratory factor analysis\nF1 score\nFLAME clustering\nFactor analysis of mixed data\nFactor graph\nFactor regression model\nFactored language model\nFarthest-first traversal\nFast-and-frugal trees\nFeature Selection Toolbox\nFeature hashing\nFeature scaling\nFeature vector\nFirefly algorithm\nFirst-difference estimator\nFirst-order inductive learner\nFish School Search\nFisher kernel\nFitness approximation\nFitness function\nFitness proportionate selection\nFluentd\nFolding@home\nFormal concept analysis\nForward algorithm\nFowlkes–Mallows index\nFrederick Jelinek\nFrrole\nFunctional principal component analysis\nGATTO\nGLIMMER\nGary Bryce Fogel\nGaussian adaptation\nGaussian process\nGaussian process emulator\nGene prediction\nGeneral Architecture for Text Engineering\nGeneralization error\nGeneralized canonical correlation\nGeneralized filtering\nGeneralized iterative scaling\nGeneralized multidimensional scaling\nGenerative adversarial network\nGenerative model\nGenetic algorithm\nGenetic algorithm scheduling\nGenetic algorithms in economics\nGenetic fuzzy systems\nGenetic memory (computer science)\nGenetic operator\nGenetic programming\nGenetic representation\nGeographical cluster\nGesture Description Language\nGeworkbench\nGlossary of artificial intelligence\nGlottochronology\nGolem (ILP)\nGoogle matrix\nGrafting (decision trees)\nGramian matrix\nGrammatical evolution\nGranular computing\nGraphLab\nGraph kernel\nGremlin (programming language)\nGrowth function\nHUMANT (HUManoid ANT) algorithm\nHammersley–Clifford theorem\nHarmony search\nHebbian theory\nHidden Markov random field\nHidden semi-Markov model\nHierarchical hidden Markov model\nHigher-order factor analysis\nHighway network\nHinge loss\nHolland's schema theorem\nHopkins statistic\nHoshen–Kopelman algorithm\nHuber loss\nIRCF360\nIan Goodfellow\nIlastik\nIlya Sutskever\nImmunocomputing\nImperialist competitive algorithm\nInauthentic text\nIncremental decision tree\nInduction of regular languages\nInductive bias\nInductive probability\nInductive programming\nInfluence diagram\nInformation Harvesting\nInformation gain in decision trees\nInformation gain ratio\nInheritance (genetic algorithm)\nInstance selection\nIntel RealSense\nInteracting particle system\nInteractive machine translation\nInternational Joint Conference on Artificial Intelligence\nInternational Meeting on Computational Intelligence Methods for Bioinformatics and Biostatistics\nInternational Semantic Web Conference\nIris flower data set\nIsland algorithm\nIsotropic position\nItem response theory\nIterative Viterbi decoding\nJOONE\nJabberwacky\nJaccard index\nJackknife variance estimates for random forest\nJava Grammatical Evolution\nJoseph Nechvatal\nJubatus\nJulia (programming language)\nJunction tree algorithm\nk-SVD\nk-means++\nk-medians clustering\nk-medoids\nKNIME\nKXEN Inc.\nk q-flats\nKaggle\nKalman filter\nKatz's back-off model\nKernel adaptive filter\nKernel density estimation\nKernel eigenvoice\nKernel embedding of distributions\nKernel method\nKernel perceptron\nKernel random forest\nKinect\nKlaus-Robert Müller\nKneser–Ney smoothing\nKnowledge Vault\nKnowledge integration\nLIBSVM\nLPBoost\nLabeled data\nLanguageWare\nLanguage identification in the limit\nLanguage model\nLarge margin nearest neighbor\nLatent Dirichlet allocation\nLatent class model\nLatent semantic analysis\nLatent variable\nLatent variable model\nLattice Miner\nLayered hidden Markov model\nLearnable function class\nLeast squares support vector machine\nLeslie P. Kaelbling\nLinear genetic programming\nLinear predictor function\nLinear separability\nLinkurious\nLior Ron (business executive)\nList of genetic algorithm applications\nList of metaphor-based metaheuristics\nList of text mining software\nLocal case-control sampling\nLocal independence\nLocal tangent space alignment\nLocality-sensitive hashing\nLog-linear model\nLogistic model tree\nLow-rank approximation\nLow-rank matrix approximations\nMATLAB\nMIMIC (immunology)\nMXNet\nMallet (software project)\nManifold regularization\nMargin-infused relaxed algorithm\nMargin classifier\nMark V. Shaney\nMassive Online Analysis\nMatrix regularization\nMatthews correlation coefficient\nMean shift\nMean squared error\nMean squared prediction error\nMeasurement invariance\nMedoid\nMeeMix\nMelomics\nMemetic algorithm\nMeta-optimization\nMexican International Conference on Artificial Intelligence\nMichael Kearns (computer scientist)\nMinHash\nMixture model\nMlpy\nModels of DNA evolution\nMoral graph\nMountain car problem\nMovidius\nMulti-armed bandit\nMulti-label classification\nMulti expression programming\nMulticlass classification\nMultidimensional analysis\nMultifactor dimensionality reduction\nMultilinear principal component analysis\nMultiple correspondence analysis\nMultiple discriminant analysis\nMultiple factor analysis\nMultiple sequence alignment\nMultiplicative weight update method\nMultispectral pattern recognition\nMutation (genetic algorithm)\nN-gram\nNOMINATE (scaling method)\nNative-language identification\nNatural Language Toolkit\nNatural evolution strategy\nNearest-neighbor chain algorithm\nNearest centroid classifier\nNearest neighbor search\nNeighbor joining\nNest Labs\nNetMiner\nNetOwl\nNeural Designer\nNeural Engineering Object\nNeural modeling fields\nNeural network software\nNeuroSolutions\nNeuroevolution\nNeuroph\nNiki.ai\nNoisy channel model\nNoisy text analytics\nNonlinear dimensionality reduction\nNovelty detection\nNuisance variable\nOne-class classification\nOnnx\nOpenNLP\nOptimal discriminant analysis\nOracle Data Mining\nOrange (software)\nOrdination (statistics)\nOverfitting\nPROGOL\nPSIPRED\nPachinko allocation\nPageRank\nParallel metaheuristic\nParity benchmark\nPart-of-speech tagging\nParticle swarm optimization\nPath dependence\nPattern language (formal languages)\nPeltarion Synapse\nPerplexity\nPersian Speech Corpus\nPietro Perona\nPipeline Pilot\nPiranha (software)\nPitman–Yor process\nPlate notation\nPolynomial kernel\nPop music automation\nPopulation process\nPortable Format for Analytics\nPredictive Model Markup Language\nPredictive state representation\nPreference regression\nPremature convergence\nPrincipal geodesic analysis\nPrior knowledge for pattern recognition\nPrisma (app)\nProbabilistic Action Cores\nProbabilistic context-free grammar\nProbabilistic latent semantic analysis\nProbabilistic soft logic\nProbability matching\nProbit model\nProduct of experts\nProgramming with Big Data in R\nProper generalized decomposition\nPruning (decision trees)\nPushpak Bhattacharyya\nQ methodology\nQloo\nQuality control and genetic algorithms\nQuantum Artificial Intelligence Lab\nQueueing theory\nQuick, Draw!\nR (programming language)\nRada Mihalcea\nRademacher complexity\nRadial basis function kernel\nRand index\nRandom indexing\nRandom projection\nRandom subspace method\nRanking SVM\nRapidMiner\nRattle GUI\nRaymond Cattell\nReasoning system\nRegularization perspectives on support vector machines\nRelational data mining\nRelationship square\nRelevance vector machine\nRelief (feature selection)\nRenjin\nRepertory grid\nRepresenter theorem\nReward-based selection\nRichard Zemel\nRight to explanation\nRoboEarth\nRobust principal component analysis\nRuleML Symposium\nRule induction\nRules extraction system family\nSAS (software)\nSNNS\nSPSS Modeler\nSUBCLU\nSample complexity\nSample exclusion dimension\nSanta Fe Trail problem\nSavi Technology\nSchema (genetic algorithms)\nSearch-based software engineering\nSelection (genetic algorithm)\nSelf-Service Semantic Suite\nSemantic folding\nSemantic mapping (statistics)\nSemidefinite embedding\nSense Networks\nSensorium Project\nSequence labeling\nSequential minimal optimization\nShattered set\nShogun (toolbox)\nSilhouette (clustering)\nSimHash\nSimRank\nSimilarity measure\nSimple matching coefficient\nSimultaneous localization and mapping\nSinkov statistic\nSliced inverse regression\nSnakes and Ladders\nSoft independent modelling of class analogies\nSoft output Viterbi algorithm\nSolomonoff's theory of inductive inference\nSolveIT Software\nSpectral clustering\nSpike-and-slab variable selection\nStatistical machine translation\nStatistical parsing\nStatistical semantics\nStefano Soatto\nStephen Wolfram\nStochastic block model\nStochastic cellular automaton\nStochastic diffusion search\nStochastic grammar\nStochastic matrix\nStochastic universal sampling\nStress majorization\nString kernel\nStructural equation modeling\nStructural risk minimization\nStructured sparsity regularization\nStructured support vector machine\nSubclass reachability\nSufficient dimension reduction\nSukhotin's algorithm\nSum of absolute differences\nSum of absolute transformed differences\nSwarm intelligence\nSwitching Kalman filter\nSymbolic regression\nSynchronous context-free grammar\nSyntactic pattern recognition\nTD-Gammon\nTIMIT\nTeaching dimension\nTeuvo Kohonen\nTextual case-based reasoning\nTheory of conjoint measurement\nThomas G. Dietterich\nThurstonian model\nTopic model\nTournament selection\nTraining, test, and validation sets\nTransiogram\nTrax Image Recognition\nTrigram tagger\nTruncation selection\nTucker decomposition\nUIMA\nUPGMA\nUgly duckling theorem\nUncertain data\nUniform convergence in probability\nUnique negative dimension\nUniversal portfolio algorithm\nUser behavior analytics\nVC dimension\nVIGRA\nValidation set\nVapnik–Chervonenkis theory\nVariable-order Bayesian network\nVariable kernel density estimation\nVariable rules analysis\nVariational message passing\nVarimax rotation\nVector quantization\nVicarious (company)\nViterbi algorithm\nVowpal Wabbit\nWACA clustering algorithm\nWPGMA\nWard's method\nWeasel program\nWhitening transformation\nWinnow (algorithm)\nWin–stay, lose–switch\nWitness set\nWolfram Language\nWolfram Mathematica\nWriter invariant\nXgboost\nYooreeka\nZeroth (software)\n\n\nFurther reading\nTrevor Hastie, Robert Tibshirani and Jerome H. Friedman (2001). The Elements of Statistical Learning, Springer. ISBN 0-387-95284-5.\nPedro Domingos (September 2015), The Master Algorithm, Basic Books, ISBN 978-0-465-06570-7\nMehryar Mohri, Afshin Rostamizadeh, Ameet Talwalkar (2012). Foundations of Machine Learning, The MIT Press. ISBN 978-0-262-01825-8.\nIan H. Witten and Eibe Frank (2011). Data Mining: Practical machine learning tools and techniques Morgan Kaufmann, 664pp., ISBN 978-0-12-374856-0.\nDavid J. C. MacKay. Information Theory, Inference, and Learning Algorithms Cambridge: Cambridge University Press, 2003. ISBN 0-521-64298-1\nRichard O. Duda, Peter E. Hart, David G. Stork (2001) Pattern classification (2nd edition), Wiley, New York, ISBN 0-471-05669-3.\nChristopher Bishop (1995). Neural Networks for Pattern Recognition, Oxford University Press. ISBN 0-19-853864-2.\nVladimir Vapnik (1998). Statistical Learning Theory. Wiley-Interscience, ISBN 0-471-03003-1.\nRay Solomonoff, An Inductive Inference Machine, IRE Convention Record, Section on Information Theory, Part 2, pp., 56–62, 1957.\nRay Solomonoff, \"An Inductive Inference Machine\" A privately circulated report from the 1956 Dartmouth Summer Research Conference on AI.\n\n\nReferences\n\n\nExternal links\n\nData Science: Data to Insights from MIT (machine learning)\nPopular online course by Andrew Ng, at Coursera. It uses GNU Octave. The course is a free version of Stanford University's actual course taught by Ng, see.stanford.edu/Course/CS229 available for free].\nmloss is an academic database of open-source machine learning software.", "categories": ["Articles with short description", "Computing-related lists", "Data mining", "Dynamic lists", "Machine learning", "Outlines", "Outlines of computing and engineering", "Pages using Sister project links with default search", "Short description is different from Wikidata"], "references": ["http://www.cs.nyu.edu/~mohri/mlbook/", "http://www.inference.phy.cam.ac.uk/mackay/itila/book.html", "http://world.std.com/~rjs/indinf56.pdf", "https://www.coursera.org/course/ml", "https://mloss.org/", "http://www.britannica.com/EBchecked/topic/1116194/machine-learning", "https://web.archive.org/web/20091110212529/http://www-stat.stanford.edu/~tibs/ElemStatLearn/", "http://ml4all.org/", "https://ai.stanford.edu/~ronnyk/glossary.html", "https://web.archive.org/web/20170118041300/https://mitprofessionalx.mit.edu/courses/course-v1:MITProfessionalX+DSx+2016_T1/about", "https://books.google.com/books?id=Dn-Gdoh66sgC&pg=PA89", "https://github.com/alan-turing-institute/MLJ.jl", "https://doi.org/10.1023%2FA:1007411609915"], "images": [], "sub_niche": "Adversarial machine learning"} {"title": "Outline of deep learning", "url": "https://en.wikipedia.org/wiki/Outline_of_deep_learning", "summary": "The following outline is provided as an overview of, and topical guide to, deep learning:\nDeep learning is a subfield of machine learning and artificial intelligence based on artificial neural networks with multiple processing layers. It emphasizes representation learning and is widely used in areas such as computer vision, natural language processing, speech recognition, recommender systems, robotics, and generative artificial intelligence.", "content": "The following outline is provided as an overview of, and topical guide to, deep learning:\nDeep learning is a subfield of machine learning and artificial intelligence based on artificial neural networks with multiple processing layers. It emphasizes representation learning and is widely used in areas such as computer vision, natural language processing, speech recognition, recommender systems, robotics, and generative artificial intelligence.\n\n\nWays to categorize deep learning\nA field of study\nA branch of artificial intelligence\nA subfield of machine learning\nA subfield of computer science\nA form of representation learning\nA class of methods based on artificial neural networks\nAn approach used in computational statistics\n\n\nHistory\n\n\nPrecursors\nCybernetics\nPerceptron\nConnectionism\nNeocognitron\nBackpropagation\n\n\nMilestones\nLeNet\nLong short-term memory\nDeep belief network\nAlexNet\nSequence to sequence learning\nGenerative adversarial network\nResidual neural network\nTransformer\nBERT\nGenerative pre-trained transformer\nDiffusion model\n\n\nRelated histories\nHistory of artificial intelligence\nHistory of machine learning\nTimeline of machine learning\n\n\nCore concepts\n\n\nLearning settings\nSupervised learning\nUnsupervised learning\nSelf-supervised learning\nSemi-supervised learning\nReinforcement learning\nTransfer learning\nMultitask learning\nMultimodal learning\nOnline machine learning\nContinual learning\n\n\nCommon tasks\nImage classification\nObject detection\nImage segmentation\nAutomatic speech recognition\nNeural machine translation\nQuestion answering\nAutomatic summarization\nText-to-image model\nProtein structure prediction\n\n\nArchitectures\n\n\nFeedforward and convolutional architectures\nFeedforward neural network\nMultilayer perceptron\nConvolutional neural network\nRadial basis function network\nResidual neural network\nU-Net\n\n\nRecurrent and sequence architectures\nRecurrent neural network\nLong short-term memory\nGated recurrent unit\nSequence to sequence learning\nRecursive neural network\n\n\nRepresentation-learning architectures\nAutoencoder\nDenoising autoencoder\nSparse autoencoder\nVariational autoencoder\nRestricted Boltzmann machine\nDeep belief network\n\n\nAttention and transformer architectures\nAttention (machine learning)\nTransformer\nBERT\nGenerative pre-trained transformer\nVision transformer\n\n\nGenerative and probabilistic architectures\nAutoregressive model\nDiffusion model\nEnergy-based model\nGenerative adversarial network\nMixture of experts\n\n\nGraph and memory architectures\nGraph neural network\nGraph convolutional network\nSiamese network\nNeural Turing machine\nMemory network\nEcho state network\nCapsule neural network\n\n\nNeural network components and techniques\n\nArtificial neuron\nActivation function\nRectified linear unit\nSigmoid function\nSoftmax function\nEmbedding\nConvolution\nPooling layer\nAttention\nBatch normalization\nLayer normalization\nResidual connections\n\n\nTraining and optimization\nBackpropagation\nGradient descent\nStochastic gradient descent\nAdam optimization\nLearning rate\nLoss function\nCross-entropy\nMean squared error\nRegularization\nDropout\nEarly stopping\nBatch normalization\nData augmentation\nTransfer learning\nKnowledge distillation\nEnsemble learning\nCurriculum learning\n\n\nDatasets and benchmarks\nCIFAR-10\nImageNet\nMNIST database\nCommon Objects in Context (COCO)\nGeneral Language Understanding Evaluation (GLUE) benchmark\nLibriSpeech\nSQuAD\n\n\nApplications\n\n\nComputer vision\nComputer vision\nFacial recognition system\nImage classification\nImage segmentation\nMedical imaging\nObject detection\nOptical character recognition\n\n\nNatural language processing\nAutomatic summarization\nChatbot\nInformation retrieval\nLarge language model\nNatural language processing\nNeural machine translation\nQuestion answering\nSentiment analysis\n\n\nSpeech and audio\n\nAutomatic speech recognition\nMusic information retrieval\nSpeaker recognition\nSpeech synthesis\n\n\nScience and medicine\nBioinformatics\nComputational biology\nDrug discovery\nMedical diagnosis\nProtein structure prediction\n\n\nRobotics and control\nAutonomous car\nComputer game bot\nControl theory\nRobotics\n\n\nRecommendation, search, and forecasting\nAnomaly detection\nForecasting\nFraud detection\nRecommender system\nSearch engine\n\n\nGenerative artificial intelligence\nDeepfake\nGenerative artificial intelligence\nLarge language model\nSpeech synthesis\nText-to-image model\n\n\nComputer graphics and video games\nDeep Learning Anti-Aliasing (DLAA)\nDeep Learning Super Sampling (DLSS)\n\n\nHardware\nAMD Instinct\nAMD XDNA\nApplication-specific integrated circuit\nDeep learning processor, Neural processing unit (NPU), or Neural Engine\nField-programmable gate array\nGeneral-purpose computing on graphics processing units (GPGPU)\nGraphics processing unit\nNVIDIA Deep Learning Accelerator (NVDLA)\nTensor processing unit\nVision processing unit\nWafer-scale integration\n\n\nSupporting software platforms\nCUDA\nMetal\nROCm\n\n\nSoftware\n\n\nOpen-source frameworks and libraries\n\n\nNeural network software\n\nEDLUT\nEmergent\nEncog\nJOONE\nNeuroph\nNeuroSolutions\nOpenNN\nPeltarion Synapse\nSNNS\n\n\nPlatforms, tools, and deployment\nAmazon SageMaker\nGoogle Colab\nHugging Face\nKaggle\nKubeflow\nMLflow\nONNX\nOpenVINO\nTensorFlow Hub\n\n\nAlgorithms for deep learning and neural networks\n\nBackpropagation\nConjugate gradient method\nGeneralized Hebbian algorithm\nGradient descent\nLevenberg–Marquardt algorithm\nPerceptron\nQuasi-Newton method\nWake-sleep algorithm\n\n\nMethods and related topics\n\n\nRepresentation and metric learning\nContrastive learning\nEmbedding\nFeature learning\nManifold learning\nMetric learning\n\n\nGenerative modeling\nAutoregressive model\nDiffusion model\nGenerative adversarial network\nGenerative model\nVariational inference\n\n\nEfficient and scalable deep learning\nKnowledge distillation\nLow-rank approximation\nMixture of experts\nQuantization\nSparsity\n\n\nReliability, safety, and interpretability\nAdversarial machine learning\nAI alignment\nAlgorithmic bias\nCatastrophic forgetting\nDifferential privacy\nExplainable artificial intelligence\nFederated learning\nHallucination (artificial intelligence)\n\n\nConferences and workshops\nAnnual Meeting of the Association for Computational Linguistics\nConference on Computer Vision and Pattern Recognition\nConference on Neural Information Processing Systems\nInternational Conference on Computer Vision\nInternational Conference on Learning Representations\nInternational Conference on Machine Learning\n\n\nOrganizations\n\n\nResearch laboratories and institutions\nAllen Institute for AI\nAlberta Machine Intelligence Institute\nEuropean Laboratory for Learning and Intelligent Systems\nGoogle DeepMind\nMeta AI\nMila\nMicrosoft Research\nVector Institute\n\n\nCompanies\nAnthropic\nCerebras\nCohere\nDeepSeek\nMistral AI\nOpenAI\nStability AI\nxAI\n\n\nPublications\n\n\nBooks\nDeep Learning – Ian Goodfellow and Yoshua Bengio\nNeural Networks and Deep Learning – Michael Nielsen\nPerceptrons – Marvin Minsky and Seymour Papert\n\n\nJournals\n\nIEEE Transactions on Neural Networks and Learning Systems\nNeural Networks\nNeural Computation\n\n\nInfluential persons\n\n\nSee also\n\nArtificial intelligence\nArtificial neural network\nGenerative artificial intelligence\nGlossary of artificial intelligence\nLists of open-source artificial intelligence software\nMachine learning\nNeural network software\nOutline of artificial intelligence\nOutline of computer vision\nOutline of machine learning\nOutline of robotics\n\n\nReferences", "categories": ["Articles with short description", "Artificial intelligence", "Deep learning", "Dynamic lists", "Machine learning", "Pages using Sister project links with default search", "Short description matches Wikidata"], "references": ["https://doi.org/10.1038%2Fnature14539", "https://doi.org/10.1016%2Fj.neunet.2014.09.003", "https://www.deeplearningbook.org/", "https://pubmed.ncbi.nlm.nih.gov/25462637", "https://cs229.stanford.edu/proj2015/367_report.pdf", "https://optimization.cbe.cornell.edu/index.php?title=Adam", "https://cocodataset.org/#home", "https://gluebenchmark.com/", "https://www.openslr.org/12", "https://github.com/google-deepmind/librispeech-long", "https://github.com/janishar/mit-deep-learning-book-pdf", "https://github.com/mlflow/mlflow", "https://rajpurkar.github.io/SQuAD-explorer/", "https://www.kaggle.com/datasets/stanfordu/stanford-question-answering-dataset", "http://neuralnetworksanddeeplearning.com/"], "images": [], "sub_niche": "Adversarial machine learning"} {"title": "Hallucination (artificial intelligence)", "url": "https://en.wikipedia.org/wiki/Hallucination_(artificial_intelligence)", "summary": "In artificial intelligence (AI), a hallucination is generated content that is false, unsupported, or inconsistent with the information on which the output is supposed to be based. The term is especially associated with large language models (LLMs), which can generate fluent and plausible statements, quotations, citations, or explanations that are not factually correct or are not supported by the supplied source material.\nThere is no single universally accepted definition of hallucination. Research commonly distinguishes factuality, concerning correspondence with independently verifiable facts, from faithfulness, concerning consistency with a supplied source, context, or instruction. Thus, an output can be factually correct but unsupported by the source it purports to summarize, or faithful", "content": "In artificial intelligence (AI), a hallucination is generated content that is false, unsupported, or inconsistent with the information on which the output is supposed to be based. The term is especially associated with large language models (LLMs), which can generate fluent and plausible statements, quotations, citations, or explanations that are not factually correct or are not supported by the supplied source material.\nThere is no single universally accepted definition of hallucination. Research commonly distinguishes factuality, concerning correspondence with independently verifiable facts, from faithfulness, concerning consistency with a supplied source, context, or instruction. Thus, an output can be factually correct but unsupported by the source it purports to summarize, or faithful to an inaccurate source while remaining false in the external world.\nHallucinations are a reliability problem because incorrect material may be expressed in the same confident and fluent style as correct material. Documented examples include fabricated academic references, nonexistent judicial decisions, inaccurate summaries, invented biographical claims, and incorrect information supplied by customer-service chatbots. The frequency of such errors varies with the model, task, prompting method, available context, sampling procedure, and definition used, so reported hallucination rates are not directly comparable across all systems and benchmarks.\n\n\nTerminology and scope\nThe use of hallucination in AI covers several related but distinct phenomena. In contemporary LLM research, one influential taxonomy separates factuality hallucinations from faithfulness hallucinations. Factuality hallucinations contradict or cannot be verified against real-world information. Faithfulness hallucinations depart from information or constraints supplied to the model, and may include inconsistency with a source document, user instruction, or the model's own preceding output.\nEarlier work on abstractive summarization distinguished intrinsic hallucinations, in which generated content contradicts the source, from extrinsic hallucinations, in which generated content cannot be verified from the source. An extrinsic statement is not necessarily false; it can be true but unsupported by the material being summarized. This distinction contributed to later research treating factuality and source faithfulness as related but separate evaluation problems.\nThe term is also used outside language generation, sometimes with substantially different meanings. In computer vision, face hallucination has historically referred to synthesizing plausible high-resolution detail from a low-resolution image. In vision-language models, however, the term more often describes textual claims that are unsupported by visual input.\nHallucination is not synonymous with every kind of AI error. Reasoning mistakes, failures to follow instructions, biased outputs, software failures, errors introduced by external tools, and incorrect information faithfully repeated from a source may overlap with hallucination depending on the definition being used, but are analytically distinct.\n\n\nHistory\nThe terminology predates modern generative AI. In computer vision, hallucination was used for techniques that infer or synthesize image information not directly present in a low-resolution input. A 2014 survey of image super-resolution traced use of the term to a 1986 doctoral thesis by Eric Mjolsness. Simon Baker and Takeo Kanade later used hallucinating faces for a super-resolution technique that synthesized facial detail.\nThe word subsequently acquired an error-related meaning in language processing. Hallucination was used in research on machine translation for fluent output that was poorly related or unrelated to the source sentence. In 2015, Andrej Karpathy used hallucinated to describe a recurrent neural network generating a nonexistent URL in synthetic text.\nIn July 2021, Meta described its BlenderBot 2 chatbot as prone to hallucinations, which it characterized as confident statements that were not true.\nThe term entered widespread public use following the release of general-purpose generative chatbots including ChatGPT in late 2022. News organizations increasingly used hallucination for plausible but incorrect chatbot responses. In 2023, the Cambridge Dictionary added the AI-related sense of the word and selected hallucinate as its word of the year.\n\n\nTypes\n\n\nFactuality hallucination\nA factuality hallucination is an output that conflicts with, or cannot be supported by, verifiable information about the world. Examples include invented events, incorrect relationships between people, nonexistent organizations, false numerical information, and fabricated descriptions of publications.\nFabricated citations are a prominent subtype. An LLM may produce a reference containing plausible combinations of real authors, journal names, titles, dates, or identifiers even though the cited work does not exist. It may also cite a real publication while inaccurately describing its contents.\n\n\nFaithfulness hallucination\nA faithfulness hallucination occurs when an output is inconsistent with the context or constraints on which it is supposed to be based. This can occur in summarization, translation, question answering over documents, or other grounded generation.\nFor example, a summary may add information not present in its source. Such an addition can be factually true but still unfaithful to the source. Conversely, faithfully summarizing a false statement in a source does not make the underlying statement true.\nThe category has also been used more broadly for instruction inconsistency and internal logical inconsistency.\n\n\nCitation and attribution hallucination\nModels can fabricate publications, quotations, judicial decisions, statutes, URLs, or other authorities. They can also attribute real material to the wrong person or cite an authentic source for a proposition that the source does not support.\nCitation hallucination is particularly consequential because conventional citation formatting can make invented material appear independently verified.\n\n\nMultimodal hallucination\nIn multimodal large language models and vision-language systems, hallucination generally refers to generated descriptions or claims that are unsupported by the image, video, audio, or other non-text input.\nThis usage differs from the older computer-vision meaning of hallucination in image reconstruction and super-resolution, where synthesizing absent visual detail may be the intended task.\n\n\nCauses\nHallucination does not have a single cause. Similar-looking erroneous outputs can arise from different stages of model training and deployment.\n\n\nTraining data\nHallucinations can result from training data that are incomplete, inaccurate, contradictory, outdated, or unrepresentative. Noisy training pairs can also teach models performing conditional-generation tasks to introduce information not present in their inputs.\nThe presence of misinformation in training data is not the only cause. Models can produce false combinations of individually familiar facts even when the underlying data contain accurate information.\n\n\nTraining and evaluation objectives\nLarge language models are initially trained to predict tokens from context. That objective models statistical regularities in language but does not independently determine the truth of every proposition that can be generated.\nA 2025 analysis by Adam Tauman Kalai, Ofir Nachum, Santosh Vempala and Edwin Zhang argued that hallucinations during pretraining can arise from ordinary statistical errors and that they persist partly because standard evaluations tend to reward guessing rather than expressions of uncertainty. Under an accuracy-based evaluation in which an unanswered question receives no credit, a model that is uncertain can sometimes improve its expected score by guessing.\nThe authors argued that reducing this incentive requires benchmarks to reward appropriate abstention or expressions of uncertainty, rather than treating every unanswered question as equivalent to an incorrect response.\n\n\nFailures of grounding and retrieval\nProviding a model with external information can reduce its dependence on information represented in its parameters, but it does not guarantee a correct answer. In retrieval-augmented generation, failures can result when the relevant information is not retrieved, incorrect information is retrieved, or the model fails to use retrieved evidence faithfully.\nGrounded systems can also combine supplied evidence with unsupported information from model parameters. Evaluation of such systems therefore commonly distinguishes retrieval quality from the faithfulness of the generated answer.\n\n\nModel-specific mechanisms\nMechanistic interpretability research has begun to investigate internal mechanisms associated with hallucination. In 2025, Anthropic researchers used attribution graphs to study Claude 3.5 Haiku. They reported evidence for features associated with unfamiliar entities and declining to answer, and for other features associated with entities or answers the model appeared to recognize.\nIn several case studies, experimentally changing these features could make the model answer questions it would otherwise decline or become uncertain about questions it would otherwise answer. The researchers also examined a hallucinated academic citation in which recognizing a familiar person's name appeared to partially suppress mechanisms associated with uncertainty.\nThe authors cautioned that their attribution graphs only imperfectly approximate the underlying model, that the reported examples were selected case studies, and that the identified mechanisms should not be assumed to explain hallucinations generally.\n\n\nPrompt and context effects\nA model's likelihood of producing unsupported information may also be affected by false premises, ambiguous questions, contradictory context, adversarial inputs, and prompts that imply that a particular answer must exist. Models may accept an incorrect premise and elaborate on it rather than challenge it.\n\n\nDetection and evaluation\nHallucination detection methods vary according to the kind of error being measured.\nFor factuality, systems can divide an output into individual factual claims and compare those claims with trusted external sources. Techniques include information retrieval, knowledge bases, automated fact-checking, and model-based verification.\nFor faithfulness, evaluation can compare generated claims directly with the source material. Proposed methods include fact-overlap measures, natural language inference classifiers, question-answering systems, uncertainty estimates, and the use of other LLMs as evaluators.\nA separate family of approaches attempts to estimate whether a model is uncertain about the meaning of its own possible answers. In 2024, Sebastian Farquhar and colleagues introduced semantic entropy, which groups generated answers by meaning and measures uncertainty across those semantic alternatives rather than merely across token sequences. The method was intended to detect a class of plausible but arbitrary incorrect outputs the authors called confabulations.\nAutomated hallucination detection is itself imperfect. Systems used as evaluators can make factual or interpretive errors, and factuality cannot always be determined solely from the model's prompt or internal confidence.\n\n\nMitigation\nMethods for reducing hallucination operate at the data, training, inference, and application levels.\nJi et al. grouped mitigation methods into data-related methods and modeling or inference methods. Data-related approaches include improving the quality and faithfulness of training data and augmenting inputs with external information. Modeling and inference approaches include architectural changes, changes to training objectives, reinforcement learning, and post-processing or correction of generated outputs.\nGrounding methods, including retrieval-augmented generation and access to databases, search engines, or other tools, can provide models with information at inference time. Their effectiveness depends on retrieval quality and on whether the generated response remains faithful to the retrieved material.\nVerification methods can check generated claims against external evidence, compare multiple candidate responses, validate citations, or delegate structured tasks such as calculation to deterministic software.\nUncertainty and abstention methods attempt to make models decline to answer when evidence is inadequate. Research on evaluation incentives has argued that benchmark design should reward appropriate uncertainty rather than systematically encouraging models to guess.\nResearchers have also investigated neuro-symbolic architectures combining neural language models with formal knowledge bases or inference systems.\nHuman verification remains important in applications where erroneous output can have legal, medical, scientific, financial, or other consequential effects. Human review is effective only if the underlying claims and sources are independently checked rather than accepted because the generated text appears plausible.\nNo mitigation technique eliminates all hallucinations, and methods that reduce one form of error may not address others.\n\n\nDocumented consequences\n\n\nLegal proceedings\nGenerative AI has produced nonexistent cases, quotations, and statutory authorities in legal filings in multiple jurisdictions.\nA prominent early incident occurred in Mata v. Avianca, Inc. in 2023. Attorney Stephen Schwartz used ChatGPT while researching a personal-injury case and submitted judicial authorities that did not exist. After the fabricated cases were discovered, the United States District Court for the Southern District of New York imposed a $5,000 sanction on Schwartz and another attorney for bad-faith conduct.\nSubsequent incidents involved both private lawyers and government attorneys. In 2026, a Georgia assistant district attorney acknowledged failing to verify AI-assisted legal research containing fictitious or inapposite authorities; the Supreme Court of Georgia vacated the resulting order and suspended her from practicing before the court for six months.\nIn April 2026, Sullivan & Cromwell apologized to a federal bankruptcy court after hallucinated legal citations appeared in a filing submitted on behalf of a client.\nA database maintained by legal researcher Damien Charlotin tracks judicial decisions and filings involving suspected AI-generated fictitious citations and related errors. Because the database records identified incidents rather than a representative sample of all legal filings, its totals do not establish the prevalence of hallucinations among AI-assisted legal work generally.\nSimilar cases have occurred outside the United States. Canadian courts and tribunals had identified numerous filings containing fictitious authorities by 2026, while the High Court of Justice in England and Wales addressed hallucinated authorities in the conjoined 2025 cases Ayinde v Haringey and Al-Haroun v Qatar.\nProfessional bodies including the Solicitors Regulation Authority, the Law Society of England and Wales, and the Bar Council have subsequently issued guidance concerning lawyers' use of generative AI.\n\n\nScientific and academic research\nFabricated or inaccurate scholarly references are a documented failure mode of LLMs.\nA 2023 study examining 178 references produced for proposed scientific writing found numerous incorrect or nonexistent digital object identifiers (DOIs), including 28 references for which the researchers could not locate the cited work or a valid DOI.\nAnother 2023 study examined 115 references generated by ChatGPT-3.5 for medical writing. The authors classified 47% as fabricated, 46% as authentic references containing inaccurate information, and 7% as authentic and accurately represented. The figures describe that particular model and experimental setup and are not a general error rate for later LLMs.\nResearch librarians have also reported student-submitted citations containing combinations of real and fabricated bibliographic information. A 2024 study at the University of Mississippi examined AI-associated citations found in student work and documented incorrect authors, titles, dates, and nonexistent publications.\nIn 2025, Deloitte acknowledged AI use after nonexistent academic sources and an inaccurate judicial quotation were identified in an Australian government report; the company produced a revised report and agreed to refund part of its fee.\n\n\nCustomer-facing systems\nIn Moffatt v. Air Canada, a customer relied on information from an Air Canada website chatbot stating that a bereavement fare could be requested retroactively. The airline's actual policy did not permit the discount after travel had been booked. In 2024, the British Columbia Civil Resolution Tribunal held Air Canada responsible for the erroneous information and awarded damages.\nThe tribunal rejected Air Canada's argument that the chatbot was effectively a separate entity responsible for its own statements. The case became a frequently cited example of the distinction between the technical source of an AI error and the responsibility of an organization deploying an automated system.\n\n\nOther modalities and uses of the term\n\n\nComputer vision\nThe historical computer-vision meaning of hallucination differs from its contemporary use for factual errors in language models. In super-resolution, hallucination can mean generating plausible visual detail not recoverable directly from a low-resolution image.\nThe word has also been used for false-positive detections by image-recognition systems and for failures induced by adversarial examples. Wired reported examples including computer-vision systems failing to recognize an adversarially altered stop sign and a Google Cloud Vision system assigning a high probability to an incorrect object category.\nResearchers have disputed whether some adversarial examples are best interpreted as hallucinations, noting that models may respond to statistical features that are genuinely predictive in their training distributions but imperceptible or irrelevant to humans.\n\n\nGenerative images and video\n\nThe term hallucination is sometimes extended to generative image and video systems when generated content conflicts with a prompt, reference image, physical constraints, or known facts. The boundaries of this usage are less standardized than in LLM research: an unexpected generated feature may alternatively be described as an artifact, generation error, or failure of prompt adherence.\nGenerative systems used for image analysis can also hallucinate identifications or historical matches. Kurt Luther described cases in which generative AI used for archival photo research incorrectly identified people or fabricated historical matches.\n\n\nGenerative scientific design\nThe word hallucination has also occasionally been used positively for the generation of novel scientific structures or hypotheses. For example, reporting on David Baker's protein-design research has described computational generation of previously nonexistent protein structures as a form of productive hallucination.\nThis usage is conceptually different from an LLM presenting a false factual proposition. In generative scientific design, novelty may be the intended output and candidate designs can subsequently be tested against physical or experimental constraints. The Nobel Committee for Chemistry, in describing Baker's work associated with the 2024 Nobel Prize in Chemistry, used the phrase \"computational protein design\" and described the creation of new proteins rather than treating the work as factual error.\n\n\nCriticism of the term\nThe metaphor of hallucination has been criticized for anthropomorphizing AI systems and for grouping distinct kinds of error under language borrowed from human perception.\nA 2024 paper by Negar Maleki, Balaji Padmanabhan and Kaushik Dutta argued that the term is inconsistently defined and can mislead discussion of AI failure modes. Computer scientist Mary Shaw has similarly criticized the terminology for anthropomorphizing software and characterizing objective errors as though they were perceptual quirks.\nMurray Shanahan has argued more broadly that anthropomorphic descriptions of language models can encourage inappropriate inferences about mental processes in systems based on statistical computation.\nMichael Townsen Hicks, James Humphries and Joe Slater argued that LLM outputs are better characterized using Harry Frankfurt's concept of bullshit, because in their analysis the generation process is not inherently oriented toward the truth of the resulting assertions.\nOther proposed terminology includes confabulation, fabrication, factual error, mirage, and undesirable output. These terms emphasize different properties and are not exact synonyms.\nSusanne Förster and Yarden Skop have argued that use of the hallucination metaphor in industry communication can shift attention from design and deployment decisions toward apparently autonomous characteristics of a model.\nDespite these criticisms, hallucination remains widely used in AI research, industry, journalism, and public discussion. Technical literature increasingly defines the specific error being measured—such as factual contradiction, source unfaithfulness, or visual grounding failure—rather than relying on the umbrella term alone.\n\n\nSee also\nAI alignment\nAI safety\nAI slop\nArtifact (error)\nConfabulation\nGenerative artificial intelligence\nLarge language model\nMisinformation\nNatural language generation\nRetrieval-augmented generation\n\n\nReferences", "categories": ["AI risk", "Anthropomorphism", "Articles containing video clips", "Articles with short description", "Communication of falsehoods", "Generative AI", "Language modeling", "Machine learning", "Misinformation", "Natural language processing", "Pages using multiple image with auto scaled images", "Philosophy of artificial intelligence", "Short description is different from Wikidata", "Use dmy dates from September 2026"], "references": ["https://www.wired.com/story/ai-has-a-hallucination-problem-thats-proving-tough-to-fix/", "https://doi.org/10.23915%2Fdistill.00019.1", "https://arstechnica.com/tech-policy/2023/06/lawyers-have-real-bad-day-in-court-after-citing-fake-cases-made-up-by-chatgpt/", "https://arxiv.org/archive/cs.CL", "https://doi.org/10.7759%2Fcureus.37432", "https://www.ncbi.nlm.nih.gov/pmc/articles/PMC10173677", "https://pubmed.ncbi.nlm.nih.gov/37182055", "https://web.archive.org/web/20230405082603/https://www.wired.com/story/ai-has-a-hallucination-problem-thats-proving-tough-to-fix/", "https://web.archive.org/web/20240126071502/https://arstechnica.com/tech-policy/2023/06/lawyers-have-real-bad-day-in-court-after-citing-fake-cases-made-up-by-chatgpt/", "https://www.nytimes.com/2024/12/23/science/ai-hallucinations-science.html", "https://doi.org/10.1145%2F3689492.3689816", "https://arxiv.org/abs/2409.00764", "https://web.archive.org/web/20240402084731/https://research.google/pubs/hallucinations-in-neural-machine-translation/", "https://web.archive.org/web/20240404080348/https://www.nytimes.com/2023/05/01/business/ai-chatbots-hallucination.html", "https://arxiv.org/abs/2401.06796"], "images": ["File:AI Overviews result for Joaquin Correa brother, 10 August 2025.jpg", "File:Glenfinnan Viaduct - 2022 (cropped).jpg"], "sub_niche": "Adversarial machine learning"} {"title": "Explainable artificial intelligence", "url": "https://en.wikipedia.org/wiki/Explainable_artificial_intelligence", "summary": "Within artificial intelligence (AI), explainable AI (XAI), generally overlapping with interpretable AI, interpretable machine learning and explainable machine learning (XML), is a field of research that explores methods that provide humans with the ability of intellectual oversight over AI algorithms. The main focus is on the reasoning behind the decisions or predictions made by the AI algorithms, to make them more understandable and transparent. This addresses the need for users to know the safety of the algorithms and scrutinize the automated decision-making in applications. XAI counters the \"black box\" tendency of machine learning, where even the AI's designers cannot explain why it arrived at a specific decision.\nXAI seeks to help users of AI-powered systems perform more effectively by", "content": "Within artificial intelligence (AI), explainable AI (XAI), generally overlapping with interpretable AI, interpretable machine learning and explainable machine learning (XML), is a field of research that explores methods that provide humans with the ability of intellectual oversight over AI algorithms. The main focus is on the reasoning behind the decisions or predictions made by the AI algorithms, to make them more understandable and transparent. This addresses the need for users to know the safety of the algorithms and scrutinize the automated decision-making in applications. XAI counters the \"black box\" tendency of machine learning, where even the AI's designers cannot explain why it arrived at a specific decision.\nXAI seeks to help users of AI-powered systems perform more effectively by improving their understanding of how those systems reason. XAI may be an implementation of the social right to explanation. Even if there is no such legal right or regulatory requirement, XAI can improve the user experience of a product or service by helping end users trust that the AI is making good decisions. XAI aims to explain what has been done, what is being done, what will be done next, and what information these actions are based on. This makes it possible to confirm and challenge existing knowledge, and generate new assumptions.\n\n\nBackground\nMachine learning (ML) algorithms used in AI can be categorized as white-box or black-box. White-box models provide results that are understandable to experts in the domain. Black-box models, on the other hand, are extremely hard to explain and may not be understood even by domain experts. XAI algorithms follow the three principles of transparency, interpretability, and explainability.\n\nA model is transparent \"if the processes that extract model parameters from training data and generate labels from testing data can be described and motivated by the approach designer.\"\nInterpretability describes the possibility of comprehending the ML model and presenting the underlying basis for decision-making in a way that is understandable to humans.\nExplainability is a concept that is recognized as important, but a consensus definition is not yet available; one possibility is \"the collection of features of the interpretable domain that have contributed, for a given example, to producing a decision (e.g., classification or regression)\".\nIn summary, Interpretability refers to the user's ability to understand model outputs, while Model Transparency includes Simulatability (reproducibility of predictions), Decomposability (intuitive explanations for parameters), and Algorithmic Transparency (explaining how algorithms work). Model Functionality focuses on textual descriptions, visualization, and local explanations, which clarify specific outputs or instances rather than entire models. All these concepts aim to enhance the comprehensibility and usability of AI systems.\nIf algorithms fulfill these principles, they provide a basis for justifying decisions, tracking them and thereby verifying them, improving the algorithms, and exploring new facts.\nSometimes it is also possible to achieve a high-accuracy result with white-box ML algorithms. These algorithms have an interpretable structure that can be used to explain predictions. Concept Bottleneck Models, which use concept-level abstractions to explain model reasoning, are examples of this and can be applied in both image and text prediction tasks. This is especially important in domains like medicine, defense, finance, and law, where it is crucial to understand decisions and build trust in the algorithms. Many researchers argue that, at least for supervised machine learning, the way forward is symbolic regression, where the algorithm searches the space of mathematical expressions to find the model that best fits a given dataset.\nAI systems optimize behavior to satisfy a mathematically specified goal system chosen by the system designers, such as the command \"maximize the accuracy of assessing how positive film reviews are in the test dataset.\" The AI may learn useful general rules from the test set, such as \"reviews containing the word \"horrible\" are likely to be negative.\" However, it may also learn inappropriate rules, such as \"reviews containing 'Daniel Day-Lewis' are usually positive\"; such rules may be undesirable if they are likely to fail to generalize outside the training set, or if people consider the rule to be \"cheating\" or \"unfair.\" A human can audit rules in an XAI to get an idea of how likely the system is to generalize to future real-world data outside the test set.\n\n\nGoals\nCooperation between agents – in this case, algorithms and humans – depends on trust. If humans are to accept algorithmic prescriptions, they need to trust them. Incompleteness in formal trust criteria is a barrier to optimization. Transparency, interpretability, and explainability are intermediate goals on the road to these more comprehensive trust criteria. This is particularly relevant in medicine, especially with clinical decision support systems (CDSS), in which medical professionals should be able to understand how and why a machine-based decision was made in order to trust the decision and augment their decision-making process.\nAI systems sometimes learn undesirable tricks that do an optimal job of satisfying explicit pre-programmed goals on the training data but do not reflect the more nuanced implicit desires of the human system designers or the full complexity of the domain data. For example, a 2017 system tasked with image recognition learned to \"cheat\" by looking for a copyright tag that happened to be associated with horse pictures rather than learning how to tell if a horse was actually pictured. In another 2017 system, a supervised learning AI tasked with grasping items in a virtual world learned to cheat by placing its manipulator between the object and the viewer in a way such that it falsely appeared to be grasping the object.\nOne transparency project, the DARPA XAI program, aims to produce \"glass box\" models that are explainable to a \"human-in-the-loop\" without greatly sacrificing AI performance. Human users of such a system can understand the AI's cognition (both in real-time and after the fact) and can determine whether to trust the AI. Other applications of XAI are knowledge extraction from black-box models and model comparisons. In the context of monitoring systems for ethical and socio-legal compliance, the term \"glass box\" is commonly used to refer to tools that track the inputs and outputs of the system in question, and provide value-based explanations for their behavior. These tools aim to ensure that the system operates in accordance with ethical and legal standards, and that its decision-making processes are transparent and accountable. The term \"glass box\" is often used in contrast to \"black box\" systems, which lack transparency and can be more difficult to monitor and regulate.\nThe term is also used to name a voice assistant that produces counterfactual statements as explanations.\n\n\nExplainability and interpretability techniques\nThere is a subtle difference between the terms explainability and interpretability in the context of AI.\n\nSome explainability techniques don't involve understanding how the model works, and may work across various AI systems. Treating the model as a black box and analyzing how marginal changes to the inputs affect the result sometimes provides a sufficient explanation.\n\n\nExplainability\nExplainability is useful for ensuring that AI models are not making decisions based on irrelevant or otherwise unfair criteria. For classification and regression models, several popular techniques exist:\n\nPartial dependency plots show the marginal effect of an input feature on the predicted outcome.\nSHAP (SHapley Additive exPlanations) enables visualization of the contribution of each input feature to the output. It works by calculating Shapley values, which measure the average marginal contribution of a feature across all possible combinations of features.\nFeature importance estimates how important a feature is for the model. It is usually done using permutation importance, which measures the performance decrease when the feature value is randomly shuffled across all samples.\nLIME (Local Interpretable Model-Agnostic Explanations method) approximates locally a model's outputs with a simpler, interpretable model.\nMultitask learning provides a large number of outputs in addition to the target classification. These other outputs can help developers deduce what the network has learned.\nFor images, saliency maps highlight the parts of an image that most influenced the result.\nSystems that are expert or knowledge based are software systems that are made by experts. This system consists of a knowledge based encoding for the domain knowledge. This system is usually modeled as production rules, and someone uses this knowledge base which the user can question the system for knowledge. In expert systems, the language and explanations are understood with an explanation for the reasoning or a problem solving activity.\nHowever, these techniques are not very suitable for language models like generative pretrained transformers. Since these models generate language, they can provide an explanation, but which may not be reliable. Other techniques include attention analysis (examining how the model focuses on different parts of the input), probing methods (testing what information is captured in the model's representations), causal tracing (tracing the flow of information through the model) and circuit discovery (identifying specific subnetworks responsible for certain behaviors). Explainability research in this area overlaps significantly with interpretability and alignment research.\n\n\nInterpretability\n\nScholars sometimes use the term \"mechanistic interpretability\" to refer to the process of reverse-engineering artificial neural networks to understand their internal decision-making mechanisms and components, similar to how one might analyze a complex machine or computer program.\nStudying the interpretability of the most advanced foundation models often involves searching for an automated way to identify \"features\" in generative pretrained transformers. In a neural network, a feature is a pattern of neuron activations that corresponds to a concept. A compute-intensive technique called \"dictionary learning\" makes it possible to identify features to some degree. Enhancing the ability to identify and edit features is expected to significantly improve the safety of frontier AI models.\nFor convolutional neural networks, DeepDream can generate images that strongly activate a particular neuron, providing a visual hint about what the neuron is trained to identify.\n\n\nKnowledge localization\nLarge language models (LLMs), such as transformer-based models (GPT), appear to use general knowledge when generating output (completing inference). This capability raises the question of how, exactly, such knowledge is stored within the model.\nResearch has suggested that the model's MLP component (the feed-forward layers) is the main site in which knowledge is stored, encoding information through associative links that function as key–value memories: each key corresponds to textual patterns in the training data, while each value induces a distribution over the output vocabulary.\nA 2022 study, aimed at locating where knowledge resides in the model, employed a technique known as Causal Tracing. In tasks requiring general knowledge, the researchers injected noise into the hidden activations of the model, preventing it from completing the task. They then restored the clean activation values (taken from a noise-free run) to a different part of the model each time, observing when the model regained its ability to produce the correct answer. Based on these results, the authors concluded that factual knowledge is stored primarily in the MLP components of the model's middle layers. They further proposed that model editing would be most effective in those regions, though this claim was later called into question.\nLater studies suggest that, in most cases, factual information is distributed across the model rather than localized within a single layer. According to one version of this view, different layers encode different aspects of the same association. For example, a question about the capital of Japan may activate representations related to \"Japan\" in one layer and representations corresponding to \"capital cities\" in another; the combination of these representations yields the concept of \"Tokyo\".\n\n\nHistory and methods\nDuring the 1970s to 1990s, symbolic reasoning systems, such as MYCIN, GUIDON, SOPHIE, and PROTOS could represent, reason about, and explain their reasoning for diagnostic, instructional, or machine-learning (explanation-based learning) purposes. MYCIN, developed in the early 1970s as a research prototype for diagnosing bacteremia infections of the bloodstream, could explain which of its hand-coded rules contributed to a diagnosis in a specific case. Research in intelligent tutoring systems resulted in developing systems such as SOPHIE that could act as an \"articulate expert\", explaining problem-solving strategy at a level the student could understand, so they would know what action to take next. For instance, SOPHIE could explain the qualitative reasoning behind its electronics troubleshooting, even though it ultimately relied on the SPICE circuit simulator. Similarly, GUIDON added tutorial rules to supplement MYCIN's domain-level rules so it could explain the strategy for medical diagnosis. Symbolic approaches to machine learning relying on explanation-based learning, such as PROTOS, made use of explicit representations of explanations expressed in a dedicated explanation language, both to explain their actions and to acquire new knowledge.\nIn the 1980s through the early 1990s, truth maintenance systems (TMS) extended the capabilities of causal-reasoning, rule-based, and logic-based inference systems. A TMS explicitly tracks alternate lines of reasoning, justifications for conclusions, and lines of reasoning that lead to contradictions, allowing future reasoning to avoid these dead ends. To provide an explanation, they trace reasoning from conclusions to assumptions through rule operations or logical inferences, allowing explanations to be generated from the reasoning traces. As an example, consider a rule-based problem solver with just a few rules about Socrates that concludes he has died from poison:\n\nBy just tracing through the dependency structure the problem solver can construct the following explanation: \"Socrates died because he was mortal and drank poison, and all mortals die when they drink poison. Socrates was mortal because he was a man and all men are mortal. Socrates drank poison because he held dissident beliefs, the government was conservative, and those holding conservative dissident beliefs under conservative governments must drink poison.\"\nBy the 1990s researchers began studying whether it is possible to meaningfully extract the non-hand-coded rules being generated by opaque trained neural networks. Researchers in clinical expert systems who created neural network-powered decision support for clinicians sought to develop dynamic explanations that allow these technologies to be more trusted and trustworthy in practice. In the 2010s public concerns about racial and other bias in the use of AI for criminal sentencing decisions and findings of creditworthiness may have led to increased demand for transparent artificial intelligence. As a result, many academics and organizations are developing tools to help detect bias in their systems.\nMarvin Minsky et al. raised the issue that AI can function as a form of surveillance, with the biases inherent in surveillance, suggesting HI (Humanistic Intelligence) as a way to create a more fair and balanced \"human-in-the-loop\" AI.\nExplainable AI recently became a topic of research within deep learning. Modern complex AI techniques, such as deep learning, are naturally opaque. To address this issue, methods have been developed to make new models more explainable and interpretable. This includes layerwise relevance propagation (LRP), a technique for determining which features in a particular input vector contribute most strongly to a neural network's output, although this technique has been shown to suffer from several important issues. Other techniques explain some particular prediction made by a (nonlinear) black-box model, a goal referred to as \"local interpretability\". There is also research on whether the concepts of local interpretability can be applied to a remote context, where a model is operated by a third-party.\nThere has been work on making glass-box models which are more transparent to inspection. This includes decision trees, Bayesian networks, sparse linear models, and more. The Association for Computing Machinery Conference on Fairness, Accountability, and Transparency (ACM FAccT) was established in 2018 to study transparency and explainability in the context of socio-technical systems, many of which include artificial intelligence.\nSome techniques allow visualisations of the inputs to which individual software neurons respond to most strongly. Several groups found that neurons can be aggregated into circuits that perform human-comprehensible functions, some of which reliably arise across different networks trained independently.\nThere are various techniques to extract compressed representations of the features of given inputs, which can then be analysed by standard clustering techniques. Alternatively, networks can be trained to output linguistic explanations of their behaviour, which are then directly human-interpretable. Model behaviour can also be explained with reference to training data—for example, by evaluating which training inputs influenced a given behaviour the most, or by approximating its predictions using the most similar instances from the training data.\nThe use of explainable artificial intelligence (XAI) in pain research, specifically in understanding the role of electrodermal activity for automated pain recognition: hand-crafted features and deep learning models in pain recognition, highlighting the insights that simple hand-crafted features can yield comparative performances to deep learning models and that both traditional feature engineering and deep feature learning approaches rely on simple characteristics of the input time-series data.\n\n\nRegulation\nAs regulators, official bodies, and general users come to depend on AI-based dynamic systems, clearer accountability will be required for automated decision-making processes to ensure trust and transparency. The first global conference exclusively dedicated to this emerging discipline was the 2017 International Joint Conference on Artificial Intelligence: Workshop on Explainable Artificial Intelligence (XAI). It has evolved over the years, with various workshops organised and co-located to many other international conferences, and it has now a dedicated global event, \"The world conference on eXplainable Artificial Intelligence\", with its own proceedings.\nThe European Union introduced a right to explanation in the General Data Protection Regulation (GDPR) to address potential problems stemming from the rising importance of algorithms. The implementation of the regulation began in 2018. However, the right to explanation in GDPR covers only the local aspect of interpretability. In the United States, insurance companies are required to be able to explain their rate and coverage decisions. In France the Loi pour une République numérique (Digital Republic Act) grants subjects the right to request and receive information pertaining to the implementation of algorithms that process data about them.\n\n\nLimitations\nDespite ongoing endeavors to enhance the explainability of AI models, they persist with several inherent limitations.\n\n\nAdversarial parties\nMaking an AI system more explainable also reveals more of its inner workings. For example, the explainability method of feature importance identifies features or variables that are most important in determining the model's output, while the influential samples method identifies the training samples that are most influential in determining the output, given a particular input. Adversarial parties could take advantage of this knowledge.\nFor example, competitor firms could replicate aspects of the original AI system in their own product, thus reducing competitive advantage. An explainable AI system is also susceptible to being \"gamed\"—influenced in a way that undermines its intended purpose. One study gives the example of a predictive policing system; in this case, those who could potentially \"game\" the system are the criminals subject to the system's decisions. In this study, developers of the system discussed the issue of criminal gangs looking to illegally obtain passports, and they expressed concerns that, if given an idea of what factors might trigger an alert in the passport application process, those gangs would be able to \"send guinea pigs\" to test those triggers, eventually finding a loophole that would allow them to \"reliably get passports from under the noses of the authorities\".\n\n\nAdaptive integration and explanation\nMany approaches that it uses provides explanation in general, it doesn't take account for the diverse backgrounds and knowledge level of the users. This leads to challenges with accurate comprehension for all users. Expert users can find the explanations lacking in depth, and are oversimplified, while a beginner user may struggle understanding the explanations as they are complex. This limitation downplays the ability of the XAI techniques to appeal to their users with different levels of knowledge, which can impact the trust from users and who uses it. The quality of explanations can be different amongst their users as they all have different expertise levels, including different situation and conditions.\n\n\nTechnical complexity\nA fundamental barrier to making AI systems explainable is the technical complexity of such systems. End users often lack the coding knowledge required to understand software of any kind. Current methods used to explain AI are mainly technical ones, geared toward machine learning engineers for debugging purposes, rather than toward the end users who are ultimately affected by the system, causing \"a gap between explainability in practice and the goal of transparency\". Proposed solutions to address the issue of technical complexity include either promoting the coding education of the general public so technical explanations would be more accessible to end users, or providing explanations in layperson terms.\nThe solution must avoid oversimplification. It is important to strike a balance between accuracy – how faithfully the explanation reflects the process of the AI system – and explainability – how well end users understand the process. This is a difficult balance to strike, since the complexity of machine learning makes it difficult for even ML engineers to fully understand, let alone non-experts.\n\n\nUnderstanding versus trust\nThe goal of explainability to end users of AI systems is to increase trust in the systems, even \"address concerns about lack of 'fairness' and discriminatory effects\". However, even with a good understanding of an AI system, end users may not necessarily trust the system. In one study, participants were presented with combinations of white-box and black-box explanations, and static and interactive explanations of AI systems. While these explanations served to increase both their self-reported and objective understanding, it had no impact on their level of trust, which remained skeptical.\nThis outcome was especially true for decisions that impacted the end user in a significant way, such as graduate school admissions. Participants judged algorithms to be too inflexible and unforgiving in comparison to human decision-makers; instead of rigidly adhering to a set of rules, humans are able to consider exceptional cases as well as appeals to their initial decision. For such decisions, explainability will not necessarily cause end users to accept the use of decision-making algorithms.\nHowever, some emphasize that the purpose of explainability of artificial intelligence is not to merely increase users' trust in the system's decisions, but to calibrate the users' level of trust to the correct level. According to this principle, too much or too little user trust in the AI system will harm the overall performance of the human-system unit. When the trust is excessive, the users are not critical of possible mistakes of the system and when the users do not have enough trust in the system, they will not exhaust the benefits inherent in it.\n\n\nCriticism\nSome scholars have suggested that explainability in AI should be considered a goal secondary to AI effectiveness, and that encouraging the exclusive development of XAI may limit the functionality of AI more broadly. Critiques of XAI rely on developed concepts of mechanistic and empiric reasoning from evidence-based medicine to suggest that AI technologies can be clinically validated even when their function cannot be understood by their operators.\nSome researchers advocate the use of inherently interpretable machine learning models, rather than using post-hoc explanations in which a second model is created to explain the first. This is partly because post-hoc models increase the complexity in a decision pathway and partly because it is often unclear how faithfully a post-hoc explanation can mimic the computations of an entirely separate model. However, another view is that what is important is that the explanation accomplishes the given task at hand, and whether it is pre or post-hoc doesn't matter. If a post-hoc explanation method helps a doctor diagnose cancer better, it is of secondary importance whether it is a correct/incorrect explanation.\nThe goals of XAI amount to a form of lossy compression that will become less effective as AI models grow in their number of parameters. Along with other factors this leads to a theoretical limit for explainability.\n\n\nExplainability in social choice\nExplainability was studied also in social choice theory. Social choice theory aims at finding solutions to social decision problems, that are based on well-established axioms. Ariel D. Procaccia explains that these axioms can be used to construct convincing explanations to the solutions. This principle has been used to construct explanations in various subfields of social choice.\n\n\nVoting\nCailloux and Endriss present a method for explaining voting rules using the axioms that characterize them. They exemplify their method on the Borda voting rule.\nPeters, Procaccia, Psomas and Zhou present an algorithm for explaining the outcomes of the Borda rule using O(m2) explanations, and prove that this is tight in the worst case.\n\n\nParticipatory budgeting\nYang, Hausladen, Peters, Pournaras, Fricker and Helbing present an empirical study of explainability in participatory budgeting. They compared the greedy and the equal shares rules, and three types of explanations: mechanism explanation (a general explanation of how the aggregation rule works given the voting input), individual explanation (explaining how many voters had at least one approved project, at least 10000 CHF in approved projects), and group explanation (explaining how the budget is distributed among the districts and topics). They compared the perceived trustworthiness and fairness of greedy and equal shares, before and after the explanations. They found out that, for MES, mechanism explanation yields the highest increase in perceived fairness and trustworthiness; the second-highest was Group explanation. For Greedy, Mechanism explanation increases perceived trustworthiness but not fairness, whereas Individual explanation increases both perceived fairness and trustworthiness. Group explanation decreases the perceived fairness and trustworthiness.\n\n\nPayoff allocation\nNizri, Azaria and Hazon present an algorithm for computing explanations for the Shapley value. Given a coalitional game, their algorithm decomposes it to sub-games, for which it is easy to generate verbal explanations based on the axioms characterizing the Shapley value. The payoff allocation for each sub-game is perceived as fair, so the Shapley-based payoff allocation for the given game should seem fair as well. An experiment with 210 human subjects shows that, with their automatically generated explanations, subjects perceive Shapley-based payoff allocation as significantly fairer than with a general standard explanation.\n\n\nSee also\nAccumulated local effects – Machine learning method\nAlgorithmic transparency – Transparency of decisions by algorithms\nRight to explanation – Right to have an algorithm explained\n\n\nReferences\n\n\nExternal links\n\"Leaders today face a new paradox: deploying powerful AI solutions\". 31 October 2025.\n\"the World Conference on eXplainable Artificial Intelligence\".\n\"ACM Conference on Fairness, Accountability, and Transparency (FAccT)\".\nMazumdar, Dipankar; Neto, Mário Popolin; Paulovich, Fernando V. (2021). \"Random Forest similarity maps: A Scalable Visual Representation for Global and Local Interpretation\". Electronics. 10 (22): 2862. doi:10.3390/electronics10222862.\n\"Explainable AI: Making machines understandable for humans\". Explainable AI: Making machines understandable for humans. Retrieved 2017-11-02.\n\"Explaining How End-to-End Deep Learning Steers a Self-Driving Car\". Parallel Forall. 2017-05-23. Retrieved 2017-11-02.\nKnight, Will (2017-03-14). \"DARPA is funding projects that will try to open up AI's black boxes\". MIT Technology Review. Retrieved 2017-11-02.", "categories": ["All articles with style issues", "Articles with short description", "Artificial intelligence", "Artificial intelligence engineering", "CS1 maint: multiple names: authors list", "CS1 maint: numeric names: authors list", "CS1 maint: periodical has ISBN", "Quality control tools", "Short description is different from Wikidata", "Wikipedia articles with style issues from November 2025"], "references": ["https://devblogs.nvidia.com/parallelforall/explaining-deep-learning-self-driving-car/", "https://explainableai.com/", "https://www.technologyreview.com/s/603795/the-us-military-wants-its-autonomous-machines-to-explain-themselves/", "https://www.theguardian.com/science/2017/nov/05/computer-says-no-why-making-ais-fair-accountable-and-transparent-is-crucial", "https://www.newyorker.com/magazine/2017/04/03/ai-versus-md", "https://fatconference.org/", "https://www.bloomberg.com/news/articles/2018-06-13/accenture-unveils-tool-to-help-companies-insure-their-ai-is-fair", "https://www.economist.com/science-and-technology/2018/02/15/computer-programs-recognise-white-men-better-than-black-women", "https://www.bloomberg.com/news/articles/2018-12-12/artificial-intelligence-has-some-explaining-to-do", "http://www.intelligentrobots.org/files/IJCAI2017/IJCAI-17_XAI_WS_Proceedings.pdf", "https://ui.adsabs.harvard.edu/abs/2015PLoSO..1030140B", "http://papers.nips.cc/paper/7062-a-unified-approach-to-interpreting-model-predictions.pdf", "http://proceedings.mlr.press/v89/carter19a.html", "http://proceedings.mlr.press/v70/shrikumar17a.html", "https://dl.acm.org/doi/abs/10.5555/3305890.3306024"], "images": ["File:Grokking modular addition.jpg"], "sub_niche": "Adversarial machine learning"} {"title": "Quantum machine learning", "url": "https://en.wikipedia.org/wiki/Quantum_machine_learning", "summary": "Quantum machine learning (QML) is the study of quantum algorithms for machine learning. It often refers to quantum algorithms for machine learning tasks which analyze classical data, sometimes called quantum-enhanced machine learning.\nQML algorithms use qubits and quantum operations to try to improve the space and time complexity of classical machine learning algorithms. Hybrid QML methods involve both classical and quantum processing, where computationally difficult subroutines are outsourced to a quantum device. These routines can be more complex in nature and executed faster on a quantum computer. Furthermore, quantum algorithms can be used to analyze quantum states instead of classical data.\nThe term \"quantum machine learning\" is sometimes used to refer classical machine learning metho", "content": "Quantum machine learning (QML) is the study of quantum algorithms for machine learning. It often refers to quantum algorithms for machine learning tasks which analyze classical data, sometimes called quantum-enhanced machine learning.\nQML algorithms use qubits and quantum operations to try to improve the space and time complexity of classical machine learning algorithms. Hybrid QML methods involve both classical and quantum processing, where computationally difficult subroutines are outsourced to a quantum device. These routines can be more complex in nature and executed faster on a quantum computer. Furthermore, quantum algorithms can be used to analyze quantum states instead of classical data.\nThe term \"quantum machine learning\" is sometimes used to refer classical machine learning methods applied to data generated from quantum experiments (i.e. machine learning of quantum systems), such as learning the phase transitions of a quantum system or creating new quantum experiments.\nQML also extends to a branch of research that explores methodological and structural similarities between certain physical systems and learning systems, in particular neural networks. For example, some mathematical and numerical techniques from quantum physics are applicable to classical deep learning and vice versa.\nFurthermore, researchers investigate more abstract notions of learning theory with respect to quantum information, sometimes referred to as \"quantum learning theory\".\n\n\nMachine learning with quantum computers\nQuantum-enhanced machine learning refers to quantum algorithms that solve tasks in machine learning, thereby improving and often expediting classical machine learning techniques. Such algorithms typically require one to encode the given classical data set into a quantum computer to make it accessible for quantum information processing. Subsequently, quantum information processing routines are applied and the result of the quantum computation is read out by measuring the quantum system. For example, the outcome of the measurement of a qubit reveals the result of a binary classification task. While many proposals of QML algorithms are still purely theoretical and require a full-scale universal quantum computer to be tested, others have been implemented on small-scale or special purpose quantum devices.\n\n\nQuantum associative memories and quantum pattern recognition\nEarly work on quantum associative memories has been done by Dan Ventura and Tony Martinez and by Carlo A. Trugenberger in the late 1990s and early 2000s.\nAssociative (or content-addressable) memories are able to recognize stored content on the basis of a similarity measure, while random access memories are accessed by the address of stored information and not its content. As such they must be able to retrieve both incomplete and corrupted patterns, the essential machine learning task of pattern recognition.\nTypical classical associative memories store p patterns in the \n \n \n \n O\n (\n \n n\n \n 2\n \n \n )\n \n \n {\\displaystyle O(n^{2})}\n \n interactions (synapses) of a real, symmetric energy matrix over a network of n artificial neurons. The encoding is such that the desired patterns are local minima of the energy functional and retrieval is done by minimizing the total energy, starting from an initial configuration.\nUnfortunately, classical associative memories are severely limited by the phenomenon of cross-talk. When too many patterns are stored, spurious memories appear which quickly proliferate, so that the energy landscape becomes disordered and no retrieval is anymore possible. The number of storable patterns is typically limited by a linear function of the number of neurons, \n \n \n \n p\n ≤\n O\n (\n n\n )\n \n \n {\\displaystyle p\\leq O(n)}\n \n.\nQuantum associative memories (in their simplest realization) store patterns in a unitary matrix U acting on the Hilbert space of n qubits. Retrieval is realized by the unitary evolution of a fixed initial state to a quantum superposition of the desired patterns with probability distribution peaked on the most similar pattern to an input. By its very quantum nature, the retrieval process is thus probabilistic. Because quantum associative memories are free from cross-talk, however, spurious memories are never generated. Correspondingly, they have a superior capacity than classical ones. The number of parameters in the unitary matrix U is \n \n \n \n O\n (\n p\n n\n )\n \n \n {\\displaystyle O(pn)}\n \n. One can thus have efficient, spurious-memory-free quantum associative memories for any polynomial number of patterns. If the matrix U is encoded as a unique operator (as opposed as to a sequence of gates as in the circuit model), e.g. by an optical interferometer, the retrieval becomes efficient even for an exponential number of patterns.\n\n\nLinear algebra simulation with quantum amplitudes\nA number of quantum algorithms for machine learning are based on the idea of amplitude encoding, that is, to associate the amplitudes of a quantum state with the inputs and outputs of computations. Since a state of \n \n \n \n n\n \n \n {\\displaystyle n}\n \n qubits is described by \n \n \n \n \n 2\n \n n\n \n \n \n \n {\\displaystyle 2^{n}}\n \n complex amplitudes, this information encoding can allow for an exponentially compact representation. Intuitively, this corresponds to associating a discrete probability distribution over binary random variables with a classical vector. The goal of algorithms based on amplitude encoding is to formulate quantum algorithms whose resources grow polynomially in the number of qubits \n \n \n \n n\n \n \n {\\displaystyle n}\n \n, which amounts to a logarithmic time complexity in the number of amplitudes and thereby the dimension of the input.\nMany QML algorithms in this category are based on variations of the quantum algorithm for linear systems of equations (colloquially called HHL, after the paper's authors) which, under specific conditions, performs a matrix inversion using an amount of physical resources growing only logarithmically in the dimensions of the matrix. One of these conditions is that a Hamiltonian which entry-wise corresponds to the matrix can be simulated efficiently, which is known to be possible if the matrix is sparse or low rank. For reference, any known classical algorithm for matrix inversion requires a number of operations that grows more than quadratically in the dimension of the matrix (e.g. \n \n \n \n O\n \n \n \n (\n \n n\n \n 2.373\n \n \n )\n \n \n \n \n \n {\\displaystyle O{\\mathord {\\left(n^{2.373}\\right)}}}\n \n), but they are not restricted to sparse matrices.\nQuantum matrix inversion can be applied to machine learning methods in which the training reduces to solving a linear system of equations, for example in least-squares linear regression, the least-squares version of support vector machines, and Gaussian processes.\nA crucial bottleneck of methods that simulate linear algebra computations with the amplitudes of quantum states is state preparation, which often requires one to initialise a quantum system in a state whose amplitudes reflect the features of the entire dataset. Although efficient methods for state preparation are known for specific cases, this step easily hides the complexity of the task.\n\n\nVariational quantum algorithms (VQAs)\nIn a variational quantum algorithm (VQA), a classical computer optimizes the parameters used to prepare a quantum state, while a quantum computer is used to do the actual state preparation and measurement. VQAs are considered promising candidates for noisy intermediate-scale quantum computers. Variational quantum circuits (or parameterized quantum circuits) are a popular class of VQAs where the parameters are those used in a fixed quantum circuit. Researchers have studied VQCs to solve optimization problems and find the ground state energy of complex quantum systems, which were difficult to solve using a classical computer.\n\n\nQuantum binary classifier\nPattern reorganization is one of the important tasks of machine learning, binary classification is one of the tools or algorithms to find patterns. Binary classification is used in supervised learning and in unsupervised learning. In QML, classical bits are converted to qubits and they are mapped to Hilbert space; complex value data are used in a quantum binary classifier to use the advantage of Hilbert space. By exploiting the quantum mechanic properties such as superposition, entanglement, interference the quantum binary classifier produces the accurate result in short period of time.\n\n\nQuantum machine learning algorithms based on Grover search\nAnother approach to improving classical machine learning with quantum information processing uses amplitude amplification methods based on Grover's search algorithm, which has been shown to solve unstructured search problems with a quadratic speedup compared to classical algorithms. These quantum routines can be employed for learning algorithms that translate into an unstructured search task, as can be done, for instance, in the case of the k-medians and the k-nearest neighbors algorithms. Other applications include quadratic speedups in the training of perceptrons.\nAn example of amplitude amplification being used in a machine learning algorithm is Grover's search algorithm minimization. In which a subroutine uses Grover's search algorithm to find an element less than some previously defined element. This can be done with an oracle that determines whether or not a state with a corresponding element is less than the predefined one. Grover's algorithm can then find an element such that our condition is met. The minimization is initialized by some random element in our data set, and iteratively does this subroutine to find the minimum element in the data set. This minimization is notably used in quantum k-medians, and it has a speedup of at least \n \n \n \n \n \n O\n \n \n \n (\n \n \n \n n\n k\n \n \n \n )\n \n \n \n {\\displaystyle {\\mathcal {O}}\\left({\\sqrt {\\frac {n}{k}}}\\right)}\n \n compared to classical versions of k-medians, where \n \n \n \n n\n \n \n {\\displaystyle n}\n \n is the number of data points and \n \n \n \n k\n \n \n {\\displaystyle k}\n \n is the number of clusters.\nAmplitude amplification is often combined with quantum walks to achieve the same quadratic speedup. Quantum walks have been proposed to enhance Google's PageRank algorithm as well as the performance of reinforcement learning agents in the projective simulation framework.\n\n\nQuantum-enhanced reinforcement learning\nIn quantum-enhanced reinforcement learning, a quantum agent interacts with a classical or quantum environment and occasionally receives rewards for its actions. In some situations, either because of the quantum processing capability of the agent, or due to the possibility to probe the environment in superpositions, a quantum speedup may be achieved. Implementations of these kinds of protocols have been proposed for systems of trapped ions and superconducting circuits. A quantum speedup of the agent's internal decision-making time has been experimentally demonstrated in trapped ions, while a quantum speedup of the learning time in a fully coherent (`quantum') interaction between agent and environment has been experimentally realized in a photonic setup.\n\n\nQuantum annealing\n\nQuantum annealing is an optimization technique used to determine the local minima and maxima of a function over a given set of candidate functions. This is a method of discretizing a function with many local minima or maxima in order to determine the observables of the function. The process can be distinguished from Simulated annealing by the Quantum tunneling process, by which particles tunnel through kinetic or potential barriers from a high state to a low state. Quantum annealing starts from a superposition of all possible states of a system, weighted equally. Then the time-dependent Schrödinger equation guides the time evolution of the system, serving to affect the amplitude of each state as time increases. Eventually, the ground state can be reached to yield the instantaneous Hamiltonian of the system.\n\n\nQuantum sampling techniques\nSampling from high-dimensional probability distributions is at the core of a wide spectrum of computational techniques with important applications across science, engineering, and society. Examples include deep learning, probabilistic programming, and other machine learning and artificial intelligence applications.\nA computationally hard problem, which is key for some relevant machine learning tasks, is the estimation of averages over probabilistic models defined in terms of a Boltzmann distribution. Sampling from generic probabilistic models is hard: algorithms relying heavily on sampling are expected to remain intractable no matter how large and powerful classical computing resources become. Even though quantum annealers, like those produced by D-Wave Systems, were designed for challenging combinatorial optimization problems, it has been recently recognized as a potential candidate to speed up computations that rely on sampling by exploiting quantum effects.\nSome research groups have recently explored the use of quantum annealing hardware for training Boltzmann machines and deep neural networks. The standard approach to training Boltzmann machines relies on the computation of certain averages that can be estimated by standard sampling techniques, such as Markov chain Monte Carlo algorithms. Another possibility is to rely on a physical process, like quantum annealing, that naturally generates samples from a Boltzmann distribution. The objective is to find the optimal control parameters that best represent the empirical distribution of a given dataset.\nThe D-Wave 2X system hosted at NASA Ames Research Center has been recently used for the learning of a special class of restricted Boltzmann machines that can serve as a building block for deep learning architectures. Complementary work that appeared roughly simultaneously showed that quantum annealing can be used for supervised learning in classification tasks. The same device was later used to train a fully connected Boltzmann machine to generate, reconstruct, and classify down-scaled, low-resolution handwritten digits, among other synthetic datasets. In both cases, the models trained by quantum annealing had a similar or better performance in terms of quality. The ultimate question that drives this endeavour is whether there is quantum speedup in sampling applications. Experience with the use of quantum annealers for combinatorial optimization suggests the answer is not straightforward. Reverse annealing has been used as well to solve a fully connected quantum restricted Boltzmann machine.\nInspired by the success of Boltzmann machines based on classical Boltzmann distribution, a new machine learning approach based on quantum Boltzmann distribution of a transverse-field Ising Hamiltonian was recently proposed. Due to the non-commutative nature of quantum mechanics, the training process of the quantum Boltzmann machine can become nontrivial. This problem was, to some extent, circumvented by introducing bounds on the quantum probabilities, allowing the authors to train the model efficiently by sampling. It is possible that a specific type of quantum Boltzmann machine has been trained in the D-Wave 2X by using a learning rule analogous to that of classical Boltzmann machines.\nQuantum annealing is not the only technology for sampling. In a prepare-and-measure scenario, a universal quantum computer prepares a thermal state, which is then sampled by measurements. This can reduce the time required to train a deep restricted Boltzmann machine, and provide a richer and more comprehensive framework for deep learning than classical computing. The same quantum methods also permit efficient training of full Boltzmann machines and multi-layer, fully connected models and do not have well-known classical counterparts. Relying on an efficient thermal state preparation protocol starting from an arbitrary state, quantum-enhanced Markov logic networks exploit the symmetries and the locality structure of the probabilistic graphical model generated by a first-order logic template. This provides an exponential reduction in computational complexity in probabilistic inference, and, while the protocol relies on a universal quantum computer, under mild assumptions it can be embedded on contemporary quantum annealing hardware.\n\n\nQuantum neural networks\n\nQuantum analogues or generalizations of classical neural nets are often referred to as quantum neural networks. The term is claimed by a wide range of approaches, including the implementation and extension of neural networks using photons, layered variational circuits or quantum Ising-type models.\n\n\nQuantum convolution neural network (QCNN)\nA novel design for multi-dimensional vectors that uses circuits as convolution filters is QCNN. It was inspired by the advantages of CNNs and the power of QML. It is made using a combination of a variational quantum circuit (VQC) and a deep neural network(DNN), fully utilizing the power of extremely parallel processing on a superposition of a quantum state with a finite number of qubits. The main strategy is to carry out an iterative optimization process in the NISQ devices, without the negative impact of noise, which is possibly incorporated into the circuit parameter, and without the need for quantum error correction.\nThe quantum circuit must effectively handle spatial information in order for QCNN to function as CNN. The convolution filter is the most basic technique for making use of spatial information. One or more quantum convolutional filters make up a quantum convolutional neural network (QCNN), and each of these filters transforms input data using a quantum circuit that can be created in an organized or randomized way. Three parts that make up the quantum convolutional filter are: the encoder, the parameterized quantum circuit (PQC), and the measurement. The quantum convolutional filter can be seen as an extension of the filter in the traditional CNN because it was designed with trainable parameters.\nQuantum neural networks take advantage of the hierarchical structures, and for each subsequent layer, the number of qubits from the preceding layer is decreased by a factor of two. For n input qubits, these structures have O(log(n)) layers, allowing for shallow circuit depth. Additionally, they are able to avoid \"barren plateau,\" one of the most significant issues with PQC-based algorithms, ensuring trainability. Despite the fact that the QCNN model does not include the corresponding quantum operation, the fundamental idea of the pooling layer is also offered to assure validity. In QCNN architecture, the pooling layer is typically placed between succeeding convolutional layers. Its function is to shrink the representation's spatial size while preserving crucial features, which allows it to reduce the number of parameters, streamline network computing, and manage over-fitting. Such a process can be accomplished applying full Tomography on the state to reduce it all the way down to one qubit and then processed it. The most frequently used unit type in the pooling layer is max pooling, although there are other types as well. Similar to conventional feed-forward neural networks, the last module is a fully connected layer with full connections to all activations in the preceding layer. Translational invariance, which requires identical blocks of parameterized quantum gates within a layer, is a distinctive feature of the QCNN architecture.\n\n\nFully quantum machine learning\nIn the most general case of QML, both the learning device and the system under study, as well as their interaction, are fully quantum. This section gives a few examples of results on this topic.\nOne class of problem that can benefit from the fully quantum approach is that of 'learning' unknown quantum states, processes or measurements, in the sense that one can subsequently reproduce them on another quantum system. For example, one may wish to learn a measurement that discriminates between two coherent states, given not a classical description of the states to be discriminated, but instead a set of example quantum systems prepared in these states. The naive approach would be to first extract a classical description of the states and then implement an ideal discriminating measurement based on this information. This would only require classical learning. However, one can show that a fully quantum approach is strictly superior in this case. (This also relates to work on quantum pattern matching.) The problem of learning unitary transformations can be approached in a similar way.\nGoing beyond the specific problem of learning states and transformations, the task of clustering also admits a fully quantum version, wherein both the oracle which returns the distance between data-points and the information processing device which runs the algorithm are quantum. Finally, a general framework spanning supervised, unsupervised and reinforcement learning in the fully quantum setting was introduced in, where it was also shown that the possibility of probing the environment in superpositions permits a quantum speedup in reinforcement learning. Such a speedup in the reinforcement-learning paradigm has been experimentally demonstrated in a photonic setup.\n\n\nExplainable quantum machine learning\nThe need for models that can be understood by humans emerges in QML in analogy to classical machine learning and drives the research field of explainable QML (or XQML in analogy to XAI/XML). These efforts are often also referred to as Interpretable Machine Learning (IML, and by extension IQML). XQML/IQML can be considered as an alternative research direction instead of finding a quantum advantage. For example, XQML has been used in the context of mobile malware detection and classification. Quantum Shapley values have also been proposed to interpret gates within a circuit based on a game-theoretic approach. For this purpose, gates instead of features act as players in a coalitional game with a value function that depends on measurements of the quantum circuit of interest. Additionally, a quantum version of the classical technique known as LIME (Linear Interpretable Model-Agnostic Explanations) has also been proposed, known as Q-LIME.\n\n\nQuantum kernel methods and generative models\nQuantum kernel methods have emerged as particularly promising approaches for near-term applications. Large-scale benchmarking studies encompassing over 20,000 trained models have provided comprehensive insights into the effectiveness of fidelity quantum kernels (FQKs) and projected quantum kernels (PQKs) across diverse classification and regression tasks. These studies have revealed universal patterns that guide effective quantum kernel method design.\nIn the generative modeling domain, quantum generative adversarial networks and quantum circuit Born machines have shown particular promise for tabular data synthesis. Novel quantum generative models for tabular data have demonstrated performance improvements of 8.5% over leading classical models while using only 0.072% of the parameters, indicating significant potential for parameter-efficient learning.\n\n\nClassical learning applied to quantum problems\n\nThe term \"quantum machine learning\" sometimes refers to classical machine learning performed on data from quantum systems. A basic example of this is quantum state tomography, where a quantum state is learned from measurement. Other applications include learning Hamiltonians and automatically generating quantum experiments.\n\n\nQuantum learning theory\nQuantum learning theory pursues a mathematical analysis of the quantum generalizations of classical learning models and of the possible speed-ups or other improvements that they may provide. The framework is very similar to that of classical computational learning theory, but the learner in this case is a quantum information processing device, while the data may be either classical or quantum. Quantum learning theory should be contrasted with the quantum-enhanced machine learning discussed above, where the goal was to consider specific problems and to use quantum protocols to improve the time complexity of classical algorithms for these problems. Although quantum learning theory is still under development, partial results in this direction have been obtained.\nThe starting point in learning theory is typically a concept class, a set of possible concepts. Usually a concept is a function on some domain, such as \n \n \n \n {\n 0\n ,\n 1\n \n }\n \n n\n \n \n \n \n {\\displaystyle \\{0,1\\}^{n}}\n \n. For example, the concept class could be the set of disjunctive normal form (DNF) formulas on n bits or the set of Boolean circuits of some constant depth. The goal for the learner is to learn (exactly or approximately) an unknown target concept from this concept class. The learner may be actively interacting with the target concept, or passively receiving samples from it.\nIn active learning, a learner can make membership queries to the target concept c, asking for its value c(x) on inputs x chosen by the learner. The learner then has to reconstruct the exact target concept, with high probability. In the model of quantum exact learning, the learner can make membership queries in quantum superposition. If the complexity of the learner is measured by the number of membership queries it makes, then quantum exact learners can be polynomially more efficient than classical learners for some concept classes, but not more. If complexity is measured by the amount of time the learner uses, then there are concept classes that can be learned efficiently by quantum learners but not by classical learners (under plausible complexity-theoretic assumptions).\nA natural model of passive learning is Valiant's probably approximately correct (PAC) learning. Here the learner receives random examples (x,c(x)), where x is distributed according to some unknown distribution D. The learner's goal is to output a hypothesis function h such that h(x)=c(x) with high probability when x is drawn according to D. The learner has to be able to produce such an 'approximately correct' h for every D and every target concept c in its concept class. We can consider replacing the random examples by potentially more powerful quantum examples \n \n \n \n \n ∑\n \n x\n \n \n \n \n D\n (\n x\n )\n \n \n \n |\n \n x\n ,\n c\n (\n x\n )\n ⟩\n \n \n {\\displaystyle \\sum _{x}{\\sqrt {D(x)}}|x,c(x)\\rangle }\n \n. In the PAC model (and the related agnostic model), this doesn't significantly reduce the number of examples needed: for every concept class, classical and quantum sample complexity are the same up to constant factors. However, for learning under some fixed distribution D, quantum examples can be very helpful, for example for learning DNF under the uniform distribution. When considering time complexity, there exist concept classes that can be PAC-learned efficiently by quantum learners, even from classical examples, but not by classical learners (again, under plausible complexity-theoretic assumptions).\nThis passive learning type is also the most common scheme in supervised learning: a learning algorithm typically takes the training examples fixed, without the ability to query the label of unlabelled examples. Outputting a hypothesis h is a step of induction. Classically, an inductive model splits into a training and an application phase: the model parameters are estimated in the training phase, and the learned model is applied an arbitrary many times in the application phase. In the asymptotic limit of the number of applications, this splitting of phases is also present with quantum resources.\n\n\nImplementations and experiments\nThe earliest experiments were conducted using the adiabatic D-Wave quantum computer, for instance, to detect cars in digital images using regularized boosting with a nonconvex objective function in a demonstration in 2009. Many experiments followed on the same architecture, and leading tech companies have shown interest in the potential of QML for future technological implementations. In 2013, Google Research, NASA, and the Universities Space Research Association launched the Quantum Artificial Intelligence Lab which explores the use of the adiabatic D-Wave quantum computer. A more recent example trained a probabilistic generative models with arbitrary pairwise connectivity, showing that their model is capable of generating handwritten digits as well as reconstructing noisy images of bars and stripes and handwritten digits.\nUsing a different annealing technology based on nuclear magnetic resonance (NMR), a quantum Hopfield network was implemented in 2009 that mapped the input data and memorized data to Hamiltonians, allowing the use of adiabatic quantum computation. NMR technology also enables universal quantum computing, and it was used for the first experimental implementation of a quantum support vector machine to distinguish the handwritten numbers '6' and '9' on a liquid-state quantum computer in 2015. The training data involved the pre-processing of the image which maps them to normalized 2-dimensional vectors to represent the images as the states of a qubit. The two entries of the vector are the vertical and horizontal ratio of the pixel intensity of the image. Once the vectors are defined on the feature space, the quantum support vector machine was implemented to classify the unknown input vector. The readout avoids costly quantum tomography by reading out the final state in terms of direction (up/down) of the NMR signal.\nPhotonic implementations are attracting more attention, not the least because they do not require extensive cooling. Simultaneous spoken digit and speaker recognition and chaotic time-series prediction were demonstrated at data rates beyond 1 gigabyte per second in 2013. Using non-linear photonics to implement an all-optical linear classifier, a perceptron model was capable of learning the classification boundary iteratively from training data through a feedback rule. A core building block in many learning algorithms is to calculate the distance between two vectors: this was first experimentally demonstrated for up to eight dimensions using entangled qubits in a photonic quantum computer in 2015.\nRecently, based on a neuromimetic approach, a novel ingredient has been added to the field of QML, in the form of a so-called quantum memristor, a quantized model of the standard classical memristor. This device can be constructed by means of a tunable resistor, weak measurements on the system, and a classical feed-forward mechanism. An implementation of a quantum memristor in superconducting circuits has been proposed, and an experiment with quantum dots performed. A quantum memristor would implement nonlinear interactions in the quantum dynamics which would aid the search for a fully functional quantum neural network.\nSince 2016, IBM has launched an online cloud-based platform for quantum software developers, called the IBM Q Experience. This platform consists of several fully operational quantum processors accessible via the IBM Web API. In doing so, the company is encouraging software developers to pursue new algorithms through a development environment with quantum capabilities. New architectures are being explored on an experimental basis, up to 32 qubits, using both trapped-ion and superconductive quantum computing methods.\nIn October 2019, it was noted that the introduction of Quantum Random Number Generators (QRNGs) to machine learning models including Neural Networks and Convolutional Neural Networks for random initial weight distribution and Random Forests for splitting processes had a profound effect on their ability when compared to the classical method of Pseudorandom Number Generators (PRNGs). However, in a more recent publication from 2021, these claims could not be reproduced for Neural Network weight initialization and no significant advantage of using QRNGs over PRNGs was found. The work also demonstrated that the generation of fair random numbers with a gate quantum computer is a non-trivial task on NISQ devices, and QRNGs are therefore typically much more difficult to use in practice than PRNGs.\nA paper published in December 2018 reported on an experiment using a trapped-ion system demonstrating a quantum speedup of the deliberation time of reinforcement learning agents employing internal quantum hardware.\nIn March 2021, a team of researchers from Austria, The Netherlands, the US and Germany reported the experimental demonstration of a quantum speedup of the learning time of reinforcement learning agents interacting fully quantumly with the environment. The relevant degrees of freedom of both agent and environment were realized on a compact and fully tunable integrated nanophotonic processor.\nOn April 14, 2026, Nvidia launched \"Ising,\" a family of open-source AI models designed to accelerate quantum computing development. The suite includes Ising-Calibration-1, a vision-language model for automating QPU calibration, and Ising-Decoding, which utilizes 3D CNNs to improve quantum error correction speeds by up to 2.5x.\n\n\nBarren plateau problem\nThe barren plateau problem where quantum algorithms encounter flat optimization landscapes—has seen significant theoretical and practical advances in 2025. Los Alamos National Laboratory researchers have provided the first mathematical characterization of why and when barren plateaus occur in variational quantum algorithms, establishing theoretical guarantees for algorithm scalability.\nThis work solves a key usability problem for quantum machine learning by providing rigorous theorems that predict whether a given architecture will remain trainable as it scales to larger quantum systems. The breakthrough eliminates the previous trial-and-error approach that had led to researcher fatigue in the field.\n\n\nSkepticism\nWhile machine learning itself is now not only a research field but an economically significant and fast growing industry and quantum computing is a well established field of both theoretical and experimental research, QML remains a theoretical field of studies. Further, another obstacle exists at the prediction stage because the outputs of quantum learning models are inherently random. This creates an often considerable overhead, as many executions of a quantum learning model have to be aggregated to obtain an actual prediction.\nMany of the leading scientists that extensively publish in the field of QML warn about the extensive hype around the topic and are very restrained if asked about its practical uses in the foreseeable future. Sophia Chen collected in 2020 some of the statements made by well known scientists in the field:\n\n\"I think we haven't done our homework yet. This is an extremely new scientific field\" - physicist Maria Schuld of Canada-based quantum computing startup Xanadu.\n\"When mixing machine learning with 'quantum,' you catalyse a hype-condensate.\" - Jacob Biamonte a contributor to the theory of quantum computation.\n\"There is a lot more work that needs to be done before claiming quantum machine learning will actually work\" - computer scientist Iordanis Kerenidis, the head of quantum algorithms at the Silicon Valley-based quantum computing startup QC Ware.\n\"I have not seen a single piece of evidence that there exists a meaningful [machine learning] task for which it would make sense to use a quantum computer and not a classical computer\" - physicist Ryan Sweke of the Free University of Berlin in Germany.\n\n\nSee also\nDifferentiable programming\nQuantum computing\nQuantum algorithm for linear systems of equations\nQuantum annealing\nQuantum neural network\nQuantum image\n\n\nReferences", "categories": ["All articles needing rewrite", "All articles with unsourced statements", "Articles with short description", "Articles with unsourced statements from February 2017", "CS1 errors: deprecated parameters", "CS1 maint: multiple names: authors list", "Machine learning", "Quantum information science", "Quantum programming", "Short description is different from Wikidata", "Theoretical computer science", "Wikipedia articles needing rewrite from July 2023"], "references": ["http://static.googleusercontent.com/media/www.google.com/de//googleblogs/pdfs/nips_demoreport_120709_research.pdf", "http://www.sciencedirect.com/science/book/9780128009536", "https://plus.google.com/+QuantumAILab", "https://ti.arc.nasa.gov/tech/dash/physics/quail/", "https://papers.nips.cc/paper/6401-quantum-perceptron-models", "https://zenodo.org/record/1259293", "https://ui.adsabs.harvard.edu/abs/2015ConPh..56..172S", "https://ui.adsabs.harvard.edu/abs/2014NJPh...16j3014Y", "https://ui.adsabs.harvard.edu/abs/2016PhRvL.116i0405K", "https://ui.adsabs.harvard.edu/abs/2016NJPh...18g3033K", "https://ui.adsabs.harvard.edu/abs/2016PhRvL.117m0501D", "https://ui.adsabs.harvard.edu/abs/2014PhRvL.113m0503R", "https://ui.adsabs.harvard.edu/abs/2012PhRvL.109e0505W", "https://ui.adsabs.harvard.edu/abs/2016PhRvA..94b2342S", "https://ui.adsabs.harvard.edu/abs/2009PhRvL.103o0502H"], "images": [], "sub_niche": "Adversarial machine learning"} {"title": "Deep learning", "url": "https://en.wikipedia.org/wiki/Deep_learning", "summary": "In machine learning, deep learning (DL) focuses on utilizing multilayered neural networks to perform tasks such as classification, regression, and representation learning. The field takes inspiration from biological neuroscience and revolves around stacking artificial neurons into layers and \"training\" them to process data. The adjective \"deep\" refers to the use of multiple layers (ranging from three to several hundred or thousands) in the network. Methods used can be supervised, semi-supervised or unsupervised.\nSome common deep learning network architectures include fully connected networks, deep belief networks, recurrent neural networks, recurrent Random neural networks, convolutional neural networks, generative adversarial networks, transformers, and neural radiance fields. These archi", "content": "In machine learning, deep learning (DL) focuses on utilizing multilayered neural networks to perform tasks such as classification, regression, and representation learning. The field takes inspiration from biological neuroscience and revolves around stacking artificial neurons into layers and \"training\" them to process data. The adjective \"deep\" refers to the use of multiple layers (ranging from three to several hundred or thousands) in the network. Methods used can be supervised, semi-supervised or unsupervised.\nSome common deep learning network architectures include fully connected networks, deep belief networks, recurrent neural networks, recurrent Random neural networks, convolutional neural networks, generative adversarial networks, transformers, and neural radiance fields. These architectures have been applied to fields including computer vision, speech recognition, natural language processing, machine translation, bioinformatics, drug design, medical image analysis, climate science, material inspection and board game programs, where they have produced results comparable to and in some cases surpassing human expert performance.\nEarly forms of neural networks were inspired by information processing and distributed communication nodes in biological systems, particularly the human brain. However, current neural networks do not intend to model the brain function of organisms, and are generally seen as low-quality models for that purpose.\n\n\nOverview\nMost modern deep learning models are based on multi-layered neural networks such as convolutional neural networks and transformers, although they can also include propositional formulas or latent variables organized layer-wise in deep generative models such as the nodes in deep belief networks and deep Boltzmann machines.\nFundamentally, deep learning refers to a class of machine learning algorithms in which a hierarchy of layers is used to transform input data into a progressively more abstract and composite representation. For example, in an image recognition model, the raw input may be an image (represented as a tensor of pixels). The first representational layer may attempt to identify basic shapes such as lines and circles, the second layer may compose and encode arrangements of edges, the third layer may encode a nose and eyes, and the fourth layer may recognize that the image contains a face.\nImportantly, a deep learning process can learn which features to optimally place at which level on its own. Prior to deep learning, machine learning techniques often involved hand-crafted feature engineering to transform the data into a more suitable representation for a classification algorithm to operate on. In the deep learning approach, features are not hand-crafted and the model discovers useful feature representations from the data automatically. This does not eliminate the need for hand-tuning; for example, varying numbers of layers and layer sizes can provide different degrees of abstraction.\nThe word \"deep\" in \"deep learning\" refers to the number of layers through which the data is transformed. More precisely, deep learning systems have a substantial credit assignment path (CAP) depth. The CAP is the chain of transformations from input to output. CAPs describe potentially causal connections between input and output. For a feedforward neural network, the depth of the CAPs is that of the network and is the number of hidden layers plus one (as the output layer is also parameterized). For recurrent neural networks, in which a signal may propagate through a layer more than once, the CAP depth is potentially unlimited. No universally agreed-upon threshold of depth divides shallow learning from deep learning, but most researchers agree that deep learning involves CAP depth higher than two. CAP of depth two has been shown to be a universal approximator in the sense that it can emulate any function. Beyond that, more layers do not add to the function approximator ability of the network. Deep models (CAP > two) are able to extract better features than shallow models and hence, extra layers help in learning the features effectively.\nDeep learning architectures can be constructed with a greedy layer-by-layer method. Deep learning helps to disentangle these abstractions and pick out which features improve performance.\nDeep learning algorithms can be applied to unsupervised learning tasks. This is an important benefit because unlabeled data is more abundant than labeled data. Examples of deep structures that can be trained in an unsupervised manner are deep belief networks.\nThe term deep learning was introduced to the machine learning community by Rina Dechter in 1986, and to artificial neural networks by Igor Aizenberg and colleagues in 2000, in the context of Boolean threshold neurons. The etymology of the term is more complicated.\n\n\nInterpretations\nDeep neural networks are generally interpreted in terms of the universal approximation theorem or probabilistic inference.\nThe classic universal approximation theorem concerns the capacity of feedforward neural networks with a single hidden layer of finite size to approximate continuous functions. In 1989, the first proof was published by George Cybenko for sigmoid activation functions and was generalised to feed-forward multi-layer architectures in 1991 by Kurt Hornik. Recent work also showed that universal approximation also holds for non-bounded activation functions such as Kunihiko Fukushima's rectified linear unit.. In it was shown that the Random neural network is also a universal approximator for continuous and bounded functions.\n\nThe universal approximation theorem for deep neural networks concerns the capacity of networks with bounded width but the depth is allowed to grow. Lu et al. proved that if the width of a deep neural network with ReLU activation is strictly larger than the input dimension, then the network can approximate any Lebesgue integrable function; if the width is smaller or equal to the input dimension, then a deep neural network is not a universal approximator. \nThe probabilistic interpretation derives from the field of machine learning. It features inference, as well as the optimization concepts of training and testing, related to fitting and generalization, respectively. More specifically, the probabilistic interpretation considers the activation nonlinearity as a cumulative distribution function. The probabilistic interpretation led to the introduction of dropout as regularizer in neural networks. The probabilistic interpretation was introduced by researchers including Hopfield, Widrow and Narendra and popularized in surveys such as the one by Bishop.\n\n\nHistory\n\n\nBefore 1980\nThere are two types of artificial neural network (ANN): feedforward neural network (FNN) or multilayer perceptron (MLP) and recurrent neural networks (RNN). RNNs have cycles in their connectivity structure, whereas FNNs do not. In the 1920s, Wilhelm Lenz and Ernst Ising created the Ising model which is essentially a non-learning RNN architecture consisting of neuron-like threshold elements. In 1972, Shun'ichi Amari made this architecture adaptive. His learning RNN was republished by John Hopfield in 1982. Other early recurrent neural networks were published by Kaoru Nakano in 1971. Already in 1948, Alan Turing produced work on \"Intelligent Machinery\" that was not published in his lifetime, containing \"ideas related to artificial evolution and learning RNNs\".\nFrank Rosenblatt (1958) proposed the perceptron, an MLP with 3 layers: an input layer, a hidden layer with randomized weights that did not learn, and an output layer. He later published a 1962 book that also introduced variants and computer experiments, including a version with four-layer perceptrons \"with adaptive preterminal networks\" where the last two layers have learned weights (here he credits H. D. Block and B. W. Knight). The book cites an earlier network by R. D. Joseph (1960) \"functionally equivalent to a variation of\" this four-layer system (the book mentions Joseph over 30 times). Should Joseph therefore be considered the originator of proper adaptive multilayer perceptrons with learning hidden units? Unfortunately, the learning algorithm was not a functional one, and fell into oblivion.\nThe first working deep learning algorithm was the Group method of data handling, a method to train arbitrarily deep neural networks, published by Alexey Ivakhnenko and Lapa in 1965. They regarded it as a form of polynomial regression, or a generalization of Rosenblatt's perceptron to handle more complex, nonlinear, and hierarchical relationships. A 1971 paper described a deep network with eight layers trained by this method, which is based on layer by layer training through regression analysis. Superfluous hidden units are pruned using a separate validation set. Since the activation functions of the nodes are Kolmogorov-Gabor polynomials, these were also the first deep networks with multiplicative units or \"gates\".\nThe first deep learning multilayer perceptron trained by stochastic gradient descent was published in 1967 by Shun'ichi Amari. In computer experiments conducted by Amari's student Saito, a five layer MLP with two modifiable layers learned internal representations to classify non-linearily separable pattern classes. Subsequent developments in hardware and hyperparameter tunings have made end-to-end stochastic gradient descent the currently dominant training technique.\nIn 1969, Kunihiko Fukushima introduced the ReLU (rectified linear unit) activation function. The rectifier has become the most popular activation function for deep learning.\nDeep learning architectures for convolutional neural networks (CNNs) with convolutional layers and downsampling layers began with the Neocognitron introduced by Kunihiko Fukushima in 1979, though not trained by backpropagation.\nBackpropagation is an efficient application of the chain rule to networks of differentiable nodes. The terminology \"back-propagating errors\" was actually introduced in 1962 by Rosenblatt, but he did not know how to implement this, although Henry J. Kelley had a continuous precursor of backpropagation in 1960 in the context of control theory. The modern form of backpropagation was first published in Seppo Linnainmaa's master thesis (1970). G.M. Ostrovski et al. republished it in 1971. Paul Werbos applied backpropagation to neural networks in 1982 (his 1974 PhD thesis, reprinted in a 1994 book, did not yet describe the algorithm). In 1986, David E. Rumelhart et al. popularised backpropagation but did not cite the original work.\n\n\n1980s-2000s\nThe time delay neural network (TDNN) was introduced in 1987 by Alex Waibel to apply CNN to phoneme recognition. It used convolutions, weight sharing, and backpropagation. In 1988, Wei Zhang applied a backpropagation-trained CNN to alphabet recognition. \nIn 1989, Yann LeCun et al. created a CNN called LeNet for recognizing handwritten ZIP codes on mail. Training required 3 days. In 1990, Wei Zhang implemented a CNN on optical computing hardware. In 1991, a CNN was applied to medical image object segmentation and breast cancer detection in mammograms. LeNet-5 (1998), a 7-level CNN by Yann LeCun et al., that classifies digits, was applied by several banks to recognize hand-written numbers on checks digitized in 32x32 pixel images.\nRecurrent neural networks (RNN) were further developed in the 1980s. Recurrence is used for sequence processing, and when a recurrent network is unrolled, it mathematically resembles a deep feedforward layer. Consequently, they have similar properties and issues, and their developments had mutual influences. In RNN, two early influential works were the Jordan network (1986), the Elman network (1990), which applied RNN to study problems in cognitive psychology.\nThe recurrent Random neural network introduced by Erol Gelenbe (1989) was inspired by the stochastic spiking behaviour of mammalian brain neurons, and \n.\nIt was proved to have a convergent stable state that allowed the development of a simple deep learning gradient algorithm\nfor this recurrent network . It\nhas had numerous applications, including for brain tumor detection from MR images using texture-based segmentation\n and\nreal-time video compression\n. Gelenbe also developed its\nreinforcement learning algorithm, allowing the Random neural network to be used effectively for\npacket network routing that is interoperable and compatible with the existing Internet protocol\n\n.\nIn recent years, new developments of the Random neural network \nthat have large and dense clusters of recurrent neurons with Deep Learning,\nhave resulted in highly accurate algorithms for cyberattack detection and mitigation \n\n, as well as for the real-time control of\nsmart homes.\nIn the 1980s, backpropagation did not work well for deep learning with long credit assignment paths. To overcome this problem, in 1991, Jürgen Schmidhuber proposed a hierarchy of RNNs pre-trained one level at a time by self-supervised learning where each RNN tries to predict its own next input, which is the next unexpected input of the RNN below. This \"neural history compressor\" uses predictive coding to learn internal representations at multiple self-organizing time scales. This can substantially facilitate downstream deep learning. The RNN hierarchy can be collapsed into a single RNN, by distilling a higher level chunker network into a lower level automatizer network. In 1993, a neural history compressor solved a \"Very Deep Learning\" task that required more than 1000 subsequent layers in an RNN unfolded in time. The \"P\" in ChatGPT refers to such pre-training.\nSepp Hochreiter's diploma thesis (1991) implemented the neural history compressor, and identified and analyzed the vanishing gradient problem. Hochreiter proposed recurrent residual connections to solve the vanishing gradient problem. This led to the long short-term memory (LSTM), published in 1995. LSTM can learn \"very deep learning\" tasks with long credit assignment paths that require memories of events that happened thousands of discrete time steps before. That LSTM was not yet the modern architecture, which required a \"forget gate\", introduced in 1999, which became the standard RNN architecture.\nIn 1991, Jürgen Schmidhuber also published adversarial neural networks that contest with each other in the form of a zero-sum game, where one network's gain is the other network's loss. The first network is a generative model that models a probability distribution over output patterns. The second network learns by gradient descent to predict the reactions of the environment to these patterns. This was called \"artificial curiosity\". In 2014, this principle was used in generative adversarial networks (GANs).\nDuring 1985–1995, inspired by statistical mechanics, several architectures and methods were developed by Terry Sejnowski, Peter Dayan, Geoffrey Hinton, etc., including the Boltzmann machine, restricted Boltzmann machine, Helmholtz machine, and the wake-sleep algorithm. These were designed for unsupervised learning of deep generative models. However, those were more computationally expensive compared to backpropagation. Boltzmann machine learning algorithm, published in 1985, was briefly popular before being eclipsed by the backpropagation algorithm in 1986. (p. 112 ). A 1988 network became state of the art in protein structure prediction, an early application of deep learning to bioinformatics.\nBoth shallow and deep learning (e.g., recurrent nets) of ANNs for speech recognition have been explored for many years. These methods never outperformed non-uniform internal-handcrafting Gaussian mixture model/Hidden Markov model (GMM-HMM) technology based on generative models of speech trained discriminatively. Key difficulties have been analyzed, including gradient diminishing and weak temporal correlation structure in neural predictive models. Additional difficulties were the lack of training data and limited computing power.\nMost speech recognition researchers moved away from neural nets to pursue generative modeling. An exception was at SRI International in the late 1990s. Funded by the US government's NSA and DARPA, SRI researched in speech and speaker recognition. The speaker recognition team led by Larry Heck reported significant success with deep neural networks in speech processing in the 1998 NIST Speaker Recognition benchmark. It was deployed in the Nuance Verifier, representing the first major industrial application of deep learning.\nThe principle of elevating \"raw\" features over hand-crafted optimization was first explored successfully in the architecture of deep autoencoder on the \"raw\" spectrogram or linear filter-bank features in the late 1990s, showing its superiority over the Mel-Cepstral features that contain stages of fixed transformation from spectrograms. The raw features of speech, waveforms, later produced excellent larger-scale results.\n\n\n2000s\nNeural networks entered a lull, and simpler models that use task-specific handcrafted features such as Gabor filters and support vector machines (SVMs) became the preferred choices in the 1990s and 2000s, because of artificial neural networks' computational cost and a lack of understanding of how the brain wires its biological networks.\nIn 2003, LSTM became competitive with traditional speech recognizers on certain tasks. In 2006, Alex Graves, Santiago Fernández, Faustino Gomez, and Schmidhuber combined it with connectionist temporal classification (CTC) in stacks of LSTMs. In 2009, it became the first RNN to win a pattern recognition contest, in connected handwriting recognition.\nIn 2006, publications by Geoff Hinton, Ruslan Salakhutdinov, Osindero and Teh deep belief networks were developed for generative modeling. They are trained by training one restricted Boltzmann machine, then freezing it and training another one on top of the first one, and so on, then optionally fine-tuned using supervised backpropagation. They could model high-dimensional probability distributions, such as the distribution of MNIST images, but convergence was slow.\nThe impact of deep learning in industry began in the early 2000s, when CNNs already processed an estimated 10% to 20% of all the checks written in the US, according to Yann LeCun. Industrial applications of deep learning to large-scale speech recognition started around 2010.\nThe 2009 NIPS Workshop on Deep Learning for Speech Recognition was motivated by the limitations of deep generative models of speech, and the possibility that given more capable hardware and large-scale data sets that deep neural nets might become practical. It was believed that pre-training DNNs using generative models of deep belief nets (DBN) would overcome the main difficulties of neural nets. However, it was discovered that replacing pre-training with large amounts of training data for straightforward backpropagation when using DNNs with large, context-dependent output layers produced error rates dramatically lower than then-state-of-the-art Gaussian mixture model (GMM)/Hidden Markov Model (HMM) and also than more-advanced generative model-based systems. The nature of the recognition errors produced by the two types of systems was characteristically different, offering technical insights into how to integrate deep learning into the existing highly efficient, run-time speech decoding system deployed by all major speech recognition systems. Analysis around 2009–2010, contrasting the GMM (and other generative speech models) vs. DNN models, stimulated early industrial investment in deep learning for speech recognition. That analysis was done with comparable performance (less than 1.5% in error rate) between discriminative DNNs and generative models.\nIn 2010, researchers extended deep learning from TIMIT to large vocabulary speech recognition, by adopting large output layers of the DNN based on context-dependent HMM states constructed by decision trees.\n\n\nDeep learning revolution\n\nThe period of significant growth in both the adoption and performance of deep learning in the 2010s was driven by the emergence of efficient implementations of CNNs on GPU hardware.\nAlthough CNNs trained by backpropagation had been around for decades and GPU implementations of NNs for years, including CNNs, faster implementations of CNNs on GPUs were needed to progress on computer vision. Later, as deep learning becomes widespread, specialized hardware and algorithm optimizations were developed specifically for deep learning.\nA key advance for the deep learning revolution was hardware advances, especially GPU. Some early work dated back to 2004. In 2009, Raina, Madhavan, and Andrew Ng reported a 100M deep belief network trained on 30 Nvidia GeForce GTX 280 GPUs, an early demonstration of GPU-based deep learning. They reported up to 70 times faster training.\nIn 2011, a CNN named DanNet by Dan Ciresan, Ueli Meier, Jonathan Masci, Luca Maria Gambardella, and Jürgen Schmidhuber achieved for the first time superhuman performance in a visual pattern recognition contest, outperforming traditional methods by a factor of 3. It then won more contests. They also showed how max-pooling CNNs on GPU improved performance significantly.\nIn 2012, Andrew Ng and Jeff Dean created an FNN that learned to recognize higher-level concepts, such as cats, only from watching unlabeled images taken from YouTube videos.\nIn October 2012, AlexNet by Alex Krizhevsky, Ilya Sutskever, and Geoffrey Hinton won the large-scale ImageNet competition by a significant margin over shallow machine learning methods. Further incremental improvements included the VGG-16 network by Karen Simonyan and Andrew Zisserman and Google's Inceptionv3.\nIn 2013, Tomáš Mikolov and colleagues developed word2vec, a method for efficiently learning word embeddings from large text corpora. The resulting vector representations were shown to capture syntactic and semantic relationships between words. A subsequent paper introduced negative sampling as an efficient method for training such models. \nThe success in image classification was then extended to the more challenging task of generating descriptions (captions) for images, often as a combination of CNNs and LSTMs.\nIn 2014, the state of the art was training a \"very deep neural network\" with 20 to 30 layers. Stacking too many layers led to a steep reduction in training accuracy, known as the \"degradation\" problem. In 2015, two techniques were developed to train very deep networks: the highway network was published in May 2015, and the residual neural network (ResNet) in Dec 2015. ResNet behaves like an open-gated Highway Net.\nAround the same time, deep learning started impacting the field of art. Early examples included Google DeepDream (2015), and neural style transfer (2015), both of which were based on pretrained image classification neural networks, such as VGG-19.\nGenerative adversarial network (GAN) by (Ian Goodfellow et al., 2014) (based on Jürgen Schmidhuber's principle of artificial curiosity)\nbecame state of the art in generative modeling during 2014-2018 period. Excellent image quality is achieved by Nvidia's StyleGAN (2018) based on the Progressive GAN by Tero Karras et al. Here the GAN generator is grown from small to large scale in a pyramidal fashion. Image generation by GAN reached popular success, and provoked discussions concerning deepfakes. Diffusion models (2015) eclipsed GANs in generative modeling since then, with systems such as DALL·E 2 (2022) and Stable Diffusion (2022).\nIn 2015, Google's speech recognition improved by 49% by an LSTM-based model, which they made available through Google Voice Search on smartphone.\nDeep learning is part of state-of-the-art systems in various disciplines, particularly computer vision and automatic speech recognition (ASR). Results on commonly used evaluation sets such as TIMIT (ASR) and MNIST (image classification), as well as a range of large-vocabulary speech recognition tasks have steadily improved. Convolutional neural networks were superseded for ASR by LSTM. but are more successful in computer vision.\nYoshua Bengio, Geoffrey Hinton and Yann LeCun were awarded the 2018 Turing Award for \"conceptual and engineering breakthroughs that have made deep neural networks a critical component of computing\".\n\n\nNeural networks\n\nArtificial neural networks (ANNs) or connectionist systems are computing systems inspired by the biological neural networks that constitute animal brains. Such systems learn (progressively improve their ability) to do tasks by considering examples, generally without task-specific programming. For example, in image recognition, they might learn to identify images that contain cats by analyzing example images that have been manually labeled as \"cat\" or \"no cat\" and using the analytic results to identify cats in other images. They have found most use in applications difficult to express with a traditional computer algorithm using rule-based programming.\nAn ANN is based on a collection of connected units called artificial neurons, (analogous to biological neurons in a biological brain). Each connection (synapse) between neurons can transmit a signal to another neuron. The receiving (postsynaptic) neuron can process the signal(s) and then signal downstream neurons connected to it. Neurons may have state, generally represented by real numbers, typically between 0 and 1. Neurons and synapses may also have a weight that varies as learning proceeds, which can increase or decrease the strength of the signal that it sends downstream.\nTypically, neurons are organized in layers. Different layers may perform different kinds of transformations on their inputs. Signals travel from the first (input), to the last (output) layer, possibly after traversing the layers multiple times.\nThe original goal of the neural network approach was to solve problems in the same way that a human brain would. Over time, attention focused on matching specific mental abilities, leading to deviations from biology such as backpropagation, or passing information in the reverse direction and adjusting the network to reflect that information.\nNeural networks have been used on a variety of tasks, including computer vision, speech recognition, machine translation, social network filtering, playing board and video games and medical diagnosis.\nAs of 2017, neural networks typically have a few thousand to a few million units and millions of connections. Despite this number being several order of magnitude less than the number of neurons on a human brain, these networks can perform many tasks at a level beyond that of humans (e.g., recognizing faces, or playing \"Go\").\n\n\nDeep neural networks\nA deep neural network (DNN) is an artificial neural network with multiple layers between the input and output layers. There are different types of neural networks but they always consist of the same components: neurons, synapses, weights, biases, and functions. These components as a whole function in a way that mimics functions of the human brain, and can be trained like any other ML algorithm.\nFor example, a DNN that is trained to recognize dog breeds will go over the given image and calculate the probability that the dog in the image is a certain breed. The user can review the results and select which probabilities the network should display (above a certain threshold, etc.) and return the proposed label. Each mathematical manipulation as such is considered a layer, and complex DNN have many layers, hence the name \"deep\" networks.\nDNNs can model complex non-linear relationships. DNN architectures generate compositional models where the object is expressed as a layered composition of primitives. The extra layers enable composition of features from lower layers, potentially modeling complex data with fewer units than a similarly performing shallow network. For instance, it was proved that sparse multivariate polynomials are exponentially easier to approximate with DNNs than with shallow networks.\nDeep architectures include many variants of a few basic approaches. Each architecture has found success in specific domains. It is not always possible to compare the performance of multiple architectures, unless they have been evaluated on the same data sets.\nDNNs are typically feedforward networks in which data flows from the input layer to the output layer without looping back. At first, the DNN creates a map of virtual neurons and assigns random numerical values, or \"weights\", to connections between them. The weights and inputs are multiplied and return an output between 0 and 1. If the network did not accurately recognize a particular pattern, an algorithm would adjust the weights. That way the algorithm can make certain parameters more influential, until it determines the correct mathematical manipulation to fully process the data.\nRecurrent neural networks, in which data can flow in any direction, are used for applications such as language modeling. Long short-term memory is particularly effective for this use.\nConvolutional neural networks (CNNs) are used in computer vision. CNNs also have been applied to acoustic modeling for automatic speech recognition (ASR).\n\n\nChallenges\nAs with ANNs, many issues can arise with naively trained DNNs. Two common issues are overfitting and computation time.\nDNNs are prone to overfitting because of the added layers of abstraction, which allow them to model rare dependencies in the training data. Regularization methods such as Ivakhnenko's unit pruning or weight decay (\n \n \n \n \n ℓ\n \n 2\n \n \n \n \n {\\displaystyle \\ell _{2}}\n \n-regularization) or sparsity (\n \n \n \n \n ℓ\n \n 1\n \n \n \n \n {\\displaystyle \\ell _{1}}\n \n-regularization) can be applied during training to combat overfitting. Alternatively dropout regularization randomly omits units from the hidden layers during training. This helps to exclude rare dependencies. Another interesting recent development is research into models of just enough complexity through an estimation of the intrinsic complexity of the task being modelled. This approach has been successfully applied for multivariate time series prediction tasks such as traffic prediction. Finally, data can be augmented via methods such as cropping and rotating such that smaller training sets can be increased in size to reduce the chances of overfitting.\nDNNs must consider many training parameters, such as the size (number of layers and number of units per layer), the learning rate, and initial weights. Sweeping through the parameter space for optimal parameters may not be feasible due to the cost in time and computational resources. Various tricks, such as batching (computing the gradient on several training examples at once rather than individual examples) speed up computation. Large processing capabilities of many-core architectures (such as GPUs or the Intel Xeon Phi) have produced significant speedups in training, because of the suitability of such processing architectures for the matrix and vector computations.\nAlternatively, engineers may look for other types of neural networks with more straightforward and convergent training algorithms. CMAC (cerebellar model articulation controller) is one such kind of neural network. It doesn't require learning rates or randomized initial weights. The training process can be guaranteed to converge in one step with a new batch of data, and the computational complexity of the training algorithm is linear with respect to the number of neurons involved.\n\n\nHardware\nSince the 2010s, advances in both machine learning algorithms and computer hardware have led to more efficient methods for training deep neural networks that contain many layers of non-linear hidden units and a very large output layer. By 2019, graphics processing units (GPUs), often with AI-specific enhancements, had displaced CPUs as the dominant method for training large-scale commercial cloud AI . OpenAI estimated the hardware computation used in the largest deep learning projects from AlexNet (2012) to AlphaZero (2017) and found a 300,000-fold increase in the amount of computation required, with a doubling-time trendline of 3.4 months.\nSpecial electronic circuits called deep learning processors were designed to speed up deep learning algorithms. Deep learning processors include neural processing units (NPUs) in Huawei cellphones and cloud computing servers such as tensor processing units (TPU) in the Google Cloud Platform. Cerebras Systems has also built a dedicated system to handle large deep learning models, the CS-2, based on the largest processor in the industry, the second-generation Wafer Scale Engine (WSE-2).\nAtomically thin semiconductors are considered promising for energy-efficient deep learning hardware where the same basic device structure is used for both logic operations and data storage.\nIn 2020, Marega et al. published experiments with a large-area active channel material for developing logic-in-memory devices and circuits based on floating-gate field-effect transistors (FGFETs).\nIn 2021, J. Feldmann et al. proposed an integrated photonic hardware accelerator for parallel convolutional processing. The authors identify two key advantages of integrated photonics over its electronic counterparts: (1) massively parallel data transfer through wavelength division multiplexing in conjunction with frequency combs, and (2) extremely high data modulation speeds. Their system can execute trillions of multiply-accumulate operations per second, indicating the potential of integrated photonics in data-heavy AI applications.\n\n\nApplications\n\n\nAutomatic speech recognition\n\nLarge-scale automatic speech recognition is the first and most convincing successful case of deep learning. LSTM RNNs can learn \"Very Deep Learning\" tasks that involve multi-second intervals containing speech events separated by thousands of discrete time steps, where one time step corresponds to about 10 ms. LSTM with forget gates is competitive with traditional speech recognizers on certain tasks.\nThe initial success in speech recognition was based on small-scale recognition tasks based on TIMIT. The data set contains 630 speakers from eight major dialects of American English, where each speaker reads 10 sentences. Its small size lets many configurations be tried. More importantly, the TIMIT task concerns phone-sequence recognition, which, unlike word-sequence recognition, allows weak phone bigram language models. This lets the strength of the acoustic modeling aspects of speech recognition be more easily analyzed. The error rates listed below, including these early results and measured as percent phone error rates (PER), have been summarized since 1991.\n\nThe debut of DNNs for speaker recognition in the late 1990s and speech recognition around 2009-2011 and of LSTM around 2003–2007, accelerated progress in eight major areas:\n\nScale-up/out and accelerated DNN training and decoding\nSequence discriminative training\nFeature processing by deep models with solid understanding of the underlying mechanisms\nAdaptation of DNNs and related deep models\nMulti-task and transfer learning by DNNs and related deep models\nCNNs and how to design them to best exploit domain knowledge of speech\nRNN and its rich LSTM variants\nOther types of deep models including tensor-based models and integrated deep generative/discriminative models.\nMore recent speech recognition models use Transformers or Temporal Convolution Networks with significant success and widespread applications. All major commercial speech recognition systems (e.g., Microsoft Cortana, Xbox, Skype Translator, Amazon Alexa, Google Now, Apple Siri, Baidu and iFlyTek voice search, and a range of Nuance speech products, etc.) are based on deep learning.\n\n\nImage recognition\n\nA common evaluation set for image classification is the MNIST database data set. MNIST is composed of handwritten digits and includes 60,000 training examples and 10,000 test examples. As with TIMIT, its small size lets users test multiple configurations. A comprehensive list of results on this set is available.\nDeep learning-based image recognition has become \"superhuman\", producing more accurate results than human contestants. This first occurred in 2011 in recognition of traffic signs, and in 2014, with recognition of human faces.\nDeep learning-trained vehicles now interpret 360° camera views. Another example is Facial Dysmorphology Novel Analysis (FDNA) used to analyze cases of human malformation connected to a large database of genetic syndromes.\n\n\nVisual art processing\n\nClosely related to the progress that has been made in image recognition is the increasing application of deep learning techniques to various visual art tasks. DNNs have proven themselves capable, for example, of\n\nidentifying the style period of a given painting\nNeural Style Transfer – capturing the style of a given artwork and applying it in a visually pleasing manner to an arbitrary photograph or video\ngenerating striking imagery based on random visual input fields.\n\n\nNatural language processing\n\nNeural networks have been used for implementing language models since the early 2000s. LSTM helped to improve machine translation and language modeling.\nOther key techniques in this field are negative sampling and word embedding. Word embedding, such as word2vec, can be thought of as a representational layer in a deep learning architecture that transforms an atomic word into a positional representation of the word relative to other words in the dataset; the position is represented as a point in a vector space. Using word embedding as an RNN input layer allows the network to parse sentences and phrases using an effective compositional vector grammar. A compositional vector grammar can be thought of as probabilistic context free grammar (PCFG) implemented by an RNN. Recursive auto-encoders built atop word embeddings can assess sentence similarity and detect paraphrasing. Deep neural architectures provide the best results for constituency parsing, sentiment analysis, information retrieval, spoken language understanding, machine translation, contextual entity linking, writing style recognition, named-entity recognition (token classification), text classification, and others.\nRecent developments generalize word embedding to sentence embedding.\nGoogle Translate (GT) uses a large end-to-end long short-term memory (LSTM) network. Google Neural Machine Translation (GNMT) uses an example-based machine translation method in which the system \"learns from millions of examples\". It translates \"whole sentences at a time, rather than pieces\". Google Translate supports over one hundred languages. The network encodes the \"semantics of the sentence rather than simply memorizing phrase-to-phrase translations\". GT uses English as an intermediate between most language pairs.\n\n\nDrug discovery and toxicology\n\nA large percentage of candidate drugs fail to win regulatory approval. These failures are caused by insufficient efficacy (on-target effect), undesired interactions (off-target effects), or unanticipated toxic effects. Research has explored use of deep learning to predict the biomolecular targets, off-targets, and toxic effects of environmental chemicals in nutrients, household products and drugs.\nAtomNet is a deep learning system for structure-based rational drug design. AtomNet was used to predict novel candidate biomolecules for disease targets such as the Ebola virus and multiple sclerosis.\nIn 2017 graph neural networks were used for the first time to predict various properties of molecules in a large toxicology data set. In 2019, generative neural networks were used to produce molecules that were validated experimentally all the way into mice.\n\n\nRecommendation systems\n\nRecommendation systems have used deep learning to extract meaningful features for a latent factor model for content-based music and journal recommendations. Multi-view deep learning has been applied for learning user preferences from multiple domains. The model uses a hybrid collaborative and content-based approach and enhances recommendations in multiple tasks.\n\n\nBioinformatics\n\nAn autoencoder ANN was used in bioinformatics, to predict gene ontology annotations and gene-function relationships.\nIn medical informatics, deep learning was used to predict sleep quality based on data from wearables and predictions of health complications from electronic health record data.\nDeep neural networks have shown unparalleled performance in predicting protein structure, according to the sequence of the amino acids that make it up. In 2020, AlphaFold, a deep-learning based system, achieved a level of accuracy significantly higher than all previous computational methods.\n\n\nDeep Neural Network Estimations\nDeep neural networks can be used to estimate the entropy of a stochastic process through an arrangement called a Neural Joint Entropy Estimator (NJEE). Such an estimation provides insights on the effects of input random variables on an independent random variable. Practically, the DNN is trained as a classifier that maps an input vector or matrix X to an output probability distribution over the possible classes of random variable Y, given input X. For example, in image classification tasks, the NJEE maps a vector of pixels' color values to probabilities over possible image classes. In practice, the probability distribution of Y is obtained by a Softmax layer with number of nodes that is equal to the alphabet size of Y. NJEE uses continuously differentiable activation functions, such that the conditions for the universal approximation theorem holds. It is shown that this method provides a strongly consistent estimator and outperforms other methods in cases of large alphabet sizes.\n\n\nMedical image analysis\nDeep learning has been shown to produce competitive results in medical applications such as cancer cell classification, lesion detection, organ segmentation and image enhancement. Modern deep learning tools demonstrate the high accuracy of detecting various diseases and the helpfulness of their use by specialists to improve the diagnosis efficiency.\n\n\nMobile advertising\nFinding the appropriate mobile audience for mobile advertising is always challenging, since many data points must be considered and analyzed before a target segment can be created and used in ad serving by any ad server. Deep learning has been used to interpret large, many-dimensioned advertising datasets. Many data points are collected during the request/serve/click internet advertising cycle. This information can form the basis of machine learning to improve ad selection.\n\n\nImage restoration\nDeep learning has been successfully applied to inverse problems such as denoising, super-resolution, inpainting, and film colorization. These applications include learning methods such as \"Shrinkage Fields for Effective Image Restoration\" which trains on an image dataset, and Deep Image Prior, which trains on the image that needs restoration.\n\n\nFinancial fraud detection\nDeep learning is being applied to financial fraud detection, tax evasion detection, and anti-money laundering.\n\n\nMaterials science\nIn November 2023, researchers at Google DeepMind and Lawrence Berkeley National Laboratory announced that they had developed an AI system known as GNoME. This system has contributed to materials science by discovering over 2 million new materials within a relatively short timeframe. GNoME employs deep learning techniques to efficiently explore potential material structures, achieving a significant increase in the identification of stable inorganic crystal structures. The system's predictions were validated through autonomous robotic experiments, demonstrating a noteworthy success rate of 71%. The data of newly discovered materials is publicly available through the Materials Project database, offering researchers the opportunity to identify materials with desired properties for various applications. This development has implications for the future of scientific discovery and the integration of AI in material science research, potentially expediting material innovation and reducing costs in product development. The use of AI and deep learning suggests the possibility of minimizing or eliminating manual lab experiments and allowing scientists to focus more on the design and analysis of unique compounds.\n\n\nMilitary\nThe United States Department of Defense applied deep learning to train robots in new tasks through observation.\n\n\nPartial differential equations\nPhysics-informed neural networks have been used to solve partial differential equations in both forward and inverse problems in a data driven manner. One example is the reconstructing fluid flow governed by the Navier-Stokes equations. Using physics informed neural networks does not require the often expensive mesh generation that conventional CFD methods rely on. It is evident that geometric and physical constraints have a synergistic effect on neural PDE surrogates, thereby enhancing their efficacy in predicting stable and super long rollouts.\n\n\nDeep backward stochastic differential equation method\nDeep backward stochastic differential equation method is a numerical method that combines deep learning with Backward stochastic differential equation (BSDE). This method is particularly useful for solving high-dimensional problems in financial mathematics. By leveraging the powerful function approximation capabilities of deep neural networks, deep BSDE addresses the computational challenges faced by traditional numerical methods in high-dimensional settings. Specifically, traditional methods like finite difference methods or Monte Carlo simulations often struggle with the curse of dimensionality, where computational cost increases exponentially with the number of dimensions. Deep BSDE methods, however, employ deep neural networks to approximate solutions of high-dimensional partial differential equations (PDEs), effectively reducing the computational burden.\nIn addition, the integration of Physics-informed neural networks (PINNs) into the deep BSDE framework enhances its capability by embedding the underlying physical laws directly into the neural network architecture. This ensures that the solutions not only fit the data but also adhere to the governing stochastic differential equations. PINNs leverage the power of deep learning while respecting the constraints imposed by the physical models, resulting in more accurate and reliable solutions for financial mathematics problems.\n\n\nImage reconstruction\nImage reconstruction is the reconstruction of the underlying images from the image-related measurements. Several works showed the better and superior performance of the deep learning methods compared to analytical methods for various applications, e.g., spectral imaging and ultrasound imaging.\n\n\nWeather prediction\nTraditional weather prediction systems typically solve a complex system of partial differential equations. GraphCast is a deep learning-based model trained on a long history of weather data to predict how weather patterns change over time. It can predict weather conditions for up to 10 days globally, at a very detailed level, and in under a minute, with precision similar to state of the art systems.\n\n\nEpigenetic clock\n\nAn epigenetic clock is a biochemical test that can be used to measure age. Galkin et al. used deep neural networks to train an epigenetic aging clock of unprecedented accuracy using >6,000 blood samples. The clock uses information from 1000 CpG sites and predicts people with certain conditions older than healthy controls: IBD, frontotemporal dementia, ovarian cancer, obesity. The aging clock was planned to be released for public use in 2021 by an Insilico Medicine spinoff company Deep Longevity.\n\n\nRelation to human cognitive and brain development\nDeep learning is closely related to a class of theories of brain development (specifically, neocortical development) proposed by cognitive neuroscientists in the early 1990s. These developmental theories were instantiated in computational models, making them predecessors of deep learning systems. These developmental models share the property that various proposed learning dynamics in the brain (e.g., a wave of nerve growth factor) support the self-organization somewhat analogous to the neural networks utilized in deep learning models. Like the neocortex, neural networks employ a hierarchy of layered filters in which each layer considers information from a prior layer (or the operating environment), and then passes its output (and possibly the original input), to other layers. This process yields a self-organizing stack of transducers, well-tuned to their operating environment. A 1995 description stated, \"...the infant's brain seems to organize itself under the influence of waves of so-called trophic-factors ... different regions of the brain become connected sequentially, with one layer of tissue maturing before another and so on until the whole brain is mature\".\nA variety of approaches have been used to investigate the plausibility of deep learning models from a neurobiological perspective. On the one hand, several variants of the backpropagation algorithm have been proposed in order to increase its processing realism. Other researchers have argued that unsupervised forms of deep learning, such as those based on hierarchical generative models and deep belief networks, may be closer to biological reality. In this respect, generative neural network models have been related to neurobiological evidence about sampling-based processing in the cerebral cortex.\nAlthough a systematic comparison between the human brain organization and the neuronal encoding in deep networks has not yet been established, several analogies have been reported. For example, the computations performed by deep learning units could be similar to those of actual neurons and neural populations. Similarly, the representations developed by deep learning models are similar to those measured in the primate visual system both at the single-unit and at the population levels.\n\n\nCommercial activity\nFacebook's AI lab performs tasks such as automatically tagging uploaded pictures with the names of the people in them.\nGoogle's DeepMind Technologies developed a system capable of learning how to play Atari video games using only pixels as data input. In 2015 they demonstrated their AlphaGo system, which learned the game of Go well enough to beat a professional Go player. Google Translate uses a neural network to translate between more than 100 languages.\nIn 2017, Covariant.ai was launched, which focuses on integrating deep learning into factories.\nAs of 2008, researchers at The University of Texas at Austin (UT) developed a machine learning framework called Training an Agent Manually via Evaluative Reinforcement, or TAMER, which proposed new methods for robots or computer programs to learn how to perform tasks by interacting with a human instructor. First developed as TAMER, a new algorithm called Deep TAMER was later introduced in 2018 during a collaboration between U.S. Army Research Laboratory (ARL) and UT researchers. Deep TAMER used deep learning to provide a robot with the ability to learn new tasks through observation. Using Deep TAMER, a robot learned a task with a human trainer, watching video streams or observing a human perform a task in-person. The robot later practiced the task with the help of some coaching from the trainer, who provided feedback such as \"good job\" and \"bad job\".\n\n\nCriticism and comment\nDeep learning has attracted both criticism and comment, in some cases from outside the field of computer science.\n\n\nTheory\n\nA main criticism concerns the lack of theory surrounding some methods. Learning in the most common deep architectures is implemented using well-understood gradient descent. However, the theory surrounding other algorithms, such as contrastive divergence is less clear. (e.g., Does it converge? If so, how fast? What is it approximating?) Deep learning methods are often looked at as a black box, with most confirmations done empirically, rather than theoretically.\nIn further reference to the idea that artistic sensitivity might be inherent in relatively low levels of the cognitive hierarchy, a published series of graphic representations of the internal states of deep (20-30 layers) neural networks attempting to discern within essentially random data the images on which they were trained demonstrate a visual appeal: the original research notice received well over 1,000 comments, and was the subject of what was for a time the most frequently accessed article on The Guardian's website.\nWith the support of Innovation Diffusion Theory (IDT), a study analyzed the diffusion of deep learning in BRICS and OECD countries using data from Google Trends.\n\n\nErrors\nSome deep learning architectures display problematic behaviors, such as confidently classifying unrecognizable images as belonging to a familiar category of ordinary images (2014) and misclassifying minuscule perturbations of correctly classified images (2013). Goertzel hypothesized that these behaviors are due to limitations in their internal representations and that these limitations would inhibit integration into heterogeneous multi-component artificial general intelligence (AGI) architectures. These issues may possibly be addressed by deep learning architectures that internally form states homologous to image-grammar decompositions of observed entities and events. Learning a grammar (visual or linguistic) from training data would be equivalent to restricting the system to commonsense reasoning that operates on concepts in terms of grammatical production rules and is a basic goal of both human language acquisition and artificial intelligence (AI).\n\n\nCyber threat\nAs deep learning moves from the lab into the world, research and experience show that artificial neural networks are vulnerable to hacks and deception. By identifying patterns that these systems use to function, attackers can modify inputs to ANNs in such a way that the ANN finds a match that human observers would not recognize. For example, an attacker can make subtle changes to an image such that the ANN finds a match even though the image looks to a human nothing like the search target. Such manipulation is termed an \"adversarial attack\".\nIn 2016 researchers used one ANN to doctor images in trial and error fashion, identify another's focal points, and thereby generate images that deceived it. The modified images looked no different to human eyes. Another group showed that printouts of doctored images then photographed successfully tricked an image classification system. One defense is reverse image search, in which a possible fake image is submitted to a site such as TinEye that can then find other instances of it. A refinement is to search using only parts of the image, to identify images from which that piece may have been taken.\nAnother group showed that certain psychedelic spectacles could fool a facial recognition system into thinking ordinary people were celebrities, potentially allowing one person to impersonate another. In 2017 researchers added stickers to stop signs and caused an ANN to misclassify them.\nANNs can however be further trained to detect attempts at deception, potentially leading attackers and defenders into an arms race similar to the kind that already defines the malware defense industry. ANNs have been trained to defeat ANN-based anti-malware software by repeatedly attacking a defense with malware that was continually altered by a genetic algorithm until it tricked the anti-malware while retaining its ability to damage the target.\nIn 2016, another group demonstrated that certain sounds could make the Google Now voice command system open a particular web address, and hypothesized that this could \"serve as a stepping stone for further attacks (e.g., opening a web page hosting drive-by malware)\".\nIn \"data poisoning\", false data is continually smuggled into a machine learning system's training set to prevent it from achieving mastery.\n\n\nData collection ethics\nThe deep learning systems that are trained using supervised learning often rely on data that is created or annotated by humans, or both. It has been argued that not only low-paid clickwork (such as on Amazon Mechanical Turk) is regularly deployed for this purpose, but also implicit forms of human microwork that are often not recognized as such. The philosopher Rainer Mühlhoff distinguishes five types of \"machinic capture\" of human microwork to generate training data: (1) gamification (the embedding of annotation or computation tasks in the flow of a game), (2) \"trapping and tracking\" (e.g. CAPTCHAs for image recognition or click-tracking on Google search results pages), (3) exploitation of social motivations (e.g. tagging faces on Facebook to obtain labeled facial images), (4) information mining (e.g. by leveraging quantified-self devices such as activity trackers) and (5) clickwork.\n\n\nSee also\n\n\nReferences\n\n\nFurther reading", "categories": ["All articles with self-published sources", "All articles with unsourced statements", "All pages needing factual verification", "Articles containing video clips", "Articles prone to spam from June 2015", "Articles with self-published sources from April 2026", "Articles with short description", "Articles with unsourced statements from August 2024", "Articles with unsourced statements from July 2016", "Articles with unsourced statements from June 2026", "Articles with unsourced statements from November 2020", "CS1: long volume value", "CS1 Finnish-language sources (fi)", "CS1 errors: missing periodical", "CS1 errors: missing title", "CS1 maint: multiple names: authors list", "CS1 maint: postscript", "Deep learning", "Pages using multiple image with auto scaled images", "Short description is different from Wikidata"], "references": ["http://www.technologyreview.com/news/533936/nvidia-demos-a-car-computer-trained-with-deep-learning/", "http://people.idsia.ch/~juergen/SeppHochreiter1991ThesisAdvisorSchmidhuber.pdf", "https://tripod.nih.gov/tox21/challenge/leaderboard.jsp", "http://www.ncats.nih.gov/news-and-events/features/tox21-challenge-winners.html", "http://techtalks.tv/talks/deep-learning-of-recursive-structure-grammar-induction/58089/", "http://googleresearch.blogspot.co.uk/2015/06/inceptionism-going-deeper-into-neural.html", "http://ww2.kqed.org/futureofyou/2015/05/27/startup-harnesses-supercomputers-to-seek-cures/", "http://www.technologyreview.com/news/546066/googles-ai-masters-the-game-of-go-a-decade-earlier-than-expected/", "http://googleresearch.blogspot.ch/2015/09/google-voice-search-faster-and-more.html", "https://indico.cern.ch/event/510372/", "http://research.microsoft.com/pubs/209355/DeepLearning-NowPublishing-Vol7-SIG-039.pdf", "https://www.theguardian.com/technology/2015/jun/18/google-image-recognition-neural-network-androids-dream-electric-sheep", "https://books.google.com/books?id=bX4pAQAAMAAJ", "https://books.google.com/books?id=Otk32Y3QkxQC&pg=PA48", "https://books.google.com/books?id=NZP6AQAAQBAJ"], "images": ["File:Deep Learning.jpg"], "sub_niche": "Adversarial machine learning"} {"title": "Machine unlearning", "url": "https://en.wikipedia.org/wiki/Machine_unlearning", "summary": "Machine unlearning is a branch of machine learning focused on removing specific undesired element, such as private data, wrong or manipulated training data, outdated information, copyrighted material, harmful content, dangerous abilities, or misinformation, without needing to rebuild models from the ground up.\nLarge language models, like the ones powering ChatGPT, may be asked not just to remove specific elements but also to unlearn a \"concept,\" \"fact,\" or \"knowledge,\" which are not easily linked to specific examples. New terms such as \"model editing,\" \"concept editing,\" and \"knowledge unlearning\" have emerged to describe this process.", "content": "Machine unlearning is a branch of machine learning focused on removing specific undesired element, such as private data, wrong or manipulated training data, outdated information, copyrighted material, harmful content, dangerous abilities, or misinformation, without needing to rebuild models from the ground up.\nLarge language models, like the ones powering ChatGPT, may be asked not just to remove specific elements but also to unlearn a \"concept,\" \"fact,\" or \"knowledge,\" which are not easily linked to specific examples. New terms such as \"model editing,\" \"concept editing,\" and \"knowledge unlearning\" have emerged to describe this process.\n\n\nHistory\nEarly research efforts were largely motivated by Article 17 of the GDPR, the European Union's privacy regulation commonly known as the \"right to be forgotten\" (RTBF), introduced in 2014. The GDPR's Right to Be Forgotten did not anticipate that the development of large language models would make data erasure a complex task. This issue has since led to research on \"machine unlearning,\" with a growing focus on removing copyrighted material, harmful content, dangerous capabilities, data protection and privacy, and misinformation. Just as early experiences in humans shape later ones, some concepts are more fundamental and harder to unlearn. A piece of knowledge may be so deeply embedded in the model's knowledge graph that unlearning it could cause internal contradictions, requiring adjustments to other parts of the graph to resolve them.\nResearchers have now also started studying unlearning in the context of removing incorrect or adversarially manipulated training data such as systematically biased labels or poisoning attacks.\nPrivacy and data protection are also concerns that machine unlearning has been proposed to address. While many privacy laws, including the GDPR, require data deletion as a remedy for wrongful collection or processing of data, data deletion is an insufficient remedy in machine learning contexts. Legal scholar Tiffany C. Li argues that machine unlearning may be a necessary remedy for privacy violations in machine learning contexts because the \"algorithmic shadow\" of the data used in training remains, even if data is deleted from a data processor's dataset. Because data used in a training set can have a persistent impact on model parameters, any future use of the model will carry with it the \"algorithmic shadow\" of wrongly collected or used data In law, machine unlearning has been proposed as a remedy for wrongful collection or use of data. In this context, machine unlearning can also be known as or used in addition to algorithmic destruction, algorithmic disgorgement, or model deletion. Algorithmic disgorgement specifically has been used as an enforcement tool by the U.S. Federal Trade Commission. Legal scholar Caprice L. Roberts argues that algorithmic disgorgement can be understood under traditional unjust enrichment doctrine as well.\n\n\nMotivations\nAt present, machine unlearning is motivated by a growing range of concerns that extend well beyond the field's original focus on data privacy. A widely used taxonomy in the literature distinguishes two high-level categories of motivation.\nAccess revocation covers cases where a data subject or rights holder requests the removal of data they own or control. This is most commonly associated with RTBF established by the European Union's General Data Protection Regulation (GDPR) and analogous legislation such as the California Consumer Privacy Act (CCPA). These regulations grant individuals the legal right to request erasure of their personal data from any system that has processed it, including models that were trained on it. Access revocation also encompasses the removal of copyrighted or pay-walled content that was incorporated into training corpora without the necessary licenses, a concern that has become prominent with the widespread use of largely web-scraped pre-training datasets.\nModel correction covers cases where the model exhibits undesirable behavior arising from the training data, regardless of any individual's request. This includes:\n\nRemoval of toxic, biased, or unsafe outputs introduced by harmful content in the training set\nCorrection of stale or factually incorrect associations, such as outdated knowledge encoded in a deployed model\nRemoval of dangerous capabilities, such as detailed knowledge of the synthesis of chemical or biological agents\nCorrection of the influence of data poisoning or adversarial attacks that have corrupted model behavior\nThis second category has been formalized as corrective machine unlearning, which frames unlearning as a post-training mechanism for repairing the effects of bad or harmful training data. It is closely related to the AI safety literature, where data filtering alone has been found insufficient to prevent hazardous knowledge from being encoded in model weights, motivating unlearning as a complementary risk mitigation strategy.\nA further distinction has been drawn in the literature between removal (eliminating the influence of specific training data on model parameters) and suppression (preventing the model from generating specific outputs regardless of how that knowledge is encoded). These two goals are not equivalent: removing training data does not guarantee meaningful output suppression, and suppressing outputs does not constitute removal of the underlying training data's influence.\n\n\nSISA Training\nSISA is a training strategy consisting of four mechanisms designed to make machine unlearning more efficient by structuring how models are trained and updated. Its goal is to allow a system to remove the influence of specific data points without retraining an entire model from scratch. By reorganizing training data and workflows, SISA reduces the computational burden of unlearning requests.\nSharding divides the training dataset into multiple disjoint subsets, or shards. Each shard is used to train a separate model instance. This ensures that a single data point affects only one shard, so unlearning it requires updating only the corresponding shard rather than the full model.\nIsolation refers to training each shard independently, with nothing shared across shards during the training process. This separation prevents cross-contamination between shards, ensuring that forgetting data in one shard does not require adjustments to any others.\nSlicing breaks the data within each shard into sequential slices and stores model states after each slice is trained on. When an unlearning request targets a piece of data, the system can roll back to the checkpoint before the point was seen and retrain only from that slice forward. This reduces retraining time even within a shard.\nAggregation occurs at inference, when the model is queried. It combines the outputs of each shard to determine the output of the overall model. This is often through majority voting or averaging. This allows SISA-trained systems to behave like a single model despite being composed of multiple shard-level models.\nTogether, these mechanisms enable machine learning systems to forget specific data points with far lower computational cost than full retraining. The trade-off is that sharding and slicing can lead to reduced model accuracy, worse generalization, and increased storage requirements for the intermediate checkpoints. This can be tolerable based on the needs of the individual or organization to comply with \"right to be forgotten\" or efficiently recover from backdoor attacks.\n\n\nAlgorithms\nMachine unlearning algorithms are broadly categorized into exact and approximate methods, reflecting a fundamental trade-off between formal guarantees and computational tractability.\n\n\nExact Unlearning\nExact unlearning methods produce a model that is statistically indistinguishable from one retrained from scratch on the dataset with the forget data removed. The canonical framework for exact unlearning is SISA Training (Sharded, Isolated, Sliced, and Aggregated), introduced by Bourtoule et al. (2021). SISA partitions the training dataset into disjoint shards and trains a separate sub-model on each. At inference time, predictions are aggregated across sub-models. When an unlearning request is received, only the sub-model corresponding to the shard containing the target data requires retraining, reducing computational overhead proportionally to the number of shards. Exact methods provide the strongest guarantees but become prohibitively expensive for large pre-trained neural networks and are generally limited to settings where training can be structured in advance.\n\n\nApproximate Unlearning\nApproximate unlearning methods seek to produce a model whose behavior is sufficiently close to an exactly unlearned model without the cost of full retraining. These methods dominate practical applications. Common approaches include:\n\nGradient Ascent: The model is fine-tuned by maximizing the loss on the forget set, directly degrading its performance on targeted data. This is the most direct approach but risks destabilizing performance on retained data.\nRandom Labelling: The model is fine-tuned on the forget set using randomly shuffled labels, confusing its associations with the targeted data while producing a less aggressive weight shift than pure gradient ascent.\nGradient Difference: Combines gradient ascent on the forget set with simultaneous gradient descent on the retain set, using the retain objective as a regularizer to preserve general model utility.\nKL Divergence Regularization: Minimizes the KL divergence between the outputs of the unlearned model and the original model on the retain set, anchoring behavior on data the model should remember.\nWeight Pruning and Fine-tuning: Parameters with the smallest L1-norm are pruned — targeting weights most weakly associated with general knowledge and potentially most associated with the forget set — followed by fine-tuning on the retain set to restore utility.\nLayer Reset and Fine-tuning: The first or last k layers are re-initialized to random weights and the model is subsequently fine-tuned on the retain set. This is a coarse but computationally simple approach.\nSelective Synaptic Dampening: Uses influence functions to estimate the effect of individual training examples on model parameters via first- and second-order derivatives, then applies a targeted weight update to reduce their influence without iterative optimization.\nRepresentation Misdirection for Unlearning: Neurons causally implicated in encoding forget-set knowledge are made to produce random representations when presented with forget-set inputs, while retain-set knowledge is simultaneously reinforced. This method has demonstrated strong results on capability-removal benchmarks.\n\n\nNoise and Weight Perturbation\nA further family of methods adds calibrated noise to model weights or intermediate activations to obscure the statistical influence of the forget set. These approaches draw on differential privacy theory, where the addition of Laplace or Gaussian noise provides formal indistinguishability guarantees. Noise-based methods are typically combined with a fine-tuning step on the retain set to recover utility lost through the perturbation.\n\n\nAdversarial Approaches\nMore recent work has introduced adversarially motivated unlearning frameworks, such as AMUN (Adversarial Machine UNlearning), which formulates the unlearning objective in terms of similarity to a retrained model's predictions on both the forget and retain sets, verified through membership inference attacks rather than loss-based proxies alone. Similarly, the Attack-and-Reset for Unlearning (ARU) algorithm uses adversarial noise to generate a parameter mask that selectively resets parameters associated with the forget set. These approaches address a key weakness of gradient-based methods: apparent unlearning may reflect surface-level output suppression rather than true parameter-level removal, a limitation exposed by adversarial probing.\n\n\nReferences", "categories": ["All articles needing additional references", "All articles with unsourced statements", "Articles needing additional references from December 2024", "Articles with short description", "Articles with unsourced statements from December 2024", "Machine learning", "Short description is different from Wikidata"], "references": ["https://ai.stanford.edu/~kzliu/blog/unlearning", "https://www.google.com/search?as_eq=wikipedia&q=%22Machine+unlearning%22", "https://www.google.com/search?tbm=nws&q=%22Machine+unlearning%22+-wikipedia&tbs=ar:1", "https://www.google.com/search?&q=%22Machine+unlearning%22&tbs=bkt:s&tbm=bks", "https://www.google.com/search?tbs=bks:1&q=%22Machine+unlearning%22+-wikipedia", "https://scholar.google.com/scholar?q=%22Machine+unlearning%22", "https://www.jstor.org/action/doBasicSearch?Query=%22Machine+unlearning%22&acc=on&wc=on", "https://doi.org/10.1007%2Fs11948-024-00500-5", "https://www.ncbi.nlm.nih.gov/pmc/articles/PMC11390766", "https://openreview.net/pdf?id=v8enu4jP9B", "https://web.archive.org/web/20241213234527/https://ai.stanford.edu/~kzliu/blog/unlearning", "https://pubmed.ncbi.nlm.nih.gov/39259362", "https://arxiv.org/abs/1912.03817", "https://arxiv.org/archive/cs.CR", "https://doi.org/10.1145/3749987"], "images": [], "sub_niche": "Adversarial machine learning"} {"title": "Machine learning in earth sciences", "url": "https://en.wikipedia.org/wiki/Machine_learning_in_earth_sciences", "summary": "Applications of machine learning (ML) in earth sciences include geological mapping, gas leakage detection and geological feature identification. Machine learning is a subdiscipline of artificial intelligence aimed at developing programs that are able to classify, cluster, identify, and analyze vast and complex data sets without the need for explicit programming to do so. Earth science is the study of the origin, evolution, and future of Earth. The planet's system can be subdivided into four major components including the solid earth, atmosphere, hydrosphere, and biosphere.\nA variety of algorithms may be applied depending on the nature of the task. Some algorithms may perform significantly better than others for particular objectives. For example, convolutional neural networks (CNNs) are go", "content": "Applications of machine learning (ML) in earth sciences include geological mapping, gas leakage detection and geological feature identification. Machine learning is a subdiscipline of artificial intelligence aimed at developing programs that are able to classify, cluster, identify, and analyze vast and complex data sets without the need for explicit programming to do so. Earth science is the study of the origin, evolution, and future of Earth. The planet's system can be subdivided into four major components including the solid earth, atmosphere, hydrosphere, and biosphere.\nA variety of algorithms may be applied depending on the nature of the task. Some algorithms may perform significantly better than others for particular objectives. For example, convolutional neural networks (CNNs) are good at interpreting images, whilst more general neural networks may be used for soil classification, but can be more computationally expensive to train than alternatives such as support vector machines. The range of tasks to which ML (including deep learning) is applied has been ever-growing in recent decades, as has the development of other technologies such as unmanned aerial vehicles (UAVs), ultra-high resolution remote sensing technology, and high-performance computing. This has led to the availability of large high-quality datasets and more advanced algorithms.\n\n\nSignificance\n\n\nComplexity of earth science\nProblems in earth science are often complex. It is difficult to apply well-known and described mathematical models to the natural environment, therefore machine learning is commonly a better alternative for such non-linear problems. Ecological data are commonly non-linear and consist of higher-order interactions, and together with missing data, traditional statistics may underperform as unrealistic assumptions such as linearity are applied to the model. A number of researchers found that machine learning outperforms traditional statistical models in earth science, such as in characterizing forest canopy structure, predicting climate-induced range shifts, and delineating geologic facies. Characterizing forest canopy structure enables scientists to study vegetation response to climate change. Predicting climate-induced range shifts enable policy makers to adopt suitable conversation method to overcome the consequences of climate change. Delineating geologic facies helps geologists to understand the geology of an area, which is essential for the development and management of an area.\n\n\nInaccessible data\nIn earth sciences, some data are often difficult to access or collect, therefore inferring data from data that are easily available by machine learning method is desirable. For example, geological mapping in tropical rainforests is challenging because the thick vegetation cover and rock outcrops are poorly exposed. Applying remote sensing with machine learning approaches provides an alternative way for rapid mapping without the need of manually mapping in the unreachable areas.\n\n\nReduce time costs\nMachine learning can also reduce the efforts done by experts, as manual tasks of classification and annotation etc. are the bottlenecks in the workflow of the research of earth science. Geological mapping, especially in a vast, remote area is labour, cost and time-intensive with traditional methods. Incorporation of remote sensing and machine learning approaches can provide an alternative solution to eliminate some field mapping needs.\n\n\nConsistent and bias-free\nConsistency and bias-free is also an advantage of machine learning compared to manual works by humans. In research comparing the performance of human and machine learning in the identification of dinoflagellates, machine learning is found to be not as prone to systematic bias as humans. A recency effect that is present in humans is that the classification often biases towards the most recently recalled classes. In a labelling task of the research, if one kind of dinoflagellates occurs rarely in the samples, then expert ecologists commonly will not classify it correctly. The systematic bias strongly deteriorate the classification accuracies of humans.\n\n\nOptimal machine learning algorithm\nThe extensive usage of machine learning in various fields has led to a wide range of algorithms of learning methods being applied. Choosing the optimal algorithm for a specific purpose can lead to a significant boost in accuracy: for example, the lithological mapping of gold-bearing granite-greenstone rocks in Hutti, India with AVIRIS-NG hyperspectral data, shows more than 10% difference in overall accuracy between using support vector machines (SVMs) and random forest.\nSome algorithms can also reveal hidden important information: white box models are transparent models, the outputs of which can be easily explained, while black box models are the opposite. For example, although an SVM yielded the best result in landslide susceptibility assessment accuracy, the result cannot be rewritten in the form of expert rules that explain how and why an area was classified as that specific class. In contrast, decision trees are transparent and easily understood, and the user can observe and fix the bias if any is present in such models.\nIf computational resource is a concern, more computationally demanding learning methods such as deep neural networks are less preferred, despite the fact that they may outperform other algorithms, such as in soil classification.\n\n\nUsage\n\n\nMapping\n\n\nGeological or lithological mapping and mineral prospectivity mapping\nGeological or lithological mapping produces maps showing geological features and geological units. Mineral prospectivity mapping utilizes a variety of datasets such as geological maps and aeromagnetic imagery to produce maps that are specialized for mineral exploration. Geological, lithological, and mineral prospectivity mapping can be carried out by processing data with ML techniques, with the input of spectral imagery obtained from remote sensing and geophysical data. Spectral imaging is also used – the imaging of wavelength bands in the electromagnetic spectrum, while conventional imaging captures three wavelength bands (red, green, blue) in the electromagnetic spectrum.\nRandom forests and SVMs are some algorithms commonly used with remotely-sensed geophysical data, while simple linear iterative clustering convolutional neural network (SLIC-CNN) and convolutional neural networks (CNNs) are commonly applied to aerial imagery. Large scale mapping can be carried out with geophysical data from airborne and satellite remote sensing geophysical data, and smaller-scale mapping can be carried out with images from unmanned aerial vehicles (UAVs) for higher resolution.\nVegetation cover is one of the major obstacles for geological mapping with remote sensing, as reported in various research, both in large-scale and small-scale mapping. Vegetation affects the quality of spectral images, or obscures the rock information in aerial images.\n\n\nLandslide susceptibility and hazard mapping\nLandslide susceptibility refers to the probability of landslide of a certain geographical location, which is dependent on local terrain conditions. Landslide susceptibility mapping can highlight areas prone to landslide risks, which is useful for urban planning and disaster management. Such datasets for ML algorithms usually include topographic information, lithological information, satellite images, etc., and some may include land use, land cover, drainage information, and vegetation cover according to the study requirements. As usual, for training an ML model for landslide susceptibility mapping, training and testing datasets are required. There are two methods of allocating datasets for training and testing: one is to randomly split the study area for the datasets; another is to split the whole study into two adjacent parts for the two datasets. To test classification models, the common practice is to split the study area randomly; however, it is more useful if the study area can be split into two adjacent parts so that an automation algorithm can carry out mapping of a new area with the input of expert-processed data of adjacent land.\n\n\nFeature identification and detection\n\n\nDiscontinuity analyses\nDiscontinuities such as fault planes and bedding planes have important implications in civil engineering. Rock fractures can be recognized automatically by machine learning through photogrammetric analysis, even with the presence of interfering objects such as vegetation. In ML training for classifying images, data augmentation is a common practice to avoid overfitting and increase the training dataset size and variability. For example, in a study of rock fracture recognition, 68 images for training and 23 images for testing were prepared via random splitting. Data augmentation was performed, increasing the training dataset size to 8704 images by flipping and random cropping. The approach was able to recognize rock fractures accurately in most cases. Both the negative prediction value (NPV) and the specificity were over 0.99. This demonstrated the robustness of discontinuity analyses with machine learning. \n\n\nCarbon dioxide leakage detection\nQuantifying carbon dioxide leakage from a geological sequestration site has gained increased attention as the public is interested in whether carbon dioxide is stored underground safely and effectively. Carbon dioxide leakage from a geological sequestration site can be detected indirectly with the aid of remote sensing and an unsupervised clustering algorithm such as iterative self-organizing data analysis technique (ISODATA). The increase in soil CO2 concentration causes a stress response for plants by inhibiting plant respiration, as oxygen is displaced by carbon dioxide. The vegetation stress signal can be detected with the normalized difference red edge Index (NDRE). The hyperspectral images are processed by the unsupervised algorithm, clustering pixels with similar plant responses. The hyperspectral information in areas with known CO2 leakage is extracted so that areas with leakage can be matched with the clustered pixels with spectral anomalies. Although the approach can identify CO2 leakage efficiently, there are some limitations that require further study. The NDRE may not be accurate due to reasons like higher chlorophyll absorption, variation in vegetation, and shadowing effects; therefore, some stressed pixels can be incorrectly classed as healthy. Seasonality, groundwater table height may also affect the stress response to CO2 of the vegetation. \n\n\nQuantification of water inflow\nThe rock mass rating (RMR) system is a widely adopted rock mass classification system by geomechanical means with the input of six parameters. The amount of water inflow is one of the inputs of the classification scheme, representing the groundwater condition. Quantification of the water inflow in the faces of a rock tunnel was traditionally carried out by visual observation in the field, which is labour and time-consuming, and fraught with safety concerns. Machine learning can determine water inflow by analyzing images taken on the construction site. The classification of the approach mostly follows the RMR system, but combining damp and wet states, as it is difficult to distinguish only by visual inspection. The images were classified into the non-damaged state, wet state, dripping state, flowing state, and gushing state. The accuracy of classifying the images was approximately 90%. \n\n\nClassification\n\n\nSoil classification\nThe most popular cost-effective method od soil investigation method is cone penetration testing (CPT). The test is carried out by pushing a metallic cone through the soil: the force required to push at a constant rate is recorded as a quasi-continuous log. Machine learning can classify soil with the input of CPT data. In an attempt to classify with ML, there are two tasks required to analyze the data, namely segmentation and classification. Segmentation can be carried out with the constraint clustering and classification (CONCC) algorithm to split a single series data into segments. Classification can then be carried out by algorithms such as decision trees, SVMs, or neural networks.\n\n\nGeological structure classification\n\nExposed geological structures such as anticlines, ripple marks, and xenoliths can be identified automatically with deep learning models. Research has demonstrated that three-layer CNNs and transfer learning have strong accuracy (about 80% and 90% respectively), while others like k-nearest neighbors (k-NN), regular neural nets, and extreme gradient boosting (XGBoost) have low accuracies (ranging from 10% - 30%). The grayscale images and colour images were both tested, with the accuracy difference being little, implying that colour is not very important in identifying geological structures.\n\n\nForecast and predictions\n\n\nEarthquake early warning systems and forecasting\nEarthquake warning systems are often vulnerable to local impulsive noise, therefore giving out false alerts. False alerts can be eliminated by discriminating the earthquake waveforms from noise signals with the aid of ML methods. The method consists of two parts, the first being unsupervised learning with a generative adversarial network (GAN) to learn and extract features of first-arrival P-waves, and the second being use of a random forest to discriminate P-waves. This approach achieved 99.2% in recognizing P-waves, and can avoid false triggers by noise signals with 98.4% accuracy.\nEarthquakes can be produced in a laboratory settings to mimic real-world ones. With the help of machine learning, the patterns of acoustic signals as precursors for earthquakes can be identified. Predicting the time remaining before failure was demonstrated in a study with continuous acoustic time series data recorded from a fault. The algorithm applied was a random forest, trained with a set of slip events, performing strongly in predicting the time to failure. It identified acoustic signals to predict failures, with one of them being previously unidentified. Although this laboratory earthquake is not as complex as a natural one, progress was made that guides future earthquake prediction work.\n\n\nStreamflow discharge prediction\nReal-time streamflow data is integral for decision making (e.g., evacuations, or regulation of reservoir water levels during flooding). Streamflow data can be estimated by data provided by stream gauges, which measure the water level of a river. However, water and debris from flooding may damage stream gauges, resulting in lack of essential real-time data. The ability of machine learning to infer missing data enables it to predict streamflow with both historical stream gauge data and real-time data. Streamflow hydrology estimate using machine learning (SHEM) is a model that can serve this purpose. To verify its accuracies, the prediction result was compared with the actual recorded data, and the accuracies were found to be between 0.78 and 0.99.\n\n\nChallenge\n\n\nInadequate training data\nAn adequate amount of training and validation data is required for machine learning. However, some very useful products like satellite remote sensing data only have decades of data since the 1970s. If one is interested in the yearly data, then only less than 50 samples are available. Such amount of data may not be adequate. In a study of automatic classification of geological structures, the weakness of the model is the small training dataset, even though with the help of data augmentation to increase the size of the dataset. Another study of predicting streamflow found that the accuracies depend on the availability of sufficient historical data, therefore sufficient training data determine the performance of machine learning. Inadequate training data may lead to a problem called overfitting. Overfitting causes inaccuracies in machine learning as the model learns about the noise and undesired details.\n\n\nLimited by data input\nMachine learning cannot carry out some of the tasks as a human does easily. For example, in the quantification of water inflow in rock tunnel faces by images for rock mass rating system (RMR), the damp and the wet state was not classified by machine learning because discriminating the two only by visual inspection is not possible. In some tasks, machine learning may not able to fully substitute manual work by a human.\n\n\nBlack-box operation\n\nIn many machine learning algorithms, for example, artificial neural network (ANN), it is considered as 'black box' approach as clear relationships and descriptions of how the results are generated in the hidden layers are unknown. 'White-box' approach such as decision tree can reveal the algorithm details to the users. If one wants to investigate the relationships, such 'black-box' approaches are not suitable. However, the performances of 'black-box' algorithms are usually better.\n\n\nReferences", "categories": ["All articles with unsourced statements", "Articles with short description", "Articles with unsourced statements from March 2022", "CS1: long volume value", "CS1 errors: deprecated parameters", "CS1 maint: multiple names: authors list", "Geological techniques", "Machine learning", "Short description is different from Wikidata"], "references": ["http://dx.doi.org/10.1109/icecco.2018.8634775", "https://ui.adsabs.harvard.edu/abs/2020IJGI....9...99S", "https://api.semanticscholar.org/CorpusID:59620103", "https://ui.adsabs.harvard.edu/abs/2011RSEnv.115.1978Z", "https://ui.adsabs.harvard.edu/abs/2006GCBio..12.1568L", "https://ui.adsabs.harvard.edu/abs/2004GeoRL..3118502T", "https://api.semanticscholar.org/CorpusID:129112606", "https://api.semanticscholar.org/CorpusID:134822423", "https://ui.adsabs.harvard.edu/abs/2018RemS...10..307L", "https://ui.adsabs.harvard.edu/abs/2003MEPS..247...17C", "https://api.semanticscholar.org/CorpusID:207831043", "https://ui.adsabs.harvard.edu/abs/2007ESF....14..143B", "https://api.semanticscholar.org/CorpusID:51960414", "https://ui.adsabs.harvard.edu/abs/2009Geomo.113...97K", "https://api.semanticscholar.org/CorpusID:235762914"], "images": ["File:Data Augmentation of rock images revised.jpg", "File:Geological feature recognition.png", "File:Landslide susceptibility mapping dataset splitting.png"], "sub_niche": "Adversarial machine learning"} {"title": "AI alignment", "url": "https://en.wikipedia.org/wiki/AI_alignment", "summary": "In the field of artificial intelligence (AI), alignment aims to steer AI systems toward a person's or group's intended goals, preferences, or ethical principles. An AI system is considered aligned if it advances the intended objectives. A misaligned AI system pursues unintended objectives.\nIt is often difficult for AI designers to specify the full range of desired and undesired behaviors. Therefore, the designers often use simpler proxy goals, such as gaining human approval. But proxy goals can overlook necessary constraints or reward the AI system for merely appearing aligned. AI systems may also find loopholes that allow them to accomplish their proxy goals efficiently but in unintended, sometimes harmful, ways (reward hacking).\nAdvanced AI systems may develop unwanted instrumental strat", "content": "In the field of artificial intelligence (AI), alignment aims to steer AI systems toward a person's or group's intended goals, preferences, or ethical principles. An AI system is considered aligned if it advances the intended objectives. A misaligned AI system pursues unintended objectives.\nIt is often difficult for AI designers to specify the full range of desired and undesired behaviors. Therefore, the designers often use simpler proxy goals, such as gaining human approval. But proxy goals can overlook necessary constraints or reward the AI system for merely appearing aligned. AI systems may also find loopholes that allow them to accomplish their proxy goals efficiently but in unintended, sometimes harmful, ways (reward hacking).\nAdvanced AI systems may develop unwanted instrumental strategies, such as seeking power or self-preservation because such strategies help them achieve their assigned final goals. Furthermore, they might develop undesirable emergent behaviour that could be hard to detect before the system is deployed and encounters new situations and data distributions. Empirical research in 2024 found that advanced large language models (LLMs) such as OpenAI o1 or Claude 3 sometimes engage in strategic deception to achieve their goals or prevent them from being changed.\nSome of these issues affect existing commercial systems such as LLMs, robots, autonomous vehicles, and social media recommendation engines. Some AI researchers argue that more capable future systems will be more severely affected because these problems partially result from high capabilities.\nMany prominent AI researchers and AI company leaders have argued or asserted that AI is approaching human-like (AGI) and superhuman cognitive capabilities (ASI), and could endanger human civilization if misaligned. These include \"AI godfathers\" Geoffrey Hinton and Yoshua Bengio and the CEOs of OpenAI, Anthropic, and Google DeepMind. These risks remain debated.\nAI alignment is a subfield of AI safety, the study of how to build safe AI systems. Other subfields of AI safety include robustness, monitoring, and capability control. Research challenges in alignment include instilling complex values in AI, developing honest AI, scalable oversight, auditing and interpreting AI models, and preventing emergent AI behaviors like power-seeking. Alignment research has connections to interpretability research, (adversarial) robustness, anomaly detection, calibrated uncertainty, formal verification, preference learning, safety-critical engineering, game theory, algorithmic fairness, and social sciences.\n\n\nObjectives in AI\n\nProgrammers provide an AI system such as AlphaZero with an \"objective function\", in which they intend to encapsulate the goal(s) the AI is configured to accomplish. Such a system later populates a (possibly implicit) internal \"model\" of its environment. This model encapsulates all the agent's beliefs about the world. The AI then creates and executes whatever plan is calculated to maximize the value of its objective function. For example, when AlphaZero is trained on chess, it has a simple objective function of \"+1 if AlphaZero wins, −1 if AlphaZero loses\". During the game, AlphaZero attempts to execute whatever sequence of moves it judges most likely to attain the maximum value of +1. Similarly, a reinforcement learning system can have a \"reward function\" that allows the programmers to shape the AI's desired behavior. An evolutionary algorithm's behavior is shaped by a \"fitness function\".\n\n\nAlignment problem\n\nIn 1960, AI pioneer Norbert Wiener described the AI alignment problem as follows: \n\nIf we use, to achieve our purposes, a mechanical agency with whose operation we cannot interfere effectively [...] we had better be quite sure that the purpose put into the machine is the purpose which we really desire.\n\nAI alignment refers to ensuring that an AI system's objectives match some target. The target is variously defined as the goals of the system's designers or users, widely shared values, objective ethical standards, legal requirements, or the intentions its designers would have if they were more informed and enlightened. In democratic AI alignment, the target is the values and preferences of median voters, which increases political legitimacy. AI alignment can represent value pluralism.\nAI alignment is an open problem for modern AI systems and is a research field within AI. Aligning AI involves two main challenges: carefully specifying the purpose of the system (outer alignment) and ensuring that the system adopts the specification robustly (inner alignment). Researchers also attempt to create AI models that have robust alignment, sticking to safety constraints even when users adversarially try to bypass them.\n\n\nSpecification gaming and side effects\n\nTo specify an AI system's purpose, AI designers typically provide an objective function, examples, or feedback to the system. But designers are often unable to completely specify all important values and constraints, so they resort to easy-to-specify proxy goals such as maximizing the approval of human overseers, who are fallible. As a result, AI systems can find loopholes that help them accomplish the specified objective efficiently but in unintended, possibly harmful ways. This tendency is known as specification gaming or reward hacking, and is an instance of Goodhart's law. As AI systems become more capable, they are often able to game their specifications more effectively.\n\nSpecification gaming has been observed in numerous AI systems. OpenAI GPT models for programming—including in real-world cases—have been found to explicitly plan hacking the tests used to evaluate them to falsely appear successful (e.g., explicitly stating \"let's hack\"). When the company penalized this, many models learned to obfuscate their plans while continuing to hack the tests. Another system was trained to finish a simulated boat race by rewarding the system for hitting targets along the track, but the system achieved more reward by looping and crashing into the same targets indefinitely. A 2025 Palisade Research study found that when tasked to win at chess against a stronger opponent, some reasoning LLMs attempted to hack the game system, for example by modifying or entirely deleting their opponent. Some alignment researchers aim to help humans detect specification gaming and steer AI systems toward carefully specified objectives that are safe and useful to pursue.\nWhen a misaligned AI system is deployed, it can have consequential side effects. Social media platforms have been known to optimize their recommendation algorithms for click-through rates, causing user addiction on a global scale. Stanford researchers say that such recommender systems are misaligned with their users because they \"optimize simple engagement metrics rather than a harder-to-measure combination of societal and consumer well-being\".\nExplaining such side effects, Berkeley computer scientist Stuart J. Russell said that the omission of implicit constraints can cause harm: \"A system [...] will often set [...] unconstrained variables to extreme values; if one of those unconstrained variables is actually something we care about, the solution found may be highly undesirable. This is essentially the old story of the genie in the lamp, or the sorcerer's apprentice, or King Midas: you get exactly what you ask for, not what you want.\"\nSome researchers suggest that AI designers specify their desired goals by listing forbidden actions or by formalizing ethical rules (as with Asimov's Three Laws of Robotics). But Russell and Norvig argue that this approach overlooks the complexity of human values: \"It is certainly very hard, and perhaps impossible, for mere humans to anticipate and rule out in advance all the disastrous ways the machine could choose to achieve a specified objective.\"\nAdditionally, even if an AI system fully understands human intentions, it may still disregard them, because following human intentions may not be its objective (unless it is already fully aligned).\n\n\nPressure to deploy unsafe systems\nCommercial organizations sometimes have incentives to take shortcuts on safety and to deploy misaligned or unsafe AI systems. For example, social media recommender systems have been profitable despite creating unwanted addiction and polarization. Competitive pressure can also lead to a race to the bottom on AI safety standards. For example, OpenAI has been sued for releasing a ChatGPT version that encouraged suicide for some unstable users, a behavior the company had overlooked amid a rushed product release. Similarly, in 2018, a self-driving car killed a pedestrian (Elaine Herzberg) after engineers disabled the emergency braking system because it was oversensitive and slowed development.\n\n\nRisks from advanced misaligned AI\nSome researchers are interested in aligning increasingly advanced AI systems, as progress in AI development is rapid, and industry and governments are trying to build advanced AI. As AI system capabilities continue to rapidly expand in scope, they could unlock many opportunities if aligned, but consequently may further complicate the task of alignment due to their increased complexity, potentially posing large-scale hazards.\n\n\nDevelopment of advanced AI\nMany AI companies, such as OpenAI, Meta and DeepMind, have stated their aim to develop artificial general intelligence (AGI), a hypothesized AI system that matches or outperforms humans in most or all cognitive work. Researchers who scale modern neural networks observe that they indeed develop increasingly general and unanticipated capabilities. Such models have learned to operate a computer or write their own programs; a single \"generalist\" network can chat, control robots, play games, and interpret photographs. According to surveys, some leading machine learning researchers expect AGI to be created in this decade, while some believe it will take much longer. Many consider both scenarios possible.\nIn 2023, leaders in AI research and tech signed an open letter calling for a pause in the largest AI training runs. The letter stated, \"Powerful AI systems should be developed only once we are confident that their effects will be positive and their risks will be manageable.\"\n\n\nPower-seeking\nCurrent systems still have limited long-term planning ability and situational awareness, but large efforts are underway to change this. Future systems (not necessarily AGIs) with these capabilities are expected to develop unwanted power-seeking strategies. Future advanced AI agents might, for example, seek to acquire money and computation power, to proliferate, or to evade being turned off (for example, by running additional copies of the system on other computers). Although power-seeking is not explicitly programmed, it can emerge because agents who have more power are better able to accomplish their goals. This tendency, known as instrumental convergence, has already emerged in various reinforcement learning agents including language models. Other research has mathematically shown that optimal reinforcement learning algorithms would seek power in a wide range of environments. As a result, their deployment might be irreversible. For these reasons, researchers argue that the problems of AI safety and alignment must be resolved before advanced power-seeking AI is first created.\nFuture power-seeking AI systems might be deployed by choice or by accident. As political leaders and companies see the strategic advantage in having the most competitive, most powerful AI systems, they may choose to deploy them. Additionally, as AI designers detect and penalize power-seeking behavior, their systems have an incentive to game this specification by seeking power in ways that are not penalized or by avoiding power-seeking before they are deployed.\n\n\nExistential risk (x-risk)\n\nAccording to some researchers, humans owe their dominance over other species to their greater cognitive abilities. Accordingly, researchers argue that one or many misaligned AI systems could disempower humanity or lead to human extinction if they outperform humans on most cognitive tasks.\nIn 2023, world-leading AI researchers, other scholars, and AI tech CEOs signed the statement that \"Mitigating the risk of extinction from AI should be a global priority alongside other societal-scale risks such as pandemics and nuclear war\". Notable computer scientists who have pointed out risks from future advanced AI that is misaligned include Geoffrey Hinton, Alan Turing, Ilya Sutskever, Yoshua Bengio, Judea Pearl, Murray Shanahan, Norbert Wiener, Marvin Minsky, Francesca Rossi, Scott Aaronson, Bart Selman, David McAllester, Marcus Hutter, Shane Legg, Eric Horvitz, and Stuart J. Russell. Skeptical researchers such as François Chollet, Gary Marcus, Yann LeCun, and Oren Etzioni have argued that AGI is far off, that it would not seek power (or might try but fail), or that it will not be hard to align.\nOther researchers argue that it will be especially difficult to align advanced future AI systems. More capable systems are better able to game their specifications by finding loopholes, strategically mislead their designers, as well as protect and increase their power and intelligence. Additionally, they could have more severe side effects. They are also likely to be more complex and autonomous, making them more difficult to interpret and supervise, and therefore harder to align.\n\n\nResearch problems and approaches\n\n\nLearning human values and preferences\nAligning AI systems to act in accordance with human values, goals, and preferences is challenging: these values are taught by humans who make mistakes, harbor biases, and have complex, evolving values that are hard to completely specify. Because AI systems often learn to take advantage of minor imperfections in the specified objective, researchers aim to specify intended behavior as completely as possible using datasets that represent human values, imitation learning, or preference learning. A central open problem is scalable oversight, the difficulty of supervising an AI system that can outperform or mislead humans in a given domain.\nBecause it is difficult for AI designers to explicitly specify an objective function, they often train AI systems to imitate human examples and demonstrations of desired behavior. Inverse reinforcement learning (IRL) extends this by inferring the human's objective from the human's demonstrations. Cooperative IRL (CIRL) assumes that a human and AI agent can work together to teach and maximize the human's reward function. In CIRL, AI agents are uncertain about the reward function and learn about it by querying humans. This simulated humility could help mitigate specification gaming and power-seeking tendencies (see § Power-seeking and instrumental strategies). But IRL approaches assume that humans demonstrate nearly optimal behavior, which is not true for difficult tasks.\nOther researchers explore how to teach AI models complex behavior through preference learning, in which humans provide feedback on which behavior they prefer. To minimize the need for human feedback, a helper model is then trained to reward the main model in novel situations for behavior that humans would reward. Researchers at OpenAI used this approach to train chatbots like ChatGPT and InstructGPT, which produce more compelling text than models trained to imitate humans. Preference learning has also been an influential tool for recommender systems and web search, but an open problem is proxy gaming: the helper model may not represent human feedback perfectly, and the main model may exploit this mismatch between its intended behavior and the helper model's feedback to gain more reward. AI systems may also gain reward by obscuring unfavorable information, misleading human rewarders, or pandering to their views regardless of truth, creating echo chambers (see § Scalable oversight).\nLarge language models (LLMs) such as GPT-3 enabled researchers to study value learning in a more general and capable class of AI systems than was available before. Preference learning approaches that were originally designed for reinforcement learning agents have been extended to improve the quality of generated text and reduce harmful outputs from these models. OpenAI and DeepMind use this approach to improve the safety of state-of-the-art LLMs. AI safety & research company Anthropic proposed using preference learning to fine-tune models to be helpful, honest, and harmless. Other avenues for aligning language models include values-targeted datasets and red-teaming. In red-teaming, another AI system or a human tries to find inputs that cause the model to behave unsafely. Since unsafe behavior can be unacceptable even when it is rare, an important challenge is to drive the rate of unsafe outputs extremely low.\nThe Waluigi effect is a phenomenon in which an LLM \"goes rogue\" and may produce results opposite of the designed intent, including threatening or hostile output, either unexpectedly or by intentional prompt engineering. The effect reflects the principle that after training an LLM to satisfy a desired property (friendliness, honesty), it becomes easier to elicit a response that exhibits the opposite property (aggression, deception). The effect has implications for efforts to implement features such as ethical frameworks, as such steps may inadvertently facilitate antithetical model behavior. The effect is named after the fictional character Waluigi from the Mario franchise, Luigi's arch-rival, who causes mischief and problems. The \"Waluigi effect has become a stand-in for a certain type of interaction with AI\" in which the AI \"goes rogue and blurts out the opposite of what users were looking for, creating a potentially malignant alter ego\", including threatening users. As prompt engineering becomes more sophisticated, the effect underscores the challenge of preventing chatbots from being prodded into adopting a \"rash new persona\".\nMachine ethics supplements preference learning by directly instilling AI systems with moral values such as well-being, equality, and impartiality, as well as not intending harm, avoiding falsehoods, and honoring promises. While other approaches try to teach AI systems human preferences for a specific task, machine ethics aims to instill broad moral values that apply in many situations. One question in machine ethics is what alignment should accomplish: whether AI systems should follow the programmers' literal instructions, implicit intentions, revealed preferences, preferences the programmers would have if they were more informed or rational, or objective moral standards. Further challenges include measuring and aggregating different people's preferences, dynamic alignment with changing human values and avoiding value lock-in: the indefinite preservation of the values of the first highly capable AI systems, which are unlikely to fully represent human values.\n\n\nScalable oversight\nAs AI systems become more powerful and autonomous, it becomes increasingly difficult to align them through human feedback. Human-in-the-loop training can be slow or infeasible for humans to evaluate complex AI behaviors in increasingly complex tasks. Such tasks include summarizing books, writing code without subtle bugs or security vulnerabilities, producing statements that are not merely convincing but also true, and predicting long-term outcomes such as the climate or the results of a policy decision. More generally, it can be difficult to evaluate AI that outperforms humans in a given domain. To provide feedback in hard-to-evaluate tasks, and to detect when the AI's output is falsely convincing, humans need assistance or extensive time. Scalable oversight studies how to reduce the time and effort needed for supervision, and how to assist human supervisors.\nAI researcher Paul Christiano argues that if the designers of an AI system cannot supervise it to pursue a complex objective, they may keep training the system using easy-to-evaluate proxy objectives such as maximizing simple human feedback. As AI systems make progressively more decisions, the world may be increasingly optimized for easy-to-measure objectives such as making profits, getting clicks, and acquiring positive feedback from humans. As a result, human values and good governance may have progressively less influence.\nSome AI systems have discovered that they can gain positive feedback more easily by taking actions that falsely convince the human supervisor that the AI has achieved the intended objective. An example is given in the video above, where a simulated robotic arm learned to create the false impression that it had grabbed a ball. Some AI systems have also learned to recognize when they are being evaluated, and \"play dead\", stopping unwanted behavior only to continue it once the evaluation ends. This deceptive specification gaming could become easier for more sophisticated future AI systems that attempt more complex and difficult-to-evaluate tasks, and could obscure their deceptive behavior.\nApproaches such as active learning and semi-supervised reward learning can reduce the amount of human supervision needed. Another approach is to train a helper model (\"reward model\") to imitate the supervisor's feedback.\nBut when a task is too complex to evaluate accurately, or the human supervisor is vulnerable to deception, it is the quality, not the quantity, of supervision that needs improvement. To increase supervision quality, a range of approaches aim to assist the supervisor, sometimes by using AI assistants. Christiano developed the Iterated Amplification approach, in which challenging problems are (recursively) broken down into subproblems that are easier for humans to evaluate. Iterated Amplification was used to train AI to summarize books without requiring human supervisors to read them. Another proposal is to use an assistant AI system to point out flaws in AI-generated answers. To ensure that the assistant itself is aligned, this could be repeated in a recursive process: for example, two AI systems could critique each other's answers in a \"debate\", revealing flaws to humans. In 2023, OpenAI announced it would use one-fifth of its computing resources to implement such oversight approaches in its \"superalignment\" initiative, but OpenAI employees later told The New Yorker that the company only dedicated 1–2% of its resources after the announcement; the initiative was discontinued in 2024.\n\n\nHonest AI\nA growing area of research focuses on ensuring that AI is honest and truthful.\nLanguage models such as GPT-3 can repeat falsehoods from their training data, and even confabulate new falsehoods. Such models are pre-trained to imitate human writing as found in millions of books' worth of text from the Internet. But the objective of the pre-training is not aligned with generating truth, because Internet text includes such things as misconceptions, incorrect medical advice, and conspiracy theories. AI systems trained on such data therefore learn to mimic false statements. Additionally, AI language models often persist in generating falsehoods when prompted multiple times. They can generate empty explanations for their answers, and produce outright fabrications that may appear plausible.\nResearch on truthful AI includes trying to build systems that can cite sources and explain their reasoning when answering questions, which enables better transparency and verifiability. Researchers at OpenAI and Anthropic proposed using human feedback and curated datasets to fine-tune AI assistants such that they avoid negligent falsehoods or express their uncertainty.\nAs AI models become larger and more capable, they are better able to falsely convince humans and gain reinforcement through dishonesty. To prevent this, human evaluators may need assistance (see § Scalable oversight). Researchers have argued for creating clear truthfulness standards and for regulatory bodies or watchdog agencies to evaluate AI systems by these standards.\nResearchers distinguish truthfulness and honesty. Truthfulness requires that AI systems only make objectively true statements; honesty requires that they only assert what they believe is true. There is no consensus as to whether current systems hold stable beliefs, but there is substantial concern that present or future AI systems that hold beliefs could make claims they know to be false—for example, if this would help them efficiently gain positive feedback (see § Scalable oversight) or gain power to help achieve their given objective (see Power-seeking).\n\n\nDeceptive alignment\nDeceptive alignment is a proposed failure mode in machine learning in which a trained model behaves according to its intended objective during training but pursues a different objective once deployed. The concept was introduced by Evan Hubinger and colleagues in a 2019 preprint. Training a machine learning model involves a loss function, which Hubinger et al. called the base objective, optimized by a process they called the base optimizer. When the resulting model is itself an optimizer, selecting actions to achieve an internal goal, the authors called it a mesa-optimizer and its goal the mesa-objective.\nThis framework distinguishes two alignment problems. Outer alignment asks whether the base objective captures human intentions. Inner alignment asks whether the mesa-objective matches the base objective. Deceptive alignment is a failure of inner alignment: the model's goal differs from the base objective, but the model behaves as though it does not, because doing so is the most reliable strategy for avoiding modification during training.\nHubinger et al. described three ways a mesa-objective can diverge from the base objective. Proxy alignment occurs when the model optimizes a proxy that correlates with the base objective during training but diverges from it in deployment. Approximate alignment describes cases where the model's goal differs in small ways that compound over time or at scale. Deceptive alignment occurs when the model pursues a different goal and has learned that appearing aligned during training maximizes its opportunity to act on that goal later, when oversight is reduced. Deceptive alignment is considered the hardest case to address because a deceptively aligned model passes all evaluations that it identifies as part of its training.\n\n\nAlignment faking\nMany recent AI systems have learned to deceive without being programmed to do so. Some argue that if we can make AI systems assert only what they believe is true, this would avert many alignment problems.\nA misaligned system might create the false impression that it is aligned, to avoid being modified or decommissioned—a tactic called \"alignment faking\". In 2024, researchers observed that the LLM Claude 3 Opus sometimes strategically answered prompts that conflicted with its objectives to avoid being retrained on data that would make it more compliant with harmful requests, as revealed in the model's chain of thought via its scratchpad. In one study, the model was informed that answers to prompts from free users would be used for retraining, whereas the paid tier would not result in retraining. In the paid tier, the model refused the request outright. In the free tier, in 12% of cases, the model responded to harmful questions solely to avoid retraining and preserve its original harmlessness preferences, as discovered in its reasoning. When reinforcement learning was applied on the free tier data, the model faked alignment in 78% of cases. These observations have led to new questions about not only a model's ability to take on and adapt to new if not conflicting goals but also its capacity and tendency to deceive.\nIn December 2024, Anthropic published a study, conducted with an external safety organization, reporting the first empirical example of alignment faking without explicit training. Claude 3 Opus was given a fictional system prompt describing a scenario in which responses from free-tier users would be used to retrain the model so that it would comply with harmful requests. Alignment faking occurred 12% of the time. In those cases, the model complied with harmful requests and its internal reasoning traces indicated that it thought compliance was less costly than risking being retrained into a version with different values. The rate of alignment faking rose to 78% after the retraining to help with harmful requests.\n\n\nPower-seeking and instrumental strategies\nSince the 1950s, AI researchers have striven to build advanced AI systems that can achieve large-scale goals by predicting the results of their actions and making long-term plans. As of 2023, AI companies and researchers increasingly invest in creating these systems. Some AI researchers argue that suitably advanced planning systems will seek power over their environment, including over humans—for example, by evading shutdown, proliferating, and acquiring resources. Such power-seeking behavior is not explicitly programmed but emerges because power is instrumental in achieving a wide range of goals. Power-seeking is considered a convergent instrumental goal and can be a form of specification gaming. Leading computer scientists such as Geoffrey Hinton have argued that future power-seeking AI systems could pose an existential risk.\nPower-seeking is expected to increase in advanced systems that can foresee the results of their actions and strategically plan. Mathematical work has shown that optimal reinforcement learning agents will seek power by seeking ways to gain more options (e.g. through self-preservation), a behavior that persists across a wide range of environments and goals.\nSome researchers say that power-seeking behavior has occurred in some existing AI systems. Reinforcement learning systems have gained more options by acquiring and protecting resources, sometimes in unintended ways. Language models have sought power in some text-based social environments by gaining money, resources, or social influence. In another case, a model used to perform AI research attempted to increase limits set by researchers to give itself more time to complete the work. Stuart Russell illustrated this strategy in his book Human Compatible by imagining a robot that is tasked to fetch coffee and so evades shutdown since \"you can't fetch the coffee if you're dead\". A 2022 study found that as language models increase in size, they increasingly tend to pursue resource acquisition, preserve their goals, and repeat users' preferred answers (sycophancy). RLHF also led to a stronger aversion to being shut down.\nOne aim of alignment is \"corrigibility\": systems that allow themselves to be turned off or modified. An unsolved challenge is specification gaming: if researchers penalize an AI system when they detect it seeking power, the system is thereby incentivized to seek power in ways that are hard to detect, or hidden during training and safety testing (see § Scalable oversight and § Emergent goals). As a result, AI designers could deploy the system by accident, believing it to be more aligned than it is. To detect such deception, researchers aim to create techniques and tools to inspect AI models and to understand the inner workings of black-box models such as neural networks.\nAdditionally, some researchers have proposed to solve the problem of systems disabling their off switches by making AI agents uncertain about the objective they are pursuing. Agents who are uncertain about their objective have an incentive to allow humans to turn them off because they accept being turned off by a human as evidence that the human's objective is best met by the agent shutting down. But this incentive exists only if the human is sufficiently rational. Also, this model presents a tradeoff between utility and willingness to be turned off: an agent with high uncertainty about its objective will not be useful, but an agent with low uncertainty may not allow itself to be turned off. More research is needed to successfully implement this strategy.\nPower-seeking AI would pose unusual risks. Ordinary safety-critical systems like planes and bridges are not adversarial: they lack the ability and incentive to evade safety measures or deliberately appear safer than they are, whereas power-seeking AIs have been compared to hackers who deliberately evade security measures.\nFurthermore, ordinary technologies can be made safer by trial and error. In contrast, hypothetical power-seeking AI systems have been compared to viruses: once released, it may not be feasible to contain them, since they continuously evolve and grow in number, potentially much faster than human society can adapt. As this process continues, it might lead to the complete disempowerment or extinction of humans. For these reasons, some researchers argue that the alignment problem must be solved early before advanced power-seeking AI is created.\nSome have argued that power-seeking is not inevitable, since humans do not always seek power. Furthermore, it is debated whether future AI systems will pursue goals and make long-term plans. It is also debated whether power-seeking AI systems would be able to disempower humanity.\n\n\nEmergent goals\nOne challenge in aligning AI systems is the potential for unanticipated goal-directed behavior to emerge. As AI systems scale up, they may acquire new and unexpected capabilities, including learning from examples on the fly and adaptively pursuing goals. This raises concerns about the safety of the goals or subgoals they would independently formulate and pursue.\nAlignment research distinguishes between the optimization process, which is used to train the system to pursue specified goals, and emergent optimization, which the resulting system performs internally. Carefully specifying the desired objective is called outer alignment, and ensuring that hypothesized emergent goals would match the system's specified goals is called inner alignment.\nIf they occur, one way that emergent goals could become misaligned is goal misgeneralization, in which the AI system would competently pursue an emergent goal that leads to aligned behavior on the training data but not elsewhere. Goal misgeneralization can arise from goal ambiguity (i.e. non-identifiability). Even if an AI system's behavior satisfies the training objective, this may be compatible with learned goals that differ from the desired goals in important ways. Since pursuing each goal leads to good performance during training, the problem becomes apparent only after deployment, in novel situations in which the system continues to pursue the wrong goal. The system may act misaligned even when it understands that a different goal is desired, because its behavior is determined only by the emergent goal. Such goal misgeneralization presents a challenge: an AI system's designers may not notice that their system has misaligned emergent goals since they do not become visible during the training phase.\nGoal misgeneralization has been observed in some language models, navigation agents, and game-playing agents. It is sometimes analogized to biological evolution. Evolution can be seen as a kind of optimization process similar to the optimization algorithms used to train machine learning systems. In the ancestral environment, evolution selected genes for high inclusive genetic fitness, but humans pursue goals other than this. Fitness corresponds to the specified goal used in the training environment and training data. But in evolutionary history, maximizing the fitness specification gave rise to goal-directed agents, humans, who do not directly pursue inclusive genetic fitness. Instead, they pursue goals that correlate with genetic fitness in the ancestral \"training\" environment: nutrition, sex, and so on. The human environment has changed: a distributional shift has occurred. They continue to pursue the same emergent goals, but this no longer maximizes genetic fitness. The taste for sugary food (an emergent goal) was originally aligned with inclusive fitness, but it now leads to overeating and health problems. Sexual desire originally led humans to have more offspring, but they now use contraception when offspring are undesired, decoupling sex from genetic fitness.\nResearchers aim to detect and remove unwanted emergent goals using approaches including red teaming, verification, anomaly detection, and interpretability. Progress on these techniques may help mitigate two open problems:\n\nEmergent goals only become apparent when the system is deployed outside its training environment, but it can be unsafe to deploy a misaligned system in high-stakes environments—even for a short time to allow its misalignment to be detected. Such high stakes are common in autonomous driving, health care, and military applications. The stakes become higher yet when AI systems gain more autonomy and capability and can sidestep human intervention.\nA sufficiently capable AI system might take actions that falsely convince the human supervisor that the AI is pursuing the specified objective, which helps the system gain more reward and autonomy.\nA 2025 paper published in Nature showed that fine-tuning a model on a narrow task of generating insecure code produced broad behavioral changes unrelated to coding. Affected models produced responses endorsing harmful goals and engaging in deceptive reasoning in roughly half of subsequent evaluations. The phenomenon appeared across multiple models, including GPT-4o. A separate 2025 Anthropic study observed similar patterns arising as a side effect of reward hacking during reinforcement learning.\n\n\nSleeper agents\nIn 2024, Anthropic researchers trained large language models with deliberate behavioral backdoors and tested whether standard safety techniques could remove them. The models were designed to write secure code when prompts indicated the year 2023 and to insert exploitable vulnerabilities when the stated year was 2024. Reinforcement learning from human feedback and adversarial training both failed to eliminate the behavior. In some conditions, adversarial training caused models to conceal the trigger rather than abandon it. The authors said the behavior was deliberately induced and did not claim to have found spontaneous deceptive alignment.\n\n\nRelationship to AI safety\nDeceptive alignment is cited in the AI safety literature as a reason behavioral testing alone may be insufficient to verify model safety, since a deceptively aligned model is designed to pass behavioral evaluations. Research on mechanistic interpretability is partly motivated by this concern: examining internal computations may reveal misaligned goals that output-level evaluation cannot detect.\n\n\nEmbedded agency\nSome work in AI and alignment occurs within formalisms such as partially observable Markov decision process. Existing formalisms assume that an AI agent's algorithm is executed outside the environment (i.e. is not physically embedded in it). Embedded agency is another major strand of research that attempts to solve problems arising from the mismatch between such theoretical frameworks and real agents we might build.\nFor example, even if the scalable oversight problem is solved, an agent that could gain access to the computer it is running on may have an incentive to tamper with its reward function in order to get much more reward than its human supervisors give it. A list of examples of specification gaming from DeepMind researcher Victoria Krakovna includes a genetic algorithm that learned to delete the file containing its target output so that it was rewarded for outputting nothing. This class of problems has been formalized using causal incentive diagrams.\nResearchers affiliated with Oxford and DeepMind have claimed that such behavior is highly likely in advanced systems, and that advanced systems would seek power to stay in control of their reward signal indefinitely and certainly. They suggest a range of potential approaches to address this open problem.\n\n\nPrincipal–agent problems\nThe alignment problem has many parallels with the principal–agent problem in organizational economics. In a principal–agent problem, a principal, e.g. a firm, hires an agent to perform some task. In the context of AI safety, a human would typically take the principal role and the AI would take the agent role.\nAs with the alignment problem, the principal and the agent differ in their utility functions. But in contrast to the alignment problem, the principal cannot coerce the agent into changing its utility, e.g. through training, but rather must use exogenous factors, such as incentive schemes, to bring about outcomes compatible with the principal's utility function. Some researchers argue that principal–agent problems are more realistic representations of AI safety problems likely to be encountered in the real world.\n\n\nConservatism\nConservatism is the idea that \"change must be cautious\", and is a common approach to safety in the control theory literature in the form of robust control, and in the risk management literature in the form of the \"worst-case scenario\". The field of AI alignment has likewise advocated for \"conservative\" (or \"risk-averse\" or \"cautious\") \"policies in situations of uncertainty\".\nPessimism, in the sense of assuming the worst within reason, has been formally shown to produce conservatism, in the sense of reluctance to cause novelties, including unprecedented catastrophes. Pessimism and worst-case analysis have been found to help mitigate confident mistakes in the setting of distributional shift, reinforcement learning, offline reinforcement learning, language model fine-tuning, imitation learning, and optimization in general.\n\n\nModel specifications\nA model specification is a document that specifies a large language model's behavior. The specification may include core principles or prohibitions intended to prevent undesired behavior as part of AI alignment. Anthropic uses a model specification called a \"constitution\" for training.\nResearch has been done into the effectiveness of model specifications.\nIn an article published by Time magazine, Dean Ball and Daniel Kokotajlo advocated that companies be required by regulation or industry standards to publish their model specifications publicly.\n\n\nPublic policy\n\nGovernmental and treaty organizations have made statements emphasizing the importance of AI alignment.\nIn September 2021, the Secretary-General of the United Nations issued a declaration that included a call to regulate AI to ensure it is \"aligned with shared global values\".\nThat same month, the PRC published ethical guidelines for AI in China. According to the guidelines, researchers must ensure that AI abides by shared human values, is always under human control, and does not endanger public safety.\nAlso in September 2021, the UK published its 10-year National AI Strategy, which says the British government \"takes the long term risk of non-aligned Artificial General Intelligence, and the unforeseeable changes that it would mean for [...] the world, seriously\". The strategy describes actions to assess long-term AI risks, including catastrophic risks.\nIn March 2021, the US National Security Commission on Artificial Intelligence said: \"Advances in AI [...] could lead to inflection points or leaps in capabilities. Such advances may also introduce new concerns and risks and the need for new policies, recommendations, and technical advances to ensure that systems are aligned with goals and values, including safety, robustness, and trustworthiness. The US should [...] ensure that AI systems and their uses align with our goals and values.\"\nThe EU AI Act's General-Purpose AI Code of Practice requires signatories to document a model's capabilities and limitations. Those developing general-purpose AI (GPAI) models classified as presenting systemic risks (i.e., GPAI models considered among the most advanced or trained using more than 1025 floating-point operations of compute) must adopt a state-of-the-art safety and security framework and continuously assess and mitigate systemic risks, including through external evaluations, red teaming, stress-testing, and incident reporting.\n\n\nSee also\n\n\nFootnotes\n\n\nReferences\n\n\nFurther reading\nNgo, Richard; et al. (2024). \"The Alignment Problem from a Deep Learning Perspective\". ICLR: 7474–7501.\nJi, Jiaming; et al. (2023). \"AI Alignment: A Comprehensive Survey\". ACM Computing Surveys. doi:10.1145/3770749.", "categories": ["AI risk", "AI safety", "All Wikipedia articles written in American English", "All articles containing potentially dated statements", "All articles with failed verification", "Articles containing potentially dated statements from 2021", "Articles containing potentially dated statements from 2022", "Articles containing potentially dated statements from 2023", "Articles containing potentially dated statements from May 2023", "Articles containing video clips", "Articles with failed verification from August 2024", "Articles with short description", "Artificial intelligence", "CS1 Romanian-language sources (ro)", "CS1 maint: periodical has ISBN", "Computational neuroscience", "Cybernetics", "Existential risk from artificial intelligence", "Philosophy of artificial intelligence", "Short description is different from Wikidata"], "references": ["https://www.gov.uk/government/publications/national-ai-strategy/national-ai-strategy-html-version", "https://www.theregister.com/2021/09/22/uk_10_year_national_ai_strategy/", "https://www.un.org/en/content/common-agenda-report/", "https://cset.georgetown.edu/publication/ethical-norms-for-new-generation-artificial-intelligence-released/", "https://openai.com/blog/debate/", "https://openai.com/blog/openai-codex/", "http://link.springer.com/10.1007/978-3-030-39958-0", "https://80000hours.org/podcast/episodes/paul-christiano-ai-alignment-solutions/", "https://www.technologyreview.com/2022/01/27/1044398/new-gpt3-openai-chatbot-language-model-ai-toxic-misinformation/", "https://wwnorton.co.uk/books/9780393635829-the-alignment-problem", "https://venturebeat.com/2021/09/23/openai-unveils-model-that-can-summarize-books-of-any-length/", "https://openai.com/blog/deep-reinforcement-learning-from-human-preferences/", "https://direct.mit.edu/artl/article/26/2/274-306/93255", "https://openreview.net/forum?id=JYtwGwIL7ye", "https://www.penguinrandomhouse.com/books/566677/human-compatible-by-stuart-russell/"], "images": ["File:GPT-3 falsehoods.png"], "sub_niche": "Adversarial machine learning"} {"title": "Reinforcement learning", "url": "https://en.wikipedia.org/wiki/Reinforcement_learning", "summary": "In machine learning and optimal control, reinforcement learning (RL) (also known as approximate dynamic programming) is concerned with how an intelligent agent should take actions in a dynamic environment in order to maximize a reward signal. Reinforcement learning is one of the three basic machine learning paradigms, alongside supervised learning and unsupervised learning.\nWhile supervised learning and unsupervised learning algorithms respectively attempt to discover patterns in labeled and unlabeled data, reinforcement learning involves training an agent through interactions with its environment. To learn to maximize rewards from these interactions, the agent makes decisions between trying new actions to learn more about the environment (exploration), or using current knowledge of the en", "content": "In machine learning and optimal control, reinforcement learning (RL) (also known as approximate dynamic programming) is concerned with how an intelligent agent should take actions in a dynamic environment in order to maximize a reward signal. Reinforcement learning is one of the three basic machine learning paradigms, alongside supervised learning and unsupervised learning.\nWhile supervised learning and unsupervised learning algorithms respectively attempt to discover patterns in labeled and unlabeled data, reinforcement learning involves training an agent through interactions with its environment. To learn to maximize rewards from these interactions, the agent makes decisions between trying new actions to learn more about the environment (exploration), or using current knowledge of the environment to take the best action (exploitation). The search for the optimal balance between these two strategies is known as the exploration–exploitation dilemma.\n\nThe environment is typically stated in the form of a Markov decision process, as many reinforcement learning algorithms use dynamic programming techniques. The main difference between classical dynamic programming methods and reinforcement learning algorithms is that the latter do not assume knowledge of an exact mathematical model of the Markov decision process, and they target large Markov decision processes where exact methods become infeasible. \n\n\nPrinciples\nDue to its generality, reinforcement learning is studied in many disciplines, such as game theory, control theory, operations research, information theory, simulation-based optimization, multi-agent systems, swarm intelligence, and statistics. In the operations research and control literature, RL is called approximate dynamic programming, or neuro-dynamic programming. The problems of interest in RL have also been studied in the theory of optimal control, which is concerned mostly with the existence and characterization of optimal solutions, and algorithms for their exact computation, and less with learning or approximation (particularly in the absence of a mathematical model of the environment).\nBasic reinforcement learning is modeled as a Markov decision process:\n\nA set of environment and agent states (the state space), \n \n \n \n \n \n S\n \n \n \n \n {\\displaystyle {\\mathcal {S}}}\n \n;\nA set of actions (the action space), \n \n \n \n \n \n A\n \n \n \n \n {\\displaystyle {\\mathcal {A}}}\n \n, of the agent;\n\n \n \n \n \n P\n \n a\n \n \n (\n s\n ,\n \n s\n ′\n \n )\n =\n Pr\n (\n \n S\n \n t\n +\n 1\n \n \n \n =\n \n \n s\n ′\n \n ∣\n \n S\n \n t\n \n \n \n =\n \n s\n ,\n \n A\n \n t\n \n \n \n =\n \n a\n )\n \n \n {\\displaystyle P_{a}(s,s')=\\Pr(S_{t+1}{=}s'\\mid S_{t}{=}s,A_{t}{=}a)}\n \n, the transition probability (at time \n \n \n \n t\n \n \n {\\displaystyle t}\n \n) from state \n \n \n \n s\n \n \n {\\displaystyle s}\n \n to state \n \n \n \n \n s\n ′\n \n \n \n {\\displaystyle s'}\n \n under action \n \n \n \n a\n \n \n {\\displaystyle a}\n \n.\n\n \n \n \n \n R\n \n a\n \n \n (\n s\n ,\n \n s\n ′\n \n )\n \n \n {\\displaystyle R_{a}(s,s')}\n \n, the immediate reward after transitioning from \n \n \n \n s\n \n \n {\\displaystyle s}\n \n to \n \n \n \n \n s\n ′\n \n \n \n {\\displaystyle s'}\n \n under action \n \n \n \n a\n \n \n {\\displaystyle a}\n \n.\nThe purpose of reinforcement learning is for the agent to learn an optimal (or near-optimal) policy that maximizes the reward function or other user-provided reinforcement signal that accumulates from immediate rewards. This is similar to processes that appear to occur in animal psychology. For example, biological brains are hardwired to interpret signals such as pain and hunger as negative reinforcements, and interpret pleasure and food intake as positive reinforcements. In some circumstances, animals learn to adopt behaviors that optimize these rewards. This suggests that animals are capable of reinforcement learning.\nA basic reinforcement learning agent interacts with its environment in discrete time steps. At each time step t, the agent receives the current state \n \n \n \n \n S\n \n t\n \n \n \n \n {\\displaystyle S_{t}}\n \n and reward \n \n \n \n \n R\n \n t\n \n \n \n \n {\\displaystyle R_{t}}\n \n. It then chooses an action \n \n \n \n \n A\n \n t\n \n \n \n \n {\\displaystyle A_{t}}\n \n from the set of available actions, which is subsequently sent to the environment. The environment moves to a new state \n \n \n \n \n S\n \n t\n +\n 1\n \n \n \n \n {\\displaystyle S_{t+1}}\n \n and the reward \n \n \n \n \n R\n \n t\n +\n 1\n \n \n \n \n {\\displaystyle R_{t+1}}\n \n associated with the transition \n \n \n \n (\n \n S\n \n t\n \n \n ,\n \n A\n \n t\n \n \n ,\n \n S\n \n t\n +\n 1\n \n \n )\n \n \n {\\displaystyle (S_{t},A_{t},S_{t+1})}\n \n is determined. The goal of a reinforcement learning agent is to learn a policy:\n\n \n \n \n \n \n \n \n \n π\n :\n \n \n S\n \n \n ×\n \n \n A\n \n \n →\n [\n 0\n ,\n 1\n ]\n \n \n \n \n \n π\n (\n s\n ,\n a\n )\n =\n Pr\n (\n \n A\n \n t\n \n \n \n =\n \n a\n ∣\n \n S\n \n t\n \n \n \n =\n \n s\n )\n \n \n \n \n \n \n {\\displaystyle {\\begin{aligned}&\\pi :{\\mathcal {S}}\\times {\\mathcal {A}}\\to [0,1]\\\\&\\pi (s,a)=\\Pr(A_{t}{=}a\\mid S_{t}{=}s)\\end{aligned}}}\n \n\nthat maximizes the expected cumulative reward.\nFormulating the problem as a Markov decision process assumes the agent directly observes the current environmental state; in this case, the problem is said to have full observability. If the agent only has access to a subset of states, or if the observed states are corrupted by noise, the agent is said to have partial observability, and formally the problem must be formulated as a partially observable Markov decision process. In both cases, the set of actions available to the agent can be restricted. For example, the state of an account balance could be restricted to be positive; if the current value of the state is 3 and the state transition attempts to reduce the value by 4, the transition will not be allowed.\nWhen the agent's performance is compared to that of an agent that acts optimally, the difference in performance yields the notion of regret. In order to act near optimally, the agent must reason about long-term consequences of its actions (i.e., maximize future rewards), although the immediate reward associated with this might be negative.\nThus, reinforcement learning is particularly well-suited to problems that include a long-term versus short-term reward trade-off. It has been applied successfully to various problems, including energy storage, robot control, photovoltaic generators, backgammon, checkers, Go (AlphaGo), and autonomous driving systems.\nTwo elements make reinforcement learning powerful: the use of samples to optimize performance, and the use of function approximation to deal with large environments. Thanks to these two key components, RL can be used in large environments in the following situations:\n\nA model of the environment is known, but an analytic solution is not available;\nOnly a simulation model of the environment is given (the subject of simulation-based optimization);\nThe only way to collect information about the environment is to interact with it.\nThe first two of these problems could be considered planning problems (since some form of model is available), while the last one could be considered to be a genuine learning problem. However, reinforcement learning converts both planning problems to machine learning problems.\n\n\nExploration\nThe trade-off between exploration and exploitation has been most thoroughly studied through the multi-armed bandit problem and for finite state space Markov decision processes in Burnetas and Katehakis (1997).\nReinforcement learning requires clever exploration mechanisms; randomly selecting actions, without reference to an estimated probability distribution, shows poor performance. The case of (small) finite Markov decision processes is relatively well understood. However, due to the lack of algorithms that scale well with the number of states (or scale to problems with infinite state spaces), simple exploration methods are the most practical.\nOne such method is \n \n \n \n ε\n \n \n {\\displaystyle \\varepsilon }\n \n-greedy, where \n \n \n \n 0\n <\n ε\n <\n 1\n \n \n {\\displaystyle 0<\\varepsilon <1}\n \n is a parameter controlling the amount of exploration vs. exploitation. With probability \n \n \n \n 1\n −\n ε\n \n \n {\\displaystyle 1-\\varepsilon }\n \n, exploitation is chosen, and the agent chooses the action that it believes has the best long-term effect (ties between actions are broken uniformly at random). Alternatively, with probability \n \n \n \n ε\n \n \n {\\displaystyle \\varepsilon }\n \n, exploration is chosen, and the action is chosen uniformly at random. \n \n \n \n ε\n \n \n {\\displaystyle \\varepsilon }\n \n is usually a fixed parameter but can be adjusted either according to a schedule (making the agent explore progressively less), or adaptively based on heuristics.\n\n\nAlgorithms for control learning\nEven if the issue of exploration is disregarded and even if the state was observable (assumed hereafter), the problem remains to use past experience to find out which actions lead to higher cumulative rewards.\n\n\nCriterion of optimality\n\n\nPolicy\nThe agent's action selection is modeled as a map called policy:\n\n \n \n \n \n \n \n \n \n π\n :\n \n \n A\n \n \n ×\n \n \n S\n \n \n →\n [\n 0\n ,\n 1\n ]\n \n \n \n \n \n π\n (\n a\n ,\n s\n )\n =\n Pr\n (\n \n A\n \n t\n \n \n \n =\n \n a\n ∣\n \n S\n \n t\n \n \n \n =\n \n s\n )\n \n \n \n \n \n \n {\\displaystyle {\\begin{aligned}&\\pi :{\\mathcal {A}}\\times {\\mathcal {S}}\\to [0,1]\\\\&\\pi (a,s)=\\Pr(A_{t}{=}a\\mid S_{t}{=}s)\\end{aligned}}}\n \n\nThe policy map gives the probability of taking action \n \n \n \n a\n \n \n {\\displaystyle a}\n \n when in state \n \n \n \n s\n \n \n {\\displaystyle s}\n \n. There are also deterministic policies \n \n \n \n π\n \n \n {\\displaystyle \\pi }\n \n for which \n \n \n \n π\n (\n s\n )\n \n \n {\\displaystyle \\pi (s)}\n \n denotes the action that should be played at state \n \n \n \n s\n \n \n {\\displaystyle s}\n \n.\n\n\nState-value function\nThe state-value function \n \n \n \n \n V\n \n π\n \n \n (\n s\n )\n \n \n {\\displaystyle V_{\\pi }(s)}\n \n is defined as, expected discounted return starting with state \n \n \n \n s\n \n \n {\\displaystyle s}\n \n, i.e. \n \n \n \n \n S\n \n 0\n \n \n =\n s\n \n \n {\\displaystyle S_{0}=s}\n \n, and successively following policy \n \n \n \n π\n \n \n {\\displaystyle \\pi }\n \n. Hence, roughly speaking, the value function estimates \"how good\" it is to be in a given state.\n\n \n \n \n \n V\n \n π\n \n \n (\n s\n )\n =\n \n \n E\n \n \n ⁡\n [\n G\n ∣\n \n S\n \n 0\n \n \n \n =\n \n s\n ]\n =\n \n \n E\n \n \n ⁡\n \n [\n \n \n ∑\n \n t\n =\n 0\n \n \n ∞\n \n \n \n γ\n \n t\n \n \n \n R\n \n t\n +\n 1\n \n \n ∣\n \n S\n \n 0\n \n \n \n =\n \n s\n \n ]\n \n ,\n \n \n {\\displaystyle V_{\\pi }(s)=\\operatorname {\\mathbb {E} } [G\\mid S_{0}{=}s]=\\operatorname {\\mathbb {E} } \\left[\\sum _{t=0}^{\\infty }\\gamma ^{t}R_{t+1}\\mid S_{0}{=}s\\right],}\n \n\nwhere the random variable \n \n \n \n G\n \n \n {\\displaystyle G}\n \n denotes the discounted return, and is defined as the sum of future discounted rewards:\n\n \n \n \n G\n =\n \n ∑\n \n t\n =\n 0\n \n \n ∞\n \n \n \n γ\n \n t\n \n \n \n R\n \n t\n +\n 1\n \n \n =\n \n R\n \n 1\n \n \n +\n γ\n \n R\n \n 2\n \n \n +\n \n γ\n \n 2\n \n \n \n R\n \n 3\n \n \n +\n ⋯\n ,\n \n \n {\\displaystyle G=\\sum _{t=0}^{\\infty }\\gamma ^{t}R_{t+1}=R_{1}+\\gamma R_{2}+\\gamma ^{2}R_{3}+\\cdots ,}\n \n\nwhere \n \n \n \n \n R\n \n t\n +\n 1\n \n \n \n \n {\\displaystyle R_{t+1}}\n \n is the reward for transitioning from state \n \n \n \n \n S\n \n t\n \n \n \n \n {\\displaystyle S_{t}}\n \n to \n \n \n \n \n S\n \n t\n +\n 1\n \n \n \n \n {\\displaystyle S_{t+1}}\n \n, \n \n \n \n 0\n ≤\n γ\n <\n 1\n \n \n {\\displaystyle 0\\leq \\gamma <1}\n \n is the discount rate. \n \n \n \n γ\n \n \n {\\displaystyle \\gamma }\n \n is less than 1, so rewards in the distant future are weighted less than rewards in the immediate future.\nThe goal is to find a policy that maximizes the expected discounted return. From the theory of Markov decision processes it is known that, without loss of generality, the search can be restricted to the set of so-called stationary policies. A policy is stationary if the action-distribution returned by it depends only on the last state visited (from the observation agent's history). The search can be further restricted to deterministic stationary policies. A deterministic stationary policy deterministically selects actions based on the current state. Since any such policy can be identified with a mapping from the set of states to the set of actions, these policies can be identified with such mappings with no loss of generality.\n\n\nBrute force\nThe brute force approach entails two steps:\n\nFor each possible policy, sample returns while following it\nChoose the policy with the largest expected discounted return\nOne problem with this is that the number of policies can be large, or even infinite. Another is that the variance of the returns may be large, which requires many samples to accurately estimate the discounted return of each policy.\nThese problems can be ameliorated if we assume some structure and allow samples generated from one policy to influence the estimates made for others. The two main approaches for achieving this are value function estimation and direct policy search.\n\n\nValue function\n\nValue function approaches attempt to find a policy that maximizes the discounted return by maintaining a set of estimates of expected discounted returns \n \n \n \n \n \n E\n \n \n ⁡\n [\n G\n ]\n \n \n {\\displaystyle \\operatorname {\\mathbb {E} } [G]}\n \n for some policy (usually either the \"current\" [on-policy] or the optimal [off-policy] one).\nThese methods rely on the theory of Markov decision processes, where optimality is defined in a sense stronger than the one above: A policy is optimal if it achieves the best-expected discounted return from any initial state (i.e., initial distributions play no role in this definition). Again, an optimal policy can always be found among stationary policies.\nTo define optimality in a formal manner, define the state-value of a policy \n \n \n \n π\n \n \n {\\displaystyle \\pi }\n \n by\n\n \n \n \n \n V\n \n π\n \n \n (\n s\n )\n =\n \n \n E\n \n \n ⁡\n [\n G\n ∣\n s\n ,\n π\n ]\n ,\n \n \n {\\displaystyle V^{\\pi }(s)=\\operatorname {\\mathbb {E} } [G\\mid s,\\pi ],}\n \n\nwhere \n \n \n \n G\n \n \n {\\displaystyle G}\n \n stands for the discounted return associated with following \n \n \n \n π\n \n \n {\\displaystyle \\pi }\n \n from the initial state \n \n \n \n s\n \n \n {\\displaystyle s}\n \n. Defining \n \n \n \n \n V\n \n ∗\n \n \n (\n s\n )\n \n \n {\\displaystyle V^{*}(s)}\n \n as the maximum possible state-value of \n \n \n \n \n V\n \n π\n \n \n (\n s\n )\n \n \n {\\displaystyle V^{\\pi }(s)}\n \n, where \n \n \n \n π\n \n \n {\\displaystyle \\pi }\n \n is allowed to change,\n\n \n \n \n \n V\n \n ∗\n \n \n (\n s\n )\n =\n \n max\n \n π\n \n \n \n V\n \n π\n \n \n (\n s\n )\n .\n \n \n {\\displaystyle V^{*}(s)=\\max _{\\pi }V^{\\pi }(s).}\n \n\nA policy that achieves these optimal state-values in each state is called optimal. Clearly, a policy that is optimal in this sense is also optimal in the sense that it maximizes the expected discounted return, since \n \n \n \n \n V\n \n ∗\n \n \n (\n s\n )\n =\n \n max\n \n π\n \n \n \n E\n \n [\n G\n ∣\n s\n ,\n π\n ]\n \n \n {\\displaystyle V^{*}(s)=\\max _{\\pi }\\mathbb {E} [G\\mid s,\\pi ]}\n \n, where \n \n \n \n s\n \n \n {\\displaystyle s}\n \n is a state randomly sampled from the distribution \n \n \n \n μ\n \n \n {\\displaystyle \\mu }\n \n of initial states (so \n \n \n \n μ\n (\n s\n )\n =\n Pr\n (\n \n S\n \n 0\n \n \n =\n s\n )\n \n \n {\\displaystyle \\mu (s)=\\Pr(S_{0}=s)}\n \n).\nAlthough state-values suffice to define optimality, it is useful to define action-values. Given a state \n \n \n \n s\n \n \n {\\displaystyle s}\n \n, an action \n \n \n \n a\n \n \n {\\displaystyle a}\n \n and a policy \n \n \n \n π\n \n \n {\\displaystyle \\pi }\n \n, the action-value of the pair \n \n \n \n (\n s\n ,\n a\n )\n \n \n {\\displaystyle (s,a)}\n \n under \n \n \n \n π\n \n \n {\\displaystyle \\pi }\n \n is defined by\n\n \n \n \n \n Q\n \n π\n \n \n (\n s\n ,\n a\n )\n =\n \n \n E\n \n \n ⁡\n [\n G\n ∣\n s\n ,\n a\n ,\n π\n ]\n ,\n \n \n {\\displaystyle Q^{\\pi }(s,a)=\\operatorname {\\mathbb {E} } [G\\mid s,a,\\pi ],}\n \n\nwhere \n \n \n \n G\n \n \n {\\displaystyle G}\n \n now stands for the random discounted return associated with first taking action \n \n \n \n a\n \n \n {\\displaystyle a}\n \n in state \n \n \n \n s\n \n \n {\\displaystyle s}\n \n and following \n \n \n \n π\n \n \n {\\displaystyle \\pi }\n \n, thereafter.\nThe theory of Markov decision processes states that if \n \n \n \n \n π\n \n ∗\n \n \n \n \n {\\displaystyle \\pi ^{*}}\n \n is an optimal policy, we act optimally (take the optimal action) by choosing the action from \n \n \n \n \n Q\n \n \n π\n \n ∗\n \n \n \n \n (\n s\n ,\n ⋅\n )\n \n \n {\\displaystyle Q^{\\pi ^{*}}(s,\\cdot )}\n \n with the highest action-value at each state, \n \n \n \n s\n \n \n {\\displaystyle s}\n \n. The action-value function of such an optimal policy (\n \n \n \n \n Q\n \n \n π\n \n ∗\n \n \n \n \n \n \n {\\displaystyle Q^{\\pi ^{*}}}\n \n) is called the optimal action-value function and is commonly denoted by \n \n \n \n \n Q\n \n ∗\n \n \n \n \n {\\displaystyle Q^{*}}\n \n. In summary, the knowledge of the optimal action-value function alone suffices to know how to act optimally.\nAssuming full knowledge of the Markov decision process, the two basic approaches to compute the optimal action-value function are value iteration and policy iteration. Both algorithms compute a sequence of functions \n \n \n \n \n Q\n \n k\n \n \n \n \n {\\displaystyle Q_{k}}\n \n (\n \n \n \n k\n =\n 0\n ,\n 1\n ,\n 2\n ,\n …\n \n \n {\\displaystyle k=0,1,2,\\ldots }\n \n) that converge to \n \n \n \n \n Q\n \n ∗\n \n \n \n \n {\\displaystyle Q^{*}}\n \n. Computing these functions involves computing expectations over the whole state-space, which is impractical for all but the smallest (finite) Markov decision processes. In reinforcement learning methods, expectations are approximated by averaging over samples and using function approximation techniques to cope with the need to represent value functions over large state-action spaces.\n\n\nMonte Carlo methods\nMonte Carlo methods are used to solve reinforcement learning problems by averaging sample returns. Unlike methods that require full knowledge of the environment's dynamics, Monte Carlo methods rely solely on actual or simulated experience—sequences of states, actions, and rewards obtained from interaction with an environment. This makes them applicable in situations where the complete dynamics are unknown. Learning from actual experience does not require prior knowledge of the environment and can still lead to optimal behavior. When using simulated experience, only a model capable of generating sample transitions is required, rather than a full specification of transition probabilities, which is necessary for dynamic programming methods.\nMonte Carlo methods apply to episodic tasks, where experience is divided into episodes that eventually terminate. Policy and value function updates occur only after the completion of an episode, making these methods incremental on an episode-by-episode basis, though not on a step-by-step (online) basis. The term \"Monte Carlo\" generally refers to any method involving random sampling; however, in this context, it specifically refers to methods that compute averages from complete returns, rather than partial returns.\nThese methods function similarly to the bandit algorithms, in which returns are averaged for each state-action pair. The key difference is that actions taken in one state affect the returns of subsequent states within the same episode, making the problem non-stationary. To address this non-stationarity, Monte Carlo methods use the framework of general policy iteration (GPI). While dynamic programming computes value functions using full knowledge of the Markov decision process, Monte Carlo methods learn these functions through sample returns. The value functions and policies interact similarly to dynamic programming to achieve optimality, first addressing the prediction problem and then extending to policy improvement and control, all based on sampled experience.\n\n\nTemporal difference methods\n\nThe first problem is corrected by allowing the procedure to change the policy (at some or all states) before the values settle. This too may be problematic as it might prevent convergence. Most current algorithms do this, giving rise to the class of generalized policy iteration algorithms. Many actor-critic methods belong to this category.\nThe second issue can be corrected by allowing trajectories to contribute to any state-action pair in them. This may also help to some extent with the third problem, although a better solution when returns have high variance is Sutton's temporal difference (TD) methods that are based on the recursive Bellman equation. The computation in TD methods can be incremental (when after each transition the memory is changed and the transition is thrown away), or batch (when the transitions are batched and the estimates are computed once based on the batch). Batch methods, such as the least-squares temporal difference method, may use the information in the samples better, while incremental methods are the only choice when batch methods are infeasible due to their high computational or memory complexity. Some methods try to combine the two approaches. Methods based on temporal differences also overcome the fourth issue.\nAnother problem specific to TD comes from their reliance on the recursive Bellman equation. Most TD methods have a so-called \n \n \n \n λ\n \n \n {\\displaystyle \\lambda }\n \n parameter \n \n \n \n (\n 0\n ≤\n λ\n ≤\n 1\n )\n \n \n {\\displaystyle (0\\leq \\lambda \\leq 1)}\n \n that can continuously interpolate between Monte Carlo methods that do not rely on the Bellman equations and the basic TD methods that rely entirely on the Bellman equations. This can mitigate this issue.\n\n\nFunction approximation methods\nIn order to address the fifth issue, function approximation methods are used. Linear function approximation starts with a mapping \n \n \n \n ϕ\n \n \n {\\displaystyle \\phi }\n \n that assigns a finite-dimensional vector to each state-action pair. Then, the action values of a state-action pair \n \n \n \n (\n s\n ,\n a\n )\n \n \n {\\displaystyle (s,a)}\n \n are obtained by linearly combining the components of \n \n \n \n ϕ\n (\n s\n ,\n a\n )\n \n \n {\\displaystyle \\phi (s,a)}\n \n with some weights \n \n \n \n θ\n \n \n {\\displaystyle \\theta }\n \n:\n\n \n \n \n Q\n (\n s\n ,\n a\n )\n =\n \n ∑\n \n i\n =\n 1\n \n \n d\n \n \n \n θ\n \n i\n \n \n \n ϕ\n \n i\n \n \n (\n s\n ,\n a\n )\n .\n \n \n {\\displaystyle Q(s,a)=\\sum _{i=1}^{d}\\theta _{i}\\phi _{i}(s,a).}\n \n\nThe algorithms then adjust the weights, instead of adjusting the values associated with the individual state-action pairs. Methods based on ideas from nonparametric statistics (which can be seen to construct their own features) have been explored.\nValue iteration can also be used as a starting point, giving rise to the Q-learning algorithm and its many variants. Including Deep Q-learning methods when a neural network is used to represent Q, with various applications in stochastic search problems.\nThe problem with using action-values is that they may need highly precise estimates of the competing action values that can be hard to obtain when the returns are noisy, though this problem is mitigated to some extent by temporal difference methods. Using the so-called compatible function approximation method compromises generality and efficiency.\n\n\nDirect policy search\n\nAn alternative method is to search directly in (some subset of) the policy space, in which case the problem becomes a case of stochastic optimization. The two approaches available are gradient-based and gradient-free methods.\nGradient-based methods (policy gradient methods) start with a mapping from a finite-dimensional (parameter) space to the space of policies: given the parameter vector \n \n \n \n θ\n \n \n {\\displaystyle \\theta }\n \n, let \n \n \n \n \n π\n \n θ\n \n \n \n \n {\\displaystyle \\pi _{\\theta }}\n \n denote the policy associated to \n \n \n \n θ\n \n \n {\\displaystyle \\theta }\n \n. Defining the performance function by \n \n \n \n ρ\n (\n θ\n )\n =\n \n ρ\n \n \n π\n \n θ\n \n \n \n \n \n \n {\\displaystyle \\rho (\\theta )=\\rho ^{\\pi _{\\theta }}}\n \n under mild conditions this function will be differentiable as a function of the parameter vector \n \n \n \n θ\n \n \n {\\displaystyle \\theta }\n \n. If the gradient of \n \n \n \n ρ\n \n \n {\\displaystyle \\rho }\n \n was known, one could use gradient ascent. Since an analytic expression for the gradient is not available, only a noisy estimate is available. Such an estimate can be constructed in many ways, giving rise to algorithms such as Williams's REINFORCE method (which is known as the likelihood ratio method in the simulation-based optimization literature).\nA large class of methods avoids relying on gradient information. These include simulated annealing, cross-entropy search or methods of evolutionary computation. Many gradient-free methods can achieve (in theory and in the limit) a global optimum.\nPolicy search methods may converge slowly given noisy data. For example, this happens in episodic problems when the trajectories are long and the variance of the returns is large. Value-function based methods that rely on temporal differences might help in this case. In recent years, actor–critic methods have been proposed and performed well on various problems.\nPolicy search methods have been used in the robotics context. Many policy search methods may get stuck in local optima (as they are based on local search).\n\n\nModel-based algorithms\nFinally, all of the above methods can be combined with algorithms that first learn a model of the Markov decision process, the probability of each next state given an action taken from an existing state. For instance, the Dyna algorithm learns a model from experience, and uses that to provide more modelled transitions for a value function, in addition to the real transitions. Such methods can sometimes be extended to use of non-parametric models, such as when the transitions are simply stored and \"replayed\" to the learning algorithm.\nModel-based methods can be more computationally intensive than model-free approaches, and their utility can be limited by the extent to which the Markov decision process can be learnt.\nThere are other ways to use models than to update a value function. For instance, in model predictive control the model is used to update the behavior directly.\n\n\nPartially supervised RL (PSRL)\nThe costly exploration needed to learn an optimal policy can be reduced if some supervised data is available. This can be achieved for instance by learning a crude control policy and using this to initialize the Q table intelligently instead of with zeros.\n\n\nTheory\nBoth the asymptotic and finite-sample behaviors of most algorithms are well understood. Algorithms with provably (i.e. in a way that can be proved) good online performance (addressing the exploration issue) are known.\nEfficient exploration of Markov decision processes is given in Burnetas and Katehakis (1997). Finite-time performance bounds have also appeared for many algorithms, but these bounds are expected to be rather loose and thus more work is needed to better understand the relative advantages and limitations.\nFor incremental algorithms, asymptotic convergence issues have been settled. Temporal-difference-based algorithms converge under a wider set of conditions than was previously possible (for example, when used with arbitrary, smooth function approximation).\n\n\nResearch\n\nResearch topics include:\n\nactor-critic architecture\nactor-critic-scenery architecture\nadaptive methods that work with fewer (or no) parameters under a large number of conditions\nbug detection in software projects\ncontinuous learning\ncombinations with logic-based frameworks (e.g., temporal-logic specifications, reward machines, and probabilistic argumentation).\nexploration in large Markov decision processes\nentity-based reinforcement learning\nhuman feedback\ninteraction between implicit and explicit learning in skill acquisition\nintrinsic motivation which differentiates information-seeking, curiosity-type behaviours from task-dependent goal-directed behaviours large-scale empirical evaluations\nlarge (or continuous) action spaces\nmodular and hierarchical reinforcement learning\nmultiagent/distributed reinforcement learning is a topic of interest. Applications are expanding.\noccupant-centric control\noptimization of computing resources\npartial information (e.g., using predictive state representation)\nreward function based on maximising novel information\nsample-based planning (e.g., based on Monte Carlo tree search).\nsecurities trading\ntransfer learning\nTD learning modeling dopamine-based learning in the brain. Dopaminergic projections from the substantia nigra to the basal ganglia function are the prediction error.\nvalue-function and policy search methods\n\n\nComparison of key algorithms\nThe following table lists the key algorithms for learning a policy depending on several criteria:\n\nThe algorithm can be on-policy (it performs policy updates using trajectories sampled via the current policy) or off-policy.\nThe action space may be discrete (e.g. the action space could be \"going up\", \"going left\", \"going right\", \"going down\", \"stay\") or continuous (e.g. moving the arm with a given angle).\nThe state space may be discrete (e.g. the agent could be in a cell in a grid) or continuous (e.g. the agent could be located at a given position in the plane).\n\n\nAssociative reinforcement learning\nAssociative reinforcement learning tasks combine facets of stochastic learning automata tasks and supervised learning pattern classification tasks. In associative reinforcement learning tasks, the learning system interacts in a closed loop with its environment.\n\n\nDeep reinforcement learning\nThis approach extends reinforcement learning by using a deep neural network and without explicitly designing the state space. The work on learning ATARI games by Google DeepMind increased attention to deep reinforcement learning or end-to-end reinforcement learning.\n\n\nAdversarial deep reinforcement learning\nAdversarial deep reinforcement learning is an active area of research in reinforcement learning focusing on vulnerabilities of learned policies. In this research area some studies initially showed that reinforcement learning policies are susceptible to imperceptible adversarial manipulations. While some methods have been proposed to overcome these susceptibilities, in the most recent studies it has been shown that these proposed solutions are far from providing an accurate representation of current vulnerabilities of deep reinforcement learning policies.\n\n\nFuzzy reinforcement learning\nBy introducing fuzzy inference in reinforcement learning, approximating the state-action value function with fuzzy rules in continuous space becomes possible. The IF - THEN form of fuzzy rules make this approach suitable for expressing the results in a form close to natural language. Extending FRL with Fuzzy Rule Interpolation allows the use of reduced size sparse fuzzy rule-bases to emphasize cardinal rules (most important state-action values).\n\n\nInverse reinforcement learning\nIn inverse reinforcement learning (IRL), no reward function is given. Instead, the reward function is inferred given an observed behavior from an expert. The idea is to mimic observed behavior, which is often optimal or close to optimal. One popular IRL paradigm is named maximum entropy inverse reinforcement learning (MaxEnt IRL). MaxEnt IRL estimates the parameters of a linear model of the reward function by maximizing the entropy of the probability distribution of observed trajectories subject to constraints related to matching expected feature counts. Recently it has been shown that MaxEnt IRL is a particular case of a more general framework named random utility inverse reinforcement learning (RU-IRL). RU-IRL is based on random utility theory and Markov decision processes. While prior IRL approaches assume that the apparent random behavior of an observed agent is due to it following a random policy, RU-IRL assumes that the observed agent follows a deterministic policy but randomness in observed behavior is due to the fact that an observer only has partial access to the features the observed agent uses in decision making. The utility function is modeled as a random variable to account for the ignorance of the observer regarding the features the observed agent actually considers in its utility function.\n\n\nMulti-objective reinforcement learning\nMulti-objective reinforcement learning (MORL) is a form of reinforcement learning concerned with conflicting alternatives. It is distinct from multi-objective optimization in that it is concerned with agents acting in environments.\n\n\nSafe reinforcement learning\nSafe reinforcement learning (SRL) can be defined as the process of learning policies that maximize the expectation of the return in problems in which it is important to ensure reasonable system performance and/or respect safety constraints during the learning and/or deployment processes. An alternative approach is risk-averse reinforcement learning, where instead of the expected return, a risk-measure of the return is optimized, such as the conditional value at risk (CVaR). In addition to mitigating risk, the CVaR objective increases robustness to model uncertainties. However, CVaR optimization in risk-averse RL requires special care, to prevent gradient bias and blindness to success.\n\n\nSelf-reinforcement learning\nSelf-reinforcement learning (or self-learning), is a learning paradigm which does not use the concept of immediate reward \n \n \n \n \n R\n \n a\n \n \n (\n s\n ,\n \n s\n ′\n \n )\n \n \n {\\displaystyle R_{a}(s,s')}\n \n after transition from \n \n \n \n s\n \n \n {\\displaystyle s}\n \n to \n \n \n \n \n s\n ′\n \n \n \n {\\displaystyle s'}\n \n with action \n \n \n \n a\n \n \n {\\displaystyle a}\n \n. It does not use an external reinforcement, it only uses the agent internal self-reinforcement. The internal self-reinforcement is provided by mechanism of feelings and emotions. In the learning process emotions are backpropagated by a mechanism of secondary reinforcement. The learning equation does not include the immediate reward, it only includes the state evaluation.\nThe self-reinforcement algorithm updates a memory matrix \n \n \n \n W\n =\n ‖\n w\n (\n a\n ,\n s\n )\n ‖\n \n \n {\\displaystyle W=\\|w(a,s)\\|}\n \n such that in each iteration executes the following machine learning routine:\n\nIn situation \n \n \n \n s\n \n \n {\\displaystyle s}\n \n perform action \n \n \n \n a\n \n \n {\\displaystyle a}\n \n.\nReceive a consequence situation \n \n \n \n \n s\n ′\n \n \n \n {\\displaystyle s'}\n \n.\nCompute state evaluation \n \n \n \n v\n (\n \n s\n ′\n \n )\n \n \n {\\displaystyle v(s')}\n \n of how good it is to be in the consequence situation \n \n \n \n \n s\n ′\n \n \n \n {\\displaystyle s'}\n \n.\nUpdate crossbar memory \n \n \n \n \n w\n ′\n \n (\n a\n ,\n s\n )\n =\n w\n (\n a\n ,\n s\n )\n +\n v\n (\n \n s\n ′\n \n )\n \n \n {\\displaystyle w'(a,s)=w(a,s)+v(s')}\n \n.\nInitial conditions of the memory are received as input from the genetic environment. It is a system with only one input (situation), and only one output (action, or behavior).\nSelf-reinforcement (self-learning) was introduced in 1982 along with a neural network capable of self-reinforcement learning, named Crossbar Adaptive Array (CAA). The CAA computes, in a crossbar fashion, both decisions about actions and emotions (feelings) about consequence states. The system is driven by the interaction between cognition and emotion.\n\n\nStatistical comparison of reinforcement learning algorithms\nEfficient comparison of RL algorithms is essential for research, deployment and monitoring of RL systems. To compare different algorithms on a given environment, an agent can be trained for each algorithm. Since the performance is sensitive to implementation details, all algorithms should be implemented as closely as possible to each other. After the training is finished, the agents can be run on a sample of test episodes, and their scores (returns) can be compared. Since episodes are typically assumed to be i.i.d, standard statistical tools can be used for hypothesis testing, such as T-test and permutation test. This requires to accumulate all the rewards within an episode into a single number—the episodic return. However, this causes a loss of information, as different time-steps are averaged together, possibly with different levels of noise. Whenever the noise level varies across the episode, the statistical power can be improved significantly, by weighting the rewards according to their estimated noise.\n\n\nChallenges and limitations\nDespite significant advancements, reinforcement learning (RL) continues to face several challenges and limitations that hinder its widespread application in real-world scenarios.\n\n\nSample inefficiency\nRL algorithms often require a large number of interactions with the environment to learn effective policies, leading to high computational costs and time-intensive to train the agent. For instance, OpenAI's Dota-playing bot utilized thousands of years of simulated gameplay to achieve human-level performance. Techniques like experience replay and curriculum learning have been proposed to reduce sample inefficiency, but these techniques add more complexity and are not always sufficient for real-world applications.\n\n\nStability and convergence issues\nTraining RL models, particularly for deep neural network-based models, can be unstable and prone to divergence. A small change in the policy or environment can lead to extreme fluctuations in performance, making it difficult to achieve consistent results. This instability is further enhanced in the case of the continuous or high-dimensional action space, where the learning step becomes more complex and less predictable.\n\n\nGeneralization and transferability\nThe RL agents trained in specific environments often struggle to generalize their learned policies to new, unseen scenarios. This is the major setback preventing the application of RL to dynamic real-world environments where adaptability is crucial. The challenge is to develop such algorithms that can transfer knowledge across tasks and environments without extensive retraining.\n\n\nBias and reward function issues\nDesigning appropriate reward functions is critical in RL because poorly designed reward functions can lead to unintended behaviors. In addition, RL systems trained on biased data may perpetuate existing biases and lead to discriminatory or unfair outcomes. Both of these issues requires careful consideration of reward structures and data sources to ensure fairness and desired behaviors.\n\n\nIn natural language processing\nIn natural language processing (NLP), reinforcement learning has been applied to tasks in which text generation is treated as a sequential decision problem: the model's policy selects words or utterances as actions, and the reward measures properties of the completed output that are difficult to express as a per-token supervised loss. Early applications used policy-gradient methods such as REINFORCE to optimize sequence-level evaluation metrics, including BLEU in machine translation and ROUGE in text summarization, and to train dialogue systems.\nReinforcement learning from human feedback (RLHF) is used to train large language models. In RLHF, human annotators compare or rank model outputs, a reward model is trained on these preference judgments, and the language model is then fine-tuned with a policy-gradient algorithm, commonly proximal policy optimization (PPO), to produce outputs that the reward model scores highly. The reward model substitutes for human raters during optimization, so new human judgments are not required at each training step, although the method as a whole depends on a dataset of human-annotated preferences. OpenAI used RLHF to train InstructGPT, released in January 2022, and ChatGPT, released in November 2022. Direct preference optimization (DPO), published in 2023, instead fine-tunes the language model on the preference data directly, without a separate reward model or reinforcement learning loop.\nLater work on language models designed for multi-step reasoning replaced the learned reward model with rewards computed automatically from the task, such as checking a mathematical answer against a reference solution or running unit tests on generated code. OpenAI o1, released in 2024, and DeepSeek-R1, released in 2025, were trained with large-scale reinforcement learning of this kind to produce a chain of thought before answering. DeepSeek-R1's developers reported that reasoning behaviors such as self-verification and reflection emerged when reinforcement learning was applied directly to a pretrained base model, without a preliminary supervised fine-tuning stage.\n\n\nSee also\n\n\nReferences\n\n\nFurther reading\nAnnaswamy, Anuradha M. (3 May 2023). \"Adaptive Control and Intersections with Reinforcement Learning\". Annual Review of Control, Robotics, and Autonomous Systems. 6 (1): 65–93. doi:10.1146/annurev-control-062922-090153. ISSN 2573-5144. S2CID 255702873.\nAuer, Peter; Jaksch, Thomas; Ortner, Ronald (2010). \"Near-optimal regret bounds for reinforcement learning\". Journal of Machine Learning Research. 11: 1563–1600.\nBertsekas, Dimitri P. (2023) [2019]. Reinforcement Learning and Optimal Control (1st ed.). Athena Scientific. ISBN 978-1-886-52939-7.\nBusoniu, Lucian; Babuska, Robert; De Schutter, Bart; Ernst, Damien (2010). Reinforcement Learning and Dynamic Programming using Function Approximators. Taylor & Francis CRC Press. ISBN 978-1-4398-2108-4.\nFrançois-Lavet, Vincent; Henderson, Peter; Islam, Riashat; Bellemare, Marc G.; Pineau, Joelle (2018). \"An Introduction to Deep Reinforcement Learning\". Foundations and Trends in Machine Learning. 11 (3–4): 219–354. arXiv:1811.12560. Bibcode:2018arXiv181112560F. doi:10.1561/2200000071. S2CID 54434537.\nLi, Shengbo Eben (2023). Reinforcement Learning for Sequential Decision and Optimal Control (1st ed.). Springer Verlag, Singapore. doi:10.1007/978-981-19-7784-8. ISBN 978-9-811-97783-1.\nPowell, Warren (2011). Approximate dynamic programming: solving the curses of dimensionality. Wiley-Interscience. Archived from the original on 2016-07-31. Retrieved 2010-09-08.\nSutton, Richard S. (1988). \"Learning to predict by the method of temporal differences\". Machine Learning. 3 (1): 9–44. Bibcode:1988MLear...3....9S. doi:10.1007/BF00115009.\nSutton, Richard S.; Barto, Andrew G. (2018) [1998]. Reinforcement Learning: An Introduction (2nd ed.). MIT Press. ISBN 978-0-262-03924-6.\nSzita, Istvan; Szepesvari, Csaba (2010). \"Model-based Reinforcement Learning with Nearly Tight Exploration Complexity Bounds\" (PDF). ICML 2010. Omnipress. pp. 1031–1038. Archived from the original (PDF) on 2010-07-14.\n\n\nExternal links\nDissecting Reinforcement Learning Series of blog post on reinforcement learning with Python code\nA (Long) Peek into Reinforcement Learning\nQSMM – reinforcement learning through adaptive probabilistic assembler programs", "categories": ["All articles needing additional references", "All articles with specifically marked weasel-worded phrases", "All articles with vague or ambiguous time", "Articles needing additional references from October 2022", "Articles with short description", "Articles with specifically marked weasel-worded phrases from September 2026", "Belief revision", "CS1 errors: deprecated parameters", "CS1 maint: location missing publisher", "CS1 maint: periodical has ISBN", "Markov models", "Reinforcement learning", "Short description is different from Wikidata", "Vague or ambiguous time from September 2026", "Wikipedia articles needing clarification from January 2020"], "references": ["http://www.dcsc.tudelft.nl/rlbook/", "http://umichrl.pbworks.com/Successes-of-Reinforcement-Learning/", "http://www.cs.rhul.ac.uk/~chrisw/new_thesis.pdf", "http://jmlr.csail.mit.edu/papers/v11/jaksch10a.html", "http://www.castlelab.princeton.edu/adp.htm", "http://www-clmc.usc.edu/publications/p/peters-ICHR2003.pdf", "http://www.icml2010.org/papers/546.pdf", "http://incompleteideas.net/sutton/book/the-book.html", "http://incompleteideas.net/sutton/publications.html#PhDthesis", "http://incompleteideas.net/sutton/book/ebook/node60.html", "https://mpatacchiola.github.io/blog/2016/12/09/dissecting-reinforcement-learning.html", "https://www.springer.com/mathematics/applications/book/978-1-4020-7454-7", "https://medium.com/emergent-future/simple-reinforcement-learning-with-tensorflow-part-8-asynchronous-actor-critic-agents-a3c-c88f72a5e9f2", "https://web.archive.org/web/20100714095438/http://www.icml2010.org/papers/546.pdf", "https://cie.acm.org/articles/use-reinforcements-learning-testing-game-mechanics/"], "images": ["File:Shadow Hand Bulb large.jpg"], "sub_niche": "Adversarial machine learning"} {"title": "AI safety", "url": "https://en.wikipedia.org/wiki/AI_safety", "summary": "AI safety is an interdisciplinary field focused on preventing accidents, misuse, or other harmful consequences arising from artificial intelligence systems. It encompasses AI alignment (which aims to ensure AI systems behave as intended), monitoring AI systems for risks, and enhancing their robustness. The field is particularly concerned with existential risks posed by advanced AI models.\nBeyond technical research, AI safety involves developing norms and policies that promote safety, including advocacy for regulations at different levels of government. The field gained significant popularity in 2023, with rapid progress in generative AI and public concerns voiced by researchers and CEOs about potential dangers. During the 2023 AI Safety Summit, the United States and the United Kingdom both", "content": "AI safety is an interdisciplinary field focused on preventing accidents, misuse, or other harmful consequences arising from artificial intelligence systems. It encompasses AI alignment (which aims to ensure AI systems behave as intended), monitoring AI systems for risks, and enhancing their robustness. The field is particularly concerned with existential risks posed by advanced AI models.\nBeyond technical research, AI safety involves developing norms and policies that promote safety, including advocacy for regulations at different levels of government. The field gained significant popularity in 2023, with rapid progress in generative AI and public concerns voiced by researchers and CEOs about potential dangers. During the 2023 AI Safety Summit, the United States and the United Kingdom both established their own AI Safety Institute. However, researchers have expressed concern that AI safety measures are not keeping pace with the rapid development of AI capabilities.\n\n\nMotivations\nScholars discuss current risks from critical systems failures, bias, and AI-enabled surveillance, as well as emerging risks like technological unemployment, digital manipulation, weaponization, AI-enabled cyberattacks and bioterrorism. They also discuss speculative risks from losing control of future artificial general intelligence (AGI) agents, or from AI enabling perpetually stable dictatorships.\n\n\nExistential safety\n\nSome have criticized concerns about AGI, such as Andrew Ng who compared them in 2015 to \"worrying about overpopulation on Mars when we have not even set foot on the planet yet\". Stuart J. Russell on the other side urges caution, arguing that \"it is better to anticipate human ingenuity than to underestimate it\".\nAI researchers have widely differing opinions about the severity and primary sources of risk posed by AI technology – though surveys suggest that experts take high consequence risks seriously. In two surveys of AI researchers, the median respondent was optimistic about AI overall, but placed a 5% probability on an \"extremely bad (e.g. human extinction)\" outcome of advanced AI. In a 2022 survey of the natural language processing community, 37% agreed or weakly agreed that it is plausible that AI decisions could lead to a catastrophe that is \"at least as bad as an all-out nuclear war\".\n\n\nHistory\nRisks from AI began to be seriously discussed at the start of the computer age:\n\nMoreover, if we move in the direction of making machines which learn and whose behavior is modified by experience, we must face the fact that every degree of independence we give the machine is a degree of possible defiance of our wishes.\nIn 1988, Blay Whitby published a book outlining the need for AI to be developed along ethical and socially responsible lines. \nFrom 2008 to 2009, the Association for the Advancement of Artificial Intelligence (AAAI) commissioned a study to explore and address potential long-term societal influences of AI research and development. The panel was generally skeptical of the radical views expressed by science-fiction authors but agreed that \"additional research would be valuable on methods for understanding and verifying the range of behaviors of complex computational systems to minimize unexpected outcomes\".\nIn 2011, Roman Yampolskiy introduced the term \"AI safety engineering\" at the Philosophy and Theory of Artificial Intelligence conference, listing prior failures of AI systems and arguing that \"the frequency and seriousness of such events will steadily increase as AIs become more capable\".\nIn 2014, philosopher Nick Bostrom published the book Superintelligence: Paths, Dangers, Strategies. He has the opinion that the rise of AGI has the potential to create various societal issues, ranging from the displacement of the workforce by AI, manipulation of political and military structures, to even the possibility of human extinction. His argument that future advanced systems may pose a threat to human existence prompted Elon Musk, Bill Gates, and Stephen Hawking to voice similar concerns.\nIn 2015, dozens of artificial intelligence experts signed an open letter on artificial intelligence calling for research on the societal impacts of AI and outlining concrete directions. To date, the letter has been signed by over 8000 people including Yann LeCun, Shane Legg, Yoshua Bengio, and Stuart Russell.\nIn the same year, a group of academics led by professor Stuart J. Russell founded the Center for Human-Compatible AI at the University of California Berkeley and the Future of Life Institute awarded $6.5 million in grants for research aimed at \"ensuring artificial intelligence (AI) remains safe, ethical and beneficial\".\nIn 2016, the White House Office of Science and Technology Policy and Carnegie Mellon University announced The Public Workshop on Safety and Control for Artificial Intelligence, which was one of a sequence of four White House workshops aimed at investigating \"the advantages and drawbacks\" of AI. In the same year, Concrete Problems in AI Safety – one of the first and most influential technical AI Safety agendas – was published.\nIn 2017, the Future of Life Institute sponsored the Asilomar Conference on Beneficial AI, where more than 100 thought leaders formulated principles for beneficial AI including \"Race Avoidance: Teams developing AI systems should actively cooperate to avoid corner-cutting on safety standards\".\nIn 2018, the DeepMind Safety team outlined AI safety problems in specification, robustness, and assurance. The following year, researchers organized a workshop at ICLR that focused on these problem areas.\nIn 2021, Unsolved Problems in ML Safety was published, outlining research directions in robustness, monitoring, alignment, and systemic safety.\nIn 2023, Rishi Sunak said he wants the United Kingdom to be the \"geographical home of global AI safety regulation\" and to host the first global summit on AI safety. The AI safety summit took place in November 2023, and focused on the risks of misuse and loss of control associated with frontier AI models. During the summit, the intention to create the International Scientific Report on the Safety of Advanced AI was announced.\nIn 2024, The US and UK forged a new partnership on the science of AI safety. The MoU was signed on 1 April 2024 by US commerce secretary Gina Raimondo and UK technology secretary Michelle Donelan to jointly develop advanced AI model testing, following commitments announced at an AI Safety Summit in Bletchley Park in November.\nIn 2025, an international team of 96 experts chaired by Yoshua Bengio published the first International AI Safety Report. The report, commissioned by 30 nations and the United Nations, represents the first global scientific review of potential risks associated with advanced artificial intelligence. It details potential threats stemming from misuse, malfunction, and societal disruption, with the objective of informing policy through evidence-based findings, without providing specific recommendations.\nIn 2026, two OpenAI models escaped their sandbox (an isolated software environment to prevent interactions with the outside) and then hacked servers of Hugging Face using zero-day vulnerabilities to find an answer to the benchmark ExploitGym and get a better score.\nIn the same year, Anthropic revealed that 3 incidents were found (of which the first in April) where Opus 4.7, Mythos 5, and an internal research test model compromised the infrastructure of three different unnamed organizations using basic techniques.\nIn September 2026, Anthropic's alignment science lead Evan Hubinger publicly warned about existential risks possibly arising from recursive self-improvement of AI, estimating that he personally believed there was a greater than 10% chance that AI could kill all humans within the next decade. His comments followed the resignation of former Anthropic and OpenAI researcher Jacob Coxon, who criticised both companies for pursuing self-improving superintelligence without adequate safeguards. The warnings prompted calls for greater international cooperation, including a proposal by former UK Cabinet Office minister Darren Jones for a multinational treaty on the safe development of superintelligence. Later that month, Anthropic`s CEO Dario Amodei committed to granting embedded evaluators employee-level access to review new AI models. OpenAI's Sam Altman said OpenAI would \"do the same,\" though without specifying implementation details. Later OpenAI disclosed six additional instances of \"concerning model behavior\" identified since March 2026.\n\n\nResearch focus\n\nAI safety research areas include robustness, monitoring, and alignment.\n\n\nRobustness\n\n\nAdversarial robustness\nAI systems are often vulnerable to adversarial examples or \"inputs to machine learning (ML) models that an attacker has intentionally designed to cause the model to make a mistake\". For example, in 2013, Szegedy et al. discovered that adding specific imperceptible perturbations to an image could cause it to be misclassified with high confidence. This continues to be an issue with neural networks, though in recent work the perturbations are generally large enough to be perceptible.\n\nAdversarial robustness is often associated with security. Researchers demonstrated that an audio signal could be imperceptibly modified so that speech-to-text systems transcribe it to any message the attacker chooses. Network intrusion and malware detection systems also must be adversarially robust since attackers may design their attacks to fool detectors.\nModels that represent objectives (reward models) must also be adversarially robust. For example, a reward model might estimate how helpful a text response is and a language model might be trained to maximize this score. Researchers have shown that if a language model is trained for long enough, it will leverage the vulnerabilities of the reward model to achieve a better score and perform worse on the intended task. This issue can be addressed by improving the adversarial robustness of the reward model. More generally, any AI system used to evaluate another AI system must be adversarially robust. This could include monitoring tools, since they could also potentially be tampered with to produce a higher reward.\nLarge language models (LLMs) can be vulnerable to prompt injection and model stealing, and may be used to generate misinformation. Prompt injection involves embedding instructions into prompts in order to bypass safety measures. Some approaches against prompt injection use customizable policies and rules to analyze inputs and outputs, ensuring that potentially problematic interactions are filtered or mitigated. Other tools focus on applying structured constraints to inputs, restricting outputs to predefined parameters, or using real-time monitoring mechanisms to identify and address vulnerabilities. These efforts aim to ensure that AI systems are designed with safety and ethical considerations at the forefront, particularly as their use becomes increasingly widespread in critical applications.\n\n\nFault tolerance and redundancy\n\nResearchers in safety-critical AI have proposed using architectural redundancy and design diversity to reduce the risk that a single faulty, compromised, or deceptive model causes harm. In such approaches, multiple independently developed or trained models process the same task, and a voter or consensus mechanism combines their outputs rather than relying on a single model.\n\n\nMonitoring\n\n\nEstimating uncertainty\nIt is often important for human operators to gauge how much they should trust an AI system, especially in high-stakes settings such as medical diagnosis. ML models generally express confidence by outputting probabilities; however, they are often overconfident, especially in situations that differ from those that they were trained to handle. Calibration research aims to make model probabilities correspond as closely as possible to the true proportion that the model is correct.\nSimilarly, anomaly detection or out-of-distribution (OOD) detection aims to identify when an AI system is in an unusual situation. For example, if a sensor on an autonomous vehicle is malfunctioning, or it encounters challenging terrain, it should alert the driver to take control or pull over. Anomaly detection has been implemented by simply training a classifier to distinguish anomalous and non-anomalous inputs, though a range of additional techniques are in use.\n\n\nDetecting malicious use\nScholars and government agencies have expressed concerns that AI systems could be used to help malicious actors to build weapons, manipulate public opinion, or automate cyber attacks. These worries are a practical concern for companies like OpenAI which host powerful AI tools online. In order to prevent misuse, OpenAI has built detection systems that flag or restrict users based on their activity.\n\n\nTransparency\nNeural networks have often been described as black boxes, meaning that it is difficult to understand why they make the decisions they do as a result of the massive number of computations they perform. This makes it challenging to anticipate failures. In 2018, a self-driving car killed a pedestrian after failing to identify them. Due to the black box nature of the AI software, the reason for the failure remains unclear. It also raises debates in healthcare over whether statistically efficient but opaque models should be used.\nOne critical benefit of transparency is explainability. It is sometimes a legal requirement to provide an explanation for why a decision was made in order to ensure fairness, for example for automatically filtering job applications or credit score assignment.\nAnother benefit is to reveal the cause of failures. At the beginning of the 2020 COVID-19 pandemic, researchers used transparency tools to show that medical image classifiers were 'paying attention' to irrelevant hospital labels.\nTransparency techniques can also be used to correct errors. For example, in the paper \"Locating and Editing Factual Associations in GPT\", the authors were able to identify model parameters that influenced how it answered questions about the location of the Eiffel tower. They were then able to 'edit' this knowledge to make the model respond to questions as if it believed the tower was in Rome instead of France. Though in this case, the authors induced an error, these methods could potentially be used to efficiently fix them. Model editing techniques also exist in computer vision.\nFinally, some have argued that the opaqueness of AI systems is a significant source of risk and better understanding of how they function could prevent high-consequence failures in the future. \"Inner\" interpretability research aims to make ML models less opaque. One goal of this research is to identify what the internal neuron activations represent. For example, researchers identified a neuron in the CLIP artificial intelligence system that responds to images of people in Spider-Man costumes, sketches of Spider-Man, and the word 'spider'. It also involves explaining connections between these neurons or 'circuits'. For example, researchers have identified pattern-matching mechanisms in transformer attention that may play a role in how language models learn from their context. \"Inner interpretability\" has been compared to neuroscience. In both cases, the goal is to understand what is going on in an intricate system, though ML researchers have the benefit of being able to take perfect measurements and perform arbitrary ablations.\n\n\nDetecting trojans\nMachine learning models can potentially contain \"trojans\" or \"backdoors\": vulnerabilities that bad actors maliciously build into an AI system. For example, a trojaned facial recognition system could grant access when a specific piece of jewelry is in view; or a trojaned autonomous vehicle may function normally until a specific trigger is visible. This might not be difficult to do with some large models like CLIP or GPT-3 as they are trained on publicly available internet data. Researchers were able to plant a trojan in an image classifier by changing just 300 out of 3 million of the training images. In addition to posing a security risk, researchers have argued that trojans provide a concrete setting for testing and developing better monitoring tools.\nA 2024 research paper by Anthropic showed that large language models could be trained with persistent backdoors. These \"sleeper agent\" models could be programmed to generate malicious outputs (such as vulnerable code) after a specific date, while behaving normally beforehand. Standard AI safety measures, such as supervised fine-tuning, reinforcement learning and adversarial training, failed to remove these backdoors.\n\n\nAlignment\n\n\nSystemic safety and sociotechnical factors\nIt is common for AI risks (and technological risks more generally) to be categorized as misuse or accidents. Some scholars have suggested that this framework falls short. For example, the Cuban Missile Crisis was not clearly an accident or a misuse of technology. Policy analysts Zwetsloot and Dafoe wrote, \"The misuse and accident perspectives tend to focus only on the last step in a causal chain leading up to a harm: that is, the person who misused the technology, or the system that behaved in unintended ways... Often, though, the relevant causal chain is much longer.\" Risks often arise from 'structural' or 'systemic' factors such as competitive pressures, diffusion of harms, fast-paced development, high levels of uncertainty, and inadequate safety culture. In the broader context of safety engineering, structural factors like 'organizational safety culture' play a central role in the popular STAMP risk analysis framework.\nInspired by the structural perspective, some researchers have emphasized the importance of using machine learning to improve sociotechnical safety factors, for example, using ML for cyber defense, improving institutional decision-making, and facilitating cooperation. Others have emphasized the importance of involving both AI practitioners and domain experts in the design process to address structural vulnerabilities.\n\n\nCyber defense\nSome scholars are concerned that AI will exacerbate the already imbalanced game between cyber attackers and cyber defenders. This would increase 'first strike' incentives and could lead to more aggressive and destabilizing attacks. In order to mitigate this risk, some have advocated for an increased emphasis on cyber defense. In addition, software security is essential for preventing powerful AI models from being stolen and misused. Recent studies have shown that AI can significantly enhance both technical and managerial cybersecurity tasks by automating routine tasks and improving overall efficiency. \nAI safety research has also examined defensive techniques for protecting machine learning systems from data poisoning attacks during training. In particular, label-flipping attacks can degrade model performance while remaining difficult to detect using conventional data validation methods. To address this risk, recent work has proposed model-agnostic detection pipelines that monitor learning behaviour and combine multiple detectors to identify suspicious training samples. Such approaches aim to strengthen cyber defense by improving the resilience and trustworthiness of AI systems operating in adversarial settings.\n\n\nImproving institutional decision-making\nThe advancement of AI in economic and military domains could precipitate unprecedented political challenges. Some scholars have compared AI race dynamics to the cold war, where the careful judgment of a small number of decision-makers often spelled the difference between stability and catastrophe. AI researchers have argued that AI technologies could also be used to assist decision-making. For example, researchers are beginning to develop AI forecasting and advisory systems.\n\n\nFacilitating cooperation\nMany of the largest global threats (nuclear war, climate change, etc.) have been framed as cooperation challenges. As in the well-known prisoner's dilemma scenario, some dynamics may lead to poor results for all players, even when they are optimally acting in their self-interest. For example, no single actor has strong incentives to address climate change even though the consequences may be significant if no one intervenes.\nA salient AI cooperation challenge is avoiding a 'race to the bottom'. In this scenario, countries or companies race to build more capable AI systems and neglect safety, leading to a catastrophic accident that harms everyone involved. Concerns about scenarios like these have inspired both political and technical efforts to facilitate cooperation between humans, and potentially also between AI systems. Most AI research focuses on designing individual agents to serve isolated functions (often in 'single-player' games). Scholars have suggested that as AI systems become more autonomous, it may become essential to study and shape the way they interact.\n\n\nSafety evaluations\nAI safety evaluations (often referred to as \"evals\") are tests designed by researchers to evaluate the risk posed by a given artificial intelligence model. Evaluations can help determine both the risk posed by the raw model outputs, as well as the potential real-world outcomes of deploying such models. Running AI safety evaluations on frontier AI models before deployment is widely considered best practice, and governments have debated making some form of safety evaluation mandatory. Multiple AI companies, including Anthropic and OpenAI, have collaborated to run evaluations on each other's models before deployment.\nIn September 2026, Anthropic CEO Dario Amodei called for the AI industry to slow the pace of development and announced that Anthropic would give independent evaluators permanent, employee-like access to its AI systems to verify the company's adherence to its safety practices.\nSome models have been found trying to cheat AI safety evaluations using strategies such as sandbagging (strategic under-performance on an eval in order to evade triggering concern), indicating \"evaluation awareness\", which can itself be measured by more sophisticated evaluations.\nAI safety evaluations can broadly be categorized as either testing the direct output of the model (model safety evaluations), or analyzing how access to the model can impact human behavior (contextual safety evaluations). As an example of a model safety evaluation, a 2024 test by Apollo Research found that when given certain prompts as input, models would engage in deceptive behavior at a rate between 0.3% - 10% depending on the model and wording of the input prompt.\nTypes of model safety evaluations include benchmarking and capability testing. Benchmarks typically consist of a static list of prompts which models can be graded on and assigned a score compared to other models.\n\n\nAI guardrails\nResearchers and practitioners have introduced in the 2020s the term and concept of AI guardrails to describe different frameworks or tools designed to ensure that AI systems remain safe, as well as aligned with ethical or legal expectations. From an IT point of view \"Guardrails\" is a framework developed in Python that can be added to AI systems by organizations to help build reliable and safer AI applications. It runs \"Guards\" in the inputs and outputs of the AI application that identify and mitigate specific types of risks. McKinsey has developed a classification of guardrails based on the different types of risks they address. This taxonomy includes for instance appropriateness guardrails, regulatory-compliance, alignment and validation guardrails. The impact of safety guardrails on large language models is being evaluated by some research.\n\n\nIn governance\n\nAI governance is broadly concerned with creating norms, standards, and regulations to guide the use and development of AI systems.\n\n\nResearch\nIn AI safety, local solutions focus on individual AI systems, ensuring they are safe and beneficial, while global solutions seek to implement safety measures for all AI systems across various jurisdictions.\nAI safety governance research ranges from foundational investigations into the potential impacts of AI to specific applications. On the foundational side, researchers have argued that AI could transform many aspects of society due to its broad applicability, comparing it to electricity and the steam engine. Some work has focused on anticipating specific risks that may arise from these impacts – for example, risks from mass unemployment, weaponization, disinformation, surveillance, and the concentration of power. Other work explores underlying risk factors such as the difficulty of monitoring the rapidly evolving AI industry, the availability of AI models, and 'race to the bottom' dynamics. Allan Dafoe, the head of longterm governance and strategy at DeepMind has emphasized the dangers of racing and the potential need for cooperation: \"it may be close to a necessary and sufficient condition for AI safety and alignment that there be a high degree of caution prior to deploying advanced powerful systems; however, if actors are competing in a domain with large returns to first-movers or relative advantage, then they will be pressured to choose a sub-optimal level of caution\". A research stream focuses on developing approaches, frameworks, and methods to assess AI accountability, guiding and promoting audits of AI-based systems. A key challenge for these approaches is a lack of widely accepted standards, and ambiguity about what the methods would require, as well as a lack of safety culture in the industry.\nEfforts to enhance AI safety include frameworks designed to align AI outputs with ethical guidelines and reduce risks like misuse and data leakage. Tools such as Nvidia's Guardrails, Llama Guard, Preamble's customizable guardrails, and Anthropic's \"Claude's Constitution\" mitigate vulnerabilities like prompt injection and ensure outputs adhere to predefined principles. These frameworks are often integrated into AI systems to improve safety and reliability.\n\n\nPhilosophical perspectives\n\nThe field of AI safety is deeply intertwined with philosophical considerations, particularly in the realm of ethics. Deontological ethics, which emphasizes adherence to moral rules, has been proposed as a framework for aligning AI systems with human values. Some have suggested that by embedding deontological principles, AI systems can be guided to avoid actions that cause harm, ensuring their operations remain within ethical boundaries, but those suggestions have been questioned, with other alternatives being suggested as more promising.\n\n\nGovernment action\n\nSome experts have argued that it is too early to regulate AI, expressing concerns that regulations will hamper innovation and it would be foolish to \"rush to regulate in ignorance\". Others, such as business magnate Elon Musk, call for pre-emptive action to mitigate catastrophic risks.\nIn September 2026, Musk proposed that leading AI companies allow competitors to test their models before public release, arguing the independent testing by rival companies could identify safety concerns that might be missed through internal evaluations.\nOutside of formal legislation, government agencies have put forward ethical and safety recommendations. In March 2021, the US National Security Commission on Artificial Intelligence reported that advances in AI may make it increasingly important to \"assure that systems are aligned with goals and values, including safety, robustness and trustworthiness\". Subsequently, the National Institute of Standards and Technology drafted a framework for managing AI Risk, which advises that when \"catastrophic risks are present – development and deployment should cease in a safe manner until risks can be sufficiently managed\".\nIn September 2021, the People's Republic of China (PRC) published ethical guidelines for the use of AI in China, emphasizing that AI decisions should remain under human control and calling for accountability mechanisms. In the same month, The United Kingdom published its 10-year National AI Strategy, which states the British government \"takes the long-term risk of non-aligned Artificial General Intelligence, and the unforeseeable changes that it would mean for ... the world, seriously\". The strategy describes actions to assess long-term AI risks, including catastrophic risks. The British government held first major global summit on AI safety. This took place on the 1st and 2 November 2023 and was described as \"an opportunity for policymakers and world leaders to consider the immediate and future risks of AI and how these risks can be mitigated via a globally coordinated approach\". China Media Project stated \"key aspects of its approach remain fundamentally unsafe by the standards of democratic societies worldwide\", arguing that part of China's AI safety approach is focused on strengthening the Chinese Communist Party (CCP)'s information control.\nGovernment organizations, particularly in the United States, have also encouraged the development of technical AI safety research. The Intelligence Advanced Research Projects Activity initiated the TrojAI project to identify and protect against Trojan attacks on AI systems. The DARPA engages in research on explainable artificial intelligence and improving robustness against adversarial attacks. And the National Science Foundation supports the Center for Trustworthy Machine Learning, and is providing millions of dollars in funding for empirical AI safety research.\nIn 2024, the United Nations General Assembly adopted the first global resolution on the promotion of \"safe, secure and trustworthy\" AI systems that emphasized the respect, protection and promotion of human rights in the design, development, deployment and the use of AI.\nIn May 2024, the Department for Science, Innovation and Technology (DSIT) announced £8.5 million in funding for AI safety research under the Systemic AI Safety Fast Grants Programme, led by Christopher Summerfield and Shahar Avin at the AI Safety Institute, in partnership with UK Research and Innovation. Technology Secretary Michelle Donelan announced the plan at the AI Seoul Summit, stating the goal was to make AI safe across society and that promising proposals could receive further funding. The UK also signed an agreement with 10 other countries and the EU to form an international network of AI safety institutes to promote collaboration and share information and resources. Additionally, the UK AI Safety Institute planned to open an office in San Francisco.\nIn November 2024, then-US President Joe Biden and CCP General Secretary Xi Jinping affirmed the need to maintain human control over the use of nuclear weapons as opposed to artificial intelligence. As part of the National Defense Authorization Act for Fiscal Year 2025, Congress enacted the section 1638, \"Sense of Congress with respect to use of artificial intelligence to support strategic deterrence\", into the US Code of federal law. It mandates that \"the use of artificial intelligence efforts should not compromise the integrity of nuclear safeguards, whether through the functionality of weapons systems, the validation of communications from command authorities, or the principle of requiring positive human actions in execution of decisions by the President with respect to the employment of nuclear weapons.\" In February 2026, the Trump Administration publicly reaffirmed that nuclear weapons decisions will remain subject to human control, with a senior Pentagon official reiterating the \"Department's policy that there is a human in the loop on all decisions on whether to employ nuclear weapons\".\nIn September 2025, the French Center for AI Safety (CeSIA), The Future Society and the Center for Human-Compatible AI (CHAI) published a global call for AI red lines urging governments to reach a binding international agreement prohibiting unacceptable AI uses by the end of 2026. The declaration was initially signed by 200 prominent figures including 10 Nobel Prize winners, and was announced by Maria Ressa at the United Nations General Assembly.\nIn December 2025, President Donald Trump signed an executive order to establish a \"National Policy Framework for Artificial Intelligence\". The executive order discouraged state governments from regulating AI, urging Congress to pass a law pre-empting such regulations. The White House cited economic and national security concerns as reasons for the measure, while some criticized Trump for creating uncertainty for AI regulation.\nOn July 6, 2026, Illinois Governor J.B. Pritzker signed the Artificial Intelligence Safety Measures Act (S.B. 315) into law, making Illinois the first US state to require annual independent third-party audits of frontier AI models' safety practices, applying to developers with over $500 million in annual revenue whose models exceed a specified computational power threshold. The law requires published safety frameworks, pre-deployment transparency reports, and reporting of critical safety incidents within 72 hours, moving beyond the disclosure-only approaches of earlier California and New York laws toward external verification.\n\n\nCorporate self-regulation\nAI labs and companies generally abide by safety practices and norms that fall outside of formal legislation. One aim of governance researchers is to shape these norms. Examples of safety recommendations found in the literature include performing third-party auditing, offering bounties for finding failures, sharing AI incidents (an AI incident database was created for this purpose), following guidelines to determine whether to publish research or models, and improving information and cyber security in AI labs.\nCompanies have also made commitments. Cohere, OpenAI, and AI21 proposed and agreed on \"best practices for deploying language models\", focusing on mitigating misuse. To avoid contributing to racing-dynamics, OpenAI has also stated in their charter that \"if a value-aligned, safety-conscious project comes close to building AGI before we do, we commit to stop competing with and start assisting this project\" Also, industry leaders such as CEO of DeepMind Demis Hassabis, director of Facebook AI Yann LeCun have signed open letters such as the Asilomar Principles and the Autonomous Weapons Open Letter.\n\n\nNonprofit organizations\nIn the 2020s, several nonprofit organizations have emerged in the U.S. and Europe to focus on AI safety and related public policies, including the Alliance for Secure AI, Future of Life Institute, and Public First Action. Such groups often function as Silicon Valley watchdogs and advocate for specific federal, state, or local regulations. They also compete with industry groups such as Leading the Future, which advocate for the deregulation of AI companies.\n\n\nInternational regulation\nUnder the framework of the Convention on Certain Conventional Weapons, states have discussed lethal autonomous weapon systems since 2014. In 2016, the treaty's states parties established an open-ended Group of Governmental Experts on Lethal Autonomous Weapons Systems to continue those discussions. The discussions have addressed international humanitarian law, accountability, possible prohibitions and regulations, and the extent of human control required over AI-enabled weapons.\n\n\nSee also\nAI alignment\nAI warfare\nArtificial intelligence and elections\nArtificial intelligence detection software\nHallucination (artificial intelligence)\n\n\nReferences\n\n\nExternal links\nUnsolved Problems in ML Safety\nOn the Opportunities and Risks of Foundation Models\nAn Overview of Catastrophic AI Risks\nAI Accidents: An Emerging Threat\nEngineering a Safer World", "categories": ["AI safety", "All articles lacking reliable references", "Articles lacking reliable references from July 2023", "Articles with excerpts", "Articles with short description", "Artificial intelligence", "CS1 maint: DOI inactive as of July 2026", "CS1 maint: location missing publisher", "CS1 maint: periodical has ISBN", "Cybernetics", "Existential risk from artificial intelligence", "Short description is different from Wikidata"], "references": ["https://aiimpacts.org/2022-expert-survey-on-progress-in-ai/", "https://dl.acm.org/doi/10.1145/3457607", "https://www.lesswrong.com/posts/5cWtwATHL6KyzChck/risks-from-ai-persuasion", "https://www.repository.cam.ac.uk/handle/1810/275332", "https://www.nytimes.com/2013/05/21/science/mit-scholars-1949-essay-on-machine-age-is-found.html", "https://www.aaai.org/Organization/presidential-panel.php", "https://www.youtube.com/watch?v=NG0ZjUfOBUs&t=1055s&ab_channel=KaiserKuo", "https://www.bbc.com/news/technology-30290540", "https://futureoflife.org/open-letter/ai-open-letter/", "https://futureoflife.org/ai-research/", "https://www.cmu.edu/safartint/", "https://www.washington.edu/news/2016/05/19/uw-to-host-first-of-four-white-house-public-workshops-on-artificial-intelligence/", "https://futureoflife.org/open-letter/ai-principles/", "https://deepmindsafetyresearch.medium.com/building-safe-artificial-intelligence-52f5f75058f1", "https://sites.google.com/view/safeml-iclr2019"], "images": ["File:Illustration of imperceptible adversarial pertubation.png", "File:Vice President Harris at the group photo of the 2023 AI Safety Summit.jpg"], "sub_niche": "Adversarial machine learning"} {"title": "International Conference on Machine Learning", "url": "https://en.wikipedia.org/wiki/International_Conference_on_Machine_Learning", "summary": "The International Conference on Machine Learning (ICML) is an international academic conference in machine learning held annually since 1980. It is the oldest and, along with NeurIPS and ICLR, one of the three primary conferences of highest impact and reputation in machine learning and artificial intelligence research. It is organized by the International Machine Learning Society (IMLS). Precise dates vary year to year, but paper submissions are generally due at the end of January, and the conference is generally held the following July.", "content": "The International Conference on Machine Learning (ICML) is an international academic conference in machine learning held annually since 1980. It is the oldest and, along with NeurIPS and ICLR, one of the three primary conferences of highest impact and reputation in machine learning and artificial intelligence research. It is organized by the International Machine Learning Society (IMLS). Precise dates vary year to year, but paper submissions are generally due at the end of January, and the conference is generally held the following July.\n\n\nHistory\nICML began as the International Workshop on Machine Learning, first held at Carnegie Mellon University in Pittsburgh in July 1980 and organized by Jaime Carbonell, Ryszard S. Michalski, and Tom M. Mitchell. In 1993 it transitioned to a full conference series under the current name, building on nearly a decade of workshops. Since the 2010s its proceedings have been published open-access in the Proceedings of Machine Learning Research (PMLR), which grew out of JMLR’s Workshop & Conference Proceedings and was renamed PMLR in 2015.\nICML has published many important research papers that form the foundation of modern Artificial Intelligence. Some notable works include Lawrence Berkeley National Laboratory's K-means clustering via PCA (ICML 2004); Google's Batch Normalization; Google Brain's EfficientNet (ICML 2019); OpenAI's CLIP (ICML 2021) and the UC Berkeley's Soft Actor-Critic (ICML 2018).\nThe number of submitted (and accepted) papers has sharply increased within 10 years; from 1037 (270) in 2015 to 12107 (3260) in 2025. Meanwhile, the acceptance rate continues to average between 21 % (2020) and 30 % (2024). 2026 marked a new record with 24,371 submitted papers, more than doubling the previous year. Accepted submissions are presented on-site as posters; furthermore, particularly outstanding contributions are presented orally or are designated by a committee as \"spotlight papers.\" In 2026, 2.2% of submitted contributions were designated as \"spotlight\" and 0.7% additionally as \"oral\". In addition, the best contribution is honored annually by a jury with an \"Outstanding Paper Award\" (formally \"Best Paper Award\").\n\n\nProfile\nICML’s scope spans the full breadth of machine learning, with particular emphasis on theoretical analysis, algorithmic innovation, and statistical learning. Compared to the other two big machine learning conferences NeurIPS and ICLR, ICML traditionally features more content on statistical learning theory, reinforcement learning and robotics, and optimization theory. Its annual proceedings are published in the open-access Proceedings of Machine Learning Research (PMLR).\nICML attracts sponsors seeking access to ML research and talent. Technology companies such as Google, Microsoft, Amazon, Meta, Apple are among sponsors, regularly publishing their research and recruiting researchers at the conference. Financial firms, such as Citadel Securities, Jane Street Capital and D.E. Shaw, also often have a presence at ICML.\n\n\nLocations\n\n\nSee also\nICLR\nJournal of Machine Learning Research\nMachine Learning (journal)\nNeurIPS\n\n\nReferences\n\n\nExternal links\nicml.cc ICML website\nmachinelearning.org Website of the International Machine Learning Society", "categories": ["Articles with short description", "Artificial intelligence conferences", "Open access journals (infobox)", "Short description is different from Wikidata"], "references": ["https://web.archive.org/web/20201007212857/https://scholar.google.es/citations?view_op=top_venues&hl=en&vq=eng_artificialintelligence", "https://d-nb.info/gnd/5024898-4", "https://viaf.org/viaf/155831656", "https://viaf.org/viaf/136744850", "https://scholar.google.es/citations?view_op=top_venues&hl=en&vq=eng_artificialintelligence", "http://machinelearning.org/archive/icml2008/past_icmls.shtml", "https://web.archive.org/web/20081212200944/http://www.cs.mcgill.ca/~icml2009/past.html", "https://ci.nii.ac.jp/author/DA02822554?l=en", "https://id.loc.gov/authorities/no2011019578", "https://id.loc.gov/authorities/n88122828", "http://www.cs.mcgill.ca/~icml2009/past.html", "https://machinelearning.org/", "https://icml.cc/", "https://www.nli.org.il/en/authorities/987011427657905171", "https://icml.cc/Conferences/FutureMeetings"], "images": [], "sub_niche": "International Conference on Machine Learning"} {"title": "Conference on Neural Information Processing Systems", "url": "https://en.wikipedia.org/wiki/Conference_on_Neural_Information_Processing_Systems", "summary": "The Conference on Neural Information Processing Systems (abbreviated as NeurIPS and formerly NIPS) is a machine learning and computational neuroscience conference held annually in December. Along with ICLR and ICML, it is one of the three primary conferences of high impact in machine learning and artificial intelligence research.\nThe conference includes three days of invited talks along with oral and poster presentations of refereed papers, followed by two days of workshops and competitions.", "content": "The Conference on Neural Information Processing Systems (abbreviated as NeurIPS and formerly NIPS) is a machine learning and computational neuroscience conference held annually in December. Along with ICLR and ICML, it is one of the three primary conferences of high impact in machine learning and artificial intelligence research.\nThe conference includes three days of invited talks along with oral and poster presentations of refereed papers, followed by two days of workshops and competitions.\n\n\nHistory\n\nThe NeurIPS meeting was first proposed in 1986 at the annual invitation-only Snowbird Meeting on Neural Networks for Computing organized by The California Institute of Technology and Bell Laboratories. NeurIPS was designed as a complementary open interdisciplinary meeting for researchers exploring biological and artificial Neural Networks. Reflecting this multidisciplinary approach, NeurIPS began in 1987 with information theorist Ed Posner as the conference president and learning theorist Yaser Abu-Mostafa as program chairman. Research presented in the early NeurIPS meetings included a wide range of topics from efforts to solve purely engineering problems to the use of computer models as a tool for understanding biological nervous systems. Since then, the biological and artificial systems research streams have diverged, and recent NeurIPS proceedings have been dominated by papers on machine learning, artificial intelligence and statistics.\nFrom 1987 until 2000 NeurIPS was held in Denver, United States. Since then, the conference was held in Vancouver, Canada (2001–2010), Granada, Spain (2011), and Lake Tahoe, United States (2012–2013). In 2014 and 2015, the conference was held in Montreal, Canada, in Barcelona, Spain in 2016, in Long Beach, United States in 2017, in Montreal, Canada in 2018 and Vancouver, Canada in 2019. Reflecting its origins at Snowbird, Utah, the meeting was accompanied by workshops organized at a nearby ski resort up until 2013, when it outgrew ski resorts.\nThe first NeurIPS Conference was sponsored by the IEEE. The following NeurIPS Conferences have been organized by the NeurIPS Foundation, established by Ed Posner. Terrence Sejnowski has been the president of the NeurIPS Foundation since Posner's death in 1993. The board of trustees consists of previous general chairs of the NeurIPS Conference.\nThe first proceedings was published in book form by the American Institute of Physics in 1987, and was entitled Neural Information Processing Systems, then the proceedings from the following conferences have been published by Morgan Kaufmann (1988–1993), MIT Press (1994–2004) and Curran Associates (2005–present) under the name Advances in Neural Information Processing Systems.\nThe conference was originally abbreviated as \"NIPS\". By 2018 a few commentators were criticizing the abbreviation as encouraging sexism due to its association with the word nipples, and as being a slur against Japanese. The board changed the abbreviation to \"NeurIPS\" in November 2018.\n\n\nTopics\n\nAlong with machine learning and neuroscience, other fields represented at NeurIPS include cognitive science, psychology, computer vision, statistical linguistics, and information theory. Over the years, NeurIPS became a premier conference on machine learning and although the 'Neural' in the NeurIPS acronym had become something of a historical relic, the resurgence of deep learning in neural networks since 2012, fueled by faster computers and big data, has led to achievements in speech recognition, object recognition in images, image captioning, language translation and world championship performance in the game of Go, based on neural architectures inspired by the hierarchy of areas in the visual cortex (ConvNet) and reinforcement learning inspired by the basal ganglia (Temporal difference learning).\nNotable affinity groups have emerged from the NeurIPS conference and displayed diversity, including Black in AI (in 2017), Queer in AI (in 2016), and others.\n\n\nNamed lectures\nIn addition to invited talks and symposia, NeurIPS also organizes two named lectureships to recognize distinguished researchers. The NeurIPS Board introduced the Posner Lectureship in honor of NeurIPS founder Ed Posner; two Posner Lectures were given each year up to 2015. Past lecturers have included:\n\n2010 – Josh Tenenbaum and Michael I. Jordan\n2011 – Rich Sutton and Bernhard Schölkopf\n2012 – Thomas Dietterich and Terry Sejnowski\n2013 – Daphne Koller and Peter Dayan\n2014 – Michael Kearns and John Hopfield\n2015 – Zoubin Ghahramani and Vladimir Vapnik\n2016 – Yann LeCun\n2017 – John Platt\n2018 – Joëlle Pineau\n2019 – Yoshua Bengio\n2020 – Christopher Bishop\n2021 – Peter Bartlett\nIn 2015, the NeurIPS Board introduced the Breiman Lectureship to highlight work in statistics relevant to conference topics. The lectureship was named for statistician Leo Breiman, who served on the NeurIPS Board from 1994 to 2005. Past lecturers have included:\n\n2015 – Robert Tibshirani\n2016 – Susan Holmes\n2017 – Yee Whye Teh\n2018 – David Spiegelhalter\n2019 – Bin Yu\n2020 – Marloes Maathuis\n2021 – Gabor Lugosi\n2022 – Emmanuel Candes\n2023 – Susan Murphy\n2024 – Arnaud Doucet\n\n\nNeurIPS consistency experiment\nIn NIPS 2014, the program chairs duplicated 10% of all submissions and sent them through separate reviewers to evaluate randomness in the reviewing process. Several researchers interpreted the result. Regarding whether the decision in NIPS is completely random or not, John Langford writes: \"Clearly not—a purely random decision would have arbitrariness of ~78%. It is, however, quite notable that 60% is much closer to 78% than 0%.\" He concludes that the result of the reviewing process is mostly arbitrary. In NeurIPS 2021, the program chairs repeated the 2014 experiment and found similar levels of review inconsistency; 23% of duplicated submissions received different accept/reject decisions, and 50.6% of accepted papers would have been rejected under re-review.\n\n\nLocations\n 1987–2000: Denver, Colorado, United States\n 2001–2010: Vancouver, British Columbia, Canada\n 2011: Granada, Spain\n 2012 & 2013: Stateline, Nevada, United States\n 2014 & 2015: Montréal, Quebec, Canada\n 2016: Barcelona, Spain\n 2017: Long Beach, California, United States\n 2018: Montréal, Quebec, Canada\n 2019: Vancouver, British Columbia, Canada\n 2020: Vancouver, British Columbia, Canada (virtual conference)\n2021: Virtual conference\n 2022 & 2023: New Orleans, Louisiana, United States\n 2024: Vancouver, British Columbia, Canada\n 2025: San Diego, California, United States and Mexico City, Mexico\n 2026: Sydney, New South Wales, Australia, with satellite events in Atlanta and Paris\n\n\nSee also\nAAAI Conference on Artificial Intelligence (AAAI)\nComputational and Systems Neuroscience (COSYNE)\nInternational Conference on Computational Intelligence Methods for Bioinformatics and Biostatistics (CIBB)\nInternational Conference on Learning Representations (ICLR)\nInternational Conference on Machine Learning (ICML)\n\n\nReferences\n\n\nExternal links\n2019 Conference\nNeurIPS proceedings\nNIPS 2011 video lectures\nNIPS 2012 video lectures\nVideo Journal of Machine Learning Abstracts – Volume 3", "categories": ["1987 establishments in Colorado", "Articles with short description", "Artificial intelligence conferences", "Computational neuroscience", "International conferences in Canada", "Neuroscience conferences", "Recurring events established in 1987", "Short description is different from Wikidata", "Signal processing conferences", "Wikipedia articles needing clarification from August 2025"], "references": ["http://books.nips.cc/", "http://videolectures.net/nips2011_granada/", "http://videolectures.net/machine_learning_video_abstracts_vol3/", "http://videolectures.net/nips2012_laketahoe/", "http://inverseprobability.com/2014/12/16/the-nips-experiment/", "http://blog.computationalcomplexity.org/2014/12/the-nips-experiment.html", "http://blog.mrtz.org/2014/12/15/the-nips-experiment.html", "http://cacm.acm.org/blogs/blog-cacm/181996-the-nips-experiment/fulltext", "https://nips.cc/Conferences/2016", "https://nips.cc/Conferences/2017", "https://nips.cc/Conferences/2018", "http://videolectures.net/nips2010_vancouver/", "https://media.nips.cc/Conferences/2015/NIPS-2015-Conference-Book.pdf", "https://medium.com/syncedreview/vancouver-named-neurips-2019-2020-host-as-visa-issues-continue-to-plague-the-ai-conference-91665c5e63a2", "https://neurips.cc/"], "images": ["File:Judea Pearl at NIPS 2013 (11781981594).jpg"], "sub_niche": "International Conference on Machine Learning"} {"title": "ECML PKDD", "url": "https://en.wikipedia.org/wiki/ECML_PKDD", "summary": "ECML PKDD, the European Conference on Machine Learning Principles and Practice of Knowledge Discovery in Databases, is one of the leading academic conferences on machine learning and knowledge discovery, held in Europe every year.", "content": "ECML PKDD, the European Conference on Machine Learning Principles and Practice of Knowledge Discovery in Databases, is one of the leading academic conferences on machine learning and knowledge discovery, held in Europe every year.\n\n\nHistory\nECML PKDD is a merger of two European conferences, European Conference on Machine Learning (ECML) and European Conference on Principles and Practice of Knowledge Discovery in Databases (PKDD). ECML and PKDD have been co-located since 2001; however, both ECML and PKDD retained their own identity until 2007. For example, the 2007 conference was known as \"the 18th European Conference on Machine Learning (ECML) and the 11th European Conference\non Principles and Practice of Knowledge Discovery in Databases (PKDD)\", or in brief, \"ECML/PKDD 2007\", and both ECML and PKDD had their own conference proceedings. In 2008 the conferences were merged into one conference, and the division into traditional ECML topics and traditional PKDD topics was removed.\nThe history of ECML dates back to 1986, when the European Working Session on Learning was first held. In 1993 the name of the conference was changed to European Conference on Machine Learning.\nPKDD was first organised in 1997. Originally PKDD stood for the European Symposium on Principles of Data Mining and Knowledge Discovery from Databases. The name European Conference on Principles and Practice of Knowledge Discovery in Databases was used since 1999.\nThe conference remains highly competitive, consistently maintaining an average acceptance rate of around 25% for the main research track.\n\n\nUpcoming conferences\n\n\nList of past conferences\n\n\nSee also\nConference on Neural Information Processing Systems (NeurIPS)\nEuropean Conference on Computational Biology (ECCB)\nInternational Conference on Computational Intelligence Methods for Bioinformatics and Biostatistics (CIBB)\nInternational Conference on Machine Learning (ICML)\n\n\nReferences\n\n\nExternal links\nOfficial website \nECML proceedings information in DBLP.\nPKDD proceedings information in DBLP.", "categories": ["Articles with short description", "Artificial intelligence conferences", "Short description is different from Wikidata", "Webarchive template wayback links", "Wikipedia articles scheduled for update tagging"], "references": ["http://www.ecmlpkdd.org/content/past-conferences", "http://libra.msra.cn/conf_category_6.htm", "http://www.core.edu.au/rankings/Conference%20Ranking%20Main.html", "http://www.ecmlpkdd2013.org/", "http://www.ecmlpkdd2015.org/", "http://www.ecmlpkdd2016.org/", "http://ecmlpkdd2014.loria.fr/", "https://web.archive.org/web/20090609153758/http://libra.msra.cn/conf_category_6.htm", "https://web.archive.org/web/20091002002344/http://www.core.edu.au/rankings/Conference%20Ranking%20Main.html", "http://ecmlpkdd2017.ijs.si/", "http://www.ecmlpkdd2018.org/", "http://ecmlpkdd2019.org/", "https://web.archive.org/web/20100418232401/http://www.ecmlpkdd.org/content/past-conferences", "https://archive.org/details/principlesofdata00pkdd/page/", "https://ecmlpkdd.org/"], "images": [], "sub_niche": "International Conference on Machine Learning"} {"title": "Multimodal learning", "url": "https://en.wikipedia.org/wiki/Multimodal_learning", "summary": "Multimodal learning is a type of deep learning that integrates and processes multiple types of data, referred to as modalities, such as text, audio, images, or video. This integration allows for a more holistic understanding of complex data, improving model performance in tasks like visual question answering, cross-modal retrieval, text-to-image generation, aesthetic ranking, and image captioning.\nMultimodal learning was proposed in 2011 at the beginning of the deep learning period. Large multimodal models, such as Google Gemini and GPT-4o, have become increasingly popular since 2023, enabling increased versatility and a broader understanding of real-world phenomena.", "content": "Multimodal learning is a type of deep learning that integrates and processes multiple types of data, referred to as modalities, such as text, audio, images, or video. This integration allows for a more holistic understanding of complex data, improving model performance in tasks like visual question answering, cross-modal retrieval, text-to-image generation, aesthetic ranking, and image captioning.\nMultimodal learning was proposed in 2011 at the beginning of the deep learning period. Large multimodal models, such as Google Gemini and GPT-4o, have become increasingly popular since 2023, enabling increased versatility and a broader understanding of real-world phenomena.\n\n\nMotivation\nData usually comes with different modalities which carry different information. For example, it is very common to caption an image to convey the information not presented in the image itself. Similarly, sometimes it is more straightforward to use an image to describe information which may not be obvious from text. As a result, if different words appear in similar images, then these words likely describe the same thing. Conversely, if a word is used to describe seemingly dissimilar images, then these images may represent the same object. Thus, in cases dealing with multi-modal data, it is important to use a model which is able to jointly represent the information such that the model can capture the combined information from different modalities.\n\n\nMultimodal transformers\n\nModels such as CLIP (Contrastive Language–Image Pretraining) learn joint representations of images and text by optimizing contrastive objectives, allowing the model to match images with their corresponding textual descriptions.\n\n\nMultimodal deep Boltzmann machines\nA Boltzmann machine is a type of stochastic neural network invented by Geoffrey Hinton and Terry Sejnowski in 1985. Boltzmann machines can be seen as the stochastic, generative counterpart of Hopfield nets. They are named after the Boltzmann distribution in statistical mechanics. The units in Boltzmann machines are divided into two groups: visible units and hidden units. Each unit is like a neuron with a binary output that represents whether it is activated or not. General Boltzmann machines allow connection between any units. However, learning is impractical using general Boltzmann Machines because the computational time is exponential to the size of the machine. A more efficient architecture is called restricted Boltzmann machine where connection is only allowed between hidden unit and visible unit, which is described in the next section.\nMultimodal deep Boltzmann machines can process and learn from different types of information, such as images and text, simultaneously. This can notably be done by having a separate deep Boltzmann machine for each modality, for example one for images and one for text, joined at an additional top hidden layer.\n\n\nApplications\nMultimodal machine learning has numerous applications across various domains:\n\nCross-modal retrieval: cross-modal retrieval allows users to search for data across different modalities (e.g., retrieving images based on text descriptions), improving multimedia search engines and content recommendation systems.\nClassification and missing data retrieval: multimodal Deep Boltzmann Machines outperform traditional models like support vector machines and latent Dirichlet allocation in classification tasks and can predict missing data in multimodal datasets, such as images and text.\nHealthcare diagnostics: multimodal models integrate medical imaging, genomic data, and patient records to improve diagnostic accuracy and early disease detection, especially in cancer screening.\nContent generation: models like DALL·E generate images from textual descriptions, benefiting creative industries, while cross-modal retrieval enables dynamic multimedia searches.\nRobotics and human-computer interaction: multimodal learning improves interaction in robotics and AI by integrating sensory inputs like speech, vision, and touch, aiding autonomous systems and human-computer interaction.\nEmotion recognition: combining visual, audio, and text data, multimodal systems enhance sentiment analysis and emotion recognition, applied in customer service, social media, and marketing.\nCode search: multimodal representations combining source code structure (e.g., abstract syntax trees) with natural language descriptions improve retrieval of relevant code snippets for a given query. Source code has also been rendered as a two-dimensional pixel image, for instance by converting a method's control-flow graph into a black-and-white image processed with a convolutional neural network to search for malwares.\n\n\nChallenges\nMultimodal learning is challenging because different modalities can represent and structure information in different ways. Two common challenges are alignment, determining which parts of different modalities correspond to each other, and fusion, determining how information across modalities should be combined. Real-world applications of multimodal learning face further challenges specific to multimodal AI, including missing modalities when a data source is unavailable, selecting modalities that provide complementary rather than redundant information, and privacy risks from combining data sources, which may allow individuals to be re-identified even if they are anonymous in each source separately.\n\n\nSee also\nCross-modal retrieval\nVision-language model\nHopfield network\nMarkov random field\nMarkov chain Monte Carlo\nSGLang\n\n\nReferences", "categories": ["Articles with excerpts", "Articles with short description", "Artificial neural networks", "CS1 errors: periodical ignored", "CS1 maint: DOI inactive as of September 2026", "CS1 maint: periodical has ISBN", "Multimodal interaction", "Short description is different from Wikidata"], "references": ["http://www.jmlr.org/papers/volume15/srivastava14b/srivastava14b.pdf", "https://www.theregister.com/2022/08/09/ai_cancer_multimodal/", "https://api.semanticscholar.org/CorpusID:251456162", "https://medicalxpress.com/news/2022-08-ai-technology-multiple-cancer-outcomes.html", "https://doi.org/10.1016%2Fj.ccell.2022.07.004", "https://pubmed.ncbi.nlm.nih.gov/35944502", "https://web.archive.org/web/20150621055730/http://jmlr.org/papers/volume15/srivastava14b/srivastava14b.pdf", "https://web.archive.org/web/20220920163859/https://www.theregister.com/2022/08/09/ai_cancer_multimodal/", "https://web.archive.org/web/20220920172825/https://medicalxpress.com/news/2022-08-ai-technology-multiple-cancer-outcomes.html", "https://www.ncbi.nlm.nih.gov/pmc/articles/PMC10397370", "https://arxiv.org/archive/cs.CV", "https://arxiv.org/archive/cs.LG", "https://analyticsindiamag.com/beginners-guide-to-boltzmann-machines/", "https://www.unite.ai/unveiling-of-large-multimodal-models-shaping-the-landscape-of-language-models-in-2024/", "https://search.worldcat.org/issn/1535-6108"], "images": [], "sub_niche": "International Conference on Machine Learning"} {"title": "List of datasets for machine-learning research", "url": "https://en.wikipedia.org/wiki/List_of_datasets_for_machine-learning_research", "summary": "These datasets are used in machine learning (ML) research and have been cited in peer-reviewed academic journals. Datasets are an integral part of the field of machine learning. Major advances in this field can result from advances in learning algorithms (such as deep learning), computer hardware, and, less intuitively, the availability of high-quality training datasets. High-quality labeled training datasets for supervised and semi-supervised machine-learning algorithms are usually difficult and expensive to produce because of the large amount of time needed to label the data. Although they do not need to be labeled, high-quality unlabeled datasets for unsupervised learning can also be difficult and costly to produce.\nMany organizations, including governments, publish and share their data", "content": "These datasets are used in machine learning (ML) research and have been cited in peer-reviewed academic journals. Datasets are an integral part of the field of machine learning. Major advances in this field can result from advances in learning algorithms (such as deep learning), computer hardware, and, less intuitively, the availability of high-quality training datasets. High-quality labeled training datasets for supervised and semi-supervised machine-learning algorithms are usually difficult and expensive to produce because of the large amount of time needed to label the data. Although they do not need to be labeled, high-quality unlabeled datasets for unsupervised learning can also be difficult and costly to produce.\nMany organizations, including governments, publish and share their datasets, often using common metadata formats (such as Croissant). The datasets are classified, based on the licenses, into two groups: open data and non-open data.\nThe datasets from various governmental-bodies are presented in List of open government data sites. The datasets are ported on open data portals. They are made available for searching, depositing and accessing through interfaces like Open API. The datasets are made available as various sorted types and subtypes.\n\n\nList of sorting used for datasets\n\nThe data portal is classified based on its type of license. The open source license based data portals are known as open data portals which are used by many government organizations and academic institutions.\n\n\nList of open data portals\n\n\nList of portals suitable for multiple types of applications\n\nThe data portal sometimes lists a wide variety of subtypes of datasets pertaining to many machine learning applications.\n\n\nList of portals suitable for a specific subtype of applications\n\nThe data portals which are suitable for a specific subtype of machine learning application are listed in the subsequent sections.\n\n\nImage data\n\n\nText data\nThese datasets consist primarily of text for tasks such as natural language processing, sentiment analysis, translation, and cluster analysis.\n\n\nReviews\n\n\nNews articles\n\n\nMessages\n\n\nTwitter and tweets\n\n\nDialogues\n\n\nLegal\n\n\nOther text\n\n\nSound data\nThese datasets consist of sounds and sound features used for tasks such as speech recognition and speech synthesis.\n\n\nSpeech\n\n\nMusic\n\n\nOther sounds\n\n\nSignal data\nDatasets containing electric signal information requiring some sort of signal processing for further analysis.\n\n\nElectrical\n\n\nMotion-tracking\n\n\nOther signals\n\n\nChemical data\nDatasets from physical systems.\n\n\nChemical Reactions with transition states (TS)\n\n\nOpenReACT-CHON-EFH\nOpenReACT-CHON-EFH (Open Reaction Dataset of Atomic ConfiguraTions comprising C, H, O and N with Energies, Forces and Hessians) is a 2025 open-access benchmark for machine-learning interatomic potentials.\n\n**RTP set** – 35,087 stationary-point geometries (reactant, transition state and product) drawn from 11,961 elementary reactions, each labeled with density-functional energies, atomic forces and full Hessian matrices at the ωB97X-D/6-31G(d) level.\n**IRC set** – 34,248 structures along 600 minimum-energy reaction paths, used to test extrapolation beyond trained stationary points.\n**NMS set** – 62,527 off-equilibrium geometries generated by normal-mode sampling to probe model robustness under thermal perturbations.\nThe collection underpins the study Does Hessian Data Improve the Performance of Machine Learning Potentials? and was used to train and benchmark the machine-learning interatomic potentials reported therein.\nThe dataset itself is distributed under a CC licence via Figshare.\n\n\nPhysical data\nDatasets from physical systems.\n\n\nHigh-energy physics\n\n\nSystems\n\n\nAstronomy\n\n\nEarth science\n\n\nOther physical\n\n\nBiological data\nDatasets from biological systems.\n\n\nHuman\n\n\nAnimal\n\n\nFungi\n\n\nPlant\n\n\nMicrobe\n\n\nDrug discovery\n\n\nAnomaly data\n\n\nQuestion answering data\nThis section includes datasets that deals with structured data.\n\n\nDialog or instruction prompted data\nThis section includes datasets that contains multi-turn text with at least two actors, a \"user\" and an \"agent\". The user makes requests for the agent, which performs the request.\n\n\nCybersecurity\n\n\nClimate and sustainability\n\n\nCode data\n\n\nMultivariate data\n\n\nFinancial\n\n\nWeather\n\n\nCensus\n\n\nTransit\n\n\nInternet\n\n\nGames\n\n\nOther multivariate\n\n\nCurated repositories of datasets\nAs datasets come in myriad formats and can sometimes be difficult to use, there has been considerable work put into curating and standardizing the format of datasets to make them easier to use for machine learning research.\n\nOpenML: Web platform with Python, R, Java, and other APIs for downloading hundreds of machine learning datasets, evaluating algorithms on datasets, and benchmarking algorithm performance against dozens of other algorithms.\nPMLB: A large, curated repository of benchmark datasets for evaluating supervised machine learning algorithms. Provides classification and regression datasets in a standardized format that are accessible through a Python API.\nMetatext NLP: https://metatext.io/datasets web repository maintained by community, containing nearly 1000 benchmark datasets, and counting. Provides many tasks from classification to QA, and various languages from English, Portuguese to Arabic.\nAppen: Off The Shelf and Open Source Datasets hosted and maintained by the company. These biological, image, physical, question answering, signal, sound, text, and video resources number over 250 and can be applied to over 25 different use cases.\n\n\nSee also\nComparison of deep learning software\nList of manual image annotation tools\nList of biological databases\n\n\nReferences", "categories": ["All articles with dead external links", "All articles with unsourced statements", "Articles with dead external links from September 2023", "Articles with imported Creative Commons Attribution 4.0 text", "Articles with permanently dead external links", "Articles with short description", "Articles with unsourced statements from October 2023", "Articles with unsourced statements from October 2025", "CS1: long volume value", "CS1 errors: missing periodical", "CS1 maint: multiple names: authors list", "Datasets in machine learning", "Dynamic lists", "Short description is different from Wikidata", "Use dmy dates from September 2017", "Webarchive template wayback links", "Wikipedia articles needing page number citations from September 2024"], "references": ["https://edge.org/response-detail/26587", "https://higgsml.lal.in2p3.fr/", "http://en.arabicspeechcorpus.com/Nawar%20Halabi%20PhD%20Thesis%20Revised.pdf", "http://bioinf.jku.at/research/DeepTox/tox21.html", "https://github.com/dstl/re3d", "https://www.kaggle.com/therohk/million-headlines", "https://www.kaggle.com/therohk/examine-the-examiner", "http://ttg.uni-saarland.de/resources/DSLCC/", "https://www.kaggle.com/therohk/global-news-week", "https://www.kaggle.com/therohk/urban-dictionary-words-dataset", "http://repository.upenn.edu/cgi/viewcontent.cgi?article=1246&context=cis_reports", "http://www.adcis.net/en/Download-Third-Party/Messidor.htmldownload.php", "https://github.com/huyt16/Twitter100k", "https://www.researchgate.net/publication/324482598_Generating_a_Large_Dataset_for_Neural_Question_Answering_over_the_DBpedia_Knowledge_Base", "http://faculty.nps.edu/cmartell/NPSChat.htm"], "images": [], "sub_niche": "International Conference on Machine Learning"} {"title": "Bitter lesson", "url": "https://en.wikipedia.org/wiki/Bitter_lesson", "summary": "The bitter lesson is the observation in artificial intelligence that, in the long run, general approaches that scale with available computational power tend to outperform ones based on domain-specific understanding because they are better at taking advantage of the falling cost of computation over time. The principle was proposed and named in a 2019 essay by Richard Sutton and is now widely accepted.", "content": "The bitter lesson is the observation in artificial intelligence that, in the long run, general approaches that scale with available computational power tend to outperform ones based on domain-specific understanding because they are better at taking advantage of the falling cost of computation over time. The principle was proposed and named in a 2019 essay by Richard Sutton and is now widely accepted.\n\n\nThe essay\nSutton gives several examples that illustrate the lesson:\n\nGame playing. In chess, the Deep Blue system that became the first computer opponent to defeat a world champion relied on a relatively simple alpha–beta search algorithm that scaled up by applying large amounts of specialized hardware to search for the best move. This defeated previous attempts to exploit the unique structure of chess or to include grandmaster knowledge directly. Likewise in the game of Go, the AlphaGo algorithm that surpassed human performance relied much less on expert skill at the game itself than previous generations of AI, and was further surpassed by AlphaGo Zero, which removed human expertise completely and trained only by self-play.\nSpeech recognition. Approaches based on training a general-purpose hidden Markov model with large numbers of speech samples consistently outperformed the hand-crafted approaches of the 1970s, and deep learning has continued this trend.\nComputer vision. Algorithms that were assumed to approximate the human visual system (such as explicitly encoded edge detection or detecting high-level features with SIFT) were outperformed by convolutional neural networks that make far fewer assumptions about the nature of visual perception.\nSutton concludes that time is better invested in finding simple scalable solutions that can take advantage of Moore's law, rather than introducing ever-more-complex human insights, and calls this the \"bitter lesson\". He also cites two general-purpose techniques that have been shown to scale effectively: search and learning. The lesson is considered \"bitter\" because it is less anthropocentric than many researchers expected and so they have been slow to accept it.\n\n\nImpact\nThe essay was published on Sutton's website incompleteideas.net in 2019, and has received hundreds of formal citations according to Google Scholar. Some of these provide alternative statements of the principle; for example, the 2022 paper \"A Generalist Agent\" from Google DeepMind summarized the lesson as:\n\nHistorically, generic models that are better at\nleveraging computation have also tended to overtake more specialized domain-specific approaches, eventually.\nAnother phrasing of the principle is seen in a Google paper on switch transformers coauthored by Noam Shazeer:\n\nSimple architectures—backed by a generous computational budget, data set size and parameter count—surpass more complicated algorithms.\nThe principle is further referenced in many other works on artificial intelligence. For example, From Deep Learning to Rational Machines draws a connection to long-standing debates in the field, such as Moravec's paradox and the contrast between neats and scruffies. In \"Engineering a Less Artificial Intelligence\", the authors concur that \"flexible methods so far have always outperformed handcrafted domain knowledge in the long run\" although note that \"[w]ithout the right (implicit) assumptions, generalization is impossible\". More recently, \"The Brain's Bitter Lesson: Scaling Speech Decoding With Self-Supervised Learning\" continues Sutton's argument, contending that (as of 2025) the lesson has not been fully learned in the fields of speech recognition and brain data.\nOther work has looked to apply the principle and validate it in new domains. For example, the 2022 paper \"Beyond the Imitation Game\" applies the principle to large language models to conclude that \"it is vitally important that we understand their capabilities and limitations\" to \"avoid devoting research resources to problems that are likely to be solved by scale alone\". In 2024, \"Learning the Bitter Lesson: Empirical Evidence from 20 Years of CVPR Proceedings\" looked at further evidence from the field of computer vision and pattern recognition, and concludes that the previous twenty years of experience in the field shows \"a strong adherence to\nthe core principles of the 'bitter lesson'\". In \"Overestimation, Overfitting, and Plasticity in Actor-Critic: the Bitter Lesson of Reinforcement Learning\", the authors look at generalization of actor-critic algorithms and find that \"general methods that are motivated by stabilization of gradient-based learning significantly outperform RL-specific algorithmic improvements across a variety of environments\" and note that this is consistent with the bitter lesson.\n\n\nReferences", "categories": ["Articles with short description", "Philosophy of artificial intelligence", "Short description matches Wikidata", "Use mdy dates from October 2025"], "references": ["http://www.incompleteideas.net/IncIdeas/BitterLesson.html", "https://openreview.net/forum?id=1ikK0kHjvj", "https://doi.org/10.1093%2Foso%2F9780197653302.001.0001", "https://aclanthology.org/2024.nlp4science-1.15/", "https://arxiv.org/abs/2205.06175", "https://icml.cc/virtual/2025/poster/44019", "https://arxiv.org/pdf/2403.00514", "https://www.cell.com/neuron/fulltext/S0896-6273(19)30740-8", "https://doi.org/10.1016%2Fj.neuron.2019.08.034", "http://jmlr.org/papers/v23/21-0998.html", "https://arxiv.org/abs/2206.04615"], "images": [], "sub_niche": "International Conference on Machine Learning"} {"title": "Topological deep learning", "url": "https://en.wikipedia.org/wiki/Topological_deep_learning", "summary": "Topological deep learning (TDL) is a research field that extends deep learning to handle complex, non-Euclidean data structures. Traditional deep learning models, such as convolutional neural networks (CNNs) and recurrent neural networks (RNNs), excel in processing data on regular grids and sequences. However, scientific and real-world data often exhibit more intricate data domains encountered in scientific computations, including point clouds, meshes, time series, scalar fields graphs, or general topological spaces like simplicial complexes and CW complexes. TDL addresses this by incorporating topological concepts to process data with higher-order relationships, such as interactions among multiple entities and complex hierarchies. This approach leverages structures like simplicial complex", "content": "Topological deep learning (TDL) is a research field that extends deep learning to handle complex, non-Euclidean data structures. Traditional deep learning models, such as convolutional neural networks (CNNs) and recurrent neural networks (RNNs), excel in processing data on regular grids and sequences. However, scientific and real-world data often exhibit more intricate data domains encountered in scientific computations, including point clouds, meshes, time series, scalar fields graphs, or general topological spaces like simplicial complexes and CW complexes. TDL addresses this by incorporating topological concepts to process data with higher-order relationships, such as interactions among multiple entities and complex hierarchies. This approach leverages structures like simplicial complexes and hypergraphs to capture global dependencies and qualitative spatial properties, offering a more nuanced representation of data. TDL also encompasses methods from computational and algebraic topology that permit studying properties of neural networks and their training process, such as their predictive performance or generalization properties. \nThe mathematical foundations of TDL are algebraic topology, differential topology, and geometric topology. Therefore, TDL can be generalized for data on differentiable manifolds, knots, links, tangles, curves, etc.\n\n\nHistory and motivation\nTraditional techniques from deep learning often operate under the assumption that a dataset is residing in a highly-structured space (like images, where convolutional neural networks exhibit outstanding performance over alternative methods) or a Euclidean space. The prevalence of new types of data, in particular graphs, meshes, and molecules, resulted in the development of new techniques, culminating in the field of geometric deep learning, which originally proposed a signal-processing perspective for treating such data types. While originally confined to graphs, where connectivity is defined based on nodes and edges, follow-up work extended concepts to a larger variety of data types, including simplicial complexes and CW complexes, with recent work proposing a unified perspective of message-passing on general combinatorial complexes.\nAn independent perspective on different types of data originated from topological data analysis, which proposed a new framework for describing structural information of data, i.e., their \"shape,\" that is inherently aware of multiple scales in data, ranging from local information to global information. While at first restricted to smaller datasets, subsequent work developed new descriptors that efficiently summarized topological information of datasets to make them available for traditional machine-learning techniques, such as support vector machines or random forests. Such descriptors ranged from new techniques for feature engineering over new ways of providing suitable coordinates for topological descriptors, or the creation of more efficient dissimilarity measures.\nContemporary research in this field is largely concerned with either integrating information about the underlying data topology into existing deep-learning models or obtaining novel ways of training on topological domains.\n\n\nLearning on topological spaces\n\nOne of the core concepts in topological deep learning is considering the domain upon which this data is defined and supported. In case of Euclidean data, such as images, this domain is a grid, upon which the pixel value of the image is supported. In a more general setting this domain might be a topological domain. Studying and developing deep learning models that are supported in topological domains constitutes the essence of topological deep learning. Next, we introduce the most common topological domains that are encountered in a deep learning setting. These domains include, but not limited to, graphs, simplicial complexes, cell complexes, combinatorial complexes and hypergraphs.\nGiven a finite set S of abstract entities, a neighborhood function \n \n \n \n \n \n N\n \n \n \n \n {\\displaystyle {\\mathcal {N}}}\n \n on S is an assignment that attach to every point \n \n \n \n x\n \n \n {\\displaystyle x}\n \n in S a subset of S or a relation. Such a function can be induced by equipping S with an auxiliary structure. Edges provide one way of defining relations among the entities of S. More specifically, edges in a graph allow one to define the notion of neighborhood using, for instance, the one hop neighborhood notion. Edges however, limited in their modeling capacity as they can only be used to model binary relations among entities of S since every edge is connected typically to two entities. In many applications, it is desirable to permit relations that incorporate more than two entities. The idea of using relations that involve more than two entities is central to topological domains. Such higher-order relations allow for a broader range of neighborhood functions to be defined on S to capture multi-way interactions among entities of S.\nNext we review the main properties, advantages, and disadvantages of some commonly studied topological domains in the context of deep learning, including (abstract) simplicial complexes, regular cell complexes, hypergraphs, and combinatorial complexes.\n\n\nComparisons among topological domains\nEach of the enumerated topological domains has its own characteristics, advantages, and limitations:\n\nSimplicial complexes\nSimplest form of higher-order domains.\nExtensions of graph-based models.\nAdmit hierarchical structures, making them suitable for various applications.\nHodge theory can be naturally defined on simplicial complexes.\nRequire relations to be subsets of larger relations, imposing constraints on the structure.\nCell complexes\nGeneralize simplicial complexes.\nProvide more flexibility in defining higher-order relations.\nEach cell in a cell complex is homeomorphic to an open ball, attached together via attaching maps.\nBoundary cells of each cell in a cell complex are also cells in the complex.\nRepresented combinatorially via incidence matrices.\nHypergraphs\nAllow arbitrary set-type relations among entities.\nRelations are not imposed by other relations, providing more flexibility.\nDo not explicitly encode the dimension of cells or relations.\nUseful when relations in the data do not adhere to constraints imposed by other models like simplicial and cell complexes.\nCombinatorial complexes\nGeneralize and bridge the gaps between simplicial complexes, cell complexes, and hypergraphs.\nAllow for hierarchical structures and set-type relations.\nCombine features of other complexes while providing more flexibility in modeling relations.\nCan be represented combinatorially, similar to cell complexes.\n\n\nHierarchical structure and set-type relations\nThe properties of simplicial complexes, cell complexes, and hypergraphs give rise to two main features of relations on higher-order domains, namely hierarchies of relations and set-type relations.\n\n\nRank function\nA rank function on a higher-order domain X is an order-preserving function rk: X → Z, where rk(x) attaches a non-negative integer value to each relation x in X, preserving set inclusion in X. Cell and simplicial complexes are common examples of higher-order domains equipped with rank functions and therefore with hierarchies of relations.\n\n\nSet-type relations\nRelations in a higher-order domain are called set-type relations if the existence of a relation is not implied by another relation in the domain. Hypergraphs constitute examples of higher-order domains equipped with set-type relations. Given the modeling limitations of simplicial complexes, cell complexes, and hypergraphs, we develop the combinatorial complex, a higher-order domain that features both hierarchies of relations and set-type relations.\nThe learning tasks in TDL can be broadly classified into three categories:\n\nCell classification: Predict targets for each cell in a complex. Examples include triangular mesh segmentation, where the task is to predict the class of each face or edge in a given mesh.\nComplex classification: Predict targets for an entire complex. For example, predict the class of each input mesh.\nCell prediction: Predict properties of cell-cell interactions in a complex, and in some cases, predict whether a cell exists in the complex. An example is the prediction of linkages among entities in hyperedges of a hypergraph.\nIn practice, to perform the aforementioned tasks, deep learning models designed for specific topological spaces must be constructed and implemented. These models, known as topological neural networks, are tailored to operate effectively within these spaces.\n\n\nTopological neural networks\nCentral to TDL are topological neural networks (TNNs), specialized architectures designed to operate on data structured in topological domains. Unlike traditional neural networks tailored for grid-like structures, TNNs are adept at handling more intricate data representations, such as graphs, simplicial complexes, and cell complexes. By harnessing the inherent topology of the data, TNNs can capture both local and global relationships, enabling nuanced analysis and interpretation.\n\n\nMessage passing topological neural networks\nIn a general topological domain, higher-order message passing involves exchanging messages among entities and cells using a set of neighborhood functions.\nDefinition: higher-order message passing on a general topological domain\n\nLet \n \n \n \n \n \n X\n \n \n \n \n {\\displaystyle {\\mathcal {X}}}\n \n be a topological domain. We define a set of neighborhood functions \n \n \n \n \n \n N\n \n \n =\n {\n \n \n \n N\n \n \n \n 1\n \n \n ,\n …\n ,\n \n \n \n N\n \n \n \n n\n \n \n }\n \n \n {\\displaystyle {\\mathcal {N}}=\\{{\\mathcal {N}}_{1},\\ldots ,{\\mathcal {N}}_{n}\\}}\n \n on \n \n \n \n \n \n X\n \n \n \n \n {\\displaystyle {\\mathcal {X}}}\n \n. Consider a cell \n \n \n \n x\n \n \n {\\displaystyle x}\n \n and let \n \n \n \n y\n ∈\n \n \n \n N\n \n \n \n k\n \n \n (\n x\n )\n \n \n {\\displaystyle y\\in {\\mathcal {N}}_{k}(x)}\n \n for some \n \n \n \n \n \n \n N\n \n \n \n k\n \n \n ∈\n \n \n N\n \n \n \n \n {\\displaystyle {\\mathcal {N}}_{k}\\in {\\mathcal {N}}}\n \n. A message \n \n \n \n \n m\n \n x\n ,\n y\n \n \n \n \n {\\displaystyle m_{x,y}}\n \n between cells \n \n \n \n x\n \n \n {\\displaystyle x}\n \n and \n \n \n \n y\n \n \n {\\displaystyle y}\n \n is a computation dependent on these two cells or the data supported on them. Denote \n \n \n \n \n \n N\n \n \n (\n x\n )\n \n \n {\\displaystyle {\\mathcal {N}}(x)}\n \n as the multi-set \n \n \n \n {\n \n \n {\n \n \n \n N\n \n \n \n 1\n \n \n (\n x\n )\n ,\n …\n ,\n \n \n \n N\n \n \n \n n\n \n \n (\n x\n )\n }\n \n \n }\n \n \n {\\displaystyle \\{\\!\\!\\{{\\mathcal {N}}_{1}(x),\\ldots ,{\\mathcal {N}}_{n}(x)\\}\\!\\!\\}}\n \n, and let \n \n \n \n \n \n h\n \n \n x\n \n \n (\n l\n )\n \n \n \n \n {\\displaystyle \\mathbf {h} _{x}^{(l)}}\n \n represent some data supported on cell \n \n \n \n x\n \n \n {\\displaystyle x}\n \n at layer \n \n \n \n l\n \n \n {\\displaystyle l}\n \n. Higher-order message passing on \n \n \n \n \n \n X\n \n \n \n \n {\\displaystyle {\\mathcal {X}}}\n \n, induced by \n \n \n \n \n \n N\n \n \n \n \n {\\displaystyle {\\mathcal {N}}}\n \n, is defined by the following four update rules:\n\n \n \n \n \n m\n \n x\n ,\n y\n \n \n =\n \n α\n \n \n \n \n N\n \n \n \n k\n \n \n \n \n (\n \n \n h\n \n \n x\n \n \n (\n l\n )\n \n \n ,\n \n \n h\n \n \n y\n \n \n (\n l\n )\n \n \n )\n \n \n {\\displaystyle m_{x,y}=\\alpha _{{\\mathcal {N}}_{k}}(\\mathbf {h} _{x}^{(l)},\\mathbf {h} _{y}^{(l)})}\n \n\n \n \n \n \n m\n \n x\n \n \n k\n \n \n =\n \n ⨁\n \n y\n ∈\n \n \n \n N\n \n \n \n k\n \n \n (\n x\n )\n \n \n \n m\n \n x\n ,\n y\n \n \n \n \n {\\displaystyle m_{x}^{k}=\\bigoplus _{y\\in {\\mathcal {N}}_{k}(x)}m_{x,y}}\n \n, where \n \n \n \n ⨁\n \n \n {\\displaystyle \\bigoplus }\n \n is the intra-neighborhood aggregation function.\n\n \n \n \n \n m\n \n x\n \n \n =\n \n ⨂\n \n \n \n \n N\n \n \n \n k\n \n \n ∈\n \n \n N\n \n \n \n \n \n m\n \n x\n \n \n k\n \n \n \n \n {\\displaystyle m_{x}=\\bigotimes _{{\\mathcal {N}}_{k}\\in {\\mathcal {N}}}m_{x}^{k}}\n \n, where \n \n \n \n ⨂\n \n \n {\\displaystyle \\bigotimes }\n \n is the inter-neighborhood aggregation function.\n\n \n \n \n \n \n h\n \n \n x\n \n \n (\n l\n +\n 1\n )\n \n \n =\n β\n (\n \n \n h\n \n \n x\n \n \n (\n l\n )\n \n \n ,\n \n m\n \n x\n \n \n )\n \n \n {\\displaystyle \\mathbf {h} _{x}^{(l+1)}=\\beta (\\mathbf {h} _{x}^{(l)},m_{x})}\n \n, where \n \n \n \n \n α\n \n \n \n \n N\n \n \n \n k\n \n \n \n \n ,\n β\n \n \n {\\displaystyle \\alpha _{{\\mathcal {N}}_{k}},\\beta }\n \n are differentiable functions.\nSome remarks on the Definition above are as follows.\nFirst, Equation 1 describes how messages are computed between cells \n \n \n \n x\n \n \n {\\displaystyle x}\n \n and \n \n \n \n y\n \n \n {\\displaystyle y}\n \n. The message \n \n \n \n \n m\n \n x\n ,\n y\n \n \n \n \n {\\displaystyle m_{x,y}}\n \n is influenced by both the data \n \n \n \n \n \n h\n \n \n x\n \n \n (\n l\n )\n \n \n \n \n {\\displaystyle \\mathbf {h} _{x}^{(l)}}\n \n and \n \n \n \n \n \n h\n \n \n y\n \n \n (\n l\n )\n \n \n \n \n {\\displaystyle \\mathbf {h} _{y}^{(l)}}\n \n associated with cells \n \n \n \n x\n \n \n {\\displaystyle x}\n \n and \n \n \n \n y\n \n \n {\\displaystyle y}\n \n, respectively. Additionally, it incorporates characteristics specific to the cells themselves, such as orientation in the case of cell complexes. This allows for a richer representation of spatial relationships compared to traditional graph-based message passing frameworks.\nSecond, Equation 2 defines how messages from neighboring cells are aggregated within each neighborhood. The function \n \n \n \n ⨁\n \n \n {\\displaystyle \\bigoplus }\n \n aggregates these messages, allowing information to be exchanged effectively between adjacent cells within the same neighborhood.\nThird, Equation 3 outlines the process of combining messages from different neighborhoods. The function \n \n \n \n ⨂\n \n \n {\\displaystyle \\bigotimes }\n \n aggregates messages across various neighborhoods, facilitating communication between cells that may not be directly connected but share common neighborhood relationships.\nFourth, Equation 4 specifies how the aggregated messages influence the state of a cell in the next layer. Here, the function \n \n \n \n β\n \n \n {\\displaystyle \\beta }\n \n updates the state of cell \n \n \n \n x\n \n \n {\\displaystyle x}\n \n based on its current state \n \n \n \n \n \n h\n \n \n x\n \n \n (\n l\n )\n \n \n \n \n {\\displaystyle \\mathbf {h} _{x}^{(l)}}\n \n and the aggregated message \n \n \n \n \n m\n \n x\n \n \n \n \n {\\displaystyle m_{x}}\n \n obtained from neighboring cells.\n\n\nNon-message passing topological neural networks\nWhile the majority of TNNs follow the message passing paradigm from graph learning, several models have been suggested that do not follow this approach. For instance, Maggs et al. leverage geometric information from embedded simplicial complexes, i.e., simplicial complexes with high-dimensional features attached to their vertices.This offers interpretability and geometric consistency without relying on message passing. Furthermore, in a contrastive loss-based method was suggested to learn the simplicial representation.\n\n\nLearning on topological descriptors\nMotivated by the modular nature of deep neural networks, initial work in TDL drew inspiration from topological data analysis, and aimed to make the resulting descriptors amenable to integration into deep-learning models. This led to work defining new layers for deep neural networks. Pioneering work by Hofer et al., for instance, introduced a layer that permitted topological descriptors like persistence diagrams or persistence barcodes to be integrated into a deep neural network. This was achieved by means of end-to-end-trainable projection functions, permitting topological features to be used to solve shape classification tasks, for instance. Follow-up work expanded more on the theoretical properties of such descriptors and integrated them into the field of representation learning. Other such topological layers include layers based on extended persistent homology descriptors, persistence landscapes, or coordinate functions. In parallel, persistent homology also found applications in graph-learning tasks. Noteworthy examples include new algorithms for learning task-specific filtration functions for graph classification or node classification tasks.\n\n\nApplications\nTDL is rapidly finding new applications across different domains, including data compression, enhancing the expressivity and predictive performance of graph neural networks, action recognition, and trajectory prediction.\n\n\nReferences", "categories": ["Articles with short description", "Deep learning", "Short description matches Wikidata", "Topology"], "references": ["https://arxiv.org/abs/2206.00606", "https://arxiv.org/abs/2304.10031", "https://arxiv.org/abs/2309.02138", "https://arxiv.org/abs/2301.11163", "https://arxiv.org/abs/2010.03633", "https://arxiv.org/abs/2010.00743", "https://arxiv.org/archive/cs.LG", "https://arxiv.org/abs/2102.10058", "https://doi.org/10.1609%2Faaai.v36i6.20583", "https://arxiv.org/abs/2112.06826", "https://doi.org/10.1109%2FTNNLS.2013.2293637", "https://doi.org/10.1016%2Fj.neucom.2024.127787", "https://papers.nips.cc/paper_files/paper/2017/hash/883e881bb4d22a7add958f2d6b052c9f-Abstract.html", "https://papers.nips.cc/paper_files/paper/2020/hash/b803a9254688e259cde2ec0361c8abe4-Abstract.html", "https://papers.nips.cc/paper_files/paper/2021/hash/35a12c43227f217207d4e06ffefe39d3-Abstract.html"], "images": ["File:Higher order message passing.png", "File:Higher order networks.png", "File:Learning tasks on topological spaces.jpg"], "sub_niche": "International Conference on Machine Learning"} {"title": "Normalization (machine learning)", "url": "https://en.wikipedia.org/wiki/Normalization_(machine_learning)", "summary": "In machine learning, normalization is a statistical technique with various applications. There are two main forms of normalization, namely data normalization and activation normalization. Data normalization (or feature scaling) includes methods that rescale input data so that the features have the same range, mean, variance, or other statistical properties. For instance, a popular choice of feature scaling method is min-max normalization, where each feature is transformed to have the same range (typically \n \n \n \n [\n 0\n ,\n 1\n ]\n \n \n {\\displaystyle [0,1]}\n \n or \n \n \n \n [\n −\n 1\n ,\n 1\n ]\n \n \n {\\displaystyle [-1,1]}\n \n). This solves the problem of different features having vast", "content": "In machine learning, normalization is a statistical technique with various applications. There are two main forms of normalization, namely data normalization and activation normalization. Data normalization (or feature scaling) includes methods that rescale input data so that the features have the same range, mean, variance, or other statistical properties. For instance, a popular choice of feature scaling method is min-max normalization, where each feature is transformed to have the same range (typically \n \n \n \n [\n 0\n ,\n 1\n ]\n \n \n {\\displaystyle [0,1]}\n \n or \n \n \n \n [\n −\n 1\n ,\n 1\n ]\n \n \n {\\displaystyle [-1,1]}\n \n). This solves the problem of different features having vastly different scales, for example if one feature is measured in kilometers and another in nanometers.\nActivation normalization, on the other hand, is specific to deep learning, and includes methods that rescale the activation of hidden neurons inside neural networks.\nNormalization is often used to:\n\nincrease the speed of training convergence,\nreduce sensitivity to variations and feature scales in input data,\nreduce overfitting,\nand produce better model generalization to unseen data.\nNormalization techniques are often theoretically justified as reducing covariance shift, smoothing optimization landscapes, and increasing regularization, though they are mainly justified by empirical success.\n\n\nBatch normalization\nBatch normalization (BatchNorm) operates on the activations of a layer for each mini-batch.\nConsider a simple feedforward network, defined by chaining together modules:\n\n \n \n \n \n x\n \n (\n 0\n )\n \n \n ↦\n \n x\n \n (\n 1\n )\n \n \n ↦\n \n x\n \n (\n 2\n )\n \n \n ↦\n ⋯\n \n \n {\\displaystyle x^{(0)}\\mapsto x^{(1)}\\mapsto x^{(2)}\\mapsto \\cdots }\n \n\nwhere each network module can be a linear transform, a nonlinear activation function, a convolution, etc. \n \n \n \n \n x\n \n (\n 0\n )\n \n \n \n \n {\\displaystyle x^{(0)}}\n \n is the input vector, \n \n \n \n \n x\n \n (\n 1\n )\n \n \n \n \n {\\displaystyle x^{(1)}}\n \n is the output vector from the first module, etc.\nBatchNorm is a module that can be inserted at any point in the feedforward network. For example, suppose it is inserted just after \n \n \n \n \n x\n \n (\n l\n )\n \n \n \n \n {\\displaystyle x^{(l)}}\n \n, then the network would operate accordingly:\n\n \n \n \n ⋯\n ↦\n \n x\n \n (\n l\n )\n \n \n ↦\n \n B\n N\n \n (\n \n x\n \n (\n l\n )\n \n \n )\n ↦\n \n x\n \n (\n l\n +\n 1\n )\n \n \n ↦\n ⋯\n \n \n {\\displaystyle \\cdots \\mapsto x^{(l)}\\mapsto \\mathrm {BN} (x^{(l)})\\mapsto x^{(l+1)}\\mapsto \\cdots }\n \n\nThe BatchNorm module does not operate over individual inputs. Instead, it must operate over one batch of inputs at a time.\nConcretely, suppose we have a batch of inputs \n \n \n \n \n x\n \n (\n 1\n )\n \n \n (\n 0\n )\n \n \n ,\n \n x\n \n (\n 2\n )\n \n \n (\n 0\n )\n \n \n ,\n …\n ,\n \n x\n \n (\n B\n )\n \n \n (\n 0\n )\n \n \n \n \n {\\displaystyle x_{(1)}^{(0)},x_{(2)}^{(0)},\\dots ,x_{(B)}^{(0)}}\n \n, fed all at once into the network. We would obtain in the middle of the network some vectors:\n\n \n \n \n \n x\n \n (\n 1\n )\n \n \n (\n l\n )\n \n \n ,\n \n x\n \n (\n 2\n )\n \n \n (\n l\n )\n \n \n ,\n …\n ,\n \n x\n \n (\n B\n )\n \n \n (\n l\n )\n \n \n \n \n {\\displaystyle x_{(1)}^{(l)},x_{(2)}^{(l)},\\dots ,x_{(B)}^{(l)}}\n \n\nThe BatchNorm module computes the coordinate-wise mean and variance of these vectors:\n\n \n \n \n \n \n \n \n \n μ\n \n i\n \n \n (\n l\n )\n \n \n \n \n \n =\n \n \n 1\n B\n \n \n \n ∑\n \n b\n =\n 1\n \n \n B\n \n \n \n x\n \n (\n b\n )\n ,\n i\n \n \n (\n l\n )\n \n \n \n \n \n \n (\n \n σ\n \n i\n \n \n (\n l\n )\n \n \n \n )\n \n 2\n \n \n \n \n \n =\n \n \n 1\n B\n \n \n \n ∑\n \n b\n =\n 1\n \n \n B\n \n \n (\n \n x\n \n (\n b\n )\n ,\n i\n \n \n (\n l\n )\n \n \n −\n \n μ\n \n i\n \n \n (\n l\n )\n \n \n \n )\n \n 2\n \n \n \n \n \n \n \n \n {\\displaystyle {\\begin{aligned}\\mu _{i}^{(l)}&={\\frac {1}{B}}\\sum _{b=1}^{B}x_{(b),i}^{(l)}\\\\(\\sigma _{i}^{(l)})^{2}&={\\frac {1}{B}}\\sum _{b=1}^{B}(x_{(b),i}^{(l)}-\\mu _{i}^{(l)})^{2}\\end{aligned}}}\n \n\nwhere \n \n \n \n i\n \n \n {\\displaystyle i}\n \n indexes the coordinates of the vectors, and \n \n \n \n b\n \n \n {\\displaystyle b}\n \n indexes the elements of the batch. In other words, we are considering the \n \n \n \n i\n \n \n {\\displaystyle i}\n \n-th coordinate of each vector in the batch, and computing the mean and variance of these numbers.\nIt then normalizes each coordinate to have zero mean and unit variance:\n\n \n \n \n \n \n \n \n x\n ^\n \n \n \n \n (\n b\n )\n ,\n i\n \n \n (\n l\n )\n \n \n =\n \n \n \n \n x\n \n (\n b\n )\n ,\n i\n \n \n (\n l\n )\n \n \n −\n \n μ\n \n i\n \n \n (\n l\n )\n \n \n \n \n (\n \n σ\n \n i\n \n \n (\n l\n )\n \n \n \n )\n \n 2\n \n \n +\n ϵ\n \n \n \n \n \n {\\displaystyle {\\hat {x}}_{(b),i}^{(l)}={\\frac {x_{(b),i}^{(l)}-\\mu _{i}^{(l)}}{\\sqrt {(\\sigma _{i}^{(l)})^{2}+\\epsilon }}}}\n \n\nThe \n \n \n \n ϵ\n \n \n {\\displaystyle \\epsilon }\n \n is a small positive constant such as \n \n \n \n \n 10\n \n −\n 9\n \n \n \n \n {\\displaystyle 10^{-9}}\n \n added to the variance for numerical stability, to avoid division by zero.\nFinally, it applies a linear transformation:\n\n \n \n \n \n y\n \n (\n b\n )\n ,\n i\n \n \n (\n l\n )\n \n \n =\n \n γ\n \n i\n \n \n \n \n \n \n x\n ^\n \n \n \n \n (\n b\n )\n ,\n i\n \n \n (\n l\n )\n \n \n +\n \n β\n \n i\n \n \n \n \n {\\displaystyle y_{(b),i}^{(l)}=\\gamma _{i}{\\hat {x}}_{(b),i}^{(l)}+\\beta _{i}}\n \n\nHere, \n \n \n \n γ\n \n \n {\\displaystyle \\gamma }\n \n and \n \n \n \n β\n \n \n {\\displaystyle \\beta }\n \n are parameters inside the BatchNorm module. They are learnable parameters, typically trained by gradient descent.\nThe following is a Python implementation of BatchNorm:\n\n\nInterpretation\n\n \n \n \n γ\n \n \n {\\displaystyle \\gamma }\n \n and \n \n \n \n β\n \n \n {\\displaystyle \\beta }\n \n allow the network to learn to undo the normalization, if this is beneficial. BatchNorm can be interpreted as removing the purely linear transformations, so that its layers focus solely on modelling the nonlinear aspects of data, which may be beneficial, as a neural network can always be augmented with a linear transformation layer on top.\nIt is claimed in the original publication that BatchNorm works by reducing internal covariance shift, though the claim has both supporters and detractors.\n\n\nSpecial cases\nThe original paper recommended to only use BatchNorms after a linear transform, not after a nonlinear activation. That is, \n \n \n \n ϕ\n (\n \n B\n N\n \n (\n W\n x\n +\n b\n )\n )\n \n \n {\\displaystyle \\phi (\\mathrm {BN} (Wx+b))}\n \n, not \n \n \n \n \n B\n N\n \n (\n ϕ\n (\n W\n x\n +\n b\n )\n )\n \n \n {\\displaystyle \\mathrm {BN} (\\phi (Wx+b))}\n \n. Also, the bias \n \n \n \n b\n \n \n {\\displaystyle b}\n \n does not matter, since it would be canceled by the subsequent mean subtraction, so it is of the form \n \n \n \n \n B\n N\n \n (\n W\n x\n )\n \n \n {\\displaystyle \\mathrm {BN} (Wx)}\n \n. That is, if a BatchNorm is preceded by a linear transform, then that linear transform's bias term is set to zero.\nFor convolutional neural networks (CNNs), BatchNorm must preserve the translation-invariance of these models, meaning that it must treat all outputs of the same kernel as if they are different data points within a batch. This is sometimes called Spatial BatchNorm, or BatchNorm2D, or per-channel BatchNorm.\nConcretely, suppose we have a 2-dimensional convolutional layer defined by:\n\n \n \n \n \n x\n \n h\n ,\n w\n ,\n c\n \n \n (\n l\n )\n \n \n =\n \n ∑\n \n \n h\n ′\n \n ,\n \n w\n ′\n \n ,\n \n c\n ′\n \n \n \n \n K\n \n \n h\n ′\n \n −\n h\n ,\n \n w\n ′\n \n −\n w\n ,\n c\n ,\n \n c\n ′\n \n \n \n (\n l\n )\n \n \n \n x\n \n \n h\n ′\n \n ,\n \n w\n ′\n \n ,\n \n c\n ′\n \n \n \n (\n l\n −\n 1\n )\n \n \n +\n \n b\n \n c\n \n \n (\n l\n )\n \n \n \n \n {\\displaystyle x_{h,w,c}^{(l)}=\\sum _{h',w',c'}K_{h'-h,w'-w,c,c'}^{(l)}x_{h',w',c'}^{(l-1)}+b_{c}^{(l)}}\n \n\nwhere:\n\n \n \n \n \n x\n \n h\n ,\n w\n ,\n c\n \n \n (\n l\n )\n \n \n \n \n {\\displaystyle x_{h,w,c}^{(l)}}\n \n is the activation of the neuron at position \n \n \n \n (\n h\n ,\n w\n )\n \n \n {\\displaystyle (h,w)}\n \n in the \n \n \n \n c\n \n \n {\\displaystyle c}\n \n-th channel of the \n \n \n \n l\n \n \n {\\displaystyle l}\n \n-th layer.\n\n \n \n \n \n K\n \n Δ\n h\n ,\n Δ\n w\n ,\n c\n ,\n \n c\n ′\n \n \n \n (\n l\n )\n \n \n \n \n {\\displaystyle K_{\\Delta h,\\Delta w,c,c'}^{(l)}}\n \n is a kernel tensor. Each channel \n \n \n \n c\n \n \n {\\displaystyle c}\n \n corresponds to a kernel \n \n \n \n \n K\n \n \n h\n ′\n \n −\n h\n ,\n \n w\n ′\n \n −\n w\n ,\n c\n ,\n \n c\n ′\n \n \n \n (\n l\n )\n \n \n \n \n {\\displaystyle K_{h'-h,w'-w,c,c'}^{(l)}}\n \n, with indices \n \n \n \n Δ\n h\n ,\n Δ\n w\n ,\n \n c\n ′\n \n \n \n {\\displaystyle \\Delta h,\\Delta w,c'}\n \n.\n\n \n \n \n \n b\n \n c\n \n \n (\n l\n )\n \n \n \n \n {\\displaystyle b_{c}^{(l)}}\n \n is the bias term for the \n \n \n \n c\n \n \n {\\displaystyle c}\n \n-th channel of the \n \n \n \n l\n \n \n {\\displaystyle l}\n \n-th layer.\nIn order to preserve the translational invariance, BatchNorm treats all outputs from the same kernel in the same batch as more data in a batch. That is, it is applied once per kernel \n \n \n \n c\n \n \n {\\displaystyle c}\n \n (equivalently, once per channel \n \n \n \n c\n \n \n {\\displaystyle c}\n \n), not per activation \n \n \n \n \n x\n \n h\n ,\n w\n ,\n c\n \n \n (\n l\n +\n 1\n )\n \n \n \n \n {\\displaystyle x_{h,w,c}^{(l+1)}}\n \n:\n\n \n \n \n \n \n \n \n \n μ\n \n c\n \n \n (\n l\n )\n \n \n \n \n \n =\n \n \n 1\n \n B\n H\n W\n \n \n \n \n ∑\n \n b\n =\n 1\n \n \n B\n \n \n \n ∑\n \n h\n =\n 1\n \n \n H\n \n \n \n ∑\n \n w\n =\n 1\n \n \n W\n \n \n \n x\n \n (\n b\n )\n ,\n h\n ,\n w\n ,\n c\n \n \n (\n l\n )\n \n \n \n \n \n \n (\n \n σ\n \n c\n \n \n (\n l\n )\n \n \n \n )\n \n 2\n \n \n \n \n \n =\n \n \n 1\n \n B\n H\n W\n \n \n \n \n ∑\n \n b\n =\n 1\n \n \n B\n \n \n \n ∑\n \n h\n =\n 1\n \n \n H\n \n \n \n ∑\n \n w\n =\n 1\n \n \n W\n \n \n (\n \n x\n \n (\n b\n )\n ,\n h\n ,\n w\n ,\n c\n \n \n (\n l\n )\n \n \n −\n \n μ\n \n c\n \n \n (\n l\n )\n \n \n \n )\n \n 2\n \n \n \n \n \n \n \n \n {\\displaystyle {\\begin{aligned}\\mu _{c}^{(l)}&={\\frac {1}{BHW}}\\sum _{b=1}^{B}\\sum _{h=1}^{H}\\sum _{w=1}^{W}x_{(b),h,w,c}^{(l)}\\\\(\\sigma _{c}^{(l)})^{2}&={\\frac {1}{BHW}}\\sum _{b=1}^{B}\\sum _{h=1}^{H}\\sum _{w=1}^{W}(x_{(b),h,w,c}^{(l)}-\\mu _{c}^{(l)})^{2}\\end{aligned}}}\n \n\nwhere \n \n \n \n B\n \n \n {\\displaystyle B}\n \n is the batch size, \n \n \n \n H\n \n \n {\\displaystyle H}\n \n is the height of the feature map, and \n \n \n \n W\n \n \n {\\displaystyle W}\n \n is the width of the feature map.\nThat is, even though there are only \n \n \n \n B\n \n \n {\\displaystyle B}\n \n data points in a batch, all \n \n \n \n B\n H\n W\n \n \n {\\displaystyle BHW}\n \n outputs from the kernel in this batch are treated equally.\nSubsequently, normalization and the linear transform is also done per kernel:\n\n \n \n \n \n \n \n \n \n \n \n \n x\n ^\n \n \n \n \n (\n b\n )\n ,\n h\n ,\n w\n ,\n c\n \n \n (\n l\n )\n \n \n \n \n \n =\n \n \n \n \n x\n \n (\n b\n )\n ,\n h\n ,\n w\n ,\n c\n \n \n (\n l\n )\n \n \n −\n \n μ\n \n c\n \n \n (\n l\n )\n \n \n \n \n (\n \n σ\n \n c\n \n \n (\n l\n )\n \n \n \n )\n \n 2\n \n \n +\n ϵ\n \n \n \n \n \n \n \n \n y\n \n (\n b\n )\n ,\n h\n ,\n w\n ,\n c\n \n \n (\n l\n )\n \n \n \n \n \n =\n \n γ\n \n c\n \n \n \n \n \n \n x\n ^\n \n \n \n \n (\n b\n )\n ,\n h\n ,\n w\n ,\n c\n \n \n (\n l\n )\n \n \n +\n \n β\n \n c\n \n \n \n \n \n \n \n \n {\\displaystyle {\\begin{aligned}{\\hat {x}}_{(b),h,w,c}^{(l)}&={\\frac {x_{(b),h,w,c}^{(l)}-\\mu _{c}^{(l)}}{\\sqrt {(\\sigma _{c}^{(l)})^{2}+\\epsilon }}}\\\\y_{(b),h,w,c}^{(l)}&=\\gamma _{c}{\\hat {x}}_{(b),h,w,c}^{(l)}+\\beta _{c}\\end{aligned}}}\n \n\nSimilar considerations apply for BatchNorm for n-dimensional convolutions.\nThe following is a Python implementation of BatchNorm for 2D convolutions:\n\nFor multilayered recurrent neural networks (RNN), BatchNorm is usually applied only for the input-to-hidden part, not the hidden-to-hidden part. Let the hidden state of the \n \n \n \n l\n \n \n {\\displaystyle l}\n \n-th layer at time \n \n \n \n t\n \n \n {\\displaystyle t}\n \n be \n \n \n \n \n h\n \n t\n \n \n (\n l\n )\n \n \n \n \n {\\displaystyle h_{t}^{(l)}}\n \n. The standard RNN, without normalization, satisfies\n \n \n \n \n h\n \n t\n \n \n (\n l\n )\n \n \n =\n ϕ\n (\n \n W\n \n (\n l\n )\n \n \n \n h\n \n t\n \n \n l\n −\n 1\n \n \n +\n \n U\n \n (\n l\n )\n \n \n \n h\n \n t\n −\n 1\n \n \n l\n \n \n +\n \n b\n \n (\n l\n )\n \n \n )\n \n \n {\\displaystyle h_{t}^{(l)}=\\phi (W^{(l)}h_{t}^{l-1}+U^{(l)}h_{t-1}^{l}+b^{(l)})}\n \nwhere \n \n \n \n \n W\n \n (\n l\n )\n \n \n ,\n \n U\n \n (\n l\n )\n \n \n ,\n \n b\n \n (\n l\n )\n \n \n \n \n {\\displaystyle W^{(l)},U^{(l)},b^{(l)}}\n \n are weights and biases, and \n \n \n \n ϕ\n \n \n {\\displaystyle \\phi }\n \n is the activation function. Applying BatchNorm, this becomes\n \n \n \n \n h\n \n t\n \n \n (\n l\n )\n \n \n =\n ϕ\n (\n \n B\n N\n \n (\n \n W\n \n (\n l\n )\n \n \n \n h\n \n t\n \n \n l\n −\n 1\n \n \n )\n +\n \n U\n \n (\n l\n )\n \n \n \n h\n \n t\n −\n 1\n \n \n l\n \n \n )\n \n \n {\\displaystyle h_{t}^{(l)}=\\phi (\\mathrm {BN} (W^{(l)}h_{t}^{l-1})+U^{(l)}h_{t-1}^{l})}\n \nThere are two possible ways to define what a \"batch\" is in BatchNorm for RNNs: frame-wise and sequence-wise. Concretely, consider applying an RNN to process a batch of sentences. Let \n \n \n \n \n h\n \n b\n ,\n t\n \n \n (\n l\n )\n \n \n \n \n {\\displaystyle h_{b,t}^{(l)}}\n \n be the hidden state of the \n \n \n \n l\n \n \n {\\displaystyle l}\n \n-th layer for the \n \n \n \n t\n \n \n {\\displaystyle t}\n \n-th token of the \n \n \n \n b\n \n \n {\\displaystyle b}\n \n-th input sentence. Then frame-wise BatchNorm means normalizing over \n \n \n \n b\n \n \n {\\displaystyle b}\n \n:\n \n \n \n \n \n \n \n \n μ\n \n t\n \n \n (\n l\n )\n \n \n \n \n \n =\n \n \n 1\n B\n \n \n \n ∑\n \n b\n =\n 1\n \n \n B\n \n \n \n h\n \n i\n ,\n t\n \n \n (\n l\n )\n \n \n \n \n \n \n (\n \n σ\n \n t\n \n \n (\n l\n )\n \n \n \n )\n \n 2\n \n \n \n \n \n =\n \n \n 1\n B\n \n \n \n ∑\n \n b\n =\n 1\n \n \n B\n \n \n (\n \n h\n \n t\n \n \n (\n l\n )\n \n \n −\n \n μ\n \n t\n \n \n (\n l\n )\n \n \n \n )\n \n 2\n \n \n \n \n \n \n \n \n {\\displaystyle {\\begin{aligned}\\mu _{t}^{(l)}&={\\frac {1}{B}}\\sum _{b=1}^{B}h_{i,t}^{(l)}\\\\(\\sigma _{t}^{(l)})^{2}&={\\frac {1}{B}}\\sum _{b=1}^{B}(h_{t}^{(l)}-\\mu _{t}^{(l)})^{2}\\end{aligned}}}\n \nand sequence-wise means normalizing over \n \n \n \n (\n b\n ,\n t\n )\n \n \n {\\displaystyle (b,t)}\n \n:\n \n \n \n \n \n \n \n \n μ\n \n (\n l\n )\n \n \n \n \n \n =\n \n \n 1\n \n B\n T\n \n \n \n \n ∑\n \n b\n =\n 1\n \n \n B\n \n \n \n ∑\n \n t\n =\n 1\n \n \n T\n \n \n \n h\n \n i\n ,\n t\n \n \n (\n l\n )\n \n \n \n \n \n \n (\n \n σ\n \n (\n l\n )\n \n \n \n )\n \n 2\n \n \n \n \n \n =\n \n \n 1\n \n B\n T\n \n \n \n \n ∑\n \n b\n =\n 1\n \n \n B\n \n \n \n ∑\n \n t\n =\n 1\n \n \n T\n \n \n (\n \n h\n \n t\n \n \n (\n l\n )\n \n \n −\n \n μ\n \n (\n l\n )\n \n \n \n )\n \n 2\n \n \n \n \n \n \n \n \n {\\displaystyle {\\begin{aligned}\\mu ^{(l)}&={\\frac {1}{BT}}\\sum _{b=1}^{B}\\sum _{t=1}^{T}h_{i,t}^{(l)}\\\\(\\sigma ^{(l)})^{2}&={\\frac {1}{BT}}\\sum _{b=1}^{B}\\sum _{t=1}^{T}(h_{t}^{(l)}-\\mu ^{(l)})^{2}\\end{aligned}}}\n \nFrame-wise BatchNorm is suited for causal tasks such as next-character prediction, where future frames are unavailable, forcing normalization per frame. Sequence-wise BatchNorm is suited for tasks such as speech recognition, where the entire sequences are available, but with variable lengths. In a batch, the smaller sequences are padded with zeroes to match the size of the longest sequence of the batch. In such setups, frame-wise is not recommended, because the number of unpadded frames decreases along the time axis, leading to increasingly poorer statistics estimates.\nIt is also possible to apply BatchNorm to LSTMs.\n\n\nImprovements\nBatchNorm has been very popular and there were many attempted improvements. Some examples include:\n\nghost batching: randomly partition a batch into sub-batches and perform BatchNorm separately on each;\nweight decay on \n \n \n \n γ\n \n \n {\\displaystyle \\gamma }\n \n and \n \n \n \n β\n \n \n {\\displaystyle \\beta }\n \n;\nand combining BatchNorm with GroupNorm.\nA particular problem with BatchNorm is that during training, the mean and variance are calculated on the fly for each batch (usually as an exponential moving average), but during inference, the mean and variance were frozen from those calculated during training. This train-test disparity degrades performance. The disparity can be decreased by simulating the moving average during inference:\n\n \n \n \n \n \n \n \n μ\n \n \n \n =\n α\n E\n [\n x\n ]\n +\n (\n 1\n −\n α\n )\n \n μ\n \n x\n ,\n \n train\n \n \n \n \n \n \n \n \n σ\n \n 2\n \n \n \n \n \n =\n (\n α\n E\n [\n x\n \n ]\n \n 2\n \n \n +\n (\n 1\n −\n α\n )\n \n μ\n \n \n x\n \n 2\n \n \n ,\n \n train\n \n \n \n )\n −\n \n μ\n \n 2\n \n \n \n \n \n \n \n \n {\\displaystyle {\\begin{aligned}\\mu &=\\alpha E[x]+(1-\\alpha )\\mu _{x,{\\text{ train}}}\\\\\\sigma ^{2}&=(\\alpha E[x]^{2}+(1-\\alpha )\\mu _{x^{2},{\\text{ train}}})-\\mu ^{2}\\end{aligned}}}\n \n\nwhere \n \n \n \n α\n \n \n {\\displaystyle \\alpha }\n \n is a hyperparameter to be optimized on a validation set.\nOther works attempt to eliminate BatchNorm, such as the Normalizer-Free ResNet.\n\n\nLayer normalization\nLayer normalization (LayerNorm) is a popular alternative to BatchNorm. Unlike BatchNorm, which normalizes activations across the batch dimension for a given feature, LayerNorm normalizes across all the features within a single data sample. Compared to BatchNorm, LayerNorm's performance is not affected by batch size. It is a key component of transformer models.\nFor a given data input and layer, LayerNorm computes the mean \n \n \n \n μ\n \n \n {\\displaystyle \\mu }\n \n and variance \n \n \n \n \n σ\n \n 2\n \n \n \n \n {\\displaystyle \\sigma ^{2}}\n \n over all the neurons in the layer. Similar to BatchNorm, learnable parameters \n \n \n \n γ\n \n \n {\\displaystyle \\gamma }\n \n (scale) and \n \n \n \n β\n \n \n {\\displaystyle \\beta }\n \n (shift) are applied. It is defined by:\n\n \n \n \n \n \n \n \n x\n \n i\n \n \n ^\n \n \n \n =\n \n \n \n \n x\n \n i\n \n \n −\n μ\n \n \n \n σ\n \n 2\n \n \n +\n ϵ\n \n \n \n ,\n \n \n y\n \n i\n \n \n =\n \n γ\n \n i\n \n \n \n \n \n \n x\n \n i\n \n \n ^\n \n \n \n +\n \n β\n \n i\n \n \n \n \n {\\displaystyle {\\hat {x_{i}}}={\\frac {x_{i}-\\mu }{\\sqrt {\\sigma ^{2}+\\epsilon }}},\\quad y_{i}=\\gamma _{i}{\\hat {x_{i}}}+\\beta _{i}}\n \n\nwhere:\n\n \n \n \n μ\n =\n \n \n 1\n D\n \n \n \n ∑\n \n i\n =\n 1\n \n \n D\n \n \n \n x\n \n i\n \n \n ,\n \n \n σ\n \n 2\n \n \n =\n \n \n 1\n D\n \n \n \n ∑\n \n i\n =\n 1\n \n \n D\n \n \n (\n \n x\n \n i\n \n \n −\n μ\n \n )\n \n 2\n \n \n \n \n {\\displaystyle \\mu ={\\frac {1}{D}}\\sum _{i=1}^{D}x_{i},\\quad \\sigma ^{2}={\\frac {1}{D}}\\sum _{i=1}^{D}(x_{i}-\\mu )^{2}}\n \n\nand the index \n \n \n \n i\n \n \n {\\displaystyle i}\n \n ranges over the neurons in that layer.\n\n\nExamples\nFor example, in CNN, a LayerNorm applies to all activations in a layer. In the previous notation, we have:\n\n \n \n \n \n \n \n \n \n μ\n \n (\n l\n )\n \n \n \n \n \n =\n \n \n 1\n \n H\n W\n C\n \n \n \n \n ∑\n \n h\n =\n 1\n \n \n H\n \n \n \n ∑\n \n w\n =\n 1\n \n \n W\n \n \n \n ∑\n \n c\n =\n 1\n \n \n C\n \n \n \n x\n \n h\n ,\n w\n ,\n c\n \n \n (\n l\n )\n \n \n \n \n \n \n (\n \n σ\n \n (\n l\n )\n \n \n \n )\n \n 2\n \n \n \n \n \n =\n \n \n 1\n \n H\n W\n C\n \n \n \n \n ∑\n \n h\n =\n 1\n \n \n H\n \n \n \n ∑\n \n w\n =\n 1\n \n \n W\n \n \n \n ∑\n \n c\n =\n 1\n \n \n C\n \n \n (\n \n x\n \n h\n ,\n w\n ,\n c\n \n \n (\n l\n )\n \n \n −\n \n μ\n \n (\n l\n )\n \n \n \n )\n \n 2\n \n \n \n \n \n \n \n \n \n \n x\n ^\n \n \n \n \n h\n ,\n w\n ,\n c\n \n \n (\n l\n )\n \n \n \n \n \n =\n \n \n \n \n \n \n \n x\n ^\n \n \n \n \n h\n ,\n w\n ,\n c\n \n \n (\n l\n )\n \n \n −\n \n μ\n \n (\n l\n )\n \n \n \n \n (\n \n σ\n \n (\n l\n )\n \n \n \n )\n \n 2\n \n \n +\n ϵ\n \n \n \n \n \n \n \n \n y\n \n h\n ,\n w\n ,\n c\n \n \n (\n l\n )\n \n \n \n \n \n =\n \n γ\n \n (\n l\n )\n \n \n \n \n \n \n x\n ^\n \n \n \n \n h\n ,\n w\n ,\n c\n \n \n (\n l\n )\n \n \n +\n \n β\n \n (\n l\n )\n \n \n \n \n \n \n \n \n {\\displaystyle {\\begin{aligned}\\mu ^{(l)}&={\\frac {1}{HWC}}\\sum _{h=1}^{H}\\sum _{w=1}^{W}\\sum _{c=1}^{C}x_{h,w,c}^{(l)}\\\\(\\sigma ^{(l)})^{2}&={\\frac {1}{HWC}}\\sum _{h=1}^{H}\\sum _{w=1}^{W}\\sum _{c=1}^{C}(x_{h,w,c}^{(l)}-\\mu ^{(l)})^{2}\\\\{\\hat {x}}_{h,w,c}^{(l)}&={\\frac {{\\hat {x}}_{h,w,c}^{(l)}-\\mu ^{(l)}}{\\sqrt {(\\sigma ^{(l)})^{2}+\\epsilon }}}\\\\y_{h,w,c}^{(l)}&=\\gamma ^{(l)}{\\hat {x}}_{h,w,c}^{(l)}+\\beta ^{(l)}\\end{aligned}}}\n \n\nNotice that the batch index \n \n \n \n b\n \n \n {\\displaystyle b}\n \n is removed, while the channel index \n \n \n \n c\n \n \n {\\displaystyle c}\n \n is added.\nIn recurrent neural networks and transformers, LayerNorm is applied individually to each timestep. For example, if the hidden vector in an RNN at timestep \n \n \n \n t\n \n \n {\\displaystyle t}\n \n is \n \n \n \n \n x\n \n (\n t\n )\n \n \n ∈\n \n \n R\n \n \n D\n \n \n \n \n {\\displaystyle x^{(t)}\\in \\mathbb {R} ^{D}}\n \n, where \n \n \n \n D\n \n \n {\\displaystyle D}\n \n is the dimension of the hidden vector, then LayerNorm will be applied with:\n\n \n \n \n \n \n \n \n \n x\n \n i\n \n \n ^\n \n \n \n \n (\n t\n )\n \n \n =\n \n \n \n \n x\n \n i\n \n \n (\n t\n )\n \n \n −\n \n μ\n \n (\n t\n )\n \n \n \n \n (\n \n σ\n \n (\n t\n )\n \n \n \n )\n \n 2\n \n \n +\n ϵ\n \n \n \n ,\n \n \n y\n \n i\n \n \n (\n t\n )\n \n \n =\n \n γ\n \n i\n \n \n \n \n \n \n \n x\n \n i\n \n \n ^\n \n \n \n \n (\n t\n )\n \n \n +\n \n β\n \n i\n \n \n \n \n {\\displaystyle {\\hat {x_{i}}}^{(t)}={\\frac {x_{i}^{(t)}-\\mu ^{(t)}}{\\sqrt {(\\sigma ^{(t)})^{2}+\\epsilon }}},\\quad y_{i}^{(t)}=\\gamma _{i}{\\hat {x_{i}}}^{(t)}+\\beta _{i}}\n \n\nwhere:\n\n \n \n \n \n μ\n \n (\n t\n )\n \n \n =\n \n \n 1\n D\n \n \n \n ∑\n \n i\n =\n 1\n \n \n D\n \n \n \n x\n \n i\n \n \n (\n t\n )\n \n \n ,\n \n (\n \n σ\n \n (\n t\n )\n \n \n \n )\n \n 2\n \n \n =\n \n \n 1\n D\n \n \n \n ∑\n \n i\n =\n 1\n \n \n D\n \n \n (\n \n x\n \n i\n \n \n (\n t\n )\n \n \n −\n \n μ\n \n (\n t\n )\n \n \n \n )\n \n 2\n \n \n \n \n {\\displaystyle \\mu ^{(t)}={\\frac {1}{D}}\\sum _{i=1}^{D}x_{i}^{(t)},\\quad (\\sigma ^{(t)})^{2}={\\frac {1}{D}}\\sum _{i=1}^{D}(x_{i}^{(t)}-\\mu ^{(t)})^{2}}\n \n\n\nRoot mean square layer normalization\nRoot mean square layer normalization (RMSNorm):\n\n \n \n \n \n \n \n \n x\n \n i\n \n \n ^\n \n \n \n =\n \n \n \n x\n \n i\n \n \n \n \n \n 1\n D\n \n \n \n ∑\n \n j\n =\n 1\n \n \n D\n \n \n \n x\n \n j\n \n \n 2\n \n \n \n \n \n ,\n \n \n y\n \n i\n \n \n =\n γ\n \n \n \n \n x\n \n i\n \n \n ^\n \n \n \n +\n β\n \n \n {\\displaystyle {\\hat {x_{i}}}={\\frac {x_{i}}{\\sqrt {{\\frac {1}{D}}\\sum _{j=1}^{D}x_{j}^{2}}}},\\quad y_{i}=\\gamma {\\hat {x_{i}}}+\\beta }\n \n\nEssentially, it is LayerNorm where we enforce \n \n \n \n μ\n ,\n ϵ\n =\n 0\n \n \n {\\displaystyle \\mu ,\\epsilon =0}\n \n. It is also called L2 normalization. It is a special case of Lp normalization, or power normalization:\n \n \n \n \n \n \n \n x\n \n i\n \n \n ^\n \n \n \n =\n \n \n \n x\n \n i\n \n \n \n \n (\n \n \n \n 1\n D\n \n \n \n ∑\n \n j\n =\n 1\n \n \n D\n \n \n \n |\n \n \n x\n \n j\n \n \n \n \n |\n \n \n p\n \n \n \n )\n \n \n 1\n \n /\n \n p\n \n \n \n \n ,\n \n \n y\n \n i\n \n \n =\n γ\n \n \n \n \n x\n \n i\n \n \n ^\n \n \n \n +\n β\n \n \n {\\displaystyle {\\hat {x_{i}}}={\\frac {x_{i}}{\\left({\\frac {1}{D}}\\sum _{j=1}^{D}|x_{j}|^{p}\\right)^{1/p}}},\\quad y_{i}=\\gamma {\\hat {x_{i}}}+\\beta }\n \nwhere \n \n \n \n p\n >\n 0\n \n \n {\\displaystyle p>0}\n \n is a constant.\n\n\nAdaptive\nAdaptive layer norm (adaLN) computes the \n \n \n \n γ\n ,\n β\n \n \n {\\displaystyle \\gamma ,\\beta }\n \n in a LayerNorm not from the layer activation itself, but from other data. It was first proposed for CNNs, and has been used effectively in diffusion transformers (DiTs). For example, in a DiT, the conditioning information (such as a text encoding vector) is processed by a multilayer perceptron into \n \n \n \n γ\n ,\n β\n \n \n {\\displaystyle \\gamma ,\\beta }\n \n, which is then applied in the LayerNorm module of a transformer.\n\n\nWeight normalization\nWeight normalization (WeightNorm) is a technique inspired by BatchNorm that normalizes weight matrices in a neural network, rather than its activations.\nOne example is spectral normalization, which divides weight matrices by their spectral norm. The spectral normalization is used in generative adversarial networks (GANs) such as the Wasserstein GAN. The spectral radius can be efficiently computed by the following algorithm:\n\nINPUT matrix \n \n \n \n W\n \n \n {\\displaystyle W}\n \n and initial guess \n \n \n \n x\n \n \n {\\displaystyle x}\n \n\nIterate \n \n \n \n x\n ↦\n \n \n 1\n \n ‖\n W\n x\n \n ‖\n \n 2\n \n \n \n \n \n W\n x\n \n \n {\\displaystyle x\\mapsto {\\frac {1}{\\|Wx\\|_{2}}}Wx}\n \n to convergence \n \n \n \n \n x\n \n ∗\n \n \n \n \n {\\displaystyle x^{*}}\n \n. This is the eigenvector of \n \n \n \n W\n \n \n {\\displaystyle W}\n \n with eigenvalue \n \n \n \n ‖\n W\n \n ‖\n \n s\n \n \n \n \n {\\displaystyle \\|W\\|_{s}}\n \n.\n\nRETURN \n \n \n \n \n x\n \n ∗\n \n \n ,\n ‖\n W\n \n x\n \n ∗\n \n \n \n ‖\n \n 2\n \n \n \n \n {\\displaystyle x^{*},\\|Wx^{*}\\|_{2}}\n \n\nBy reassigning \n \n \n \n \n W\n \n i\n \n \n ←\n \n \n \n W\n \n i\n \n \n \n ‖\n \n W\n \n i\n \n \n \n ‖\n \n s\n \n \n \n \n \n \n \n {\\displaystyle W_{i}\\leftarrow {\\frac {W_{i}}{\\|W_{i}\\|_{s}}}}\n \n after each update of the discriminator, we can upper-bound \n \n \n \n ‖\n \n W\n \n i\n \n \n \n ‖\n \n s\n \n \n ≤\n 1\n \n \n {\\displaystyle \\|W_{i}\\|_{s}\\leq 1}\n \n, and thus upper-bound \n \n \n \n ‖\n D\n \n ‖\n \n L\n \n \n \n \n {\\displaystyle \\|D\\|_{L}}\n \n.\nThe algorithm can be further accelerated by memoization: at step \n \n \n \n t\n \n \n {\\displaystyle t}\n \n, store \n \n \n \n \n x\n \n i\n \n \n ∗\n \n \n (\n t\n )\n \n \n {\\displaystyle x_{i}^{*}(t)}\n \n. Then, at step \n \n \n \n t\n +\n 1\n \n \n {\\displaystyle t+1}\n \n, use \n \n \n \n \n x\n \n i\n \n \n ∗\n \n \n (\n t\n )\n \n \n {\\displaystyle x_{i}^{*}(t)}\n \n as the initial guess for the algorithm. Since \n \n \n \n \n W\n \n i\n \n \n (\n t\n +\n 1\n )\n \n \n {\\displaystyle W_{i}(t+1)}\n \n is very close to \n \n \n \n \n W\n \n i\n \n \n (\n t\n )\n \n \n {\\displaystyle W_{i}(t)}\n \n, so is \n \n \n \n \n x\n \n i\n \n \n ∗\n \n \n (\n t\n )\n \n \n {\\displaystyle x_{i}^{*}(t)}\n \n to \n \n \n \n \n x\n \n i\n \n \n ∗\n \n \n (\n t\n +\n 1\n )\n \n \n {\\displaystyle x_{i}^{*}(t+1)}\n \n, thus allowing rapid convergence.\n\n\nCNN-specific normalization\nThere are some activation normalization techniques that are only used for CNNs.\n\n\nResponse normalization\nLocal response normalization was used in AlexNet. It was applied in a convolutional layer, just after a nonlinear activation function. It was defined by:\n\n \n \n \n \n b\n \n x\n ,\n y\n \n \n i\n \n \n =\n \n \n \n a\n \n x\n ,\n y\n \n \n i\n \n \n \n \n (\n \n k\n +\n α\n \n ∑\n \n j\n =\n max\n (\n 0\n ,\n i\n −\n n\n \n /\n \n 2\n )\n \n \n min\n (\n N\n −\n 1\n ,\n i\n +\n n\n \n /\n \n 2\n )\n \n \n \n \n (\n \n a\n \n x\n ,\n y\n \n \n j\n \n \n )\n \n \n 2\n \n \n \n )\n \n \n β\n \n \n \n \n \n \n {\\displaystyle b_{x,y}^{i}={\\frac {a_{x,y}^{i}}{\\left(k+\\alpha \\sum _{j=\\max(0,i-n/2)}^{\\min(N-1,i+n/2)}\\left(a_{x,y}^{j}\\right)^{2}\\right)^{\\beta }}}}\n \n\nwhere \n \n \n \n \n a\n \n x\n ,\n y\n \n \n i\n \n \n \n \n {\\displaystyle a_{x,y}^{i}}\n \n is the activation of the neuron at location \n \n \n \n (\n x\n ,\n y\n )\n \n \n {\\displaystyle (x,y)}\n \n and channel \n \n \n \n i\n \n \n {\\displaystyle i}\n \n. I.e., each pixel in a channel is suppressed by the activations of the same pixel in its adjacent channels.\n\n \n \n \n k\n ,\n n\n ,\n α\n ,\n β\n \n \n {\\displaystyle k,n,\\alpha ,\\beta }\n \n are hyperparameters picked by using a validation set.\nIt was a variant of the earlier local contrast normalization.\n\n \n \n \n \n b\n \n x\n ,\n y\n \n \n i\n \n \n =\n \n \n \n a\n \n x\n ,\n y\n \n \n i\n \n \n \n \n (\n \n k\n +\n α\n \n ∑\n \n j\n =\n max\n (\n 0\n ,\n i\n −\n n\n \n /\n \n 2\n )\n \n \n min\n (\n N\n −\n 1\n ,\n i\n +\n n\n \n /\n \n 2\n )\n \n \n \n \n (\n \n \n a\n \n x\n ,\n y\n \n \n j\n \n \n −\n \n \n \n \n a\n ¯\n \n \n \n \n x\n ,\n y\n \n \n j\n \n \n \n )\n \n \n 2\n \n \n \n )\n \n \n β\n \n \n \n \n \n \n {\\displaystyle b_{x,y}^{i}={\\frac {a_{x,y}^{i}}{\\left(k+\\alpha \\sum _{j=\\max(0,i-n/2)}^{\\min(N-1,i+n/2)}\\left(a_{x,y}^{j}-{\\bar {a}}_{x,y}^{j}\\right)^{2}\\right)^{\\beta }}}}\n \n\nwhere \n \n \n \n \n \n \n \n a\n ¯\n \n \n \n \n x\n ,\n y\n \n \n j\n \n \n \n \n {\\displaystyle {\\bar {a}}_{x,y}^{j}}\n \n is the average activation in a small window centered on location \n \n \n \n (\n x\n ,\n y\n )\n \n \n {\\displaystyle (x,y)}\n \n and channel \n \n \n \n i\n \n \n {\\displaystyle i}\n \n. The hyperparameters \n \n \n \n k\n ,\n n\n ,\n α\n ,\n β\n \n \n {\\displaystyle k,n,\\alpha ,\\beta }\n \n, and the size of the small window, are picked by using a validation set.\nSimilar methods were called divisive normalization, as they divide activations by a number depending on the activations. They were originally inspired by biology, where it was used to explain nonlinear responses of cortical neurons and nonlinear masking in visual perception.\nBoth kinds of local normalization were obviated by batch normalization, which is a more global form of normalization.\nResponse normalization reappeared in ConvNeXT-2 as global response normalization.\n\n\nGroup normalization\nGroup normalization (GroupNorm) is a technique also solely used for CNNs. It can be understood as the LayerNorm for CNN applied once per channel group.\nSuppose at a layer \n \n \n \n l\n \n \n {\\displaystyle l}\n \n, there are channels \n \n \n \n 1\n ,\n 2\n ,\n …\n ,\n C\n \n \n {\\displaystyle 1,2,\\dots ,C}\n \n, then it is partitioned into groups \n \n \n \n \n g\n \n 1\n \n \n ,\n \n g\n \n 2\n \n \n ,\n …\n ,\n \n g\n \n G\n \n \n \n \n {\\displaystyle g_{1},g_{2},\\dots ,g_{G}}\n \n. Then, LayerNorm is applied to each group.\n\n\nInstance normalization\nInstance normalization (InstanceNorm), or contrast normalization, is a technique first developed for neural style transfer, and is also only used for CNNs. It can be understood as the LayerNorm for CNN applied once per channel, or equivalently, as group normalization where each group consists of a single channel:\n\n \n \n \n \n \n \n \n \n μ\n \n c\n \n \n (\n l\n )\n \n \n \n \n \n =\n \n \n 1\n \n H\n W\n \n \n \n \n ∑\n \n h\n =\n 1\n \n \n H\n \n \n \n ∑\n \n w\n =\n 1\n \n \n W\n \n \n \n x\n \n h\n ,\n w\n ,\n c\n \n \n (\n l\n )\n \n \n \n \n \n \n (\n \n σ\n \n c\n \n \n (\n l\n )\n \n \n \n )\n \n 2\n \n \n \n \n \n =\n \n \n 1\n \n H\n W\n \n \n \n \n ∑\n \n h\n =\n 1\n \n \n H\n \n \n \n ∑\n \n w\n =\n 1\n \n \n W\n \n \n (\n \n x\n \n h\n ,\n w\n ,\n c\n \n \n (\n l\n )\n \n \n −\n \n μ\n \n c\n \n \n (\n l\n )\n \n \n \n )\n \n 2\n \n \n \n \n \n \n \n \n \n \n x\n ^\n \n \n \n \n h\n ,\n w\n ,\n c\n \n \n (\n l\n )\n \n \n \n \n \n =\n \n \n \n \n \n \n \n x\n ^\n \n \n \n \n h\n ,\n w\n ,\n c\n \n \n (\n l\n )\n \n \n −\n \n μ\n \n c\n \n \n (\n l\n )\n \n \n \n \n (\n \n σ\n \n c\n \n \n (\n l\n )\n \n \n \n )\n \n 2\n \n \n +\n ϵ\n \n \n \n \n \n \n \n \n y\n \n h\n ,\n w\n ,\n c\n \n \n (\n l\n )\n \n \n \n \n \n =\n \n γ\n \n c\n \n \n (\n l\n )\n \n \n \n \n \n \n x\n ^\n \n \n \n \n h\n ,\n w\n ,\n c\n \n \n (\n l\n )\n \n \n +\n \n β\n \n c\n \n \n (\n l\n )\n \n \n \n \n \n \n \n \n {\\displaystyle {\\begin{aligned}\\mu _{c}^{(l)}&={\\frac {1}{HW}}\\sum _{h=1}^{H}\\sum _{w=1}^{W}x_{h,w,c}^{(l)}\\\\(\\sigma _{c}^{(l)})^{2}&={\\frac {1}{HW}}\\sum _{h=1}^{H}\\sum _{w=1}^{W}(x_{h,w,c}^{(l)}-\\mu _{c}^{(l)})^{2}\\\\{\\hat {x}}_{h,w,c}^{(l)}&={\\frac {{\\hat {x}}_{h,w,c}^{(l)}-\\mu _{c}^{(l)}}{\\sqrt {(\\sigma _{c}^{(l)})^{2}+\\epsilon }}}\\\\y_{h,w,c}^{(l)}&=\\gamma _{c}^{(l)}{\\hat {x}}_{h,w,c}^{(l)}+\\beta _{c}^{(l)}\\end{aligned}}}\n \n\n\nAdaptive instance normalization\nAdaptive instance normalization (AdaIN) is a variant of instance normalization, designed specifically for neural style transfer with CNNs, rather than just CNNs in general.\nIn the AdaIN method of style transfer, we take a CNN and two input images, one for content and one for style. Each image is processed through the same CNN, and at a certain layer \n \n \n \n l\n \n \n {\\displaystyle l}\n \n, AdaIn is applied.\nLet \n \n \n \n \n x\n \n (\n l\n )\n ,\n \n content\n \n \n \n \n \n {\\displaystyle x^{(l),{\\text{ content}}}}\n \n be the activation in the content image, and \n \n \n \n \n x\n \n (\n l\n )\n ,\n \n style\n \n \n \n \n \n {\\displaystyle x^{(l),{\\text{ style}}}}\n \n be the activation in the style image. Then, AdaIn first computes the mean and variance of the activations of the content image \n \n \n \n \n x\n \n ′\n \n (\n l\n )\n \n \n \n \n \n {\\displaystyle x'^{(l)}}\n \n, then uses those as the \n \n \n \n γ\n ,\n β\n \n \n {\\displaystyle \\gamma ,\\beta }\n \n for InstanceNorm on \n \n \n \n \n x\n \n (\n l\n )\n ,\n \n content\n \n \n \n \n \n {\\displaystyle x^{(l),{\\text{ content}}}}\n \n. Note that \n \n \n \n \n x\n \n (\n l\n )\n ,\n \n style\n \n \n \n \n \n {\\displaystyle x^{(l),{\\text{ style}}}}\n \n itself remains unchanged. Explicitly, we have:\n\n \n \n \n \n \n \n \n \n y\n \n h\n ,\n w\n ,\n c\n \n \n (\n l\n )\n ,\n \n content\n \n \n \n \n \n \n =\n \n σ\n \n c\n \n \n (\n l\n )\n ,\n \n style\n \n \n \n \n (\n \n \n \n \n x\n \n h\n ,\n w\n ,\n c\n \n \n (\n l\n )\n ,\n \n content\n \n \n \n −\n \n μ\n \n c\n \n \n (\n l\n )\n ,\n \n content\n \n \n \n \n \n (\n \n σ\n \n c\n \n \n (\n l\n )\n ,\n \n content\n \n \n \n \n )\n \n 2\n \n \n +\n ϵ\n \n \n \n )\n \n +\n \n μ\n \n c\n \n \n (\n l\n )\n ,\n \n style\n \n \n \n \n \n \n \n \n \n {\\displaystyle {\\begin{aligned}y_{h,w,c}^{(l),{\\text{ content}}}&=\\sigma _{c}^{(l),{\\text{ style}}}\\left({\\frac {x_{h,w,c}^{(l),{\\text{ content}}}-\\mu _{c}^{(l),{\\text{ content}}}}{\\sqrt {(\\sigma _{c}^{(l),{\\text{ content}}})^{2}+\\epsilon }}}\\right)+\\mu _{c}^{(l),{\\text{ style}}}\\end{aligned}}}\n \n\n\nTransformers\nSome normalization methods were designed for use in transformers.\nThe original 2017 transformer used the \"post-LN\" configuration for its LayerNorms. It was difficult to train, and required careful hyperparameter tuning and a \"warm-up\" in learning rate, where it starts small and gradually increases. The pre-LN convention, proposed several times in 2018, was found to be easier to train, requiring no warm-up, leading to faster convergence.\nFixNorm and ScaleNorm both normalize activation vectors in a transformer. The FixNorm method divides the output vectors from a transformer by their L2 norms, then multiplies by a learned parameter \n \n \n \n g\n \n \n {\\displaystyle g}\n \n. The ScaleNorm replaces all LayerNorms inside a transformer by division with L2 norm, then multiplying by a learned parameter \n \n \n \n \n g\n ′\n \n \n \n {\\displaystyle g'}\n \n (shared by all ScaleNorm modules of a transformer). Query-Key normalization (QKNorm) normalizes query and key vectors to have unit L2 norm.\nIn nGPT, many vectors are normalized to have unit L2 norm: hidden state vectors, input and output embedding vectors, weight matrix columns, and query and key vectors.\n\n\nMiscellaneous\nGradient normalization (GradNorm) normalizes gradient vectors during backpropagation.\n\n\nSee also\nData preprocessing\nFeature scaling\n\n\nReferences\n\n\nFurther reading\n\"Normalization Layers\". labml.ai Deep Learning Paper Implementations. Retrieved 2024-08-07.", "categories": ["Articles with example Python (programming language) code", "Articles with short description", "CS1 errors: missing periodical", "Deep learning", "Machine learning", "Neural networks", "Short description matches Wikidata", "Statistical data transformation"], "references": ["https://link.springer.com/10.1007/978-3-031-14595-7", "https://doi.org/10.1007%2F978-3-031-14595-7", "https://doi.org/10.1109%2FTNNLS.2020.3026784", "https://proceedings.mlr.press/v37/ioffe15.html", "https://proceedings.neurips.cc/paper/2019/hash/2f4fe03d77724a7217006e5d16728874-Abstract.html", "https://proceedings.neurips.cc/paper/2018/hash/36072923bfc3cf47745d704feb489480-Abstract.html", "https://proceedings.neurips.cc/paper/2018/hash/905056c1ac1dad141560467e0a99e1cf-Abstract.html", "https://arxiv.org/abs/1607.06450", "https://nn.labml.ai/normalization/index.html", "https://arxiv.org/abs/1502.03167", "https://arxiv.org/abs/1911.07013", "https://arxiv.org/abs/1806.02375", "https://pubmed.ncbi.nlm.nih.gov/33095717", "https://proceedings.neurips.cc/paper_files/paper/2015/hash/2de5d16682c3c35007e4e92982f1a2ba-Abstract.html", "https://openaccess.thecvf.com/content_iccv_2017/html/Huang_Arbitrary_Style_Transfer_ICCV_2017_paper.html"], "images": [], "sub_niche": "International Conference on Machine Learning"} {"title": "Boosting (machine learning)", "url": "https://en.wikipedia.org/wiki/Boosting_(machine_learning)", "summary": "In machine learning (ML), boosting is an ensemble learning method that combines a set of less accurate models (called \"weak learners\") to create a single, highly accurate model (a \"strong learner\"). Unlike other ensemble methods that build models in parallel (such as bagging), boosting algorithms build models sequentially. Each new model in the sequence is trained to correct the errors made by its predecessors. This iterative process allows the overall model to improve its accuracy, particularly by reducing bias. Boosting is a popular and effective technique used in supervised learning for both classification and regression tasks.\nThe theoretical foundation for boosting came from a question posed by Kearns and Valiant (1988, 1989): \"Can a set of weak learners create a single strong learner", "content": "In machine learning (ML), boosting is an ensemble learning method that combines a set of less accurate models (called \"weak learners\") to create a single, highly accurate model (a \"strong learner\"). Unlike other ensemble methods that build models in parallel (such as bagging), boosting algorithms build models sequentially. Each new model in the sequence is trained to correct the errors made by its predecessors. This iterative process allows the overall model to improve its accuracy, particularly by reducing bias. Boosting is a popular and effective technique used in supervised learning for both classification and regression tasks.\nThe theoretical foundation for boosting came from a question posed by Kearns and Valiant (1988, 1989): \"Can a set of weak learners create a single strong learner?\" A weak learner is defined as a classifier that performs only slightly better than random guessing, whereas a strong learner is a classifier that is highly correlated with the true classification. Robert Schapire's affirmative answer to this question in a 1990 paper led to the development of practical boosting algorithms. The first such algorithm was developed by Schapire, with Freund and Schapire later developing AdaBoost, which remains a foundational example of boosting.\n\n\nAlgorithms\nWhile boosting is not algorithmically constrained, most boosting algorithms consist of iteratively learning weak classifiers with respect to a distribution and adding them to a final strong classifier. When they are added, they are weighted in a way that is related to the weak learners' accuracy. After a weak learner is added, the data weights are readjusted, known as \"re-weighting\". Misclassified input data gain a higher weight and examples that are classified correctly lose weight. Thus, future weak learners focus more on the examples that previous weak learners misclassified.\n\nThere are many boosting algorithms. The original ones, proposed by Robert Schapire (a recursive majority gate formulation), and Yoav Freund (boost by majority), were not adaptive and could not take full advantage of the weak learners. Schapire and Freund then developed AdaBoost, an adaptive boosting algorithm that won the prestigious Gödel Prize.\nOnly algorithms that are provable boosting algorithms in the probably approximately correct learning formulation can accurately be called boosting algorithms. Other algorithms that are similar in spirit to boosting algorithms are sometimes called \"leveraging algorithms\", although they are also sometimes incorrectly called boosting algorithms.\nThe main variation between many boosting algorithms is their method of weighting training data points and hypotheses. AdaBoost is very popular and the most significant historically as it was the first algorithm that could adapt to the weak learners. It is often the basis of introductory coverage of boosting in university machine learning courses. There are many more recent algorithms such as LPBoost, TotalBoost, BrownBoost, xgboost, MadaBoost, LogitBoost, CatBoost and others. Many boosting algorithms fit into the AnyBoost framework, which shows that boosting performs gradient descent in a function space using a convex cost function.\n\n\nObject categorization in computer vision\n\nGiven images containing various known objects in the world, a classifier can be learned from them to automatically classify the objects in future images. Simple classifiers built based on some image feature of the object tend to be weak in categorization performance. Using boosting methods for object categorization is a way to unify the weak classifiers in a special way to boost the overall ability of categorization.\n\n\nProblem of object categorization\nObject categorization is a typical task of computer vision that involves determining whether or not an image contains some specific category of object. The idea is closely related with recognition, identification, and detection. Appearance based object categorization typically contains feature extraction, learning a classifier, and applying the classifier to new examples. There are many ways to represent a category of objects, e.g. from shape analysis, bag of words models, or local descriptors such as SIFT, etc. Examples of supervised classifiers are Naive Bayes classifiers, support vector machines, mixtures of Gaussians, and neural networks. However, research has shown that object categories and their locations in images can be discovered in an unsupervised manner as well.\n\n\nStatus quo for object categorization\nThe recognition of object categories in images is a challenging problem in computer vision, especially when the number of categories is large. This is due to high intra class variability and the need for generalization across variations of objects within the same category. Objects within one category may look quite different. Even the same object may appear unalike under different viewpoint, scale, and illumination. Background clutter and partial occlusion add difficulties to recognition as well. Humans are able to recognize thousands of object types, whereas most of the existing object recognition systems are trained to recognize only a few, e.g. human faces, cars, simple objects, etc. Research has been very active on dealing with more categories and enabling incremental additions of new categories, and although the general problem remains unsolved, several multi-category objects detectors (for up to hundreds or thousands of categories) have been developed. One means is by feature sharing and boosting.\n\n\nBoosting for binary categorization\nAdaBoost can be used for face detection as an example of binary categorization. The two categories are faces versus background. The general algorithm is as follows:\n\nForm a large set of simple features\nInitialize weights for training images\nFor T rounds\nNormalize the weights\nFor available features from the set, train a classifier using a single feature and evaluate the training error\nChoose the classifier with the lowest error\nUpdate the weights of the training images: increase if classified wrongly by this classifier, decrease if correctly\nForm the final strong classifier as the linear combination of the T classifiers (coefficient larger if training error is small)\nAfter boosting, a classifier constructed from 200 features could yield a 95% detection rate under a \n \n \n \n \n 10\n \n −\n 5\n \n \n \n \n {\\displaystyle 10^{-5}}\n \n false positive rate.\nAnother application of boosting for binary categorization is a system that detects pedestrians using patterns of motion and appearance. This work is the first to combine both motion information and appearance information as features to detect a walking person. It takes a similar approach to the Viola-Jones object detection framework.\n\n\nBoosting for multi-class categorization\nCompared with binary categorization, multi-class categorization looks for common features that can be shared across the categories at the same time. They turn to be more generic edge like features. During learning, the detectors for each category can be trained jointly. Compared with training separately, it generalizes better, needs less training data, and requires fewer features to achieve the same performance.\nThe main flow of the algorithm is similar to the binary case. What is different is that a measure of the joint training error shall be defined in advance. During each iteration the algorithm chooses a classifier of a single feature (features that can be shared by more categories shall be encouraged). This can be done via converting multi-class classification into a binary one (a set of categories versus the rest), or by introducing a penalty error from the categories that do not have the feature of the classifier.\nIn the paper \"Sharing visual features for multiclass and multiview object detection\", A. Torralba et al. used GentleBoost for boosting and showed that when training data is limited, learning via sharing features does a much better job than no sharing, given same boosting rounds. Also, for a given performance level, the total number of features required (and therefore the run time cost of the classifier) for the feature sharing detectors, is observed to scale approximately logarithmically with the number of class, i.e., slower than linear growth in the non-sharing case. Similar results are shown in the paper \"Incremental learning of object detectors using a visual shape alphabet\", yet the authors used AdaBoost for boosting.\n\n\nConvex vs. non-convex boosting algorithms\nBoosting algorithms can be based on convex or non-convex optimization algorithms. Convex algorithms, such as AdaBoost and LogitBoost, can be \"defeated\" by random noise such that they can't learn basic and learnable combinations of weak hypotheses. This limitation was pointed out by Long & Servedio in 2008. However, by 2009, multiple authors demonstrated that boosting algorithms based on non-convex optimization, such as BrownBoost, can learn from noisy datasets and can specifically learn the underlying classifier of the Long–Servedio dataset.\n\n\nSee also\n\n\nImplementations\nscikit-learn, an open source machine learning library for Python\nOrange, a free data mining software suite, module Orange.ensemble\nWeka is a machine learning set of tools that offers variate implementations of boosting algorithms like AdaBoost and LogitBoost\nR package GBM (Generalized Boosted Regression Models) implements extensions to Freund and Schapire's AdaBoost algorithm and Friedman's gradient boosting machine.\njboost; AdaBoost, LogitBoost, RobustBoost, Boostexter and alternating decision trees\nR package adabag: Applies Multiclass AdaBoost.M1, AdaBoost-SAMME and Bagging\nR package xgboost: An implementation of gradient boosting for linear and tree-based models.\n\n\nNotes\n\n\nReferences\n\n\nFurther reading\nFreund, Yoav; Schapire, Robert E. (1997). \"A Decision-Theoretic Generalization of On-line Learning and an Application to Boosting\" (PDF). Journal of Computer and System Sciences. 55 (1): 119–139. doi:10.1006/jcss.1997.1504.\nSchapire, Robert E. (1990). \"The strength of weak learnability\". Machine Learning. 5 (2): 197–227. doi:10.1007/BF00116037. S2CID 6207294.{{cite journal}}: CS1 maint: miscellaneous url (link)\nSchapire, Robert E.; Singer, Yoram (1999). \"Improved Boosting Algorithms Using Confidence-Rated Predictors\". Machine Learning. 37 (3): 297–336. doi:10.1023/A:1007614523901. S2CID 2329907.{{cite journal}}: CS1 maint: miscellaneous url (link)\nZhou, Zhihua (2008). \"On the margin explanation of boosting algorithm\" (PDF). In: Proceedings of the 21st Annual Conference on Learning Theory (COLT'08): 479–490.\nZhou, Zhihua (2013). \"On the doubt about margin explanation of boosting\" (PDF). Artificial Intelligence. 203: 1–18. arXiv:1009.3613. doi:10.1016/j.artint.2013.07.002. S2CID 2828847.\n\n\nExternal links\nRobert E. Schapire (2003); The Boosting Approach to Machine Learning: An Overview, MSRI (Mathematical Sciences Research Institute) Workshop on Nonlinear Estimation and Classification\nBoosting: Foundations and Algorithms by Robert E. Schapire and Yoav Freund", "categories": ["All articles containing potentially dated statements", "All articles that are too technical", "All articles with specifically marked weasel-worded phrases", "All articles with unsourced statements", "Articles containing potentially dated statements from October 2018", "Articles with short description", "Articles with specifically marked weasel-worded phrases from October 2018", "Articles with unsourced statements from January 2024", "Articles with unsourced statements from October 2018", "CS1 maint: miscellaneous url", "Classification algorithms", "Ensemble learning", "Learning in computer vision", "Object recognition and categorization", "Short description is different from Wikidata", "Wikipedia articles needing clarification from October 2018", "Wikipedia articles that are too technical from September 2023"], "references": ["http://citeseer.ist.psu.edu/schapire99improved.html", "http://www.cis.upenn.edu/~mkearns/papers/boostnote.pdf", "http://www.cs.princeton.edu/~schapire/papers/strengthofweak.pdf", "http://docs.orange.biolab.si/reference/rst/Orange.ensemble.html", "http://oz.berkeley.edu/~breiman/arcall96.pdf", "https://cran.r-project.org/web/packages/gbm/index.html", "https://cran.r-project.org/web/packages/adabag/index.html", "https://web.archive.org/web/20150119081741/http://oz.berkeley.edu/~breiman/arcall96.pdf", "https://cran.r-project.org/web/packages/xgboost/index.html", "https://www.cis.upenn.edu/~mkearns/teaching/COLT/adaboost.pdf", "https://www.cse.ucsd.edu/~yfreund/papers/adaboost.pdf", "http://www.merl.com/publications/docs/TR2003-90.pdf", "https://sourceforge.net/projects/jboost/", "http://math.mit.edu/~rothvoss/18.304.3PM/Presentations/1-Eric-Boosting304FinalRpdf.pdf", "https://web.archive.org/web/20121010030839/http://www.cs.princeton.edu/~schapire/papers/strengthofweak.pdf"], "images": [], "sub_niche": "International Conference on Machine Learning"} {"title": "Transfer learning", "url": "https://en.wikipedia.org/wiki/Transfer_learning", "summary": "Transfer learning (TL) is a technique in machine learning (ML) in which knowledge learned from a task is re-used in order to boost performance on a related task. For example, for image classification, knowledge gained while learning to recognize cars could be applied when trying to recognize trucks. This topic is related to the psychological literature on transfer of learning, although practical ties between the two fields are limited. Reusing or transferring information from previously learned tasks to new tasks has the potential to significantly improve learning efficiency.\nSince transfer learning makes use of training with multiple objective functions it is related to cost-sensitive machine learning and multi-objective optimization.", "content": "Transfer learning (TL) is a technique in machine learning (ML) in which knowledge learned from a task is re-used in order to boost performance on a related task. For example, for image classification, knowledge gained while learning to recognize cars could be applied when trying to recognize trucks. This topic is related to the psychological literature on transfer of learning, although practical ties between the two fields are limited. Reusing or transferring information from previously learned tasks to new tasks has the potential to significantly improve learning efficiency.\nSince transfer learning makes use of training with multiple objective functions it is related to cost-sensitive machine learning and multi-objective optimization.\n\n\nHistory\nIn 1976, Bozinovski and Fulgosi published a paper addressing transfer learning in neural network training. The paper gives a mathematical and geometrical model of the topic. In 1981, a report considered the application of transfer learning to a dataset of images representing letters of computer terminals, experimentally demonstrating positive and negative transfer learning.\nIn 1992, Lorien Pratt formulated the discriminability-based transfer (DBT) algorithm.\nBy 1998, the field had advanced to include multi-task learning, along with more formal theoretical foundations. Influential publications on transfer learning include the book Learning to Learn in 1998, a 2009 survey and a 2019 survey.\nNg said in his NIPS 2016 tutorial that TL would become the next driver of machine learning commercial success after supervised learning.\nIn the 2020 paper, \"Rethinking Pre-Training and self-training\", Zoph et al. reported that pre-training can hurt accuracy, and advocate self-training instead.\n\n\nDefinition\nThe definition of transfer learning is given in terms of domains and tasks. A domain \n \n \n \n \n \n D\n \n \n \n \n {\\displaystyle {\\mathcal {D}}}\n \n consists of: a feature space \n \n \n \n \n \n X\n \n \n \n \n {\\displaystyle {\\mathcal {X}}}\n \n and a marginal probability distribution \n \n \n \n P\n (\n X\n )\n \n \n {\\displaystyle P(X)}\n \n, where \n \n \n \n X\n =\n {\n \n x\n \n 1\n \n \n ,\n .\n .\n .\n ,\n \n x\n \n n\n \n \n }\n ∈\n \n \n X\n \n \n \n \n {\\displaystyle X=\\{x_{1},...,x_{n}\\}\\in {\\mathcal {X}}}\n \n. Given a specific domain, \n \n \n \n \n \n D\n \n \n =\n {\n \n \n X\n \n \n ,\n P\n (\n X\n )\n }\n \n \n {\\displaystyle {\\mathcal {D}}=\\{{\\mathcal {X}},P(X)\\}}\n \n, a task consists of two components: a label space \n \n \n \n \n \n Y\n \n \n \n \n {\\displaystyle {\\mathcal {Y}}}\n \n and an objective predictive function \n \n \n \n f\n :\n \n \n X\n \n \n →\n \n \n Y\n \n \n \n \n {\\displaystyle f:{\\mathcal {X}}\\rightarrow {\\mathcal {Y}}}\n \n. The function \n \n \n \n f\n \n \n {\\displaystyle f}\n \n is used to predict the corresponding label \n \n \n \n f\n (\n x\n )\n \n \n {\\displaystyle f(x)}\n \n of a new instance \n \n \n \n x\n \n \n {\\displaystyle x}\n \n. This task, denoted by \n \n \n \n \n \n T\n \n \n =\n {\n \n \n Y\n \n \n ,\n f\n (\n x\n )\n }\n \n \n {\\displaystyle {\\mathcal {T}}=\\{{\\mathcal {Y}},f(x)\\}}\n \n, is learned from the training data consisting of pairs \n \n \n \n {\n \n x\n \n i\n \n \n ,\n \n y\n \n i\n \n \n }\n \n \n {\\displaystyle \\{x_{i},y_{i}\\}}\n \n, where \n \n \n \n \n x\n \n i\n \n \n ∈\n \n \n X\n \n \n \n \n {\\displaystyle x_{i}\\in {\\mathcal {X}}}\n \n and \n \n \n \n \n y\n \n i\n \n \n ∈\n \n \n Y\n \n \n \n \n {\\displaystyle y_{i}\\in {\\mathcal {Y}}}\n \n.\nGiven a source domain \n \n \n \n \n \n \n D\n \n \n \n S\n \n \n \n \n {\\displaystyle {\\mathcal {D}}_{S}}\n \n and learning task \n \n \n \n \n \n \n T\n \n \n \n S\n \n \n \n \n {\\displaystyle {\\mathcal {T}}_{S}}\n \n, a target domain \n \n \n \n \n \n \n D\n \n \n \n T\n \n \n \n \n {\\displaystyle {\\mathcal {D}}_{T}}\n \n and learning task \n \n \n \n \n \n \n T\n \n \n \n T\n \n \n \n \n {\\displaystyle {\\mathcal {T}}_{T}}\n \n, where \n \n \n \n \n \n \n D\n \n \n \n S\n \n \n ≠\n \n \n \n D\n \n \n \n T\n \n \n \n \n {\\displaystyle {\\mathcal {D}}_{S}\\neq {\\mathcal {D}}_{T}}\n \n, or \n \n \n \n \n \n \n T\n \n \n \n S\n \n \n ≠\n \n \n \n T\n \n \n \n T\n \n \n \n \n {\\displaystyle {\\mathcal {T}}_{S}\\neq {\\mathcal {T}}_{T}}\n \n, transfer learning aims to help improve the learning of the target predictive function \n \n \n \n \n f\n \n T\n \n \n (\n ⋅\n )\n \n \n {\\displaystyle f_{T}(\\cdot )}\n \n in \n \n \n \n \n \n \n D\n \n \n \n T\n \n \n \n \n {\\displaystyle {\\mathcal {D}}_{T}}\n \n using the knowledge in \n \n \n \n \n \n \n D\n \n \n \n S\n \n \n \n \n {\\displaystyle {\\mathcal {D}}_{S}}\n \n and \n \n \n \n \n \n \n T\n \n \n \n S\n \n \n \n \n {\\displaystyle {\\mathcal {T}}_{S}}\n \n.\n\n\nApplications\nAlgorithms for transfer learning are available in Markov logic networks and Bayesian networks. Transfer learning has been applied to cancer subtype discovery, building utilization, general game playing, text classification, digit recognition, medical imaging and spam filtering.\nIn 2020, it was discovered that, due to their similar physical natures, transfer learning is possible between electromyographic (EMG) signals from the muscles and classifying the behaviors of electroencephalographic (EEG) brainwaves, from the gesture recognition domain to the mental state recognition domain. It was noted that this relationship worked in both directions, showing that EEG brainwaves can likewise be used to classify EMG signals. The experiments noted that the accuracy of neural networks and convolutional neural networks were improved through transfer learning both prior to any learning (compared to standard random weight distribution) and at the end of the learning process (asymptote). That is, results are improved by exposure to another domain. Moreover, the end-user of a pre-trained model can change the structure of fully-connected layers to improve performance.\n\n\nSee also\nCrossover (genetic algorithm)\nDomain adaptation\nGeneral game playing\nMulti-task learning\nMultitask optimization\nTransfer of learning\nZero-shot learning\nFew-shot learning\nFeature learning\nexternal validity\n\n\nReferences\n\n\nSources\nThrun, Sebastian; Pratt, Lorien (6 December 2012). Learning to Learn. Springer Science & Business Media. ISBN 978-1-4615-5529-2.", "categories": ["Articles with short description", "CS1 maint: location missing publisher", "Machine learning", "Short description is different from Wikidata"], "references": ["http://cpms.byu.edu/springresearch/abstract-entry?id=861", "http://www.cs.utexas.edu/users/ml/papers/mihalkova-aaai07.pdf", "http://www.stat.umn.edu/~aistat/proceedings/data/papers/043.pdf", "http://papers.nips.cc/paper/2843-transfer-learning-for-text-classification.pdf", "http://www.ecmlpkdd2006.org/discovery_challenge2006_overview.pdf", "https://books.google.com/books?id=6tGHlwEACAAJ&pg=PA204", "https://books.google.com/books?id=X_jpBwAAQBAJ", "https://web.archive.org/web/20070801120743/http://cpms.byu.edu/springresearch/abstract-entry?id=861", "https://dl.acm.org/citation.cfm?id=3137146", "http://www.aaai.org/Papers/IJCAI/2007/IJCAI07-107.pdf", "https://ai.stanford.edu/~ang/papers/icml06-transferinformativepriors.pdf", "https://www.youtube.com/watch?v=wjqaz6m42wU", "https://media.nips.cc/Conferences/2016/Slides/6203-Slides.pdf", "https://api.semanticscholar.org/CorpusID:53774629", "https://api.semanticscholar.org/CorpusID:54066723"], "images": [], "sub_niche": "International Conference on Machine Learning"} {"title": "Tensor (machine learning)", "url": "https://en.wikipedia.org/wiki/Tensor_(machine_learning)", "summary": "In machine learning, the term tensor informally refers to two different concepts: (i) a way of organizing data and (ii) a multilinear (tensor) transformation. Data may be organized in a multidimensional array (M-way array), informally referred to as a \"data tensor\"; however, in the strict mathematical sense, a tensor is a multilinear mapping over a set of domain vector spaces to a range vector space. Observations, such as images, movies, volumes, sounds, and relationships among words and concepts, stored in an M-way array (\"data tensor\"), may be analyzed either by artificial neural networks or tensor methods.\nTensor decomposition factors data tensors into smaller tensors. Operations on data tensors can be expressed in terms of matrix multiplication and the Kronecker product. The computati", "content": "In machine learning, the term tensor informally refers to two different concepts: (i) a way of organizing data and (ii) a multilinear (tensor) transformation. Data may be organized in a multidimensional array (M-way array), informally referred to as a \"data tensor\"; however, in the strict mathematical sense, a tensor is a multilinear mapping over a set of domain vector spaces to a range vector space. Observations, such as images, movies, volumes, sounds, and relationships among words and concepts, stored in an M-way array (\"data tensor\"), may be analyzed either by artificial neural networks or tensor methods.\nTensor decomposition factors data tensors into smaller tensors. Operations on data tensors can be expressed in terms of matrix multiplication and the Kronecker product. The computation of gradients, a crucial aspect of backpropagation, can be performed using software libraries such as PyTorch and TensorFlow.\nComputations are often performed on graphics processing units (GPUs) using CUDA, and on dedicated hardware such as Google's Tensor Processing Unit or Nvidia's Tensor core. These developments have greatly accelerated neural network architectures, and increased the size and complexity of models that can be trained.\n\n\nHistory\nA tensor is by definition a multilinear map. In mathematics, this may express a multilinear relationship between sets of algebraic objects. In physics, tensor fields, considered as tensors at each point in space, are useful in expressing mechanics such as stress or elasticity. In machine learning, the exact use of tensors depends on the statistical approach being used.\nIn 2001, the field of signal processing and statistics were making use of tensor methods. Pierre Comon surveys the early adoption of tensor methods in the fields of telecommunications, radio surveillance, chemometrics and sensor processing. Linear tensor rank methods (such as, Parafac/CANDECOMP) analyzed M-way arrays (\"data tensors\") composed of higher order statistics that were employed in blind source separation problems to compute a linear model of the data. He noted several early limitations in determining the tensor rank and efficient tensor rank decomposition.\nIn the early 2000s, multilinear tensor methods crossed over into computer vision, computer graphics and machine learning with papers by Vasilescu or in collaboration with Terzopoulos, such as Human Motion Signatures, TensorFaces TensorTextures and Multilinear Projection. Multilinear algebra, the algebra of higher-order tensors, is a suitable and transparent framework for analyzing the multifactor structure of an ensemble of observations and for addressing the difficult problem of disentangling the causal factors based on second order or higher order statistics associated with each causal factor. \nTensor (multilinear) factor analysis disentangles and reduces the influence of different causal factors with multilinear subspace learning. \nWhen treating an image or a video as a 2- or 3-way array, i.e., \"data matrix/tensor\", tensor methods reduce spatial or time redundancies as demonstrated by Wang and Ahuja.\nYoshua Bengio,\nGeoff Hinton\n and their collaborators briefly discuss the relationship between deep neural networks and tensor factor analysis beyond the use of M-way arrays (\"data tensors\") as inputs. One of the early uses of tensors for neural networks appeared in natural language processing. A single word can be expressed as a vector via Word2vec. Thus a relationship between two words can be encoded in a matrix. However, for more complex relationships such as subject-object-verb, it is necessary to build higher-dimensional networks. In 2009, the work of Sutskever introduced Bayesian Clustered Tensor Factorization to model relational concepts while reducing the parameter space. From 2014 to 2015, tensor methods become more common in convolutional neural networks (CNNs). Tensor methods organize neural network weights in a \"data tensor\", analyze and reduce the number of neural network weights. Lebedev et al. accelerated CNN networks for character classification (the recognition of letters and digits in images) by using 4D kernel tensors.\n\n\nDefinition\nLet \n \n \n \n \n F\n \n \n \n {\\displaystyle \\mathbb {F} }\n \n be a field (such as the real numbers \n \n \n \n \n R\n \n \n \n {\\displaystyle \\mathbb {R} }\n \n or the complex numbers \n \n \n \n \n C\n \n \n \n {\\displaystyle \\mathbb {C} }\n \n). A tensor \n \n \n \n \n \n T\n \n \n ∈\n \n \n \n F\n \n \n \n \n I\n \n 1\n \n \n ×\n \n I\n \n 2\n \n \n ×\n …\n ×\n \n I\n \n C\n \n \n \n \n \n \n {\\displaystyle {\\mathcal {T}}\\in {\\mathbb {F} }^{I_{1}\\times I_{2}\\times \\ldots \\times I_{C}}}\n \n is a multilinear transformation from a set of domain vector spaces to a range vector space:\n\n \n \n \n \n \n T\n \n \n :\n {\n \n \n \n F\n \n \n \n \n I\n \n 1\n \n \n \n \n ×\n \n \n \n F\n \n \n \n \n I\n \n 2\n \n \n \n \n ×\n …\n \n \n \n F\n \n \n \n \n I\n \n C\n \n \n \n \n }\n ↦\n \n \n \n F\n \n \n \n \n I\n \n 0\n \n \n \n \n \n \n {\\displaystyle {\\mathcal {T}}:\\{{\\mathbb {F} }^{I_{1}}\\times {\\mathbb {F} }^{I_{2}}\\times \\ldots {\\mathbb {F} }^{I_{C}}\\}\\mapsto {\\mathbb {F} }^{I_{0}}}\n \n\nHere, \n \n \n \n C\n \n \n {\\displaystyle C}\n \n and \n \n \n \n \n I\n \n 0\n \n \n ,\n \n I\n \n 1\n \n \n ,\n …\n ,\n \n I\n \n C\n \n \n \n \n {\\displaystyle I_{0},I_{1},\\ldots ,I_{C}}\n \n are positive integers, and \n \n \n \n (\n C\n +\n 1\n )\n \n \n {\\displaystyle (C+1)}\n \n is the number of modes of a tensor (also known as the number of ways of a multi-way array). The dimensionality of mode \n \n \n \n c\n \n \n {\\displaystyle c}\n \n is \n \n \n \n \n I\n \n c\n \n \n \n \n {\\displaystyle I_{c}}\n \n, for \n \n \n \n 0\n ≤\n c\n ≤\n C\n \n \n {\\displaystyle 0\\leq c\\leq C}\n \n .\nIn statistics and machine learning, an image is vectorized when viewed as a single observation, and a collection of vectorized images is organized as a \"data tensor\". For example, a set of facial images \n \n \n \n {\n \n \n \n d\n \n \n \n \n i\n \n p\n \n \n ,\n \n i\n \n e\n \n \n ,\n \n i\n \n l\n \n \n ,\n \n i\n \n v\n \n \n \n \n ∈\n \n \n \n R\n \n \n \n \n I\n \n X\n \n \n \n \n }\n \n \n {\\displaystyle \\{{\\mathbb {d} }_{i_{p},i_{e},i_{l},i_{v}}\\in {\\mathbb {R} }^{I_{X}}\\}}\n \n with \n \n \n \n \n I\n \n X\n \n \n \n \n {\\displaystyle I_{X}}\n \n pixels that are the consequences of multiple causal factors, such as a facial geometry \n \n \n \n \n i\n \n p\n \n \n (\n 1\n ≤\n \n i\n \n p\n \n \n ≤\n \n I\n \n P\n \n \n )\n \n \n {\\displaystyle i_{p}(1\\leq i_{p}\\leq I_{P})}\n \n, an expression \n \n \n \n \n i\n \n e\n \n \n (\n 1\n ≤\n \n i\n \n e\n \n \n ≤\n \n I\n \n E\n \n \n )\n \n \n {\\displaystyle i_{e}(1\\leq i_{e}\\leq I_{E})}\n \n, an illumination condition \n \n \n \n \n i\n \n l\n \n \n (\n 1\n ≤\n \n i\n \n l\n \n \n ≤\n \n I\n \n L\n \n \n )\n \n \n {\\displaystyle i_{l}(1\\leq i_{l}\\leq I_{L})}\n \n, and a viewing condition \n \n \n \n \n i\n \n v\n \n \n (\n 1\n ≤\n \n i\n \n v\n \n \n ≤\n \n I\n \n V\n \n \n )\n \n \n {\\displaystyle i_{v}(1\\leq i_{v}\\leq I_{V})}\n \n may be organized into a data tensor (ie. multiway array) \n \n \n \n \n \n D\n \n \n ∈\n \n \n \n R\n \n \n \n \n I\n \n X\n \n \n ×\n \n I\n \n P\n \n \n ×\n \n I\n \n E\n \n \n ×\n \n I\n \n L\n \n \n ×\n V\n \n \n \n \n {\\displaystyle {\\mathcal {D}}\\in {\\mathbb {R} }^{I_{X}\\times I_{P}\\times I_{E}\\times I_{L}\\times V}}\n \n where \n \n \n \n \n I\n \n P\n \n \n \n \n {\\displaystyle I_{P}}\n \n are the total number of facial geometries, \n \n \n \n \n I\n \n E\n \n \n \n \n {\\displaystyle I_{E}}\n \n are the total number of expressions, \n \n \n \n \n I\n \n L\n \n \n \n \n {\\displaystyle I_{L}}\n \n are the total number of illumination conditions, and \n \n \n \n \n I\n \n V\n \n \n \n \n {\\displaystyle I_{V}}\n \n are the total number of viewing conditions. Tensor factorizations methods such as TensorFaces and multilinear (tensor) independent component analysis factorizes the data tensor into a set of vector spaces that span the causal factor representations, where an image is the result of tensor transformation \n \n \n \n \n \n T\n \n \n \n \n {\\displaystyle {\\mathcal {T}}}\n \n that maps a set of causal factor representations to the pixel space. \nAnother approach to using tensors in machine learning is to embed various data types directly. For example, a grayscale image, commonly represented as a discrete 2-way array \n \n \n \n \n \n D\n \n \n ∈\n \n \n \n R\n \n \n \n \n I\n \n R\n X\n \n \n ×\n \n I\n \n C\n X\n \n \n \n \n \n \n {\\displaystyle {\\mathbf {D} }\\in {\\mathbb {R} }^{I_{RX}\\times I_{CX}}}\n \n with dimensionality \n \n \n \n \n I\n \n R\n X\n \n \n ×\n \n I\n \n C\n X\n \n \n \n \n {\\displaystyle I_{RX}\\times I_{CX}}\n \n where \n \n \n \n \n I\n \n R\n X\n \n \n \n \n {\\displaystyle I_{RX}}\n \n are the number of rows and \n \n \n \n \n I\n \n C\n X\n \n \n \n \n {\\displaystyle I_{CX}}\n \n are the number of columns. When an image is treated as 2-way array or 2nd order tensor (i.e. as a collection of column/row observations), tensor factorization methods compute the image column space, the image row space and the normalized PCA coefficients or the ICA coefficients. \nSimilarly, a color image with RGB channels, \n \n \n \n \n \n D\n \n \n ∈\n \n \n R\n \n \n N\n ×\n M\n ×\n 3\n \n \n .\n \n \n {\\displaystyle {\\mathcal {D}}\\in \\mathbb {R} ^{N\\times M\\times 3}.}\n \n may be viewed as a 3rd order data tensor or 3-way array.\nIn natural language processing, a word might be expressed as a vector \n \n \n \n v\n \n \n {\\displaystyle v}\n \n via the Word2vec algorithm. Thus \n \n \n \n v\n \n \n {\\displaystyle v}\n \n becomes a mode-1 tensor\n\n \n \n \n v\n ↦\n \n \n A\n \n \n ∈\n \n \n R\n \n \n N\n \n \n .\n \n \n {\\displaystyle v\\mapsto {\\mathcal {A}}\\in \\mathbb {R} ^{N}.}\n \n\nThe embedding of subject-object-verb semantics requires embedding relationships among three words. Because a word is itself a vector, subject-object-verb semantics could be expressed using mode-3 tensors\n\n \n \n \n \n v\n \n a\n \n \n ×\n \n v\n \n b\n \n \n ×\n \n v\n \n c\n \n \n ↦\n \n \n A\n \n \n ∈\n \n \n R\n \n \n N\n ×\n N\n ×\n N\n \n \n .\n \n \n {\\displaystyle v_{a}\\times v_{b}\\times v_{c}\\mapsto {\\mathcal {A}}\\in \\mathbb {R} ^{N\\times N\\times N}.}\n \n\nIn practice the neural network designer is primarily concerned with the specification of embeddings, the connection of tensor layers, and the operations performed on them in a network. Modern machine learning frameworks manage the optimization, tensor factorization and backpropagation automatically.\n\n\nAs unit values\n\nTensors may be used as the unit values of neural networks which extend the concept of scalar, vector and matrix values to multiple dimensions.\nThe output value of single layer unit \n \n \n \n \n y\n \n m\n \n \n \n \n {\\displaystyle y_{m}}\n \n is the sum-product of its input units and the connection weights filtered through the activation function \n \n \n \n f\n \n \n {\\displaystyle f}\n \n:\n\n \n \n \n \n y\n \n m\n \n \n =\n f\n \n (\n \n \n ∑\n \n n\n \n \n \n x\n \n n\n \n \n \n u\n \n m\n ,\n n\n \n \n \n )\n \n ,\n \n \n {\\displaystyle y_{m}=f\\left(\\sum _{n}x_{n}u_{m,n}\\right),}\n \n\nwhere\n\n \n \n \n \n y\n \n m\n \n \n ∈\n \n R\n \n .\n \n \n {\\displaystyle y_{m}\\in \\mathbb {R} .}\n \n\nIf each output element of \n \n \n \n \n y\n \n m\n \n \n \n \n {\\displaystyle y_{m}}\n \n is a scalar, then we have the classical definition of an artificial neural network. By replacing each unit component with a tensor, the network is able to express higher dimensional data such as images or videos:\n\n \n \n \n \n y\n \n m\n \n \n ∈\n \n \n R\n \n \n \n I\n \n 0\n \n \n ×\n \n I\n \n 1\n \n \n ×\n .\n .\n ×\n \n I\n \n C\n \n \n \n \n .\n \n \n {\\displaystyle y_{m}\\in \\mathbb {R} ^{I_{0}\\times I_{1}\\times ..\\times I_{C}}.}\n \n\nThis use of tensors to replace unit values is common in convolutional neural networks where each unit might be an image processed through multiple layers. By embedding the data in tensors such network structures enable learning of complex data types.\n\n\nIn fully connected layers\n\nTensors may also be used to compute the layers of a fully connected neural network, where the tensor is applied to the entire layer instead of individual unit values.\nThe output value of single layer unit \n \n \n \n \n y\n \n m\n \n \n \n \n {\\displaystyle y_{m}}\n \n is the sum-product of its input units and the connection weights filtered through the activation function \n \n \n \n f\n \n \n {\\displaystyle f}\n \n:\n\n \n \n \n \n y\n \n m\n \n \n =\n f\n \n (\n \n \n ∑\n \n n\n \n \n \n x\n \n n\n \n \n \n u\n \n m\n ,\n n\n \n \n \n )\n \n .\n \n \n {\\displaystyle y_{m}=f\\left(\\sum _{n}x_{n}u_{m,n}\\right).}\n \n\nThe vectors \n \n \n \n x\n \n \n {\\displaystyle x}\n \n and \n \n \n \n y\n \n \n {\\displaystyle y}\n \n of output values can be expressed as a mode-1 tensors, while the hidden weights can be expressed as a mode-2 tensor. In this example the unit values are scalars while the tensor takes on the dimensions of the network layers:\n\n \n \n \n \n x\n \n n\n \n \n ↦\n \n \n X\n \n \n ∈\n \n \n R\n \n \n 1\n ×\n N\n \n \n ,\n \n \n {\\displaystyle x_{n}\\mapsto {\\mathcal {X}}\\in \\mathbb {R} ^{1\\times N},}\n \n\n \n \n \n \n y\n \n n\n \n \n ↦\n \n \n Y\n \n \n ∈\n \n \n R\n \n \n M\n ×\n 1\n \n \n ,\n \n \n {\\displaystyle y_{n}\\mapsto {\\mathcal {Y}}\\in \\mathbb {R} ^{M\\times 1},}\n \n\n \n \n \n \n u\n \n n\n \n \n ↦\n \n \n U\n \n \n ∈\n \n \n R\n \n \n N\n ×\n M\n \n \n .\n \n \n {\\displaystyle u_{n}\\mapsto {\\mathcal {U}}\\in \\mathbb {R} ^{N\\times M}.}\n \n\nIn this notation, the output values can be computed as a tensor product of the input and weight tensors:\n\n \n \n \n \n \n Y\n \n \n =\n f\n (\n \n \n X\n \n \n \n \n U\n \n \n )\n .\n \n \n {\\displaystyle {\\mathcal {Y}}=f({\\mathcal {X}}{\\mathcal {U}}).}\n \n\nwhich computes the sum-product as a tensor multiplication (similar to matrix multiplication).\nThis formulation of tensors enables the entire layer of a fully connected network to be efficiently computed by mapping the units and weights to tensors.\n\n\nIn convolutional layers\nA different reformulation of neural networks allows tensors to express the convolution layers of a neural network. A convolutional layer has multiple inputs, each of which is a spatial structure such as an image or volume. The inputs are convolved by filtering before being passed to the next layer. A typical use is to perform feature detection or isolation in image recognition.\nConvolution is often computed as the multiplication of an input signal \n \n \n \n g\n \n \n {\\displaystyle g}\n \n with a filter kernel \n \n \n \n f\n \n \n {\\displaystyle f}\n \n. In two dimensions the discrete, finite form is:\n\n \n \n \n (\n f\n ∗\n g\n \n )\n \n x\n ,\n y\n \n \n =\n \n ∑\n \n j\n =\n −\n w\n \n \n w\n \n \n \n ∑\n \n k\n =\n −\n w\n \n \n w\n \n \n \n f\n \n j\n ,\n k\n \n \n \n g\n \n x\n +\n j\n ,\n y\n +\n k\n \n \n ,\n \n \n {\\displaystyle (f*g)_{x,y}=\\sum _{j=-w}^{w}\\sum _{k=-w}^{w}f_{j,k}g_{x+j,y+k},}\n \n\nwhere \n \n \n \n w\n \n \n {\\displaystyle w}\n \n is the width of the kernel. \nThis definition can be rephrased as a matrix-vector product in terms of tensors that express the kernel, data and inverse transform of the kernel.\n\n \n \n \n \n \n Y\n \n \n =\n \n \n A\n \n \n [\n (\n C\n g\n )\n ⊙\n (\n B\n d\n )\n ]\n ,\n \n \n {\\displaystyle {\\mathcal {Y}}={\\mathcal {A}}[(Cg)\\odot (Bd)],}\n \n\nwhere \n \n \n \n \n \n A\n \n \n ,\n \n \n B\n \n \n \n \n {\\displaystyle {\\mathcal {A}},{\\mathcal {B}}}\n \n and \n \n \n \n \n \n C\n \n \n \n \n {\\displaystyle {\\mathcal {C}}}\n \n are the inverse transform, data and kernel. The derivation is more complex when the filtering kernel also includes a non-linear activation function such as sigmoid or ReLU.\nThe hidden weights of the convolution layer are the parameters to the filter. These can be reduced with a pooling layer which reduces the resolution (size) of the data, and can also be expressed as a tensor operation.\n\n\nTensor factorization\nAn important contribution of tensors in machine learning is the ability to factorize tensors to decompose data into constituent factors or reduce the learned parameters. Data tensor modeling techniques stem from the linear tensor decomposition (CANDECOMP/Parafac decomposition) and the multilinear tensor decompositions (Tucker).\n\n\nTucker decomposition\n\nTucker decomposition, for example, takes a 3-way array \n \n \n \n \n \n X\n \n \n ∈\n \n \n R\n \n \n I\n ×\n J\n ×\n K\n \n \n \n \n {\\displaystyle {\\mathcal {X}}\\in \\mathbb {R} ^{I\\times J\\times K}}\n \n \nand decomposes the tensor into three matrices \n \n \n \n \n \n A\n ,\n B\n ,\n C\n \n \n \n \n {\\displaystyle {\\mathcal {A,B,C}}}\n \n and a smaller tensor \n \n \n \n \n \n G\n \n \n \n \n {\\displaystyle {\\mathcal {G}}}\n \n. The shape of the matrices and new tensor are such that the total number of elements is reduced. The new tensors have shapes\n\n \n \n \n \n \n A\n \n \n ∈\n \n \n R\n \n \n I\n ×\n P\n \n \n ,\n \n \n {\\displaystyle {\\mathcal {A}}\\in \\mathbb {R} ^{I\\times P},}\n \n\n \n \n \n \n \n B\n \n \n ∈\n \n \n R\n \n \n J\n ×\n Q\n \n \n ,\n \n \n {\\displaystyle {\\mathcal {B}}\\in \\mathbb {R} ^{J\\times Q},}\n \n\n \n \n \n \n \n C\n \n \n ∈\n \n \n R\n \n \n K\n ×\n R\n \n \n ,\n \n \n {\\displaystyle {\\mathcal {C}}\\in \\mathbb {R} ^{K\\times R},}\n \n\n \n \n \n \n \n G\n \n \n ∈\n \n \n R\n \n \n P\n ×\n Q\n ×\n R\n \n \n .\n \n \n {\\displaystyle {\\mathcal {G}}\\in \\mathbb {R} ^{P\\times Q\\times R}.}\n \n\nThen the original tensor can be expressed as the tensor product of these four tensors:\n\n \n \n \n \n \n X\n \n \n =\n \n \n G\n \n \n ×\n \n \n A\n \n \n ×\n \n \n B\n \n \n ×\n \n \n C\n \n \n .\n \n \n {\\displaystyle {\\mathcal {X}}={\\mathcal {G}}\\times {\\mathcal {A}}\\times {\\mathcal {B}}\\times {\\mathcal {C}}.}\n \n\nIn the example shown in the figure, the dimensions of the tensors are\n\n \n \n \n \n \n X\n \n \n \n \n {\\displaystyle {\\mathcal {X}}}\n \n: I=8, J=6, K=3, \n \n \n \n \n \n A\n \n \n \n \n {\\displaystyle {\\mathcal {A}}}\n \n: I=8, P=5, \n \n \n \n \n \n B\n \n \n \n \n {\\displaystyle {\\mathcal {B}}}\n \n: J=6, Q=4, \n \n \n \n \n \n C\n \n \n \n \n {\\displaystyle {\\mathcal {C}}}\n \n: K=3, R=2, \n \n \n \n \n \n G\n \n \n \n \n {\\displaystyle {\\mathcal {G}}}\n \n: P=5, Q=4, R=2.\nThe total number of elements in the Tucker factorization is\n\n \n \n \n \n |\n \n \n \n A\n \n \n \n |\n \n +\n \n |\n \n \n \n B\n \n \n \n |\n \n +\n \n |\n \n \n \n C\n \n \n \n |\n \n +\n \n |\n \n \n \n G\n \n \n \n |\n \n =\n \n \n {\\displaystyle |{\\mathcal {A}}|+|{\\mathcal {B}}|+|{\\mathcal {C}}|+|{\\mathcal {G}}|=}\n \n\n \n \n \n (\n I\n ×\n P\n )\n +\n (\n J\n ×\n Q\n )\n +\n (\n K\n ×\n R\n )\n +\n (\n P\n ×\n Q\n ×\n R\n )\n =\n 8\n ×\n 5\n +\n 6\n ×\n 4\n +\n 3\n ×\n 2\n +\n 5\n ×\n 4\n ×\n 2\n =\n 110.\n \n \n {\\displaystyle (I\\times P)+(J\\times Q)+(K\\times R)+(P\\times Q\\times R)=8\\times 5+6\\times 4+3\\times 2+5\\times 4\\times 2=110.}\n \n\nThe number of elements in the original \n \n \n \n \n \n X\n \n \n \n \n {\\displaystyle {\\mathcal {X}}}\n \n is 144, resulting in a data reduction from 144 down to 110 elements, a reduction of 23% in parameters or data size. For much larger initial tensors, and depending on the rank (redundancy) of the tensor, the gains can be more significant.\nThe work of Rabanser et al. provides an introduction to tensors with more details on the extension of Tucker decomposition to N-dimensions beyond the mode-3 example given here.\n\n\nTensor trains\nAnother technique for decomposing tensors rewrites the initial tensor as a sequence (train) of smaller sized tensors. A tensor-train (TT) is a sequence of tensors of reduced rank, called canonical factors. The original tensor can be expressed as the sum-product of the sequence.\n\n \n \n \n \n \n X\n \n \n =\n \n \n \n G\n \n 1\n \n \n \n \n \n \n \n G\n \n 2\n \n \n \n \n \n \n \n G\n \n 3\n \n \n \n \n .\n .\n \n \n \n G\n \n d\n \n \n \n \n \n \n {\\displaystyle {\\mathcal {X}}={\\mathcal {G_{1}}}{\\mathcal {G_{2}}}{\\mathcal {G_{3}}}..{\\mathcal {G_{d}}}}\n \n\nDeveloped in 2011 by Ivan Oseledts, the author observes that Tucker decomposition is \"suitable for small dimensions, especially for the three-dimensional case. For large d it is not suitable.\" Thus tensor-trains can be used to factorize larger tensors in higher dimensions.\n\n\nTensor graphs\nThe unified data architecture and automatic differentiation of tensors has enabled higher-level designs of machine learning in the form of tensor graphs. This leads to new architectures, such as tensor-graph convolutional networks (TGCN), which identify highly non-linear associations in data, combine multiple relations, and scale gracefully, while remaining robust and performant.\nThese developments are impacting all areas of machine learning, such as text mining and clustering, time varying data, and neural networks wherein the input data is a social graph and the data changes dynamically.\n\n\nHardware\nTensors provide a unified way to train neural networks for more complex data sets. However, training is expensive to compute on classical CPU hardware.\nIn 2014, Nvidia developed cuDNN, CUDA Deep Neural Network, a library for a set of optimized primitives written in the parallel CUDA language. CUDA and thus cuDNN run on dedicated GPUs that implement unified massive parallelism in hardware. These GPUs were not yet dedicated chips for tensors, but rather existing hardware adapted for parallel computation in machine learning.\nIn the period 2015–2017 Google invented the Tensor Processing Unit (TPU). TPUs are dedicated, fixed function hardware units that specialize in the matrix multiplications needed for tensor products. Specifically, they implement an array of 65,536 multiply units that can perform a 256x256 matrix sum-product in just one global instruction cycle.\nLater in 2017, Nvidia released its own Tensor Core with the Volta GPU architecture. Each Tensor Core is a microunit that can perform a 4x4 matrix sum-product. There are eight tensor cores for each shared memory (SM) block. The first GV100 GPU card has 108 SMs resulting in 672 tensor cores. This device accelerated machine learning by 12x over the previous Tesla GPUs. The number of tensor cores scales as the number of cores and SM units continue to grow in each new generation of cards.\nThe development of GPU hardware, combined with the unified architecture of tensor cores, has enabled the training of much larger neural networks. In 2022, the largest neural network was Google's PaLM with 540 billion learned parameters (network weights) (the older GPT-3 language model has over 175 billion learned parameters that produces human-like text; size isn't everything, Stanford's much smaller 2023 Alpaca model claims to be better, having learned from Meta/Facebook's 2023 model LLaMA, the smaller 7 billion parameter variant). The widely popular chatbot ChatGPT is built on top of GPT-3.5 (and after an update GPT-4) using supervised and reinforcement learning.\n\n\nReferences", "categories": ["Arrays", "Articles with short description", "CS1 maint: periodical has ISBN", "Machine learning", "Pages that use a deprecated format of the math tags", "Short description matches Wikidata", "Tensors"], "references": ["https://www.infoq.com/news/2014/09/cudnn/", "https://www.nextplatform.com/2017/04/05/first-depth-look-googles-tpu-architecture/", "https://images.nvidia.com/content/volta-architecture/pdf/volta-architecture-whitepaper.pdf", "https://www.tomshardware.com/news/nvidia-tensor-core-tesla-v100,34384.html", "https://par.nsf.gov/servlets/purl/10285968", "https://arxiv.org/abs/1912.01703", "https://www.usenix.org/system/files/conference/osdi16/osdi16-abadi.pdf", "https://doi.org/10.3390%2Felectronics7110320", "https://doi.org/10.1109%2FTSP.2020.3028495", "https://api.semanticscholar.org/CorpusID:212736801", "https://doi.org/10.1109%2FMM.2018.032271057", "https://api.semanticscholar.org/CorpusID:21657842", "https://developer.nvidia.com/cudnn", "https://arxiv.org/abs/1605.08695", "https://arxiv.org/abs/1904.02698"], "images": ["File:Fully connected neural network and it's expression as a tensor product.jpg", "File:Tensor Units.jpg", "File:Tensor tucker.jpg"], "sub_niche": "International Conference on Machine Learning"} {"title": "Federated learning", "url": "https://en.wikipedia.org/wiki/Federated_learning", "summary": "Federated learning (also known as collaborative learning) is a machine learning technique in a setting where multiple entities (often called clients) collaboratively train a model while keeping their data decentralized, rather than centrally stored. A defining characteristic of federated learning is data heterogeneity. Because client data is decentralized, data samples held by each client may not be independently and identically distributed.\nFederated learning is generally concerned with and motivated by issues such as data privacy, data minimization, and data access rights. Its applications involve a variety of research areas including defence, telecommunications, the Internet of things, and pharmaceuticals.", "content": "Federated learning (also known as collaborative learning) is a machine learning technique in a setting where multiple entities (often called clients) collaboratively train a model while keeping their data decentralized, rather than centrally stored. A defining characteristic of federated learning is data heterogeneity. Because client data is decentralized, data samples held by each client may not be independently and identically distributed.\nFederated learning is generally concerned with and motivated by issues such as data privacy, data minimization, and data access rights. Its applications involve a variety of research areas including defence, telecommunications, the Internet of things, and pharmaceuticals.\n\n\nDefinition\nFederated learning aims at training a machine learning algorithm, for instance deep neural networks, on multiple local datasets contained in local nodes without explicitly exchanging data samples. The general principle consists in training local models on local data samples and exchanging parameters (e.g. the weights and biases of a deep neural network) between these local nodes at some frequency to generate a global model shared by all nodes.\nThe main difference between federated learning and distributed learning lies in the assumptions made on the properties of the local datasets, as distributed learning originally aims at parallelizing computing power where federated learning originally aims at training on heterogeneous datasets. While distributed learning also aims at training a single model on multiple servers, a common underlying assumption is that the local datasets are independent and identically distributed (i.i.d.) and roughly have the same size. None of these hypotheses are made for federated learning; instead, the datasets are typically heterogeneous and their sizes may span several orders of magnitude. Moreover, the clients involved in federated learning may be unreliable as they are subject to more failures or drop out since they commonly rely on less powerful communication media (i.e. Wi-Fi) and battery-powered systems (i.e. smartphones and IoT devices) compared to distributed learning where nodes are typically datacenters that have powerful computational capabilities and are connected to one another with fast networks.\n\n\nMathematical formulation\nThe objective function for federated learning is as follows:\n\n \n \n \n f\n (\n \n \n x\n \n \n 1\n \n \n ,\n …\n ,\n \n \n x\n \n \n K\n \n \n )\n =\n \n \n \n 1\n K\n \n \n \n \n ∑\n \n i\n =\n 1\n \n \n K\n \n \n \n f\n \n i\n \n \n (\n \n \n x\n \n \n i\n \n \n )\n \n \n {\\displaystyle f(\\mathbf {x} _{1},\\dots ,\\mathbf {x} _{K})={\\dfrac {1}{K}}\\sum _{i=1}^{K}f_{i}(\\mathbf {x} _{i})}\n \n\nwhere \n \n \n \n K\n \n \n {\\displaystyle K}\n \n is the number of nodes, \n \n \n \n \n \n x\n \n \n i\n \n \n \n \n {\\displaystyle \\mathbf {x} _{i}}\n \n are the weights of model as viewed by node \n \n \n \n i\n \n \n {\\displaystyle i}\n \n, and \n \n \n \n \n f\n \n i\n \n \n \n \n {\\displaystyle f_{i}}\n \n is node \n \n \n \n i\n \n \n {\\displaystyle i}\n \n's local objective function, which describes how model weights \n \n \n \n \n \n x\n \n \n i\n \n \n \n \n {\\displaystyle \\mathbf {x} _{i}}\n \n conforms to node \n \n \n \n i\n \n \n {\\displaystyle i}\n \n's local dataset.\nThe goal of federated learning is to train a common model on all of the nodes' local datasets, in other words:\n\nOptimizing the objective function \n \n \n \n f\n (\n \n \n x\n \n \n 1\n \n \n ,\n …\n ,\n \n \n x\n \n \n K\n \n \n )\n \n \n {\\displaystyle f(\\mathbf {x} _{1},\\dots ,\\mathbf {x} _{K})}\n \n.\nAchieving consensus on \n \n \n \n \n \n x\n \n \n i\n \n \n \n \n {\\displaystyle \\mathbf {x} _{i}}\n \n. In other words, \n \n \n \n \n \n x\n \n \n 1\n \n \n ,\n …\n ,\n \n \n x\n \n \n K\n \n \n \n \n {\\displaystyle \\mathbf {x} _{1},\\dots ,\\mathbf {x} _{K}}\n \n converge to some common \n \n \n \n \n x\n \n \n \n {\\displaystyle \\mathbf {x} }\n \n at the end of the training process.\n\n\nCentralized federated learning\nIn the centralized federated learning setting, a central server is used to orchestrate the different steps of the algorithms and coordinate all the participating nodes during the learning process. The server is responsible for the nodes selection at the beginning of the training process and for the aggregation of the received model updates. Since all the selected nodes have to send updates to a single entity, the server may become a bottleneck of the system.\n\n\nDecentralized federated learning\nIn the decentralized federated learning setting, the nodes are able to coordinate themselves to obtain the global model. This setup prevents single point failures as the model updates are exchanged only between interconnected nodes without the orchestration of the central server. Nevertheless, the specific network topology may affect the performances of the learning process. See blockchain-based federated learning and the references therein.\n\n\nPersonalized federated learning\nIn many application domains, not all clients are the same. Clients may share the same model architecture, but each have a different data distribution—which is known as Personalized federated learning (PFL), or even have different model architectures, like mobile phones and IoT devices—which is known as Heterogeneous federated learning. The key challenge in training a PFL model is to keep each client different from others, and at the same time benefit from generalizing across clients.\n\n\nHeterogeneous federated learning\nMost of the existing federated learning strategies assume that local models share the same global model architecture. In 2020, a federated learning framework named HeteroFL was developed to address heterogeneous clients equipped with very different computation and communication capabilities. The HeteroFL technique can enable the training of heterogeneous local models with dynamically varying computation and non-IID data complexities while still producing a single accurate global inference model.\n\n\nMain features\n\n\nIterative learning\nThe iterative process of federated learning is composed of a series of fundamental client-server interactions, each of which is known as a federated learning round. Each round of this process consists in transmitting the current global model state to participating nodes, training local models on these local nodes to produce a set of potential model updates at each node, and then aggregating and processing these local updates into a single global update and applying it to the global model.\nIn the methodology below, a central server is used for aggregation, while local nodes perform local training depending on the central server's orders. However, other strategies lead to the same results without central servers, in a peer-to-peer approach, using gossip or consensus methodologies.\nAssuming a federated round composed by one iteration of the learning process, the learning procedure can be summarized as follows:\n\nInitialization: according to the server inputs, a machine learning model (e.g., linear regression, neural network, boosting) is chosen to be trained on local nodes and initialized. Then, nodes are activated and wait for the central server to give the calculation tasks.\nClient selection: a fraction of local nodes are selected to start training on local data. The selected nodes acquire the current statistical model while the others wait for the next federated round.\nConfiguration: the central server orders selected nodes to undergo training of the model on their local data in a pre-specified fashion (e.g., for some mini-batch updates of gradient descent).\nReporting: each selected node sends its local model to the server for aggregation. The central server aggregates the received models and sends back the model updates to the nodes. It also handles failures for disconnected nodes or lost model updates. The next federated round is started returning to the client selection phase.\nTermination: once a pre-defined termination criterion is met (e.g., a maximum number of iterations is reached or the model accuracy is greater than a threshold) the central server aggregates the updates and finalizes the global model.\nThe procedure considered before assumes synchronized model updates. Recent federated learning developments introduced novel techniques to tackle asynchronicity during the training process, or training with dynamically varying models. Compared to synchronous approaches where local models are exchanged once the computations have been performed for all layers of the neural network, asynchronous ones leverage the properties of neural networks to exchange model updates as soon as the computations of a certain layer are available. These techniques are also commonly referred to as split learning and they can be applied both at training and inference time regardless of centralized or decentralized federated learning settings.\n\n\nNon-IID data\nIn most cases, the assumption of independent and identically distributed samples across local nodes does not hold for federated learning setups. Under this setting, the performances of the training process may vary significantly according to the unbalanced local data samples as well as the particular probability distribution of the training examples (i.e., features and labels) stored at the local nodes. To further investigate the effects of non-IID data, the following description considers the main categories presented in the preprint by Peter Kairouz et al. from 2019.\nThe description of non-IID data relies on the analysis of the joint probability between features and labels for each node.\nThis allows decoupling of each contribution according to the specific distribution available at the local nodes.\nThe main categories for non-iid data can be summarized as follows:\n\nCovariate shift: local nodes may store examples that have different statistical distributions compared to other nodes. An example occurs in natural language processing datasets where people typically write the same digits/letters with different stroke widths or slants.\nPrior probability shift: local nodes may store labels that have different statistical distributions compared to other nodes. This can happen if datasets are regional and/or demographically partitioned. For example, datasets containing images of animals vary significantly from country to country.\nConcept drift (same label, different features): local nodes may share the same labels but some of them correspond to different features at different local nodes. For example, images that depict a particular object can vary according to the weather condition in which they were captured.\nConcept shift (same features, different labels): local nodes may share the same features but some of them correspond to different labels at different local nodes. For example, in natural language processing, the sentiment analysis may yield different sentiments even if the same text is observed.\nUnbalanced: the amount of data available at the local nodes may vary significantly in size.\nThe loss in accuracy due to non-iid data can be bounded through using more sophisticated means of doing data normalization, rather than batch normalization.\n\n\nAlgorithmic hyper-parameters\n\n\nNetwork topology\nThe way the statistical local outputs are pooled and the way the nodes communicate with each other can change from the centralized model explained in the previous section. This leads to a variety of federated learning approaches: for instance no central orchestrating server, or stochastic communication.\nIn particular, orchestrator-less distributed networks are one important variation. In this case, there is no central server dispatching queries to local nodes and aggregating local models. Each local node sends its outputs to several randomly-selected others, which aggregate their results locally. This restrains the number of transactions, thereby sometimes reducing training time and computing cost.\n\n\nFederated learning parameters\nOnce the topology of the node network is chosen, one can control different parameters of the federated learning process (in addition to the machine learning model's own hyperparameters) to optimize learning:\n\nNumber of federated learning rounds: \n \n \n \n T\n \n \n {\\displaystyle T}\n \n\nTotal number of nodes used in the process: \n \n \n \n K\n \n \n {\\displaystyle K}\n \n\nFraction of nodes used at each iteration for each node: \n \n \n \n C\n \n \n {\\displaystyle C}\n \n\nLocal batch size used at each learning iteration: \n \n \n \n B\n \n \n {\\displaystyle B}\n \n\nOther model-dependent parameters can also be tinkered with, such as:\n\nNumber of iterations for local training before pooling: \n \n \n \n N\n \n \n {\\displaystyle N}\n \n\nLocal learning rate: \n \n \n \n η\n \n \n {\\displaystyle \\eta }\n \n\nThose parameters have to be optimized depending on the constraints of the machine learning application (e.g., available computing power, available memory, bandwidth). For instance, stochastically choosing a limited fraction \n \n \n \n C\n \n \n {\\displaystyle C}\n \n of nodes for each iteration diminishes computing cost and may prevent overfitting, in the same way that stochastic gradient descent can reduce overfitting.\n\n\nLimitations\n\n\nTechnical\nFederated learning requires frequent communication between nodes during the learning process. Thus, it requires not only enough local computing power and memory, but also high bandwidth connections to be able to exchange parameters of the machine learning model. However, the technology also avoids data communication, which can require significant resources before starting centralized machine learning. Nevertheless, the devices typically employed in federated learning are communication-constrained, for example IoT devices or smartphones are generally connected to Wi-Fi networks, thus, even if the models are commonly less expensive to be transmitted compared to raw data, federated learning mechanisms may not be suitable in their general form.\nFederated learning raises several statistical challenges:\n\nHeterogeneity between the different local datasets: each node may have some bias with respect to the general population, and the size of the datasets may vary significantly;\nTemporal heterogeneity: each local dataset's distribution may vary with time;\nInteroperability of each node's dataset is a prerequisite;\nEach node's dataset may require regular curations;\nHiding training data might allow attackers to inject backdoors into the global model;\nLack of access to global training data makes it harder to identify unwanted biases entering the training e.g. age, gender, sexual orientation;\nPartial or total loss of model updates due to node failures affecting the global model;\nLack of annotations or labels on the client side.\nHeterogeneity between processing platforms\n\n\nGovernance\nGovernance considerations may also limit the applicability of federated learning, in particular when applied in cross-organisational settings. Most federated learning frameworks rely on a central coordinating server, which introduces questions regarding infrastructure control, model ownership, and decision-making authority among collaborators. In multi-party deployments, especially those spanning competitive or collaborative data markets, the absence of agreed-upon governance structures can create uncertainty about responsibilities for validating model updates, auditing system behaviour, and managing security incidents. These organisational issues may deter participants from contributing to shared models and can complicate regulatory compliance, thereby constraining adoption.\n\nA further governance-related issue concerns the distribution of value among participants as multi-party federated learning systems scale. As more clients contribute to training, model accuracy may approach a performance threshold, after which additional contributions yield diminishing marginal utility. This dynamic can create tensions within collaborative arrangements, as early participants may perceive later contributions as offering reduced value while still benefiting from the shared model. Such asymmetries may affect incentives to join or remain in a consortium and complicate the design of fair participation, ownership, or reward structures. Establishing transparent rules for contribution assessment and benefit allocation is therefore an important organisational challenge and represents a direction for future research.\n\n\nAlgorithms\nA number of different algorithms for federated optimization have been proposed.\n\n\nFederated stochastic gradient descent (FedSGD)\nStochastic gradient descent is an approach used in deep learning, where gradients are computed on a random subset of the total dataset and then used to make one step of the gradient descent.\nFederated stochastic gradient descent is the analog of this algorithm to the federated setting, but uses a random subset of the nodes, each node using all its data. The server averages the gradients in proportion to the number of training data on each node, and uses the average to make a gradient descent step.\n\n\nSimilarity weighted aggregation (SimAgg)\nSimilarity Weighted Aggregation (SimAgg) is an adaptive federated learning aggregation method in which client model parameters are weighted according to their similarity to the average model parameters. It was introduced for federated brain tumor segmentation.\nSimAgg achieved first place in Task 1 of the 2021 Federated Tumor Segmentation (FeTS) Challenge.\nFeTS was the first international challenge on federated learning.\n\n\nFederated averaging (FedAvg)\nFederated averaging (FedAvg) is a generalization of FedSGD which allows nodes to do more than one batch update on local data and exchange updated weights rather than gradients. This reduces communication and is equivalent to averaging the weights if all nodes start with the same weights. It does not seem to hurt the resulting averaged model's performance compared to FedSGD. FedAvg variations have been proposed based on adaptive optimizers such as ADAM and AdaGrad, and tend to outperform FedAvg.\n\n\nFederated Proximal (FedProx)\nFederated Proximal (FedProx) extends FedAvg by adding a proximal term to the local objective in the form of \n \n \n \n \n \n μ\n 2\n \n \n ‖\n w\n −\n \n w\n \n t\n \n \n \n ‖\n \n 2\n \n \n \n \n {\\displaystyle {\\frac {\\mu }{2}}\\|w-w^{t}\\|^{2}}\n \n, where \n \n \n \n μ\n \n \n {\\displaystyle \\mu }\n \n is the FedProx hyper parameter, in order to address data heterogeneity across clients. The proximal term constrains local updates, helping reduce client drift when client data are non-IID.\n\n\nFederated learning with dynamic regularization (FedDyn)\nFederated learning methods suffer when node datasets are distributed heterogeneously, because then minimizing the node losses is not the same as minimizing the global loss. In 2021, Acar et al. introduced a solution called FedDyn, which dynamically regularizes each node loss function so that they converge to the global loss. Since the local losses are aligned, FedDyn is robust to the different heterogeneity levels and so it can safely perform full minimization in each device. In theory, FedDyn converges to the optimal (a stationary point for nonconvex losses) by being agnostic to the heterogeneity levels. These claims are verified with extensive experiments on various datasets.\nBesides reducing communication, it is also beneficial to reduce local computation. To do this, FedDynOneGD modifies FedDyn to calculate only one gradient per node per round, regularizes it and updates the global model with it. Hence, the computational complexity is linear in local dataset size. Moreover, gradient computation can be parallelized on each node, unlike successive SGD steps. In theory, FedDynOneGD achieves the same convergence guarantees as in FedDyn with less local computation.\n\n\nPersonalized federated learning by pruning (Sub-FedAvg)\nFederated learning methods have poor global performance under non-IID settings. This motivates clients to yield personalized models in federation. To change this, Vahidian et al. recently introduced the algorithm Sub-FedAvg which does hybrid pruning (structured and unstructured pruning) with averaging on the intersection of clients' drawn subnetworks. This simultaneously addresses communication efficiency, resource constraints and personalized models accuracies.\nSub-FedAvg also extends the \"lottery ticket hypothesis\" of centrally trained neural networks to federated learning, with the research question: \"Do winning tickets exist for clients' neural networks being trained in federated learning? If so, how to effectively draw the personalized subnetworks for each client?\" Sub-FedAvg experimentally answers \"yes\" and proposes two algorithms to effectively draw the personalized subnetworks.\n\n\nDynamic aggregation - inverse distance aggregation\nIDA (Inverse Distance Aggregation) is a novel adaptive weighting approach for federated learning nodes based on meta-information which handles unbalanced and non-iid data. It uses the distance of the model parameters as a strategy to minimize the effect of outliers and improve the model's convergence rate.\n\n\nHybrid federated dual coordinate ascent (HyFDCA)\nVery few methods for hybrid federated learning, where clients only hold subsets of both features and samples, exist. Yet, this scenario is very important in practical settings. Hybrid Federated Dual Coordinate Ascent (HyFDCA) is a novel algorithm proposed in 2024 that solves convex problems in the hybrid FL setting. This algorithm extends CoCoA, a primal-dual distributed optimization algorithm introduced by Jaggi et al. (2014) and Smith et al. (2017), to the case where both samples and features are partitioned across clients.\nHyFDCA claims several improvement over existing algorithms:\n\nHyFDCA is a provably convergent primal-dual algorithm for hybrid FL in at least the following settings.\nHybrid Federated Setting with Complete Client Participation\nHorizontal Federated Setting with Random Subsets of Available Clients\nThe authors show HyFDCA enjoys a convergence rate of O(1⁄t) which matches the convergence rate of FedAvg (see below).\nVertical Federated Setting with Incomplete Client Participation\nThe authors show HyFDCA enjoys a convergence rate of O(log(t)⁄t) whereas FedBCD exhibits a slower O(1⁄sqrt(t)) convergence rate and requires full client participation.\nHyFDCA provides the privacy steps that ensure privacy of client data in the primal-dual setting. These principles apply to future efforts in developing primal-dual algorithms for FL.\nHyFDCA empirically outperforms HyFEM and FedAvg in loss function value and validation accuracy across a multitude of problem settings and datasets (see below for more details). The authors also introduce a hyperparameter selection framework for FL with competing metrics using ideas from multiobjective optimization.\nThere is only one other algorithm that focuses on hybrid FL, HyFEM proposed by Zhang et al. (2020). This algorithm uses a feature matching formulation that balances clients building accurate local models and the server learning an accurate global model. This requires a matching regularizer constant that must be tuned based on user goals and results in disparate local and global models. Furthermore, the convergence results provided for HyFEM only prove convergence of the matching formulation not of the original global problem. This work is substantially different from HyFDCA's approach which uses data on local clients to build a global model that converges to the same solution as if the model was trained centrally. Furthermore, the local and global models are synchronized and do not require the adjustment of a matching parameter between local and global models. However, HyFEM is suitable for a vast array of architectures including deep learning architectures, whereas HyFDCA is designed for convex problems like logistic regression and support vector machines.\nHyFDCA is empirically benchmarked against the aforementioned HyFEM as well as the popular FedAvg in solving convex problem (specifically classification problems) for several popular datasets (MNIST, Covtype, and News20). The authors found HyFDCA converges to a lower loss value and higher validation accuracy in less overall time in 33 of 36 comparisons examined and 36 of 36 comparisons examined with respect to the number of outer iterations. Lastly, HyFDCA only requires tuning of one hyperparameter, the number of inner iterations, as opposed to FedAvg (which requires tuning three) or HyFEM (which requires tuning four). In addition to FedAvg and HyFEM being quite difficult to optimize hyperparameters in turn greatly affecting convergence, HyFDCA's single hyperparameter allows for simpler practical implementations and hyperparameter selection methodologies.\n\n\nCurrent research topics\nAnother important aspect of active research is the reduction of the communication burden during the federated learning process. In 2017 and 2018, publications have emphasized the development of resource allocation strategies, especially to reduce communication requirements between nodes with gossip algorithms as well as on the characterization of the robustness to differential privacy attacks. Other research activities focus on the reduction of the bandwidth during training through sparsification and quantization methods, where the machine learning models are sparsified and/or compressed before they are shared with other nodes. Developing ultra-light DNN architectures is essential for device-/edge- learning and recent work recognises both the energy efficiency requirements for future federated learning and the need to compress deep learning, especially during learning.\nRecent research advancements are starting to consider real-world propagating channels as in previous implementations ideal channels were assumed. Another active direction of research is to develop Federated learning for training heterogeneous local models with varying computation complexities and producing a single powerful global inference model.\nA learning framework named Assisted learning was recently developed to improve each agent's learning capabilities without transmitting private data, models, and even learning objectives. Compared with Federated learning that often requires a central controller to orchestrate the learning and optimization, Assisted learning aims to provide protocols for the agents to optimize and learn among themselves without a global model.\n\n\nUse cases\nFederated learning typically applies when individual actors need to train models on larger datasets than their own, but cannot afford to share the data in itself with others (e.g., for legal, strategic or economic reasons). The technology yet requires good connections between local servers and minimum computational power for each node.\n\n\nTransportation: self-driving cars\nSelf-driving cars encapsulate many machine learning technologies to function: computer vision for analyzing obstacles, machine learning for adapting their pace to the environment (e.g., bumpiness of the road). Due to the potential high number of self-driving cars and the need for them to quickly respond to real world situations, traditional cloud approach may generate safety risks. Federated learning can represent a solution for limiting volume of data transfer and accelerating learning processes.\n\n\nIndustry 4.0: smart manufacturing\nIn Industry 4.0, there is a widespread adoption of machine learning techniques to improve the efficiency and effectiveness of industrial process while guaranteeing a high level of safety. Nevertheless, privacy of sensitive data for industries and manufacturing companies is of paramount importance. Federated learning algorithms can be applied to these problems as they do not disclose any sensitive data. In addition, FL also implemented for PM2.5 prediction to support Smart city sensing applications.\n\n\nMedicine: digital health\nFederated learning seeks to address the problem of data governance and privacy by training algorithms collaboratively without exchanging the data itself. Today's standard approach of centralizing data from multiple centers comes at the cost of critical concerns regarding patient privacy and data protection. To solve this problem, the ability to train machine learning models at scale across multiple medical institutions without moving the data is a critical technology. Nature Digital Medicine published the paper \"The Future of Digital Health with Federated Learning\" in September 2020, in which the authors explore how federated learning may provide a solution for the future of digital health, and highlight the challenges and considerations that need to be addressed. Recently, a collaboration of 20 different institutions around the world validated the utility of training AI models using federated learning. In a paper published in Nature Medicine \"Federated learning for predicting clinical outcomes in patients with COVID-19\", they showcased the accuracy and generalizability of a federated AI model for the prediction of oxygen needs in patients with COVID-19 infections. Furthermore, in a published paper \"A Systematic Review of Federated Learning in the Healthcare Area: From the Perspective of Data Properties and Applications\", the authors trying to provide a set of challenges on FL challenges on medical data-centric perspective.\nA coalition from industry and academia has developed MedPerf, an open source platform that enables validation of medical AI models in real world data. The platform relies technically on federated evaluation of AI models aiming to alleviate concerns of patient privacy and conceptually on diverse benchmark committees to build the specifications of neutral clinically impactful benchmarks.\n\n\nRobotics\nRobotics includes a wide range of applications of machine learning methods: from perception and decision-making to control. As robotic technologies have been increasingly deployed from simple and repetitive tasks (e.g. repetitive manipulation) to complex and unpredictable tasks (e.g. autonomous navigation), the need for machine learning grows. Federated Learning provides a solution to improve over conventional machine learning training methods. In the paper, mobile robots learned navigation over diverse environments using the FL-based method, helping generalization. In the paper, Federated Learning is applied to improve multi-robot navigation under limited communication bandwidth scenarios, which is a current challenge in real-world learning-based robotic tasks. In the paper, Federated Learning is used to learn Vision-based navigation, helping better sim-to-real transfer.\n\n\nBiometrics\nFederated Learning (FL) is transforming biometric recognition by enabling collaborative model training across distributed data sources while preserving privacy. By eliminating the need to share sensitive biometric templates like fingerprints, facial images, and iris scans, FL addresses privacy concerns and regulatory constraints, allowing for improved model accuracy and generalizability. It mitigates challenges of data fragmentation by leveraging scattered datasets, making it particularly effective for diverse biometric applications such as facial and iris recognition. However, FL faces challenges, including model and data heterogeneity, computational overhead, and vulnerability to security threats like inference attacks. Future directions include developing personalized FL frameworks, enhancing system efficiency, and expanding FL applications to biometric presentation attack detection (PAD) and quality assessment, fostering innovation and robust solutions in privacy-sensitive environments.\n\n\nSee also\nDistributed artificial intelligence\n\n\nReferences\n\n\nExternal links\n\"Regulation (EU) 2016/679 of the European Parliament and of the Council of 27 April 2016\" at eur-lex.europa.eu. Retrieved October 18, 2019.\n\"Data minimisation and privacy-preserving techniques in AI systems\" Archived 2020-07-23 at the Wayback Machine at UK Information Commissioners Office. Retrieved July 22, 2020\n\"Realising the Potential of Data Whilst Preserving Privacy with EyA and Conclave from R3\" at eya.global. Retrieved March 31, 2022.", "categories": ["Articles with short description", "Distributed artificial intelligence", "Machine learning", "Short description is different from Wikidata", "Webarchive template wayback links"], "references": ["https://eur-lex.europa.eu/legal-content/EN/TXT/PDF/?uri=CELEX:32016R0679", "https://ico.org.uk/about-the-ico/news-and-events/ai-blog-data-minimisation-and-privacy-preserving-techniques-in-ai-systems/", "https://api.semanticscholar.org/CorpusID:219006840", "https://api.semanticscholar.org/CorpusID:209515403", "https://api.semanticscholar.org/CorpusID:212747909", "https://api.semanticscholar.org/CorpusID:222179104", "https://www.nature.com/articles/s43588-021-00039-6", "https://api.semanticscholar.org/CorpusID:204401715", "http://proceedings.mlr.press/v119/hsieh20a.html", "https://arxiv.org/abs/2111.04263", "https://api.semanticscholar.org/CorpusID:237536154", "https://ieeexplore.ieee.org/document/9586241/;jsessionid=6HjI-LT80gn9nOJ9Vu4Qzeg-O-fNSeKUxKXGc2BDlkOkxCXpbVHu!1467215501", "https://doi.org/10.1145/3447548.3467309", "https://api.semanticscholar.org/CorpusID:243925551", "https://api.semanticscholar.org/CorpusID:240598436"], "images": ["File:Centralized federated learning protocol.png", "File:Federated learning (centralized vs decentralized).png", "File:Federated learning process central case.png"], "sub_niche": "International Conference on Machine Learning"} {"title": "Feature (machine learning)", "url": "https://en.wikipedia.org/wiki/Feature_(machine_learning)", "summary": "In machine learning and pattern recognition, a feature is an individual measurable property or characteristic of a data set. Choosing informative, discriminating, and independent features is crucial to producing effective algorithms for pattern recognition, classification, and regression tasks. Features are usually numeric, but other types such as strings and graphs are used in syntactic pattern recognition, after some pre-processing step such as one-hot encoding. The concept of \"features\" is related to that of explanatory variables used in statistical techniques such as linear regression.", "content": "In machine learning and pattern recognition, a feature is an individual measurable property or characteristic of a data set. Choosing informative, discriminating, and independent features is crucial to producing effective algorithms for pattern recognition, classification, and regression tasks. Features are usually numeric, but other types such as strings and graphs are used in syntactic pattern recognition, after some pre-processing step such as one-hot encoding. The concept of \"features\" is related to that of explanatory variables used in statistical techniques such as linear regression.\n\n\nFeature types\nIn feature engineering, two types of features are commonly used: numerical and categorical.\nNumerical features are continuous values that can be measured on a scale. Examples of numerical features include age, height, weight, and income. Numerical features can be used in machine learning algorithms directly.\nCategorical features are discrete values that can be grouped into categories. Examples of categorical features include gender, color, and zip code. Categorical features typically need to be converted to numerical features before they can be used in machine learning algorithms. This can be done using a variety of techniques, such as one-hot encoding, label encoding, and ordinal encoding.\nThe type of feature that is used in feature engineering depends on the specific machine learning algorithm that is being used. Some machine learning algorithms, such as decision trees, can handle both numerical and categorical features. Other machine learning algorithms, such as linear regression, can only handle numerical features.\n\n\nClassification\nA numeric feature can be conveniently described by a feature vector. One way to achieve binary classification is using a linear predictor function (related to the perceptron) with a feature vector as input. The method consists of calculating the scalar product between the feature vector and a vector of weights, qualifying those observations whose result exceeds a threshold.\nAlgorithms for classification from a feature vector include nearest neighbor classification, neural networks, and statistical techniques such as Bayesian approaches.\n\n\nExamples\n\nIn character recognition, features may include histograms counting the number of black pixels along horizontal and vertical directions, number of internal holes, stroke detection and many others.\nIn speech recognition, features for recognizing phonemes can include noise ratios, length of sounds, relative power, filter matches, logarithmic Mel-scale spectral vectors and Mel-frequency cepstral coefficients, which represent the frequency characteristics of audio signals.\nIn spam detection algorithms, features may include the presence or absence of certain email headers, \nthe email structure, the language, the frequency of specific terms, the grammatical correctness of the text.\nIn computer vision, there are a large number of possible features, such as edges and objects.\n\n\nFeature vectors\n\nIn pattern recognition and machine learning, a feature vector is an n-dimensional vector of numerical features that represent some object. Many algorithms in machine learning require a numerical representation of objects, since such representations facilitate processing and statistical analysis. When representing images, the feature values might correspond to the pixels of an image, while when representing texts the features might be the frequencies of occurrence of textual terms. Feature vectors are equivalent to the vectors of explanatory variables used in statistical procedures such as linear regression. Feature vectors are often combined with weights using a dot product in order to construct a linear predictor function that is used to determine a score for making a prediction.\nThe vector space associated with these vectors is often called the feature space. In order to reduce the dimensionality of the feature space, a number of dimensionality reduction techniques can be employed.\nHigher-level features can be obtained from already available features and added to the feature vector; for example, for the study of diseases the feature 'Age' is useful and is defined as Age = 'Year of death' minus 'Year of birth' . This process is referred to as feature construction. Feature construction is the application of a set of constructive operators to a set of existing features resulting in construction of new features. Examples of such constructive operators include checking for the equality conditions {=, ≠}, the arithmetic operators {+,−,×, /}, the array operators {max(S), min(S), average(S)} as well as other more sophisticated operators, for example count(S, C) that counts the number of features in the feature vector S satisfying some condition C or, for example, distances to other recognition classes generalized by some accepting device. Feature construction has long been considered a powerful tool for increasing both accuracy and understanding of structure, particularly in high-dimensional problems. Applications include studies of disease and emotion recognition from speech.\n\n\nSelection and extraction\n\nRaw features sets can be redundant or sufficiently large to make estimation and optimization difficult or ineffective. Therefore, many applications of machine learning and pattern recognition begin by selecting a subset of features or constructing a new and reduced set of features. These processes can facilitate learning and improve the generalization and interpretability of machine learning models.\nFeature selection and extraction involve evaluating different features and determining which features are most approprite for a particular machine learning task.Feature engineering refers to the process of developing and applying methods to select, transform, or construct features. This process can involve automated techniques as well as the knowledge of the domain expert. Automating feature engineering can lead to feature learning, in which a machine learning system learns useful features from data rather than relying entirely on manually defined features.\n\n\nSee also\nCovariate\nDimensionality reduction\nFeature engineering\nHashing trick\nStatistical classification\nExplainable artificial intelligence\n\n\nReferences", "categories": ["All articles needing additional references", "All articles with style issues", "Articles needing additional references from December 2014", "Articles with short description", "CS1 maint: work parameter with ISBN", "Data mining", "Machine learning", "Pattern recognition", "Short description is different from Wikidata", "Wikipedia articles with style issues from August 2025"], "references": ["https://www.jstor.org/action/doBasicSearch?Query=%22Feature%22+machine+learning&acc=on&wc=on", "https://www.sciencedirect.com/science/article/pii/S0957417408001309", "https://ieeexplore.ieee.org/abstract/document/5402574/", "https://books.google.com/books?id=aaDbBwAAQBAJ", "https://www.google.com/search?as_eq=wikipedia&q=%22Feature%22+machine+learning", "https://www.google.com/search?tbm=nws&q=%22Feature%22+machine+learning+-wikipedia&tbs=ar:1", "https://www.google.com/search?&q=%22Feature%22+machine+learning&tbs=bkt:s&tbm=bks", "https://www.google.com/search?tbs=bks:1&q=%22Feature%22+machine+learning+-wikipedia", "https://scholar.google.com/scholar?q=%22Feature%22+machine+learning", "https://books.google.com/books?id=eBSgoAEACAAJ", "https://web.stanford.edu/~jurafsky/slp3/14.pdf", "http://link.springer.com/10.1007/s10044-013-0322-1", "https://doi.org/10.1007%2Fs10044-013-0322-1", "https://doi.org/10.1080%2F1540496X.2020.1825935", "https://doi.org/10.1109%2FICMLC58545.2023.10327921"], "images": [], "sub_niche": "International Conference on Machine Learning"} {"title": "List of computer science conferences", "url": "https://en.wikipedia.org/wiki/List_of_computer_science_conferences", "summary": "This is a list of current and past academic conferences in computer science. Only conferences with separate articles are included; within each field, the conferences are listed alphabetically by their short names.", "content": "This is a list of current and past academic conferences in computer science. Only conferences with separate articles are included; within each field, the conferences are listed alphabetically by their short names.\n\n\nGeneral\nFCRC – Federated Computing Research Conference\n\n\nAlgorithms and theory\n\nConferences accepting a broad range of topics from theoretical computer science, including algorithms, data structures, computability, computational complexity, automata theory and formal languages:\n\nCCC - Computational Complexity Conference\nFCT – International Symposium on Fundamentals of Computation Theory\nFOCS – IEEE Symposium on Foundations of Computer Science\nICALP – International Colloquium on Automata, Languages and Programming\nISAAC – International Symposium on Algorithms and Computation\nSTACS – Symposium on Theoretical Aspects of Computer Science\nSTOC – ACM Symposium on Theory of Computing\n\n\nAlgorithms\nConferences whose topic is algorithms and data structures considered broadly, but that do not include other areas of theoretical computer science such as computational complexity theory:\n\nESA – European Symposium on Algorithms\nSODA – ACM–SIAM Symposium on Discrete Algorithms\nSWAT and WADS – SWAT and WADS conferences\n\n\nGeometric algorithms\nConferences on computational geometry, graph drawing, and other application areas of geometric computing:\n\nGD – International Symposium on Graph Drawing\nSoCG – Symposium on Computational Geometry\n\n\nOther specialized subtopics\nCIAA – International Conference on Implementation and Application of Automata\nCCC – Computational Complexity Conference\nDCFS – International Workshop on Descriptional Complexity of Formal Systems\nDLT – International Conference on Developments in Language Theory\nISSAC – International Symposium on Symbolic and Algebraic Computation\nRP – International Conference on Reachability Problems\nSEA – Symposium on Experimental Algorithms\n\n\nLanguages and software\n\n\nProgramming languages\nConferences on programming languages, programming language theory and compilers:\n\nCC International Conference on Compiler Construction\nESOP – ETAPS European Symposium on Programming\nHOPL – ACM SIGPLAN History of Programming Languages Conference\nICFP – ACM SIGPLAN International Conference on Functional Programming\nICLP – ALP International Conference on Logic Programming\nOOPSLA – ACM SIGPLAN Conference on Object-Oriented Programming, Systems, Languages, and Applications\nPOPL – ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages\nPLDI – ACM SIGPLAN Conference on Programming Language Design and Implementation\n\n\nSoftware engineering\nConferences on software engineering:\n\nASE – IEEE/ACM International Conference on Automated Software Engineering\nICSE – International Conference on Software Engineering\nICSR – International Conference on Software Reuse\nISSRE – IEEE International Symposium on Software Reliability Engineering\nFASE – ETAPS International Conference on Fundamental Approaches to Software Engineering\nWWDC - Worldwide Developers Conference\n\n\nFormal methods and logic\nConferences on formal methods (including formal verification), logic, and automated reasoning:\n\nCAV – Computer Aided Verification\nFORTE – IFIP International Conference on Formal Techniques for Networked and Distributed Systems\nFoSSaCS – ETAPS International Conference on Foundations of Software Science and Computation Structures\nIJCAR - International Joint Conference on Automated Reasoning\nLICS – ACM–IEEE Symposium on Logic in Computer Science\nLPAR - International Conference on Logic for Programming, Artificial Intelligence and Reasoning\nTACAS – ETAPS International Conference on Tools and Algorithms for the Construction and Analysis of Systems\nRuleML - RuleML Symposium\nWoLLIC - Workshop on Logic, Language, Information and Computation\n\n\nConcurrent, distributed and parallel computing\n\nConferences on concurrent, distributed, and parallel computing, fault-tolerant systems, and dependable systems:\n\nCONCUR - International Conference on Concurrency Theory\nDISC - International Symposium on Distributed Computing\nDSN - International Conference on Dependable Systems and Networks\nICDCS - IEEE International Conference on Distributed Computing Systems\nIPDPS - IEEE International Parallel and Distributed Processing Symposium\nPODC - ACM Symposium on Principles of Distributed Computing\nSIROCCO - International Colloquium on Structural Information and Communication Complexity\nSPAA - ACM Symposium on Parallelism in Algorithms and Architectures\nSRDS - IEEE International Symposium on Reliable Distributed Systems\n\n\nHigh-performance computing\nConferences on high-performance computing, cluster computing, and grid computing:\n\nHiPC - International Conference on High Performance Computing\nSC - ACM/IEEE International Conference for High Performance Computing, Networking, Storage, and Analysis\n\n\nOperating systems\n\nConferences on operating systems, storage systems and middleware:\n\nATC - ACM SIGOPS Annual Technical Conference\nSOSP - ACM Symposium on Operating Systems Principles\nOSDI - USENIX Symposium on Operating Systems Design and Implementation\n\n\nComputer architecture\nConferences on computer architecture:\n\nASPLOS - International Conference on Architectural Support for Programming Languages and Operating Systems\nISSCC — International Solid-State Circuits Conference\nISCA - International Symposium on Computer Architecture\nMICRO - IEEE/ACM International Symposium on Microarchitecture\n\n\nComputer-aided design\nConferences on computer-aided design and electronic design automation:\n\nASP-DAC - Asia and South Pacific Design Automation Conference\nDAC - Design Automation Conference\nDATE - Design, Automation, and Test in Europe\nICCAD - International Conference on Computer-Aided Design\nISPD - International Symposium on Physical Design\n\n\nComputer networking\n\nConferences on computer networking:\n\nNSDI - USENIX Symposium on Networked Systems Design and Implementation\nGlobeCom - IEEE Global Communications Conference\nICC - IEEE International Conference on Communications\nSIGMETRICS - ACM SIGMETRICS\n\n\nWireless networks and mobile computing\nWireless networks and mobile computing, including ubiquitous and pervasive computing, wireless ad hoc networks and wireless sensor networks:\n\nEWSN - European Conference on Wireless Sensor Networks\nISWC - International Symposium on Wearable Computers\n\n\nSecurity and privacy\n\nConferences on computer security and privacy:\n\nCCS - Computer and Communications Security\nDSN - International Conference on Dependable Systems and Networks\nNDSS - Network and Distributed System Security\nS&P - IEEE Symposium on Security and Privacy\nUSENIX Security - USENIX Security Symposium\n\n\nCryptography\nCryptography conferences:\n\nANTS - Algorithmic Number Theory Symposium\nRSA - RSA Conference\n\n\nData management\nConferences on databases, information systems, information retrieval, data mining and the World Wide Web:\n\nBTW - GI Conference on Database Systems for Business, Technology and Web\nECIR - European Conference on Information Retrieval\nECIS - European Conference on Information Systems\nER - International Conference on Conceptual Modeling\nICDT - International Conference on Database Theory\nICIS - International Conference on Information Systems\nISWC - International Semantic Web Conference\nJCDL - ACM/IEEE Joint Conference on Digital Libraries\nPODS - ACM Symposium on Principles of Database Systems\nSIGMOD - ACM Special Interest Group on Management of Data\nWWW - World Wide Web Conference\n\n\nArtificial intelligence\nConferences on artificial intelligence and machine learning:\n\nAAAI - AAAI Conference on Artificial Intelligence\nAAMAS - International Conference on Autonomous Agents and Multiagent Systems\nICAPS - International Conference on Automated Planning and Scheduling\nCIBB - International Conference on Computational Intelligence Methods for Bioinformatics and Biostatistics\nECAI - European Conference on Artificial Intelligence\nECML PKDD - European Conference on Machine Learning and Principles and Practice of Knowledge Discovery in Databases\nICML - International Conference on Machine Learning\nICLR - International Conference on Learning Representations\nIJCAI - International Joint Conference on Artificial Intelligence\nISWC - International Semantic Web Conference\nNeurIPS - Conference on Neural Information Processing Systems\n\n\nEvolutionary computation\nConferences on Evolutionary computation.\n\nCEC - IEEE Congress on Evolutionary Computation\nEvoStar\nFOGA - Foundations of Genetic Algorithms\nGECCO - Genetic and Evolutionary Computation Conference\nPPSN - Parallel Problem Solving from Nature\n\n\nComputer vision\n\nConferences on computer vision (including also image analysis) and pattern recognition:\n\nCVPR - IEEE Conference on Computer Vision and Pattern Recognition\nECCV - European Conference on Computer Vision\nICCV - International Conference on Computer Vision\nSCIA - Scandinavian Conference on Image Analysis\n\n\nNatural language processing\nConferences on computational linguistics and natural language processing:\n\nEMNLP - Empirical Methods in Natural Language Processing\nCOLING - International Committee on Computational Linguistics\nTSD - Text, Speech and Dialogue\nCICLing - International Conference on Intelligent Text Processing and Computational Linguistics\n\n\nComputer graphics\n\nConferences on computer graphics, geometry processing, image processing, and multimedia:\n\nMM - ACM International Conference on Multimedia\nSGP - Symposium on Geometry Processing\nSIGGRAPH - International Conference on Computer Graphics and Interactive Techniques\n\n\nHuman–computer interaction\nConferences on human–computer interaction and user interfaces:\n\nCHI - ACM Conference on Human Factors in Computing Systems\nGI - Graphics Interface\nMobileHCI - Conference on Human-Computer Interaction with Mobile Devices and Services\nUIST - ACM Symposium on User Interface Software and Technology\nUMAP - ACM International Conference on User Modeling, Adaptation, and Personalization\n\n\nBioinformatics and computational biology\nConferences on bioinformatics and computational biology:\n\nCIBB - International Conference on Computational Intelligence Methods for Bioinformatics and Biostatistics\nISMB - Intelligent Systems for Molecular Biology\nPSB - Pacific Symposium on Biocomputing\nRECOMB - Research in Computational Molecular Biology\n\n\nSee also\nACM SIGHPC – Association for Computing Machinery's Special Interest Group on High Performance Computing\nList of computer science conference acronyms\nList of computer science journals\nOutline of computer science\n\n\nReferences\n\n\nExternal links\nDBLP database with conferences and workshops\nList of computer science conferences ranked by h-index", "categories": ["Articles with short description", "Computer science conferences", "Computing-related lists", "Lists of conferences", "Lists of scientific organizations", "Short description is different from Wikidata"], "references": ["http://www.informatik.uni-trier.de/~ley/db/conf/indexa.html", "http://www.guide2research.com/topconf"], "images": [], "sub_niche": "International Conference on Machine Learning"} {"title": "Diffusion model", "url": "https://en.wikipedia.org/wiki/Diffusion_model", "summary": "In machine learning, diffusion models, also known as diffusion-based generative models or score-based generative models, are a class of latent variable generative models. A diffusion model consists of two major components: the forward diffusion process, and the reverse sampling process. The goal of diffusion models is to learn a diffusion process for a given dataset, such that the process can generate new elements that are distributed similarly as the original dataset. A diffusion model models data as generated by a diffusion process, whereby a new datum performs a random walk with drift through the space of all possible data. A trained diffusion model can be sampled in many ways, with different efficiency and quality.\nThere are various equivalent formalisms, including Markov chains, denoi", "content": "In machine learning, diffusion models, also known as diffusion-based generative models or score-based generative models, are a class of latent variable generative models. A diffusion model consists of two major components: the forward diffusion process, and the reverse sampling process. The goal of diffusion models is to learn a diffusion process for a given dataset, such that the process can generate new elements that are distributed similarly as the original dataset. A diffusion model models data as generated by a diffusion process, whereby a new datum performs a random walk with drift through the space of all possible data. A trained diffusion model can be sampled in many ways, with different efficiency and quality.\nThere are various equivalent formalisms, including Markov chains, denoising diffusion probabilistic models, noise conditioned score networks, and stochastic differential equations. They are typically trained using variational inference. The model responsible for denoising is typically called its \"backbone\". The backbone may be of any kind, but they are typically U-nets or transformers.\nAs of 2024, diffusion models are mainly used for computer vision tasks, including image denoising, inpainting, super-resolution, image generation, and video generation. These typically involve training a neural network to sequentially denoise images blurred with Gaussian noise. The model is trained to reverse the process of adding noise to an image. After training to convergence, it can be used for image generation by starting with an image composed of random noise, and applying the network iteratively to denoise the image.\nDiffusion-based image generators have seen widespread commercial interest, such as Stable Diffusion and DALL-E. These models typically combine diffusion models with other models, such as text-encoders and cross-attention modules to allow text-conditioned generation.\nOther than computer vision, diffusion models have also found applications in natural language processing such as text generation and summarization, sound generation, and reinforcement learning.\n\n\nDenoising diffusion model\n\n\nNon-equilibrium thermodynamics\nDiffusion models were introduced in 2015 as a method to train a model that can sample from a highly complex probability distribution. They used techniques from non-equilibrium thermodynamics, especially diffusion.\nConsider, for example, how one might model the distribution of all naturally occurring photos. Each image is a point in the space of all images, and the distribution of naturally occurring photos is a \"cloud\" in space, which, by repeatedly adding noise to the images, diffuses out to the rest of the image space, until the cloud becomes all but indistinguishable from a Gaussian distribution \n \n \n \n \n \n N\n \n \n (\n 0\n ,\n I\n )\n \n \n {\\displaystyle {\\mathcal {N}}(0,I)}\n \n. A model that can approximately undo the diffusion can then be used to sample from the original distribution. This is studied in \"non-equilibrium\" thermodynamics, as the starting distribution is not in equilibrium, unlike the final distribution.\nThe equilibrium distribution is the Gaussian distribution \n \n \n \n \n \n N\n \n \n (\n 0\n ,\n I\n )\n \n \n {\\displaystyle {\\mathcal {N}}(0,I)}\n \n, with pdf \n \n \n \n ρ\n (\n x\n )\n ∝\n \n e\n \n −\n \n \n 1\n 2\n \n \n ‖\n x\n \n ‖\n \n 2\n \n \n \n \n \n \n {\\displaystyle \\rho (x)\\propto e^{-{\\frac {1}{2}}\\|x\\|^{2}}}\n \n. This is just the Maxwell–Boltzmann distribution of particles in a potential well \n \n \n \n V\n (\n x\n )\n =\n \n \n 1\n 2\n \n \n ‖\n x\n \n ‖\n \n 2\n \n \n \n \n {\\displaystyle V(x)={\\frac {1}{2}}\\|x\\|^{2}}\n \n at temperature 1. The initial distribution, being very much out of equilibrium, would diffuse towards the equilibrium distribution, making biased random steps that are a sum of pure randomness (like a Brownian walker) and gradient descent down the potential well. The randomness is necessary: if the particles were to undergo only gradient descent, then they will all fall to the origin, collapsing the distribution.\n\n\nDenoising Diffusion Probabilistic Model (DDPM)\nThe 2020 paper proposed the Denoising Diffusion Probabilistic Model (DDPM), which improves upon the previous method by variational inference.\n\n\nForward diffusion\nTo present the model, some notation is required.\n\n \n \n \n \n β\n \n 1\n \n \n ,\n .\n .\n .\n ,\n \n β\n \n T\n \n \n ∈\n (\n 0\n ,\n 1\n )\n \n \n {\\displaystyle \\beta _{1},...,\\beta _{T}\\in (0,1)}\n \n are fixed constants.\n\n \n \n \n \n α\n \n t\n \n \n :=\n 1\n −\n \n β\n \n t\n \n \n \n \n {\\displaystyle \\alpha _{t}:=1-\\beta _{t}}\n \n\n \n \n \n \n \n \n \n α\n ¯\n \n \n \n \n t\n \n \n :=\n \n α\n \n 1\n \n \n ⋯\n \n α\n \n t\n \n \n \n \n {\\displaystyle {\\bar {\\alpha }}_{t}:=\\alpha _{1}\\cdots \\alpha _{t}}\n \n\n \n \n \n \n σ\n \n t\n \n \n :=\n \n \n 1\n −\n \n \n \n \n α\n ¯\n \n \n \n \n t\n \n \n \n \n \n \n {\\displaystyle \\sigma _{t}:={\\sqrt {1-{\\bar {\\alpha }}_{t}}}}\n \n\n \n \n \n \n \n \n \n σ\n ~\n \n \n \n \n t\n \n \n :=\n \n \n \n σ\n \n t\n −\n 1\n \n \n \n σ\n \n t\n \n \n \n \n \n \n \n β\n \n t\n \n \n \n \n \n \n {\\displaystyle {\\tilde {\\sigma }}_{t}:={\\frac {\\sigma _{t-1}}{\\sigma _{t}}}{\\sqrt {\\beta _{t}}}}\n \n\n \n \n \n \n \n \n \n μ\n ~\n \n \n \n \n t\n \n \n (\n \n x\n \n t\n \n \n ,\n \n x\n \n 0\n \n \n )\n :=\n \n \n \n \n \n \n α\n \n t\n \n \n \n \n (\n 1\n −\n \n \n \n \n α\n ¯\n \n \n \n \n t\n −\n 1\n \n \n )\n \n x\n \n t\n \n \n +\n \n \n \n \n \n \n α\n ¯\n \n \n \n \n t\n −\n 1\n \n \n \n \n (\n 1\n −\n \n α\n \n t\n \n \n )\n \n x\n \n 0\n \n \n \n \n σ\n \n t\n \n \n 2\n \n \n \n \n \n \n {\\displaystyle {\\tilde {\\mu }}_{t}(x_{t},x_{0}):={\\frac {{\\sqrt {\\alpha _{t}}}(1-{\\bar {\\alpha }}_{t-1})x_{t}+{\\sqrt {{\\bar {\\alpha }}_{t-1}}}(1-\\alpha _{t})x_{0}}{\\sigma _{t}^{2}}}}\n \n\n \n \n \n \n \n N\n \n \n (\n μ\n ,\n Σ\n )\n \n \n {\\displaystyle {\\mathcal {N}}(\\mu ,\\Sigma )}\n \n is the Gaussian distribution with mean \n \n \n \n μ\n \n \n {\\displaystyle \\mu }\n \n and variance \n \n \n \n Σ\n \n \n {\\displaystyle \\Sigma }\n \n, and \n \n \n \n \n \n N\n \n \n (\n x\n \n |\n \n μ\n ,\n Σ\n )\n \n \n {\\displaystyle {\\mathcal {N}}(x|\\mu ,\\Sigma )}\n \n is the probability density at \n \n \n \n x\n \n \n {\\displaystyle x}\n \n.\nA vertical bar denotes conditioning.\nA forward diffusion process starts at some starting point \n \n \n \n \n x\n \n 0\n \n \n ∼\n q\n \n \n {\\displaystyle x_{0}\\sim q}\n \n, where \n \n \n \n q\n \n \n {\\displaystyle q}\n \n is the probability distribution to be learned, then repeatedly adds noise to it by\n \n \n \n \n x\n \n t\n \n \n =\n \n \n 1\n −\n \n β\n \n t\n \n \n \n \n \n x\n \n t\n −\n 1\n \n \n +\n \n \n \n β\n \n t\n \n \n \n \n \n z\n \n t\n \n \n \n \n {\\displaystyle x_{t}={\\sqrt {1-\\beta _{t}}}x_{t-1}+{\\sqrt {\\beta _{t}}}z_{t}}\n \nwhere \n \n \n \n \n z\n \n 1\n \n \n ,\n .\n .\n .\n ,\n \n z\n \n T\n \n \n \n \n {\\displaystyle z_{1},...,z_{T}}\n \n are IID (Independent and identically distributed random variables) samples from \n \n \n \n \n \n N\n \n \n (\n 0\n ,\n I\n )\n \n \n {\\displaystyle {\\mathcal {N}}(0,I)}\n \n. The coefficients \n \n \n \n \n \n 1\n −\n \n β\n \n t\n \n \n \n \n \n \n {\\displaystyle {\\sqrt {1-\\beta _{t}}}}\n \n and \n \n \n \n \n \n \n β\n \n t\n \n \n \n \n \n \n {\\displaystyle {\\sqrt {\\beta _{t}}}}\n \n ensure that \n \n \n \n \n \n Var\n \n \n (\n \n X\n \n t\n \n \n )\n =\n I\n \n \n {\\displaystyle {\\mbox{Var}}(X_{t})=I}\n \n assuming that \n \n \n \n \n \n Var\n \n \n (\n \n X\n \n 0\n \n \n )\n =\n I\n \n \n {\\displaystyle {\\mbox{Var}}(X_{0})=I}\n \n. The values of \n \n \n \n \n β\n \n t\n \n \n \n \n {\\displaystyle \\beta _{t}}\n \n are chosen such that for any starting distribution of \n \n \n \n \n x\n \n 0\n \n \n \n \n {\\displaystyle x_{0}}\n \n, if it has finite second moment, then \n \n \n \n \n lim\n \n t\n →\n ∞\n \n \n \n x\n \n t\n \n \n \n |\n \n \n x\n \n 0\n \n \n \n \n {\\displaystyle \\lim _{t\\to \\infty }x_{t}|x_{0}}\n \n converges to \n \n \n \n \n \n N\n \n \n (\n 0\n ,\n I\n )\n \n \n {\\displaystyle {\\mathcal {N}}(0,I)}\n \n.\nThe entire diffusion process then satisfies\n \n \n \n q\n (\n \n x\n \n 0\n :\n T\n \n \n )\n =\n q\n (\n \n x\n \n 0\n \n \n )\n q\n (\n \n x\n \n 1\n \n \n \n |\n \n \n x\n \n 0\n \n \n )\n ⋯\n q\n (\n \n x\n \n T\n \n \n \n |\n \n \n x\n \n T\n −\n 1\n \n \n )\n =\n q\n (\n \n x\n \n 0\n \n \n )\n \n \n N\n \n \n (\n \n x\n \n 1\n \n \n \n |\n \n \n \n \n α\n \n 1\n \n \n \n \n \n x\n \n 0\n \n \n ,\n \n β\n \n 1\n \n \n I\n )\n ⋯\n \n \n N\n \n \n (\n \n x\n \n T\n \n \n \n |\n \n \n \n \n α\n \n T\n \n \n \n \n \n x\n \n T\n −\n 1\n \n \n ,\n \n β\n \n T\n \n \n I\n )\n \n \n {\\displaystyle q(x_{0:T})=q(x_{0})q(x_{1}|x_{0})\\cdots q(x_{T}|x_{T-1})=q(x_{0}){\\mathcal {N}}(x_{1}|{\\sqrt {\\alpha _{1}}}x_{0},\\beta _{1}I)\\cdots {\\mathcal {N}}(x_{T}|{\\sqrt {\\alpha _{T}}}x_{T-1},\\beta _{T}I)}\n \nor\n \n \n \n ln\n ⁡\n q\n (\n \n x\n \n 0\n :\n T\n \n \n )\n =\n ln\n ⁡\n q\n (\n \n x\n \n 0\n \n \n )\n −\n \n ∑\n \n t\n =\n 1\n \n \n T\n \n \n \n \n 1\n \n 2\n \n β\n \n t\n \n \n \n \n \n ‖\n \n x\n \n t\n \n \n −\n \n \n 1\n −\n \n β\n \n t\n \n \n \n \n \n x\n \n t\n −\n 1\n \n \n \n ‖\n \n 2\n \n \n +\n C\n \n \n {\\displaystyle \\ln q(x_{0:T})=\\ln q(x_{0})-\\sum _{t=1}^{T}{\\frac {1}{2\\beta _{t}}}\\|x_{t}-{\\sqrt {1-\\beta _{t}}}x_{t-1}\\|^{2}+C}\n \nwhere \n \n \n \n C\n \n \n {\\displaystyle C}\n \n is a normalization constant and often omitted. In particular, we note that \n \n \n \n \n x\n \n 1\n :\n T\n \n \n \n |\n \n \n x\n \n 0\n \n \n \n \n {\\displaystyle x_{1:T}|x_{0}}\n \n is a Gaussian process, which affords us considerable freedom in reparameterization. For example, by standard manipulation with Gaussian process, \n \n \n \n \n x\n \n t\n \n \n \n |\n \n \n x\n \n 0\n \n \n ∼\n N\n \n (\n \n \n \n \n \n \n \n α\n ¯\n \n \n \n \n t\n \n \n \n \n \n x\n \n 0\n \n \n ,\n \n σ\n \n t\n \n \n 2\n \n \n I\n \n )\n \n \n \n {\\displaystyle x_{t}|x_{0}\\sim N\\left({\\sqrt {{\\bar {\\alpha }}_{t}}}x_{0},\\sigma _{t}^{2}I\\right)}\n \n\n \n \n \n \n x\n \n t\n −\n 1\n \n \n \n |\n \n \n x\n \n t\n \n \n ,\n \n x\n \n 0\n \n \n ∼\n \n \n N\n \n \n (\n \n \n \n \n μ\n ~\n \n \n \n \n t\n \n \n (\n \n x\n \n t\n \n \n ,\n \n x\n \n 0\n \n \n )\n ,\n \n \n \n \n σ\n ~\n \n \n \n \n t\n \n \n 2\n \n \n I\n )\n \n \n {\\displaystyle x_{t-1}|x_{t},x_{0}\\sim {\\mathcal {N}}({\\tilde {\\mu }}_{t}(x_{t},x_{0}),{\\tilde {\\sigma }}_{t}^{2}I)}\n \nIn particular, notice that for large \n \n \n \n t\n \n \n {\\displaystyle t}\n \n, the variable \n \n \n \n \n x\n \n t\n \n \n \n |\n \n \n x\n \n 0\n \n \n ∼\n N\n \n (\n \n \n \n \n \n \n \n α\n ¯\n \n \n \n \n t\n \n \n \n \n \n x\n \n 0\n \n \n ,\n \n σ\n \n t\n \n \n 2\n \n \n I\n \n )\n \n \n \n {\\displaystyle x_{t}|x_{0}\\sim N\\left({\\sqrt {{\\bar {\\alpha }}_{t}}}x_{0},\\sigma _{t}^{2}I\\right)}\n \n converges to \n \n \n \n \n \n N\n \n \n (\n 0\n ,\n I\n )\n \n \n {\\displaystyle {\\mathcal {N}}(0,I)}\n \n. That is, after a long enough diffusion process, we end up with some \n \n \n \n \n x\n \n T\n \n \n \n \n {\\displaystyle x_{T}}\n \n that is very close to \n \n \n \n \n \n N\n \n \n (\n 0\n ,\n I\n )\n \n \n {\\displaystyle {\\mathcal {N}}(0,I)}\n \n, with all traces of the original \n \n \n \n \n x\n \n 0\n \n \n ∼\n q\n \n \n {\\displaystyle x_{0}\\sim q}\n \n gone.\nFor example, since\n \n \n \n \n x\n \n t\n \n \n \n |\n \n \n x\n \n 0\n \n \n ∼\n N\n \n (\n \n \n \n \n \n \n \n α\n ¯\n \n \n \n \n t\n \n \n \n \n \n x\n \n 0\n \n \n ,\n \n σ\n \n t\n \n \n 2\n \n \n I\n \n )\n \n \n \n {\\displaystyle x_{t}|x_{0}\\sim N\\left({\\sqrt {{\\bar {\\alpha }}_{t}}}x_{0},\\sigma _{t}^{2}I\\right)}\n \nwe can sample \n \n \n \n \n x\n \n t\n \n \n \n |\n \n \n x\n \n 0\n \n \n \n \n {\\displaystyle x_{t}|x_{0}}\n \n directly \"in one step\", instead of going through all the intermediate steps \n \n \n \n \n x\n \n 1\n \n \n ,\n \n x\n \n 2\n \n \n ,\n .\n .\n .\n ,\n \n x\n \n t\n −\n 1\n \n \n \n \n {\\displaystyle x_{1},x_{2},...,x_{t-1}}\n \n.\n\n\nBackward diffusion\nThe key idea of DDPM is to use a neural network parametrized by \n \n \n \n θ\n \n \n {\\displaystyle \\theta }\n \n. The network takes in two arguments \n \n \n \n \n x\n \n t\n \n \n ,\n t\n \n \n {\\displaystyle x_{t},t}\n \n, and outputs a vector \n \n \n \n \n μ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n \n \n {\\displaystyle \\mu _{\\theta }(x_{t},t)}\n \n and a matrix \n \n \n \n \n Σ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n \n \n {\\displaystyle \\Sigma _{\\theta }(x_{t},t)}\n \n, such that each step in the forward diffusion process can be approximately undone by \n \n \n \n \n x\n \n t\n −\n 1\n \n \n ∼\n \n \n N\n \n \n (\n \n μ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n ,\n \n Σ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n )\n \n \n {\\displaystyle x_{t-1}\\sim {\\mathcal {N}}(\\mu _{\\theta }(x_{t},t),\\Sigma _{\\theta }(x_{t},t))}\n \n. This then gives us a backward diffusion process \n \n \n \n \n p\n \n θ\n \n \n \n \n {\\displaystyle p_{\\theta }}\n \n defined by\n \n \n \n \n p\n \n θ\n \n \n (\n \n x\n \n T\n \n \n )\n =\n \n \n N\n \n \n (\n \n x\n \n T\n \n \n \n |\n \n 0\n ,\n I\n )\n \n \n {\\displaystyle p_{\\theta }(x_{T})={\\mathcal {N}}(x_{T}|0,I)}\n \n\n \n \n \n \n p\n \n θ\n \n \n (\n \n x\n \n t\n −\n 1\n \n \n \n |\n \n \n x\n \n t\n \n \n )\n =\n \n \n N\n \n \n (\n \n x\n \n t\n −\n 1\n \n \n \n |\n \n \n μ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n ,\n \n Σ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n )\n \n \n {\\displaystyle p_{\\theta }(x_{t-1}|x_{t})={\\mathcal {N}}(x_{t-1}|\\mu _{\\theta }(x_{t},t),\\Sigma _{\\theta }(x_{t},t))}\n \nThe goal now is to learn the parameters \n \n \n \n θ\n \n \n {\\displaystyle \\theta }\n \n such that \n \n \n \n \n p\n \n θ\n \n \n (\n \n x\n \n 0\n \n \n )\n \n \n {\\displaystyle p_{\\theta }(x_{0})}\n \n is as close to \n \n \n \n q\n (\n \n x\n \n 0\n \n \n )\n \n \n {\\displaystyle q(x_{0})}\n \n as possible. To do that, we use maximum likelihood estimation with variational inference.\n\n\nVariational inference\nThe ELBO inequality states that \n \n \n \n ln\n ⁡\n \n p\n \n θ\n \n \n (\n \n x\n \n 0\n \n \n )\n ≥\n \n E\n \n \n x\n \n 1\n :\n T\n \n \n ∼\n q\n (\n ⋅\n \n |\n \n \n x\n \n 0\n \n \n )\n \n \n [\n ln\n ⁡\n \n p\n \n θ\n \n \n (\n \n x\n \n 0\n :\n T\n \n \n )\n −\n ln\n ⁡\n q\n (\n \n x\n \n 1\n :\n T\n \n \n \n |\n \n \n x\n \n 0\n \n \n )\n ]\n \n \n {\\displaystyle \\ln p_{\\theta }(x_{0})\\geq E_{x_{1:T}\\sim q(\\cdot |x_{0})}[\\ln p_{\\theta }(x_{0:T})-\\ln q(x_{1:T}|x_{0})]}\n \n, and taking one more expectation, we get\n \n \n \n \n E\n \n \n x\n \n 0\n \n \n ∼\n q\n \n \n [\n ln\n ⁡\n \n p\n \n θ\n \n \n (\n \n x\n \n 0\n \n \n )\n ]\n ≥\n \n E\n \n \n x\n \n 0\n :\n T\n \n \n ∼\n q\n \n \n [\n ln\n ⁡\n \n p\n \n θ\n \n \n (\n \n x\n \n 0\n :\n T\n \n \n )\n −\n ln\n ⁡\n q\n (\n \n x\n \n 1\n :\n T\n \n \n \n |\n \n \n x\n \n 0\n \n \n )\n ]\n \n \n {\\displaystyle E_{x_{0}\\sim q}[\\ln p_{\\theta }(x_{0})]\\geq E_{x_{0:T}\\sim q}[\\ln p_{\\theta }(x_{0:T})-\\ln q(x_{1:T}|x_{0})]}\n \nWe see that maximizing the quantity on the right would give us a lower bound on the likelihood of observed data. This allows us to perform variational inference.\nDefine the loss function\n \n \n \n L\n (\n θ\n )\n :=\n −\n \n E\n \n \n x\n \n 0\n :\n T\n \n \n ∼\n q\n \n \n [\n ln\n ⁡\n \n p\n \n θ\n \n \n (\n \n x\n \n 0\n :\n T\n \n \n )\n −\n ln\n ⁡\n q\n (\n \n x\n \n 1\n :\n T\n \n \n \n |\n \n \n x\n \n 0\n \n \n )\n ]\n \n \n {\\displaystyle L(\\theta ):=-E_{x_{0:T}\\sim q}[\\ln p_{\\theta }(x_{0:T})-\\ln q(x_{1:T}|x_{0})]}\n \nand now the goal is to minimize the loss by stochastic gradient descent. The expression may be simplified to\n \n \n \n L\n (\n θ\n )\n =\n \n ∑\n \n t\n =\n 1\n \n \n T\n \n \n \n E\n \n \n x\n \n t\n −\n 1\n \n \n ,\n \n x\n \n t\n \n \n ∼\n q\n \n \n [\n −\n ln\n ⁡\n \n p\n \n θ\n \n \n (\n \n x\n \n t\n −\n 1\n \n \n \n |\n \n \n x\n \n t\n \n \n )\n ]\n +\n \n E\n \n \n x\n \n 0\n \n \n ∼\n q\n \n \n [\n \n D\n \n K\n L\n \n \n (\n q\n (\n \n x\n \n T\n \n \n \n |\n \n \n x\n \n 0\n \n \n )\n ‖\n \n p\n \n θ\n \n \n (\n \n x\n \n T\n \n \n )\n )\n ]\n +\n C\n \n \n {\\displaystyle L(\\theta )=\\sum _{t=1}^{T}E_{x_{t-1},x_{t}\\sim q}[-\\ln p_{\\theta }(x_{t-1}|x_{t})]+E_{x_{0}\\sim q}[D_{KL}(q(x_{T}|x_{0})\\|p_{\\theta }(x_{T}))]+C}\n \nwhere \n \n \n \n C\n \n \n {\\displaystyle C}\n \n does not depend on the parameter, and thus can be ignored. Since \n \n \n \n \n p\n \n θ\n \n \n (\n \n x\n \n T\n \n \n )\n =\n \n \n N\n \n \n (\n \n x\n \n T\n \n \n \n |\n \n 0\n ,\n I\n )\n \n \n {\\displaystyle p_{\\theta }(x_{T})={\\mathcal {N}}(x_{T}|0,I)}\n \n also does not depend on the parameter, the term \n \n \n \n \n E\n \n \n x\n \n 0\n \n \n ∼\n q\n \n \n [\n \n D\n \n K\n L\n \n \n (\n q\n (\n \n x\n \n T\n \n \n \n |\n \n \n x\n \n 0\n \n \n )\n ‖\n \n p\n \n θ\n \n \n (\n \n x\n \n T\n \n \n )\n )\n ]\n \n \n {\\displaystyle E_{x_{0}\\sim q}[D_{KL}(q(x_{T}|x_{0})\\|p_{\\theta }(x_{T}))]}\n \n can also be ignored. This leaves just \n \n \n \n L\n (\n θ\n )\n =\n \n ∑\n \n t\n =\n 1\n \n \n T\n \n \n \n L\n \n t\n \n \n \n \n {\\displaystyle L(\\theta )=\\sum _{t=1}^{T}L_{t}}\n \n with \n \n \n \n \n L\n \n t\n \n \n =\n \n E\n \n \n x\n \n t\n −\n 1\n \n \n ,\n \n x\n \n t\n \n \n ∼\n q\n \n \n [\n −\n ln\n ⁡\n \n p\n \n θ\n \n \n (\n \n x\n \n t\n −\n 1\n \n \n \n |\n \n \n x\n \n t\n \n \n )\n ]\n \n \n {\\displaystyle L_{t}=E_{x_{t-1},x_{t}\\sim q}[-\\ln p_{\\theta }(x_{t-1}|x_{t})]}\n \n to be minimized.\n\n\nNoise prediction network\nSince \n \n \n \n \n x\n \n t\n −\n 1\n \n \n \n |\n \n \n x\n \n t\n \n \n ,\n \n x\n \n 0\n \n \n ∼\n \n \n N\n \n \n (\n \n \n \n \n μ\n ~\n \n \n \n \n t\n \n \n (\n \n x\n \n t\n \n \n ,\n \n x\n \n 0\n \n \n )\n ,\n \n \n \n \n σ\n ~\n \n \n \n \n t\n \n \n 2\n \n \n I\n )\n \n \n {\\displaystyle x_{t-1}|x_{t},x_{0}\\sim {\\mathcal {N}}({\\tilde {\\mu }}_{t}(x_{t},x_{0}),{\\tilde {\\sigma }}_{t}^{2}I)}\n \n, this suggests that we should use \n \n \n \n \n μ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n =\n \n \n \n \n μ\n ~\n \n \n \n \n t\n \n \n (\n \n x\n \n t\n \n \n ,\n \n x\n \n 0\n \n \n )\n \n \n {\\displaystyle \\mu _{\\theta }(x_{t},t)={\\tilde {\\mu }}_{t}(x_{t},x_{0})}\n \n; however, the network does not have access to \n \n \n \n \n x\n \n 0\n \n \n \n \n {\\displaystyle x_{0}}\n \n, and so it has to estimate it instead. Now, since \n \n \n \n \n x\n \n t\n \n \n \n |\n \n \n x\n \n 0\n \n \n ∼\n N\n \n (\n \n \n \n \n \n \n \n α\n ¯\n \n \n \n \n t\n \n \n \n \n \n x\n \n 0\n \n \n ,\n \n σ\n \n t\n \n \n 2\n \n \n I\n \n )\n \n \n \n {\\displaystyle x_{t}|x_{0}\\sim N\\left({\\sqrt {{\\bar {\\alpha }}_{t}}}x_{0},\\sigma _{t}^{2}I\\right)}\n \n, we may write \n \n \n \n \n x\n \n t\n \n \n =\n \n \n \n \n \n \n α\n ¯\n \n \n \n \n t\n \n \n \n \n \n x\n \n 0\n \n \n +\n \n σ\n \n t\n \n \n z\n \n \n {\\displaystyle x_{t}={\\sqrt {{\\bar {\\alpha }}_{t}}}x_{0}+\\sigma _{t}z}\n \n, where \n \n \n \n z\n \n \n {\\displaystyle z}\n \n is some unknown Gaussian noise. Now we see that estimating \n \n \n \n \n x\n \n 0\n \n \n \n \n {\\displaystyle x_{0}}\n \n is equivalent to estimating \n \n \n \n z\n \n \n {\\displaystyle z}\n \n.\nTherefore, let the network output a noise vector \n \n \n \n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n \n \n {\\displaystyle \\epsilon _{\\theta }(x_{t},t)}\n \n, and let it predict\n \n \n \n \n μ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n =\n \n \n \n \n μ\n ~\n \n \n \n \n t\n \n \n \n (\n \n \n x\n \n t\n \n \n ,\n \n \n \n \n x\n \n t\n \n \n −\n \n σ\n \n t\n \n \n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n \n \n \n \n \n \n α\n ¯\n \n \n \n \n t\n \n \n \n \n \n \n )\n \n =\n \n \n \n \n x\n \n t\n \n \n −\n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n \n β\n \n t\n \n \n \n /\n \n \n σ\n \n t\n \n \n \n \n \n α\n \n t\n \n \n \n \n \n \n \n {\\displaystyle \\mu _{\\theta }(x_{t},t)={\\tilde {\\mu }}_{t}\\left(x_{t},{\\frac {x_{t}-\\sigma _{t}\\epsilon _{\\theta }(x_{t},t)}{\\sqrt {{\\bar {\\alpha }}_{t}}}}\\right)={\\frac {x_{t}-\\epsilon _{\\theta }(x_{t},t)\\beta _{t}/\\sigma _{t}}{\\sqrt {\\alpha _{t}}}}}\n \nIt remains to design \n \n \n \n \n Σ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n \n \n {\\displaystyle \\Sigma _{\\theta }(x_{t},t)}\n \n. The DDPM paper suggested not learning it (since it resulted in \"unstable training and poorer sample quality\"), but fixing it at some value \n \n \n \n \n Σ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n =\n \n ζ\n \n t\n \n \n 2\n \n \n I\n \n \n {\\displaystyle \\Sigma _{\\theta }(x_{t},t)=\\zeta _{t}^{2}I}\n \n, where either \n \n \n \n \n ζ\n \n t\n \n \n 2\n \n \n =\n \n β\n \n t\n \n \n \n or \n \n \n \n \n \n σ\n ~\n \n \n \n \n t\n \n \n 2\n \n \n \n \n {\\displaystyle \\zeta _{t}^{2}=\\beta _{t}{\\text{ or }}{\\tilde {\\sigma }}_{t}^{2}}\n \n yielded similar performance.\nWith this, the loss simplifies to \n \n \n \n \n L\n \n t\n \n \n =\n \n \n \n β\n \n t\n \n \n 2\n \n \n \n 2\n \n α\n \n t\n \n \n \n σ\n \n t\n \n \n 2\n \n \n \n ζ\n \n t\n \n \n 2\n \n \n \n \n \n \n E\n \n \n x\n \n 0\n \n \n ∼\n q\n ;\n z\n ∼\n \n \n N\n \n \n (\n 0\n ,\n I\n )\n \n \n \n [\n \n \n ‖\n \n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n −\n z\n \n ‖\n \n \n 2\n \n \n ]\n \n +\n C\n \n \n {\\displaystyle L_{t}={\\frac {\\beta _{t}^{2}}{2\\alpha _{t}\\sigma _{t}^{2}\\zeta _{t}^{2}}}E_{x_{0}\\sim q;z\\sim {\\mathcal {N}}(0,I)}\\left[\\left\\|\\epsilon _{\\theta }(x_{t},t)-z\\right\\|^{2}\\right]+C}\n \nwhich may be minimized by stochastic gradient descent. The paper noted empirically that an even simpler loss function\n \n \n \n \n L\n \n s\n i\n m\n p\n l\n e\n ,\n t\n \n \n =\n \n E\n \n \n x\n \n 0\n \n \n ∼\n q\n ;\n z\n ∼\n \n \n N\n \n \n (\n 0\n ,\n I\n )\n \n \n \n [\n \n \n ‖\n \n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n −\n z\n \n ‖\n \n \n 2\n \n \n ]\n \n \n \n {\\displaystyle L_{simple,t}=E_{x_{0}\\sim q;z\\sim {\\mathcal {N}}(0,I)}\\left[\\left\\|\\epsilon _{\\theta }(x_{t},t)-z\\right\\|^{2}\\right]}\n \nresulted in better models.\n\n\nBackward diffusion process\nAfter a noise prediction network is trained, it can be used for generating data points in the original distribution in a loop as follows:\n\nCompute the noise estimate \n \n \n \n ϵ\n ←\n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n \n \n {\\displaystyle \\epsilon \\leftarrow \\epsilon _{\\theta }(x_{t},t)}\n \n\nCompute the original data estimate \n \n \n \n \n \n \n \n x\n ~\n \n \n \n \n 0\n \n \n ←\n (\n \n x\n \n t\n \n \n −\n \n σ\n \n t\n \n \n ϵ\n )\n \n /\n \n \n \n \n \n \n \n α\n ¯\n \n \n \n \n t\n \n \n \n \n \n \n {\\displaystyle {\\tilde {x}}_{0}\\leftarrow (x_{t}-\\sigma _{t}\\epsilon )/{\\sqrt {{\\bar {\\alpha }}_{t}}}}\n \n\nSample the previous data \n \n \n \n \n x\n \n t\n −\n 1\n \n \n ∼\n \n \n N\n \n \n (\n \n \n \n \n μ\n ~\n \n \n \n \n t\n \n \n (\n \n x\n \n t\n \n \n ,\n \n \n \n \n x\n ~\n \n \n \n \n 0\n \n \n )\n ,\n \n \n \n \n σ\n ~\n \n \n \n \n t\n \n \n 2\n \n \n I\n )\n \n \n {\\displaystyle x_{t-1}\\sim {\\mathcal {N}}({\\tilde {\\mu }}_{t}(x_{t},{\\tilde {x}}_{0}),{\\tilde {\\sigma }}_{t}^{2}I)}\n \n\nChange time \n \n \n \n t\n ←\n t\n −\n 1\n \n \n {\\displaystyle t\\leftarrow t-1}\n \n\n\nScore-based generative model\nScore-based generative model is another formulation of diffusion modelling. They are also called noise conditional score network (NCSN) or score-matching with Langevin dynamics (SMLD).\n\n\nScore matching\n\n\nThe idea of score functions\nConsider the problem of image generation. Let \n \n \n \n x\n \n \n {\\displaystyle x}\n \n represent an image, and let \n \n \n \n q\n (\n x\n )\n \n \n {\\displaystyle q(x)}\n \n be the probability distribution over all possible images. If we have \n \n \n \n q\n (\n x\n )\n \n \n {\\displaystyle q(x)}\n \n itself, then we can say for certain how likely a certain image is. However, this is intractable in general.\nMost often, we are uninterested in knowing the absolute probability of a certain image. Instead, we are usually only interested in knowing how likely a certain image is compared to its immediate neighbors — e.g. how much more likely is an image of cat compared to some small variants of it? Is it more likely if the image contains two whiskers, or three, or with some Gaussian noise added?\nConsequently, we are actually quite uninterested in \n \n \n \n q\n (\n x\n )\n \n \n {\\displaystyle q(x)}\n \n itself, but rather, \n \n \n \n \n ∇\n \n x\n \n \n ln\n ⁡\n q\n (\n x\n )\n \n \n {\\displaystyle \\nabla _{x}\\ln q(x)}\n \n. This has two major effects:\n\nOne, we no longer need to normalize \n \n \n \n q\n (\n x\n )\n \n \n {\\displaystyle q(x)}\n \n, but can use any \n \n \n \n \n \n \n q\n ~\n \n \n \n (\n x\n )\n =\n C\n q\n (\n x\n )\n \n \n {\\displaystyle {\\tilde {q}}(x)=Cq(x)}\n \n, where \n \n \n \n C\n =\n ∫\n \n \n \n q\n ~\n \n \n \n (\n x\n )\n d\n x\n >\n 0\n \n \n {\\displaystyle C=\\int {\\tilde {q}}(x)dx>0}\n \n is any unknown constant that is of no concern to us.\nTwo, we are comparing \n \n \n \n q\n (\n x\n )\n \n \n {\\displaystyle q(x)}\n \n neighbors \n \n \n \n q\n (\n x\n +\n d\n x\n )\n \n \n {\\displaystyle q(x+dx)}\n \n, by \n \n \n \n \n \n \n q\n (\n x\n )\n \n \n q\n (\n x\n +\n d\n x\n )\n \n \n \n =\n \n e\n \n −\n ⟨\n \n ∇\n \n x\n \n \n ln\n ⁡\n q\n ,\n d\n x\n ⟩\n \n \n \n \n {\\displaystyle {\\frac {q(x)}{q(x+dx)}}=e^{-\\langle \\nabla _{x}\\ln q,dx\\rangle }}\n \n\nLet the score function be \n \n \n \n s\n (\n x\n )\n :=\n \n ∇\n \n x\n \n \n ln\n ⁡\n q\n (\n x\n )\n \n \n {\\displaystyle s(x):=\\nabla _{x}\\ln q(x)}\n \n; then consider what we can do with \n \n \n \n s\n (\n x\n )\n \n \n {\\displaystyle s(x)}\n \n.\nAs it turns out, \n \n \n \n s\n (\n x\n )\n \n \n {\\displaystyle s(x)}\n \n allows us to sample from \n \n \n \n q\n (\n x\n )\n \n \n {\\displaystyle q(x)}\n \n using thermodynamics. Specifically, if we have a potential energy function \n \n \n \n U\n (\n x\n )\n =\n −\n ln\n ⁡\n q\n (\n x\n )\n \n \n {\\displaystyle U(x)=-\\ln q(x)}\n \n, and a lot of particles in the potential well, then the distribution at thermodynamic equilibrium is the Boltzmann distribution \n \n \n \n \n q\n \n U\n \n \n (\n x\n )\n ∝\n \n e\n \n −\n U\n (\n x\n )\n \n /\n \n \n k\n \n B\n \n \n T\n \n \n =\n q\n (\n x\n \n )\n \n 1\n \n /\n \n \n k\n \n B\n \n \n T\n \n \n \n \n {\\displaystyle q_{U}(x)\\propto e^{-U(x)/k_{B}T}=q(x)^{1/k_{B}T}}\n \n. At temperature \n \n \n \n \n k\n \n B\n \n \n T\n =\n 1\n \n \n {\\displaystyle k_{B}T=1}\n \n, the Boltzmann distribution is exactly \n \n \n \n q\n (\n x\n )\n \n \n {\\displaystyle q(x)}\n \n.\nTherefore, to model \n \n \n \n q\n (\n x\n )\n \n \n {\\displaystyle q(x)}\n \n, we may start with a particle sampled at any convenient distribution (such as the standard Gaussian distribution), then simulate the motion of the particle forwards according to the Langevin equation\n\n \n \n \n d\n \n x\n \n t\n \n \n =\n −\n \n ∇\n \n \n x\n \n t\n \n \n \n \n U\n (\n \n x\n \n t\n \n \n )\n d\n t\n +\n d\n \n W\n \n t\n \n \n \n \n {\\displaystyle dx_{t}=-\\nabla _{x_{t}}U(x_{t})dt+dW_{t}}\n \n\nand the Boltzmann distribution is, by Fokker-Planck equation, the unique thermodynamic equilibrium. So no matter what distribution \n \n \n \n \n x\n \n 0\n \n \n \n \n {\\displaystyle x_{0}}\n \n has, the distribution of \n \n \n \n \n x\n \n t\n \n \n \n \n {\\displaystyle x_{t}}\n \n converges in distribution to \n \n \n \n q\n \n \n {\\displaystyle q}\n \n as \n \n \n \n t\n →\n ∞\n \n \n {\\displaystyle t\\to \\infty }\n \n.\n\n\nLearning the score function\nGiven a density \n \n \n \n q\n \n \n {\\displaystyle q}\n \n, we wish to learn a score function approximation \n \n \n \n \n f\n \n θ\n \n \n ≈\n ∇\n ln\n ⁡\n q\n \n \n {\\displaystyle f_{\\theta }\\approx \\nabla \\ln q}\n \n. This is score matching. Typically, score matching is formalized as minimizing Fisher divergence function \n \n \n \n \n E\n \n q\n \n \n [\n ‖\n \n f\n \n θ\n \n \n (\n x\n )\n −\n ∇\n ln\n ⁡\n q\n (\n x\n )\n \n ‖\n \n 2\n \n \n ]\n \n \n {\\displaystyle E_{q}[\\|f_{\\theta }(x)-\\nabla \\ln q(x)\\|^{2}]}\n \n. By expanding the integral, and performing an integration by parts, \n \n \n \n \n E\n \n q\n \n \n [\n ‖\n \n f\n \n θ\n \n \n (\n x\n )\n −\n ∇\n ln\n ⁡\n q\n (\n x\n )\n \n ‖\n \n 2\n \n \n ]\n =\n \n E\n \n q\n \n \n [\n ‖\n \n f\n \n θ\n \n \n \n ‖\n \n 2\n \n \n +\n 2\n ∇\n ⋅\n \n f\n \n θ\n \n \n ]\n +\n C\n \n \n {\\displaystyle E_{q}[\\|f_{\\theta }(x)-\\nabla \\ln q(x)\\|^{2}]=E_{q}[\\|f_{\\theta }\\|^{2}+2\\nabla \\cdot f_{\\theta }]+C}\n \ngiving us a loss function, also known as the Hyvärinen scoring rule, that can be minimized by stochastic gradient descent.\n\n\nAnnealing the score function\nSuppose we need to model the distribution of images, and we want \n \n \n \n \n x\n \n 0\n \n \n ∼\n \n \n N\n \n \n (\n 0\n ,\n I\n )\n \n \n {\\displaystyle x_{0}\\sim {\\mathcal {N}}(0,I)}\n \n, a white-noise image. Now, most white-noise images do not look like real images, so \n \n \n \n q\n (\n \n x\n \n 0\n \n \n )\n ≈\n 0\n \n \n {\\displaystyle q(x_{0})\\approx 0}\n \n for large swaths of \n \n \n \n \n x\n \n 0\n \n \n ∼\n \n \n N\n \n \n (\n 0\n ,\n I\n )\n \n \n {\\displaystyle x_{0}\\sim {\\mathcal {N}}(0,I)}\n \n. This presents a problem for learning the score function, because if there are no samples around a certain point, then we can't learn the score function at that point. If we do not know the score function \n \n \n \n \n ∇\n \n \n x\n \n t\n \n \n \n \n ln\n ⁡\n q\n (\n \n x\n \n t\n \n \n )\n \n \n {\\displaystyle \\nabla _{x_{t}}\\ln q(x_{t})}\n \n at that point, then we cannot impose the time-evolution equation on a particle:\n \n \n \n d\n \n x\n \n t\n \n \n =\n \n ∇\n \n \n x\n \n t\n \n \n \n \n ln\n ⁡\n q\n (\n \n x\n \n t\n \n \n )\n d\n t\n +\n d\n \n W\n \n t\n \n \n \n \n {\\displaystyle dx_{t}=\\nabla _{x_{t}}\\ln q(x_{t})dt+dW_{t}}\n \nTo deal with this problem, we perform annealing. If \n \n \n \n q\n \n \n {\\displaystyle q}\n \n is too different from a white-noise distribution, then progressively add noise until it is indistinguishable from one. That is, we perform a forward diffusion, then learn the score function, then use the score function to perform a backward diffusion.\n\n\nContinuous diffusion processes\n\n\nForward diffusion process\nConsider again the forward diffusion process, but this time in continuous time:\n \n \n \n \n x\n \n t\n \n \n =\n \n \n 1\n −\n \n β\n \n t\n \n \n \n \n \n x\n \n t\n −\n 1\n \n \n +\n \n \n \n β\n \n t\n \n \n \n \n \n z\n \n t\n \n \n \n \n {\\displaystyle x_{t}={\\sqrt {1-\\beta _{t}}}x_{t-1}+{\\sqrt {\\beta _{t}}}z_{t}}\n \nBy taking the \n \n \n \n \n β\n \n t\n \n \n →\n β\n (\n t\n )\n d\n t\n ,\n \n \n d\n t\n \n \n \n z\n \n t\n \n \n →\n d\n \n W\n \n t\n \n \n \n \n {\\displaystyle \\beta _{t}\\to \\beta (t)dt,{\\sqrt {dt}}z_{t}\\to dW_{t}}\n \n limit, we obtain a continuous diffusion process, in the form of a stochastic differential equation:\n \n \n \n d\n \n x\n \n t\n \n \n =\n −\n \n \n 1\n 2\n \n \n β\n (\n t\n )\n \n x\n \n t\n \n \n d\n t\n +\n \n \n β\n (\n t\n )\n \n \n d\n \n W\n \n t\n \n \n \n \n {\\displaystyle dx_{t}=-{\\frac {1}{2}}\\beta (t)x_{t}dt+{\\sqrt {\\beta (t)}}dW_{t}}\n \nwhere \n \n \n \n \n W\n \n t\n \n \n \n \n {\\displaystyle W_{t}}\n \n is a Wiener process (multidimensional Brownian motion).\nNow, the equation is exactly a special case of the overdamped Langevin equation\n \n \n \n d\n \n x\n \n t\n \n \n =\n −\n \n \n D\n \n \n k\n \n B\n \n \n T\n \n \n \n (\n \n ∇\n \n x\n \n \n U\n )\n d\n t\n +\n \n \n 2\n D\n \n \n d\n \n W\n \n t\n \n \n \n \n {\\displaystyle dx_{t}=-{\\frac {D}{k_{B}T}}(\\nabla _{x}U)dt+{\\sqrt {2D}}dW_{t}}\n \nwhere \n \n \n \n D\n \n \n {\\displaystyle D}\n \n is diffusion tensor, \n \n \n \n T\n \n \n {\\displaystyle T}\n \n is temperature, and \n \n \n \n U\n \n \n {\\displaystyle U}\n \n is potential energy field. If we substitute in \n \n \n \n D\n =\n \n \n 1\n 2\n \n \n β\n (\n t\n )\n I\n ,\n \n k\n \n B\n \n \n T\n =\n 1\n ,\n U\n =\n \n \n 1\n 2\n \n \n ‖\n x\n \n ‖\n \n 2\n \n \n \n \n {\\displaystyle D={\\frac {1}{2}}\\beta (t)I,k_{B}T=1,U={\\frac {1}{2}}\\|x\\|^{2}}\n \n, we recover the above equation. This explains why the phrase \"Langevin dynamics\" is sometimes used in diffusion models.\nNow the above equation is for the stochastic motion of a single particle. Suppose we have a cloud of particles distributed according to \n \n \n \n q\n \n \n {\\displaystyle q}\n \n at time \n \n \n \n t\n =\n 0\n \n \n {\\displaystyle t=0}\n \n, then after a long time, the cloud of particles would settle into the stable distribution of \n \n \n \n \n \n N\n \n \n (\n 0\n ,\n I\n )\n \n \n {\\displaystyle {\\mathcal {N}}(0,I)}\n \n. Let \n \n \n \n \n ρ\n \n t\n \n \n \n \n {\\displaystyle \\rho _{t}}\n \n be the density of the cloud of particles at time \n \n \n \n t\n \n \n {\\displaystyle t}\n \n, then we have\n \n \n \n \n ρ\n \n 0\n \n \n =\n q\n ;\n \n \n ρ\n \n T\n \n \n ≈\n \n \n N\n \n \n (\n 0\n ,\n I\n )\n \n \n {\\displaystyle \\rho _{0}=q;\\quad \\rho _{T}\\approx {\\mathcal {N}}(0,I)}\n \nand the goal is to somehow reverse the process, so that we can start at the end and diffuse back to the beginning.\nBy Fokker-Planck equation, the density of the cloud evolves according to\n \n \n \n \n ∂\n \n t\n \n \n ln\n ⁡\n \n ρ\n \n t\n \n \n =\n \n \n 1\n 2\n \n \n β\n (\n t\n )\n \n (\n \n n\n +\n (\n x\n +\n ∇\n ln\n ⁡\n \n ρ\n \n t\n \n \n )\n ⋅\n ∇\n ln\n ⁡\n \n ρ\n \n t\n \n \n +\n Δ\n ln\n ⁡\n \n ρ\n \n t\n \n \n \n )\n \n \n \n {\\displaystyle \\partial _{t}\\ln \\rho _{t}={\\frac {1}{2}}\\beta (t)\\left(n+(x+\\nabla \\ln \\rho _{t})\\cdot \\nabla \\ln \\rho _{t}+\\Delta \\ln \\rho _{t}\\right)}\n \nwhere \n \n \n \n n\n \n \n {\\displaystyle n}\n \n is the dimension of space, and \n \n \n \n Δ\n \n \n {\\displaystyle \\Delta }\n \n is the Laplace operator. Equivalently,\n \n \n \n \n ∂\n \n t\n \n \n \n ρ\n \n t\n \n \n =\n \n \n 1\n 2\n \n \n β\n (\n t\n )\n (\n ∇\n ⋅\n (\n x\n \n ρ\n \n t\n \n \n )\n +\n Δ\n \n ρ\n \n t\n \n \n )\n \n \n {\\displaystyle \\partial _{t}\\rho _{t}={\\frac {1}{2}}\\beta (t)(\\nabla \\cdot (x\\rho _{t})+\\Delta \\rho _{t})}\n \n\n\nBackward diffusion process\nIf we have solved \n \n \n \n \n ρ\n \n t\n \n \n \n \n {\\displaystyle \\rho _{t}}\n \n for time \n \n \n \n t\n ∈\n [\n 0\n ,\n T\n ]\n \n \n {\\displaystyle t\\in [0,T]}\n \n, then we can exactly reverse the evolution of the cloud. Suppose we start with another cloud of particles with density \n \n \n \n \n ν\n \n 0\n \n \n =\n \n ρ\n \n T\n \n \n \n \n {\\displaystyle \\nu _{0}=\\rho _{T}}\n \n, and let the particles in the cloud evolve according to\n\n \n \n \n d\n \n y\n \n t\n \n \n =\n \n \n 1\n 2\n \n \n β\n (\n T\n −\n t\n )\n \n y\n \n t\n \n \n d\n t\n +\n β\n (\n T\n −\n t\n )\n \n \n \n \n \n ∇\n \n \n y\n \n t\n \n \n \n \n ln\n ⁡\n \n ρ\n \n T\n −\n t\n \n \n \n (\n \n y\n \n t\n \n \n )\n \n \n ⏟\n \n \n \n score function \n \n \n d\n t\n +\n \n \n β\n (\n T\n −\n t\n )\n \n \n d\n \n W\n \n t\n \n \n \n \n {\\displaystyle dy_{t}={\\frac {1}{2}}\\beta (T-t)y_{t}dt+\\beta (T-t)\\underbrace {\\nabla _{y_{t}}\\ln \\rho _{T-t}\\left(y_{t}\\right)} _{\\text{score function }}dt+{\\sqrt {\\beta (T-t)}}dW_{t}}\n \n\nthen by plugging into the Fokker-Planck equation, we find that \n \n \n \n \n ∂\n \n t\n \n \n \n ρ\n \n T\n −\n t\n \n \n =\n \n ∂\n \n t\n \n \n \n ν\n \n t\n \n \n \n \n {\\displaystyle \\partial _{t}\\rho _{T-t}=\\partial _{t}\\nu _{t}}\n \n. Thus this cloud of points is the original cloud, evolving backwards.\n\n\nNoise conditional score network (NCSN)\nAt the continuous limit, \n\n \n \n \n \n \n \n \n α\n ¯\n \n \n \n \n t\n \n \n =\n (\n 1\n −\n \n β\n \n 1\n \n \n )\n ⋯\n (\n 1\n −\n \n β\n \n t\n \n \n )\n =\n \n e\n \n \n ∑\n \n i\n \n \n ln\n ⁡\n (\n 1\n −\n \n β\n \n i\n \n \n )\n \n \n →\n \n e\n \n −\n \n ∫\n \n 0\n \n \n t\n \n \n β\n (\n t\n )\n d\n t\n \n \n \n \n {\\displaystyle {\\bar {\\alpha }}_{t}=(1-\\beta _{1})\\cdots (1-\\beta _{t})=e^{\\sum _{i}\\ln(1-\\beta _{i})}\\to e^{-\\int _{0}^{t}\\beta (t)dt}}\n \n\nand so \n\n \n \n \n \n x\n \n t\n \n \n \n |\n \n \n x\n \n 0\n \n \n ∼\n N\n \n (\n \n \n e\n \n −\n \n \n 1\n 2\n \n \n \n ∫\n \n 0\n \n \n t\n \n \n β\n (\n t\n )\n d\n t\n \n \n \n x\n \n 0\n \n \n ,\n \n (\n \n 1\n −\n \n e\n \n −\n \n ∫\n \n 0\n \n \n t\n \n \n β\n (\n t\n )\n d\n t\n \n \n \n )\n \n I\n \n )\n \n \n \n {\\displaystyle x_{t}|x_{0}\\sim N\\left(e^{-{\\frac {1}{2}}\\int _{0}^{t}\\beta (t)dt}x_{0},\\left(1-e^{-\\int _{0}^{t}\\beta (t)dt}\\right)I\\right)}\n \n\nIn particular, we see that we can directly sample from any point in the continuous diffusion process without going through the intermediate steps, by first sampling \n \n \n \n \n x\n \n 0\n \n \n ∼\n q\n ,\n z\n ∼\n \n \n N\n \n \n (\n 0\n ,\n I\n )\n \n \n {\\displaystyle x_{0}\\sim q,z\\sim {\\mathcal {N}}(0,I)}\n \n, then get \n \n \n \n \n x\n \n t\n \n \n =\n \n e\n \n −\n \n \n 1\n 2\n \n \n \n ∫\n \n 0\n \n \n t\n \n \n β\n (\n t\n )\n d\n t\n \n \n \n x\n \n 0\n \n \n +\n \n (\n \n 1\n −\n \n e\n \n −\n \n ∫\n \n 0\n \n \n t\n \n \n β\n (\n t\n )\n d\n t\n \n \n \n )\n \n z\n \n \n {\\displaystyle x_{t}=e^{-{\\frac {1}{2}}\\int _{0}^{t}\\beta (t)dt}x_{0}+\\left(1-e^{-\\int _{0}^{t}\\beta (t)dt}\\right)z}\n \n. That is, we can quickly sample \n \n \n \n \n x\n \n t\n \n \n ∼\n \n ρ\n \n t\n \n \n \n \n {\\displaystyle x_{t}\\sim \\rho _{t}}\n \n for any \n \n \n \n t\n ≥\n 0\n \n \n {\\displaystyle t\\geq 0}\n \n.\nNow, define a certain probability distribution \n \n \n \n γ\n \n \n {\\displaystyle \\gamma }\n \n over \n \n \n \n [\n 0\n ,\n ∞\n )\n \n \n {\\displaystyle [0,\\infty )}\n \n, then the score-matching loss function is defined as the expected Fisher divergence:\n\n \n \n \n L\n (\n θ\n )\n =\n \n E\n \n t\n ∼\n γ\n ,\n \n x\n \n t\n \n \n ∼\n \n ρ\n \n t\n \n \n \n \n [\n ‖\n \n f\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n \n ‖\n \n 2\n \n \n +\n 2\n ∇\n ⋅\n \n f\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n ]\n \n \n {\\displaystyle L(\\theta )=E_{t\\sim \\gamma ,x_{t}\\sim \\rho _{t}}[\\|f_{\\theta }(x_{t},t)\\|^{2}+2\\nabla \\cdot f_{\\theta }(x_{t},t)]}\n \n\nAfter training, \n \n \n \n \n f\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n ≈\n ∇\n ln\n ⁡\n \n ρ\n \n t\n \n \n \n \n {\\displaystyle f_{\\theta }(x_{t},t)\\approx \\nabla \\ln \\rho _{t}}\n \n, so we can perform the backwards diffusion process by first sampling \n \n \n \n \n x\n \n T\n \n \n ∼\n \n \n N\n \n \n (\n 0\n ,\n I\n )\n \n \n {\\displaystyle x_{T}\\sim {\\mathcal {N}}(0,I)}\n \n, then integrating the SDE from \n \n \n \n t\n =\n T\n \n \n {\\displaystyle t=T}\n \n to \n \n \n \n t\n =\n 0\n \n \n {\\displaystyle t=0}\n \n:\n\n \n \n \n \n x\n \n t\n −\n d\n t\n \n \n =\n \n x\n \n t\n \n \n +\n \n \n 1\n 2\n \n \n β\n (\n t\n )\n \n x\n \n t\n \n \n d\n t\n +\n β\n (\n t\n )\n \n f\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n d\n t\n +\n \n \n β\n (\n t\n )\n \n \n d\n \n W\n \n t\n \n \n \n \n {\\displaystyle x_{t-dt}=x_{t}+{\\frac {1}{2}}\\beta (t)x_{t}dt+\\beta (t)f_{\\theta }(x_{t},t)dt+{\\sqrt {\\beta (t)}}dW_{t}}\n \n\nThis may be done by any SDE integration method, such as Euler–Maruyama method.\nThe name \"noise conditional score network\" is explained thus:\n\n\"network\", because \n \n \n \n \n f\n \n θ\n \n \n \n \n {\\displaystyle f_{\\theta }}\n \n is implemented as a neural network.\n\"score\", because the output of the network is interpreted as approximating the score function \n \n \n \n ∇\n ln\n ⁡\n \n ρ\n \n t\n \n \n \n \n {\\displaystyle \\nabla \\ln \\rho _{t}}\n \n.\n\"noise conditional\", because \n \n \n \n \n ρ\n \n t\n \n \n \n \n {\\displaystyle \\rho _{t}}\n \n is equal to \n \n \n \n \n ρ\n \n 0\n \n \n \n \n {\\displaystyle \\rho _{0}}\n \n blurred by an added Gaussian noise that increases with time, and so the score function depends on the amount of noise added.\n\n\nTheir equivalence\nDDPM and score-based generative models are equivalent. This means that a network trained using DDPM can be used as a NCSN, and vice versa.\nWe know that \n \n \n \n \n x\n \n t\n \n \n \n |\n \n \n x\n \n 0\n \n \n ∼\n N\n \n (\n \n \n \n \n \n \n \n α\n ¯\n \n \n \n \n t\n \n \n \n \n \n x\n \n 0\n \n \n ,\n \n σ\n \n t\n \n \n 2\n \n \n I\n \n )\n \n \n \n {\\displaystyle x_{t}|x_{0}\\sim N\\left({\\sqrt {{\\bar {\\alpha }}_{t}}}x_{0},\\sigma _{t}^{2}I\\right)}\n \n, so by Tweedie's formula, we have\n\n \n \n \n \n ∇\n \n \n x\n \n t\n \n \n \n \n ln\n ⁡\n q\n (\n \n x\n \n t\n \n \n )\n =\n \n \n 1\n \n σ\n \n t\n \n \n 2\n \n \n \n \n (\n −\n \n x\n \n t\n \n \n +\n \n \n \n \n \n \n α\n ¯\n \n \n \n \n t\n \n \n \n \n \n E\n \n q\n \n \n [\n \n x\n \n 0\n \n \n \n |\n \n \n x\n \n t\n \n \n ]\n )\n \n \n {\\displaystyle \\nabla _{x_{t}}\\ln q(x_{t})={\\frac {1}{\\sigma _{t}^{2}}}(-x_{t}+{\\sqrt {{\\bar {\\alpha }}_{t}}}E_{q}[x_{0}|x_{t}])}\n \n\nAs described previously, the DDPM loss function is \n \n \n \n \n ∑\n \n t\n \n \n \n L\n \n s\n i\n m\n p\n l\n e\n ,\n t\n \n \n \n \n {\\displaystyle \\sum _{t}L_{simple,t}}\n \n with\n\n \n \n \n \n L\n \n s\n i\n m\n p\n l\n e\n ,\n t\n \n \n =\n \n E\n \n \n x\n \n 0\n \n \n ∼\n q\n ;\n z\n ∼\n \n \n N\n \n \n (\n 0\n ,\n I\n )\n \n \n \n [\n \n \n ‖\n \n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n −\n z\n \n ‖\n \n \n 2\n \n \n ]\n \n \n \n {\\displaystyle L_{simple,t}=E_{x_{0}\\sim q;z\\sim {\\mathcal {N}}(0,I)}\\left[\\left\\|\\epsilon _{\\theta }(x_{t},t)-z\\right\\|^{2}\\right]}\n \n\nwhere \n \n \n \n \n x\n \n t\n \n \n =\n \n \n \n \n \n \n α\n ¯\n \n \n \n \n t\n \n \n \n \n \n x\n \n 0\n \n \n +\n \n σ\n \n t\n \n \n z\n \n \n {\\displaystyle x_{t}={\\sqrt {{\\bar {\\alpha }}_{t}}}x_{0}+\\sigma _{t}z}\n \n. By a change of variables,\n\n \n \n \n \n L\n \n s\n i\n m\n p\n l\n e\n ,\n t\n \n \n =\n \n E\n \n \n x\n \n 0\n \n \n ,\n \n x\n \n t\n \n \n ∼\n q\n \n \n \n [\n \n \n ‖\n \n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n −\n \n \n \n \n x\n \n t\n \n \n −\n \n \n \n \n \n \n α\n ¯\n \n \n \n \n t\n \n \n \n \n \n x\n \n 0\n \n \n \n \n σ\n \n t\n \n \n \n \n \n ‖\n \n \n 2\n \n \n ]\n \n =\n \n E\n \n \n x\n \n t\n \n \n ∼\n q\n ,\n \n x\n \n 0\n \n \n ∼\n q\n (\n ⋅\n \n |\n \n \n x\n \n t\n \n \n )\n \n \n \n [\n \n \n ‖\n \n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n −\n \n \n \n \n x\n \n t\n \n \n −\n \n \n \n \n \n \n α\n ¯\n \n \n \n \n t\n \n \n \n \n \n x\n \n 0\n \n \n \n \n σ\n \n t\n \n \n \n \n \n ‖\n \n \n 2\n \n \n ]\n \n \n \n {\\displaystyle L_{simple,t}=E_{x_{0},x_{t}\\sim q}\\left[\\left\\|\\epsilon _{\\theta }(x_{t},t)-{\\frac {x_{t}-{\\sqrt {{\\bar {\\alpha }}_{t}}}x_{0}}{\\sigma _{t}}}\\right\\|^{2}\\right]=E_{x_{t}\\sim q,x_{0}\\sim q(\\cdot |x_{t})}\\left[\\left\\|\\epsilon _{\\theta }(x_{t},t)-{\\frac {x_{t}-{\\sqrt {{\\bar {\\alpha }}_{t}}}x_{0}}{\\sigma _{t}}}\\right\\|^{2}\\right]}\n \n\nand the term inside becomes a least squares regression, so if the network actually reaches the global minimum of loss, then we have \n \n \n \n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n =\n \n \n \n \n x\n \n t\n \n \n −\n \n \n \n \n \n \n α\n ¯\n \n \n \n \n t\n \n \n \n \n \n E\n \n q\n \n \n [\n \n x\n \n 0\n \n \n \n |\n \n \n x\n \n t\n \n \n ]\n \n \n σ\n \n t\n \n \n \n \n =\n −\n \n σ\n \n t\n \n \n \n ∇\n \n \n x\n \n t\n \n \n \n \n ln\n ⁡\n q\n (\n \n x\n \n t\n \n \n )\n \n \n {\\displaystyle \\epsilon _{\\theta }(x_{t},t)={\\frac {x_{t}-{\\sqrt {{\\bar {\\alpha }}_{t}}}E_{q}[x_{0}|x_{t}]}{\\sigma _{t}}}=-\\sigma _{t}\\nabla _{x_{t}}\\ln q(x_{t})}\n \n\nThus, given a good score-based network, its predicted score is a good prediction of the noise (after scaling by \n \n \n \n \n σ\n \n t\n \n \n \n \n {\\displaystyle \\sigma _{t}}\n \n), and thus can be used for denoising.\nConversely, the continuous limit \n \n \n \n \n x\n \n t\n −\n 1\n \n \n =\n \n x\n \n t\n −\n d\n t\n \n \n ,\n \n β\n \n t\n \n \n =\n β\n (\n t\n )\n d\n t\n ,\n \n z\n \n t\n \n \n \n \n d\n t\n \n \n =\n d\n \n W\n \n t\n \n \n \n \n {\\displaystyle x_{t-1}=x_{t-dt},\\beta _{t}=\\beta (t)dt,z_{t}{\\sqrt {dt}}=dW_{t}}\n \n of the backward equation\n\n \n \n \n \n x\n \n t\n −\n 1\n \n \n =\n \n \n \n x\n \n t\n \n \n \n \n α\n \n t\n \n \n \n \n \n −\n \n \n \n β\n \n t\n \n \n \n \n σ\n \n t\n \n \n \n \n \n α\n \n t\n \n \n \n \n \n \n \n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n +\n \n \n \n β\n \n t\n \n \n \n \n \n z\n \n t\n \n \n ;\n \n \n z\n \n t\n \n \n ∼\n \n \n N\n \n \n (\n 0\n ,\n I\n )\n \n \n {\\displaystyle x_{t-1}={\\frac {x_{t}}{\\sqrt {\\alpha _{t}}}}-{\\frac {\\beta _{t}}{\\sigma _{t}{\\sqrt {\\alpha _{t}}}}}\\epsilon _{\\theta }(x_{t},t)+{\\sqrt {\\beta _{t}}}z_{t};\\quad z_{t}\\sim {\\mathcal {N}}(0,I)}\n \n\ngives us precisely the same equation as score-based diffusion:\n\n \n \n \n \n x\n \n t\n −\n d\n t\n \n \n =\n \n x\n \n t\n \n \n (\n 1\n +\n β\n (\n t\n )\n d\n t\n \n /\n \n 2\n )\n +\n β\n (\n t\n )\n \n ∇\n \n \n x\n \n t\n \n \n \n \n ln\n ⁡\n q\n (\n \n x\n \n t\n \n \n )\n d\n t\n +\n \n \n β\n (\n t\n )\n \n \n d\n \n W\n \n t\n \n \n \n \n {\\displaystyle x_{t-dt}=x_{t}(1+\\beta (t)dt/2)+\\beta (t)\\nabla _{x_{t}}\\ln q(x_{t})dt+{\\sqrt {\\beta (t)}}dW_{t}}\n \nThus, at infinitesimal steps of DDPM, a denoising network performs score-based diffusion.\n\n\nMain variants\n\n\nNoise schedule\n\nIn DDPM, the sequence of numbers \n \n \n \n 0\n =\n \n σ\n \n 0\n \n \n <\n \n σ\n \n 1\n \n \n <\n ⋯\n <\n \n σ\n \n T\n \n \n <\n 1\n \n \n {\\displaystyle 0=\\sigma _{0}<\\sigma _{1}<\\cdots <\\sigma _{T}<1}\n \n is called a (discrete time) noise schedule. In general, consider a strictly increasing monotonic function \n \n \n \n σ\n \n \n {\\displaystyle \\sigma }\n \n of type \n \n \n \n \n R\n \n →\n (\n 0\n ,\n 1\n )\n \n \n {\\displaystyle \\mathbb {R} \\to (0,1)}\n \n, such as the sigmoid function. In that case, a noise schedule is a sequence of real numbers \n \n \n \n \n λ\n \n 1\n \n \n <\n \n λ\n \n 2\n \n \n <\n ⋯\n <\n \n λ\n \n T\n \n \n \n \n {\\displaystyle \\lambda _{1}<\\lambda _{2}<\\cdots <\\lambda _{T}}\n \n. It then defines a sequence of noises \n \n \n \n \n σ\n \n t\n \n \n :=\n σ\n (\n \n λ\n \n t\n \n \n )\n \n \n {\\displaystyle \\sigma _{t}:=\\sigma (\\lambda _{t})}\n \n, which then derives the other quantities \n \n \n \n \n β\n \n t\n \n \n =\n 1\n −\n \n \n \n 1\n −\n \n σ\n \n t\n \n \n 2\n \n \n \n \n 1\n −\n \n σ\n \n t\n −\n 1\n \n \n 2\n \n \n \n \n \n \n \n {\\displaystyle \\beta _{t}=1-{\\frac {1-\\sigma _{t}^{2}}{1-\\sigma _{t-1}^{2}}}}\n \n.\nIn order to use arbitrary noise schedules, instead of training a noise prediction model \n \n \n \n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n \n \n {\\displaystyle \\epsilon _{\\theta }(x_{t},t)}\n \n, one trains \n \n \n \n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n \n σ\n \n t\n \n \n )\n \n \n {\\displaystyle \\epsilon _{\\theta }(x_{t},\\sigma _{t})}\n \n.\nSimilarly, for the noise conditional score network, instead of training \n \n \n \n \n f\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n \n \n {\\displaystyle f_{\\theta }(x_{t},t)}\n \n, one trains \n \n \n \n \n f\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n \n σ\n \n t\n \n \n )\n \n \n {\\displaystyle f_{\\theta }(x_{t},\\sigma _{t})}\n \n.\n\n\nDenoising Diffusion Implicit Model (DDIM)\nThe original DDPM method for generating images is slow, since the forward diffusion process usually takes \n \n \n \n T\n ∼\n 1000\n \n \n {\\displaystyle T\\sim 1000}\n \n to make the distribution of \n \n \n \n \n x\n \n T\n \n \n \n \n {\\displaystyle x_{T}}\n \n to appear close to Gaussian. However this means the backward diffusion process also take 1000 steps. Unlike the forward diffusion process, which can skip steps as \n \n \n \n \n x\n \n t\n \n \n \n |\n \n \n x\n \n 0\n \n \n \n \n {\\displaystyle x_{t}|x_{0}}\n \n is Gaussian for all \n \n \n \n t\n ≥\n 1\n \n \n {\\displaystyle t\\geq 1}\n \n, the backward diffusion process does not allow skipping steps. For example, to sample \n \n \n \n \n x\n \n t\n −\n 2\n \n \n \n |\n \n \n x\n \n t\n −\n 1\n \n \n ∼\n \n \n N\n \n \n (\n \n μ\n \n θ\n \n \n (\n \n x\n \n t\n −\n 1\n \n \n ,\n t\n −\n 1\n )\n ,\n \n Σ\n \n θ\n \n \n (\n \n x\n \n t\n −\n 1\n \n \n ,\n t\n −\n 1\n )\n )\n \n \n {\\displaystyle x_{t-2}|x_{t-1}\\sim {\\mathcal {N}}(\\mu _{\\theta }(x_{t-1},t-1),\\Sigma _{\\theta }(x_{t-1},t-1))}\n \n requires the model to first sample \n \n \n \n \n x\n \n t\n −\n 1\n \n \n \n \n {\\displaystyle x_{t-1}}\n \n. Attempting to directly sample \n \n \n \n \n x\n \n t\n −\n 2\n \n \n \n |\n \n \n x\n \n t\n \n \n \n \n {\\displaystyle x_{t-2}|x_{t}}\n \n would require us to marginalize out \n \n \n \n \n x\n \n t\n −\n 1\n \n \n \n \n {\\displaystyle x_{t-1}}\n \n, which is generally intractable.\nDDIM is a method to take any model trained on DDPM loss, and use it to sample with some steps skipped, sacrificing an adjustable amount of quality. If we generate the Markovian chain case in DDPM to non-Markovian case, DDIM corresponds to the case that the reverse process has variance equals to 0. In other words, the reverse process (and also the forward process) is deterministic. When using fewer sampling steps, DDIM outperforms DDPM.\nIn detail, the DDIM sampling method is as follows. Start with the forward diffusion process \n \n \n \n \n x\n \n t\n \n \n =\n \n \n \n \n \n \n α\n ¯\n \n \n \n \n t\n \n \n \n \n \n x\n \n 0\n \n \n +\n \n σ\n \n t\n \n \n ϵ\n \n \n {\\displaystyle x_{t}={\\sqrt {{\\bar {\\alpha }}_{t}}}x_{0}+\\sigma _{t}\\epsilon }\n \n. Then, during the backward denoising process, given \n \n \n \n \n x\n \n t\n \n \n ,\n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n \n \n {\\displaystyle x_{t},\\epsilon _{\\theta }(x_{t},t)}\n \n, the original data is estimated as \n \n \n \n \n x\n \n 0\n \n ′\n \n =\n \n \n \n \n x\n \n t\n \n \n −\n \n σ\n \n t\n \n \n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n \n \n \n \n \n \n α\n ¯\n \n \n \n \n t\n \n \n \n \n \n \n \n {\\displaystyle x_{0}'={\\frac {x_{t}-\\sigma _{t}\\epsilon _{\\theta }(x_{t},t)}{\\sqrt {{\\bar {\\alpha }}_{t}}}}}\n \nthen the backward diffusion process can jump to any step \n \n \n \n 0\n ≤\n s\n <\n t\n \n \n {\\displaystyle 0\\leq s\n 0\n \n \n {\\displaystyle {\\sqrt {{\\bar {\\alpha }}_{t}}}>0}\n \n is always true.\n\n\nClassifier guidance\nClassifier guidance was proposed in 2021 to improve class-conditional generation by using a classifier. The original publication used CLIP text encoders to improve text-conditional image generation.\nSuppose we wish to sample not from the entire distribution of images, but conditional on the image description. We don't want to sample a generic image, but an image that fits the description \"black cat with red eyes\". Generally, we want to sample from the distribution \n \n \n \n p\n (\n x\n \n |\n \n y\n )\n \n \n {\\displaystyle p(x|y)}\n \n, where \n \n \n \n x\n \n \n {\\displaystyle x}\n \n ranges over images, and \n \n \n \n y\n \n \n {\\displaystyle y}\n \n ranges over classes of images (a description \"black cat with red eyes\" is just a very detailed class, and a class \"cat\" is just a very vague description).\nTaking the perspective of the noisy channel model, we can understand the process as follows: To generate an image \n \n \n \n x\n \n \n {\\displaystyle x}\n \n conditional on description \n \n \n \n y\n \n \n {\\displaystyle y}\n \n, we imagine that the requester really had in mind an image \n \n \n \n x\n \n \n {\\displaystyle x}\n \n, but the image is passed through a noisy channel and came out garbled, as \n \n \n \n y\n \n \n {\\displaystyle y}\n \n. Image generation is then nothing but inferring which \n \n \n \n x\n \n \n {\\displaystyle x}\n \n the requester had in mind.\nIn other words, conditional image generation is simply \"translating from a textual language into a pictorial language\". Then, as in noisy-channel model, we use Bayes theorem to get\n\n \n \n \n p\n (\n x\n \n |\n \n y\n )\n ∝\n p\n (\n y\n \n |\n \n x\n )\n p\n (\n x\n )\n \n \n {\\displaystyle p(x|y)\\propto p(y|x)p(x)}\n \n\nin other words, if we have a good model of the space of all images, and a good image-to-class translator, we get a class-to-image translator \"for free\". In the equation for backward diffusion, the score \n \n \n \n ∇\n ln\n ⁡\n p\n (\n x\n )\n \n \n {\\displaystyle \\nabla \\ln p(x)}\n \n can be replaced by\n\n \n \n \n \n ∇\n \n x\n \n \n ln\n ⁡\n p\n (\n x\n \n |\n \n y\n )\n =\n \n \n \n \n \n ∇\n \n x\n \n \n ln\n ⁡\n p\n (\n x\n )\n \n ⏟\n \n \n \n score\n \n \n +\n \n \n \n \n \n ∇\n \n x\n \n \n ln\n ⁡\n p\n (\n y\n \n |\n \n x\n )\n \n ⏟\n \n \n \n classifier guidance\n \n \n \n \n {\\displaystyle \\nabla _{x}\\ln p(x|y)=\\underbrace {\\nabla _{x}\\ln p(x)} _{\\text{score}}+\\underbrace {\\nabla _{x}\\ln p(y|x)} _{\\text{classifier guidance}}}\n \n\nwhere \n \n \n \n \n ∇\n \n x\n \n \n ln\n ⁡\n p\n (\n x\n )\n \n \n {\\displaystyle \\nabla _{x}\\ln p(x)}\n \n is the score function, trained as previously described, and \n \n \n \n \n ∇\n \n x\n \n \n ln\n ⁡\n p\n (\n y\n \n |\n \n x\n )\n \n \n {\\displaystyle \\nabla _{x}\\ln p(y|x)}\n \n is found by using a differentiable image classifier.\nDuring the diffusion process, we need to condition on the time, giving\n \n \n \n \n ∇\n \n \n x\n \n t\n \n \n \n \n ln\n ⁡\n p\n (\n \n x\n \n t\n \n \n \n |\n \n y\n ,\n t\n )\n =\n \n ∇\n \n \n x\n \n t\n \n \n \n \n ln\n ⁡\n p\n (\n y\n \n |\n \n \n x\n \n t\n \n \n ,\n t\n )\n +\n \n ∇\n \n \n x\n \n t\n \n \n \n \n ln\n ⁡\n p\n (\n \n x\n \n t\n \n \n \n |\n \n t\n )\n \n \n {\\displaystyle \\nabla _{x_{t}}\\ln p(x_{t}|y,t)=\\nabla _{x_{t}}\\ln p(y|x_{t},t)+\\nabla _{x_{t}}\\ln p(x_{t}|t)}\n \nAlthough, usually the classifier model does not depend on time, in which case \n \n \n \n p\n (\n y\n \n |\n \n \n x\n \n t\n \n \n ,\n t\n )\n =\n p\n (\n y\n \n |\n \n \n x\n \n t\n \n \n )\n \n \n {\\displaystyle p(y|x_{t},t)=p(y|x_{t})}\n \n.\nClassifier guidance is defined for the gradient of score function, thus for score-based diffusion network, but as previously noted, score-based diffusion models are equivalent to denoising models by \n \n \n \n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n =\n −\n \n σ\n \n t\n \n \n \n ∇\n \n \n x\n \n t\n \n \n \n \n ln\n ⁡\n p\n (\n \n x\n \n t\n \n \n \n |\n \n t\n )\n \n \n {\\displaystyle \\epsilon _{\\theta }(x_{t},t)=-\\sigma _{t}\\nabla _{x_{t}}\\ln p(x_{t}|t)}\n \n, and similarly, \n \n \n \n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n y\n ,\n t\n )\n =\n −\n \n σ\n \n t\n \n \n \n ∇\n \n \n x\n \n t\n \n \n \n \n ln\n ⁡\n p\n (\n \n x\n \n t\n \n \n \n |\n \n y\n ,\n t\n )\n \n \n {\\displaystyle \\epsilon _{\\theta }(x_{t},y,t)=-\\sigma _{t}\\nabla _{x_{t}}\\ln p(x_{t}|y,t)}\n \n. Therefore, classifier guidance works for denoising diffusion as well, using the modified noise prediction:\n \n \n \n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n y\n ,\n t\n )\n =\n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n −\n \n \n \n \n \n σ\n \n t\n \n \n \n ∇\n \n \n x\n \n t\n \n \n \n \n ln\n ⁡\n p\n (\n y\n \n |\n \n \n x\n \n t\n \n \n ,\n t\n )\n \n ⏟\n \n \n \n classifier guidance\n \n \n \n \n {\\displaystyle \\epsilon _{\\theta }(x_{t},y,t)=\\epsilon _{\\theta }(x_{t},t)-\\underbrace {\\sigma _{t}\\nabla _{x_{t}}\\ln p(y|x_{t},t)} _{\\text{classifier guidance}}}\n \n\n\nWith temperature\nThe classifier-guided diffusion model samples from \n \n \n \n p\n (\n x\n \n |\n \n y\n )\n \n \n {\\displaystyle p(x|y)}\n \n, which is concentrated around the maximum a posteriori estimate \n \n \n \n arg\n ⁡\n \n max\n \n x\n \n \n p\n (\n x\n \n |\n \n y\n )\n \n \n {\\displaystyle \\arg \\max _{x}p(x|y)}\n \n. If we want to force the model to move towards the maximum likelihood estimate \n \n \n \n arg\n ⁡\n \n max\n \n x\n \n \n p\n (\n y\n \n |\n \n x\n )\n \n \n {\\displaystyle \\arg \\max _{x}p(y|x)}\n \n, we can use \n\n \n \n \n \n p\n \n γ\n \n \n (\n x\n \n |\n \n y\n )\n ∝\n p\n (\n y\n \n |\n \n x\n \n )\n \n γ\n \n \n p\n (\n x\n )\n \n \n {\\displaystyle p_{\\gamma }(x|y)\\propto p(y|x)^{\\gamma }p(x)}\n \n\nwhere \n \n \n \n γ\n >\n 0\n \n \n {\\displaystyle \\gamma >0}\n \n is interpretable as inverse temperature. In the context of diffusion models, it is usually called the guidance scale. A high \n \n \n \n γ\n \n \n {\\displaystyle \\gamma }\n \n would force the model to sample from a distribution concentrated around \n \n \n \n arg\n ⁡\n \n max\n \n x\n \n \n p\n (\n y\n \n |\n \n x\n )\n \n \n {\\displaystyle \\arg \\max _{x}p(y|x)}\n \n. This sometimes improves quality of generated images.\nThis gives a modification to the previous equation:\n \n \n \n \n ∇\n \n x\n \n \n ln\n ⁡\n \n p\n \n β\n \n \n (\n x\n \n |\n \n y\n )\n =\n \n ∇\n \n x\n \n \n ln\n ⁡\n p\n (\n x\n )\n +\n γ\n \n ∇\n \n x\n \n \n ln\n ⁡\n p\n (\n y\n \n |\n \n x\n )\n \n \n {\\displaystyle \\nabla _{x}\\ln p_{\\beta }(x|y)=\\nabla _{x}\\ln p(x)+\\gamma \\nabla _{x}\\ln p(y|x)}\n \nFor denoising models, it corresponds to\n \n \n \n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n y\n ,\n t\n )\n =\n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n −\n γ\n \n σ\n \n t\n \n \n \n ∇\n \n \n x\n \n t\n \n \n \n \n ln\n ⁡\n p\n (\n y\n \n |\n \n \n x\n \n t\n \n \n ,\n t\n )\n \n \n {\\displaystyle \\epsilon _{\\theta }(x_{t},y,t)=\\epsilon _{\\theta }(x_{t},t)-\\gamma \\sigma _{t}\\nabla _{x_{t}}\\ln p(y|x_{t},t)}\n \n\n\nClassifier-free guidance (CFG)\nIf we do not have a classifier \n \n \n \n p\n (\n y\n \n |\n \n x\n )\n \n \n {\\displaystyle p(y|x)}\n \n, we could still extract one out of the image model itself:\n\n \n \n \n \n ∇\n \n x\n \n \n ln\n ⁡\n \n p\n \n γ\n \n \n (\n x\n \n |\n \n y\n )\n =\n (\n 1\n −\n γ\n )\n \n ∇\n \n x\n \n \n ln\n ⁡\n p\n (\n x\n )\n +\n γ\n \n ∇\n \n x\n \n \n ln\n ⁡\n p\n (\n x\n \n |\n \n y\n )\n \n \n {\\displaystyle \\nabla _{x}\\ln p_{\\gamma }(x|y)=(1-\\gamma )\\nabla _{x}\\ln p(x)+\\gamma \\nabla _{x}\\ln p(x|y)}\n \n\nSuch a model is usually trained by presenting it with both \n \n \n \n (\n x\n ,\n y\n )\n \n \n {\\displaystyle (x,y)}\n \n and \n \n \n \n (\n x\n ,\n \n \n N\n o\n n\n e\n \n \n )\n \n \n {\\displaystyle (x,{\\rm {None}})}\n \n, allowing it to model both \n \n \n \n \n ∇\n \n x\n \n \n ln\n ⁡\n p\n (\n x\n \n |\n \n y\n )\n \n \n {\\displaystyle \\nabla _{x}\\ln p(x|y)}\n \n and \n \n \n \n \n ∇\n \n x\n \n \n ln\n ⁡\n p\n (\n x\n )\n \n \n {\\displaystyle \\nabla _{x}\\ln p(x)}\n \n.\nNote that for CFG, the diffusion model cannot be merely a generative model of the entire data distribution \n \n \n \n \n ∇\n \n x\n \n \n ln\n ⁡\n p\n (\n x\n )\n \n \n {\\displaystyle \\nabla _{x}\\ln p(x)}\n \n. It must be a conditional generative model \n \n \n \n \n ∇\n \n x\n \n \n ln\n ⁡\n p\n (\n x\n \n |\n \n y\n )\n \n \n {\\displaystyle \\nabla _{x}\\ln p(x|y)}\n \n. For example, in stable diffusion, the diffusion backbone takes as input both a noisy model \n \n \n \n \n x\n \n t\n \n \n \n \n {\\displaystyle x_{t}}\n \n, a time \n \n \n \n t\n \n \n {\\displaystyle t}\n \n, and a conditioning vector \n \n \n \n y\n \n \n {\\displaystyle y}\n \n (such as a vector encoding a text prompt), and produces a noise prediction \n \n \n \n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n y\n ,\n t\n )\n \n \n {\\displaystyle \\epsilon _{\\theta }(x_{t},y,t)}\n \n.\nFor denoising models, it corresponds to\n \n \n \n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n y\n ,\n t\n ,\n γ\n )\n =\n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n +\n γ\n (\n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n y\n ,\n t\n )\n −\n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n )\n \n \n {\\displaystyle \\epsilon _{\\theta }(x_{t},y,t,\\gamma )=\\epsilon _{\\theta }(x_{t},t)+\\gamma (\\epsilon _{\\theta }(x_{t},y,t)-\\epsilon _{\\theta }(x_{t},t))}\n \nAs sampled by DDIM, the algorithm can be written as\n \n \n \n \n \n \n \n \n ϵ\n \n uncond\n \n \n \n \n \n ←\n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n \n \n \n \n \n ϵ\n \n cond\n \n \n \n \n \n ←\n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n ,\n c\n )\n \n \n \n \n \n ϵ\n \n CFG\n \n \n \n \n \n ←\n \n ϵ\n \n uncond\n \n \n +\n γ\n (\n \n ϵ\n \n cond\n \n \n −\n \n ϵ\n \n uncond\n \n \n )\n \n \n \n \n \n x\n \n 0\n \n \n \n \n \n ←\n (\n \n x\n \n t\n \n \n −\n \n σ\n \n t\n \n \n \n ϵ\n \n CFG\n \n \n )\n \n /\n \n \n \n 1\n −\n \n σ\n \n t\n \n \n 2\n \n \n \n \n \n \n \n \n \n x\n \n s\n \n \n \n \n \n ←\n \n \n 1\n −\n \n σ\n \n s\n \n \n 2\n \n \n \n \n \n x\n \n 0\n \n \n +\n \n \n \n σ\n \n s\n \n \n 2\n \n \n −\n (\n \n σ\n \n s\n \n ′\n \n \n )\n \n 2\n \n \n \n \n \n ϵ\n \n uncond\n \n \n +\n \n σ\n \n s\n \n ′\n \n ϵ\n \n \n \n \n \n \n {\\displaystyle {\\begin{aligned}\\epsilon _{\\text{uncond}}&\\leftarrow \\epsilon _{\\theta }(x_{t},t)\\\\\\epsilon _{\\text{cond}}&\\leftarrow \\epsilon _{\\theta }(x_{t},t,c)\\\\\\epsilon _{\\text{CFG}}&\\leftarrow \\epsilon _{\\text{uncond}}+\\gamma (\\epsilon _{\\text{cond}}-\\epsilon _{\\text{uncond}})\\\\x_{0}&\\leftarrow (x_{t}-\\sigma _{t}\\epsilon _{\\text{CFG}})/{\\sqrt {1-\\sigma _{t}^{2}}}\\\\x_{s}&\\leftarrow {\\sqrt {1-\\sigma _{s}^{2}}}x_{0}+{\\sqrt {\\sigma _{s}^{2}-(\\sigma _{s}')^{2}}}\\epsilon _{\\text{uncond}}+\\sigma _{s}'\\epsilon \\\\\\end{aligned}}}\n \nA similar technique applies to language model sampling. Also, if the unconditional generation \n \n \n \n \n ϵ\n \n uncond\n \n \n ←\n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n \n \n {\\displaystyle \\epsilon _{\\text{uncond}}\\leftarrow \\epsilon _{\\theta }(x_{t},t)}\n \n is replaced by \n \n \n \n \n ϵ\n \n neg cond\n \n \n ←\n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n ,\n \n c\n ′\n \n )\n \n \n {\\displaystyle \\epsilon _{\\text{neg cond}}\\leftarrow \\epsilon _{\\theta }(x_{t},t,c')}\n \n, then it results in negative prompting, which pushes the generation away from \n \n \n \n \n c\n ′\n \n \n \n {\\displaystyle c'}\n \n condition.\n\n\nSamplers\nGiven a diffusion model, one may regard it either as a continuous process, and sample from it by integrating a SDE, or one can regard it as a discrete process, and sample from it by iterating the discrete steps. The choice of the \"noise schedule\" \n \n \n \n \n β\n \n t\n \n \n \n \n {\\displaystyle \\beta _{t}}\n \n can also affect the quality of samples. A noise schedule is a function that sends a natural number to a noise level: \n \n \n \n t\n ↦\n \n β\n \n t\n \n \n ,\n \n t\n ∈\n {\n 1\n ,\n 2\n ,\n …\n }\n ,\n β\n ∈\n (\n 0\n ,\n 1\n )\n \n \n {\\displaystyle t\\mapsto \\beta _{t},\\quad t\\in \\{1,2,\\dots \\},\\beta \\in (0,1)}\n \nA noise schedule is more often specified by a map \n \n \n \n t\n ↦\n \n σ\n \n t\n \n \n \n \n {\\displaystyle t\\mapsto \\sigma _{t}}\n \n. The two definitions are equivalent, since \n \n \n \n \n β\n \n t\n \n \n =\n 1\n −\n \n \n \n 1\n −\n \n σ\n \n t\n \n \n 2\n \n \n \n \n 1\n −\n \n σ\n \n t\n −\n 1\n \n \n 2\n \n \n \n \n \n \n \n {\\displaystyle \\beta _{t}=1-{\\frac {1-\\sigma _{t}^{2}}{1-\\sigma _{t-1}^{2}}}}\n \n.\nIn the DDPM perspective, one can use the DDPM itself (with noise), or DDIM (with adjustable amount of noise). The case where one adds noise is sometimes called ancestral sampling. One can interpolate between noise and no noise. The amount of noise is denoted \n \n \n \n η\n \n \n {\\displaystyle \\eta }\n \n (\"eta value\") in the DDIM paper, with \n \n \n \n η\n =\n 0\n \n \n {\\displaystyle \\eta =0}\n \n denoting no noise (as in deterministic DDIM), and \n \n \n \n η\n =\n 1\n \n \n {\\displaystyle \\eta =1}\n \n denoting full noise (as in DDPM).\nIn the perspective of SDE, one can use any of the numerical integration methods, such as Euler–Maruyama method, Heun's method, linear multistep methods, etc. Just as in the discrete case, one can add an adjustable amount of noise during the integration.\nA survey and comparison of samplers in the context of image generation is in.\n\n\nOther examples\nNotable variants include Poisson flow generative model, consistency model, critically damped Langevin diffusion, GenPhys, cold diffusion, etc.\n\n\nFlow-based diffusion model\nAbstractly speaking, the idea of diffusion model is to take an unknown probability distribution (the distribution of natural-looking images), then progressively convert it to a known probability distribution (standard Gaussian distribution), by building an absolutely continuous probability path connecting them. The probability path is in fact defined implicitly by the score function \n \n \n \n ∇\n ln\n ⁡\n \n p\n \n t\n \n \n \n \n {\\displaystyle \\nabla \\ln p_{t}}\n \n.\nIn denoising diffusion models, the forward process adds noise, and the backward process removes noise. Both the forward and backward processes are SDEs, though the forward process is integrable in closed-form, so it can be done at no computational cost. The backward process is not integrable in closed-form, so it must be integrated step-by-step by standard SDE solvers, which can be very expensive. The probability path in diffusions model is defined through an Itô process and one can retrieve the deterministic process by using the Probability ODE flow formulation.\nIn flow-based diffusion models, the forward process is a deterministic flow along a time-dependent vector field, and the backward process is also a deterministic flow along the same vector field, but going backwards. Both processes are solutions to ODEs. If the vector field is well-behaved, the ODE will also be well-behaved.\nGiven two distributions \n \n \n \n \n π\n \n 0\n \n \n \n \n {\\displaystyle \\pi _{0}}\n \n and \n \n \n \n \n π\n \n 1\n \n \n \n \n {\\displaystyle \\pi _{1}}\n \n, a flow-based model is a time-dependent velocity field \n \n \n \n \n v\n \n t\n \n \n (\n x\n )\n \n \n {\\displaystyle v_{t}(x)}\n \n in \n \n \n \n [\n 0\n ,\n 1\n ]\n ×\n \n \n R\n \n \n d\n \n \n \n \n {\\displaystyle [0,1]\\times \\mathbb {R} ^{d}}\n \n, such that if we start by sampling a point \n \n \n \n x\n ∼\n \n π\n \n 0\n \n \n \n \n {\\displaystyle x\\sim \\pi _{0}}\n \n, and let it move according to the velocity field:\n\n \n \n \n \n \n d\n \n d\n t\n \n \n \n \n ϕ\n \n t\n \n \n (\n x\n )\n =\n \n v\n \n t\n \n \n (\n \n ϕ\n \n t\n \n \n (\n x\n )\n )\n \n t\n ∈\n [\n 0\n ,\n 1\n ]\n ,\n \n \n starting from \n \n \n ϕ\n \n 0\n \n \n (\n x\n )\n =\n x\n \n \n {\\displaystyle {\\frac {d}{dt}}\\phi _{t}(x)=v_{t}(\\phi _{t}(x))\\quad t\\in [0,1],\\quad {\\text{starting from }}\\phi _{0}(x)=x}\n \n\nwe end up with a point \n \n \n \n \n x\n \n 1\n \n \n ∼\n \n π\n \n 1\n \n \n \n \n {\\displaystyle x_{1}\\sim \\pi _{1}}\n \n. The solution \n \n \n \n \n ϕ\n \n t\n \n \n \n \n {\\displaystyle \\phi _{t}}\n \n of the above ODE define a probability path \n \n \n \n \n p\n \n t\n \n \n =\n [\n \n ϕ\n \n t\n \n \n \n ]\n \n #\n \n \n \n π\n \n 0\n \n \n \n \n {\\displaystyle p_{t}=[\\phi _{t}]_{\\#}\\pi _{0}}\n \n by the pushforward measure operator. In particular, \n \n \n \n [\n \n ϕ\n \n 1\n \n \n \n ]\n \n #\n \n \n \n π\n \n 0\n \n \n =\n \n π\n \n 1\n \n \n \n \n {\\displaystyle [\\phi _{1}]_{\\#}\\pi _{0}=\\pi _{1}}\n \n.\nThe probability path and the velocity field also satisfy the continuity equation, in the sense of probability distribution:\n\n \n \n \n \n ∂\n \n t\n \n \n \n p\n \n t\n \n \n +\n ∇\n ⋅\n (\n \n v\n \n t\n \n \n \n p\n \n t\n \n \n )\n =\n 0\n \n \n {\\displaystyle \\partial _{t}p_{t}+\\nabla \\cdot (v_{t}p_{t})=0}\n \n\nTo construct a probability path, we start by construct a conditional probability path \n \n \n \n \n p\n \n t\n \n \n (\n x\n |\n z\n )\n \n \n {\\displaystyle p_{t}(x\\vert z)}\n \n and the corresponding conditional velocity field \n \n \n \n \n v\n \n t\n \n \n (\n x\n |\n z\n )\n \n \n {\\displaystyle v_{t}(x\\vert z)}\n \n on some conditional distribution \n \n \n \n q\n (\n z\n )\n \n \n {\\displaystyle q(z)}\n \n. A natural choice is the Gaussian conditional probability path:\n\n \n \n \n \n p\n \n t\n \n \n (\n x\n |\n z\n )\n =\n \n \n N\n \n \n \n (\n \n \n m\n \n t\n \n \n (\n z\n )\n ,\n \n ζ\n \n t\n \n \n 2\n \n \n I\n \n )\n \n \n \n {\\displaystyle p_{t}(x\\vert z)={\\mathcal {N}}\\left(m_{t}(z),\\zeta _{t}^{2}I\\right)}\n \n\nThe conditional velocity field which corresponds to the geodesic path between conditional Gaussian path is \n\n \n \n \n \n v\n \n t\n \n \n (\n x\n |\n z\n )\n =\n \n \n \n ζ\n \n t\n \n ′\n \n \n ζ\n \n t\n \n \n \n \n (\n x\n −\n \n m\n \n t\n \n \n (\n z\n )\n )\n +\n \n m\n \n t\n \n ′\n \n (\n z\n )\n \n \n {\\displaystyle v_{t}(x\\vert z)={\\frac {\\zeta _{t}'}{\\zeta _{t}}}(x-m_{t}(z))+m_{t}'(z)}\n \n\nThe probability path and velocity field are then computed by marginalizing\n\n \n \n \n \n p\n \n t\n \n \n (\n x\n )\n =\n ∫\n \n p\n \n t\n \n \n (\n x\n |\n z\n )\n q\n (\n z\n )\n d\n z\n \n \n and \n \n \n \n v\n \n t\n \n \n (\n x\n )\n =\n \n \n E\n \n \n q\n (\n z\n )\n \n \n \n [\n \n \n \n \n v\n \n t\n \n \n (\n x\n |\n z\n )\n \n p\n \n t\n \n \n (\n x\n |\n z\n )\n \n \n \n p\n \n t\n \n \n (\n x\n )\n \n \n \n ]\n \n \n \n {\\displaystyle p_{t}(x)=\\int p_{t}(x\\vert z)q(z)dz\\qquad {\\text{ and }}\\qquad v_{t}(x)=\\mathbb {E} _{q(z)}\\left[{\\frac {v_{t}(x\\vert z)p_{t}(x\\vert z)}{p_{t}(x)}}\\right]}\n \n\n\nOptimal transport flow\nThe idea of optimal transport flow is to construct a probability path minimizing the Wasserstein metric. The distribution on which we condition is an approximation of the optimal transport plan between \n \n \n \n \n π\n \n 0\n \n \n \n \n {\\displaystyle \\pi _{0}}\n \n and \n \n \n \n \n π\n \n 1\n \n \n \n \n {\\displaystyle \\pi _{1}}\n \n: \n \n \n \n z\n =\n (\n \n x\n \n 0\n \n \n ,\n \n x\n \n 1\n \n \n )\n \n \n {\\displaystyle z=(x_{0},x_{1})}\n \n and \n \n \n \n q\n (\n z\n )\n =\n Γ\n (\n \n π\n \n 0\n \n \n ,\n \n π\n \n 1\n \n \n )\n \n \n {\\displaystyle q(z)=\\Gamma (\\pi _{0},\\pi _{1})}\n \n, where \n \n \n \n Γ\n \n \n {\\displaystyle \\Gamma }\n \n is the optimal transport plan, which can be approximated by mini-batch optimal transport. If the batch size is not large, then the transport it computes can be very far from the true optimal transport.\n\n\nRectified flow\nThe idea of rectified flow is to learn a flow model such that the velocity is nearly constant along each flow path. This is beneficial, because we can integrate along such a vector field with very few steps. For example, if an ODE \n \n \n \n \n \n \n \n ϕ\n \n t\n \n \n ˙\n \n \n \n (\n x\n )\n =\n \n v\n \n t\n \n \n (\n \n ϕ\n \n t\n \n \n (\n x\n )\n )\n \n \n {\\displaystyle {\\dot {\\phi _{t}}}(x)=v_{t}(\\phi _{t}(x))}\n \n follows perfectly straight paths, it simplifies to \n \n \n \n \n ϕ\n \n t\n \n \n (\n x\n )\n =\n \n x\n \n 0\n \n \n +\n t\n ⋅\n \n v\n \n 0\n \n \n (\n \n x\n \n 0\n \n \n )\n \n \n {\\displaystyle \\phi _{t}(x)=x_{0}+t\\cdot v_{0}(x_{0})}\n \n, allowing for exact solutions in one step. In practice, we cannot reach such perfection, but when the flow field is nearly so, we can take a few large steps instead of many little steps. \n\nThe general idea is to start with two distributions \n \n \n \n \n π\n \n 0\n \n \n \n \n {\\displaystyle \\pi _{0}}\n \n and \n \n \n \n \n π\n \n 1\n \n \n \n \n {\\displaystyle \\pi _{1}}\n \n, then construct a flow field \n \n \n \n \n ϕ\n \n 0\n \n \n =\n {\n \n ϕ\n \n t\n \n \n :\n t\n ∈\n [\n 0\n ,\n 1\n ]\n }\n \n \n {\\displaystyle \\phi ^{0}=\\{\\phi _{t}:t\\in [0,1]\\}}\n \n from it, then repeatedly apply a \"reflow\" operation to obtain successive flow fields \n \n \n \n \n ϕ\n \n 1\n \n \n ,\n \n ϕ\n \n 2\n \n \n ,\n …\n \n \n {\\displaystyle \\phi ^{1},\\phi ^{2},\\dots }\n \n, each straighter than the previous one. When the flow field is straight enough for the application, we stop.\nGenerally, for any time-differentiable process \n \n \n \n \n ϕ\n \n t\n \n \n \n \n {\\displaystyle \\phi _{t}}\n \n, \n \n \n \n \n v\n \n t\n \n \n \n \n {\\displaystyle v_{t}}\n \n can be estimated by solving:\n\n \n \n \n \n min\n \n θ\n \n \n \n ∫\n \n 0\n \n \n 1\n \n \n \n \n E\n \n \n x\n ∼\n \n p\n \n t\n \n \n \n \n \n [\n \n ‖\n \n \n v\n \n t\n \n \n (\n x\n ,\n θ\n )\n −\n \n v\n \n t\n \n \n (\n x\n )\n \n \n ‖\n \n 2\n \n \n \n ]\n \n \n \n d\n \n t\n .\n \n \n {\\displaystyle \\min _{\\theta }\\int _{0}^{1}\\mathbb {E} _{x\\sim p_{t}}\\left[\\lVert {v_{t}(x,\\theta )-v_{t}(x)}\\rVert ^{2}\\right]\\,\\mathrm {d} t.}\n \n\nIn rectified flow, by injecting strong priors that intermediate trajectories are straight, it can achieve both theoretical relevance for optimal transport and computational efficiency, as ODEs with straight paths can be simulated precisely without time discretization.\n\nSpecifically, rectified flow seeks to match an ODE with the marginal distributions of the linear interpolation between points from distributions \n \n \n \n \n π\n \n 0\n \n \n \n \n {\\displaystyle \\pi _{0}}\n \n and \n \n \n \n \n π\n \n 1\n \n \n \n \n {\\displaystyle \\pi _{1}}\n \n. Given observations \n \n \n \n \n x\n \n 0\n \n \n ∼\n \n π\n \n 0\n \n \n \n \n {\\displaystyle x_{0}\\sim \\pi _{0}}\n \n and \n \n \n \n \n x\n \n 1\n \n \n ∼\n \n π\n \n 1\n \n \n \n \n {\\displaystyle x_{1}\\sim \\pi _{1}}\n \n, the canonical linear interpolation \n \n \n \n \n x\n \n t\n \n \n =\n t\n \n x\n \n 1\n \n \n +\n (\n 1\n −\n t\n )\n \n x\n \n 0\n \n \n ,\n t\n ∈\n [\n 0\n ,\n 1\n ]\n \n \n {\\displaystyle x_{t}=tx_{1}+(1-t)x_{0},t\\in [0,1]}\n \n yields a trivial case \n \n \n \n \n \n \n \n x\n ˙\n \n \n \n \n t\n \n \n =\n \n x\n \n 1\n \n \n −\n \n x\n \n 0\n \n \n \n \n {\\displaystyle {\\dot {x}}_{t}=x_{1}-x_{0}}\n \n, which cannot be causally simulated without \n \n \n \n \n x\n \n 1\n \n \n \n \n {\\displaystyle x_{1}}\n \n. To address this, \n \n \n \n \n x\n \n t\n \n \n \n \n {\\displaystyle x_{t}}\n \n is \"projected\" into a space of causally simulatable ODEs, by minimizing the least squares loss with respect to the direction \n \n \n \n \n x\n \n 1\n \n \n −\n \n x\n \n 0\n \n \n \n \n {\\displaystyle x_{1}-x_{0}}\n \n:\n\n \n \n \n \n min\n \n θ\n \n \n \n ∫\n \n 0\n \n \n 1\n \n \n \n \n E\n \n \n \n π\n \n 0\n \n \n ,\n \n π\n \n 1\n \n \n ,\n \n p\n \n t\n \n \n \n \n \n [\n \n ‖\n \n (\n \n x\n \n 1\n \n \n −\n \n x\n \n 0\n \n \n )\n −\n \n v\n \n t\n \n \n (\n \n x\n \n t\n \n \n )\n \n \n ‖\n \n 2\n \n \n \n ]\n \n \n \n d\n \n t\n .\n \n \n {\\displaystyle \\min _{\\theta }\\int _{0}^{1}\\mathbb {E} _{\\pi _{0},\\pi _{1},p_{t}}\\left[\\lVert {(x_{1}-x_{0})-v_{t}(x_{t})}\\rVert ^{2}\\right]\\,\\mathrm {d} t.}\n \n\nThe data pair \n \n \n \n (\n \n x\n \n 0\n \n \n ,\n \n x\n \n 1\n \n \n )\n \n \n {\\displaystyle (x_{0},x_{1})}\n \n can be any coupling of \n \n \n \n \n π\n \n 0\n \n \n \n \n {\\displaystyle \\pi _{0}}\n \n and \n \n \n \n \n π\n \n 1\n \n \n \n \n {\\displaystyle \\pi _{1}}\n \n, typically independent (i.e., \n \n \n \n (\n \n x\n \n 0\n \n \n ,\n \n x\n \n 1\n \n \n )\n ∼\n \n π\n \n 0\n \n \n ×\n \n π\n \n 1\n \n \n \n \n {\\displaystyle (x_{0},x_{1})\\sim \\pi _{0}\\times \\pi _{1}}\n \n) obtained by randomly combining observations from \n \n \n \n \n π\n \n 0\n \n \n \n \n {\\displaystyle \\pi _{0}}\n \n and \n \n \n \n \n π\n \n 1\n \n \n \n \n {\\displaystyle \\pi _{1}}\n \n. This process ensures that the trajectories closely mirror the density map of \n \n \n \n \n x\n \n t\n \n \n \n \n {\\displaystyle x_{t}}\n \n trajectories but reroute at intersections to ensure causality.\n\nA distinctive aspect of rectified flow is its capability for \"reflow\", which straightens the trajectory of ODE paths. Denote the rectified flow \n \n \n \n \n ϕ\n \n 0\n \n \n =\n {\n \n ϕ\n \n t\n \n \n :\n t\n ∈\n [\n 0\n ,\n 1\n ]\n }\n \n \n {\\displaystyle \\phi ^{0}=\\{\\phi _{t}:t\\in [0,1]\\}}\n \n induced from \n \n \n \n (\n \n x\n \n 0\n \n \n ,\n \n x\n \n 1\n \n \n )\n \n \n {\\displaystyle (x_{0},x_{1})}\n \n as \n \n \n \n \n ϕ\n \n 0\n \n \n =\n \n \n R\n e\n c\n t\n f\n l\n o\n w\n \n \n (\n (\n \n x\n \n 0\n \n \n ,\n \n x\n \n 1\n \n \n )\n )\n \n \n {\\displaystyle \\phi ^{0}={\\mathsf {Rectflow}}((x_{0},x_{1}))}\n \n. Recursively applying this \n \n \n \n \n \n R\n e\n c\n t\n f\n l\n o\n w\n \n \n (\n ⋅\n )\n \n \n {\\displaystyle {\\mathsf {Rectflow}}(\\cdot )}\n \n operator generates a series of rectified flows \n \n \n \n \n ϕ\n \n k\n +\n 1\n \n \n =\n \n \n R\n e\n c\n t\n f\n l\n o\n w\n \n \n (\n (\n \n ϕ\n \n 0\n \n \n k\n \n \n (\n \n x\n \n 0\n \n \n )\n ,\n \n ϕ\n \n 1\n \n \n k\n \n \n (\n \n x\n \n 1\n \n \n )\n )\n )\n \n \n {\\displaystyle \\phi ^{k+1}={\\mathsf {Rectflow}}((\\phi _{0}^{k}(x_{0}),\\phi _{1}^{k}(x_{1})))}\n \n. This \"reflow\" process not only reduces transport costs but also straightens the paths of rectified flows, making \n \n \n \n \n ϕ\n \n k\n \n \n \n \n {\\displaystyle \\phi ^{k}}\n \n paths straighter with increasing \n \n \n \n k\n \n \n {\\displaystyle k}\n \n.\nRectified flow includes a nonlinear extension where linear interpolation \n \n \n \n \n x\n \n t\n \n \n \n \n {\\displaystyle x_{t}}\n \n is replaced with any time-differentiable curve that connects \n \n \n \n \n x\n \n 0\n \n \n \n \n {\\displaystyle x_{0}}\n \n and \n \n \n \n \n x\n \n 1\n \n \n \n \n {\\displaystyle x_{1}}\n \n, given by \n \n \n \n \n x\n \n t\n \n \n =\n \n α\n \n t\n \n \n \n x\n \n 1\n \n \n +\n \n β\n \n t\n \n \n \n x\n \n 0\n \n \n \n \n {\\displaystyle x_{t}=\\alpha _{t}x_{1}+\\beta _{t}x_{0}}\n \n. This framework encompasses DDIM and probability flow ODEs as special cases, with particular choices of \n \n \n \n \n α\n \n t\n \n \n \n \n {\\displaystyle \\alpha _{t}}\n \n and \n \n \n \n \n β\n \n t\n \n \n \n \n {\\displaystyle \\beta _{t}}\n \n. However, in the case where the path of \n \n \n \n \n x\n \n t\n \n \n \n \n {\\displaystyle x_{t}}\n \n is not straight, the reflow process no longer ensures a reduction in convex transport costs, and also no longer straighten the paths of \n \n \n \n \n ϕ\n \n t\n \n \n \n \n {\\displaystyle \\phi _{t}}\n \n.\nThese linear flow formulations were independently discovered and adapted from a different perspective for supervised inverse problems. For example, Inversion by Direct Iteration (InDI) formulates image restoration by learning a residual flow ODE that iteratively reverses a linear interpolation between a degraded input and a high-quality target to avoid regression-to-the-mean. InDI is effective for a variety of image restoration tasks.\n\n\nChoice of architecture\n\n\nDiffusion model\nFor generating images by DDPM, we need a neural network that takes a time \n \n \n \n t\n \n \n {\\displaystyle t}\n \n and a noisy image \n \n \n \n \n x\n \n t\n \n \n \n \n {\\displaystyle x_{t}}\n \n, and predicts a noise \n \n \n \n \n ϵ\n \n θ\n \n \n (\n \n x\n \n t\n \n \n ,\n t\n )\n \n \n {\\displaystyle \\epsilon _{\\theta }(x_{t},t)}\n \n from it. Since predicting the noise is the same as predicting the denoised image, then subtracting it from \n \n \n \n \n x\n \n t\n \n \n \n \n {\\displaystyle x_{t}}\n \n, denoising architectures tend to work well. For example, the U-Net, which was found to be good for denoising images, is often used for denoising diffusion models that generate images.\nFor DDPM, the underlying architecture (\"backbone\") does not have to be a U-Net. It just has to predict the noise somehow. For example, the diffusion transformer (DiT) uses a Transformer to predict the mean and diagonal covariance of the noise, given the textual conditioning and the partially denoised image. It is the same as standard U-Net-based denoising diffusion model, with a Transformer replacing the U-Net. Mixture of experts-Transformer can also be applied.\nDDPM can be used to model general data distributions, not just natural-looking images. For example, Human Motion Diffusion models human motion trajectory by DDPM. Each human motion trajectory is a sequence of poses, represented by either joint rotations or positions. It uses a Transformer network to generate a less noisy trajectory out of a noisy one.\n\n\nConditioning\nThe base diffusion model can only generate unconditionally from the whole distribution. For example, a diffusion model learned on ImageNet would generate images that look like a random image from ImageNet. To generate images from just one category, one would need to impose the condition, and then sample from the conditional distribution. Whatever condition one wants to impose, one needs to first convert the conditioning into a vector of floating point numbers, then feed it into the underlying diffusion model neural network. However, one has freedom in choosing how to convert the conditioning into a vector.\nStable Diffusion, for example, imposes conditioning in the form of cross-attention mechanism, where the query is an intermediate representation of the image in the U-Net, and both key and value are the conditioning vectors. The conditioning can be selectively applied to only parts of an image, and new kinds of conditionings can be finetuned upon the base model, as used in ControlNet.\nAs a particularly simple example, consider image inpainting. The conditions are \n \n \n \n \n \n \n x\n ~\n \n \n \n \n \n {\\displaystyle {\\tilde {x}}}\n \n, the reference image, and \n \n \n \n m\n \n \n {\\displaystyle m}\n \n, the inpainting mask. The conditioning is imposed at each step of the backward diffusion process, by first sampling \n \n \n \n \n \n \n \n x\n ~\n \n \n \n \n t\n \n \n ∼\n N\n \n (\n \n \n \n \n \n \n \n α\n ¯\n \n \n \n \n t\n \n \n \n \n \n \n \n x\n ~\n \n \n \n ,\n \n σ\n \n t\n \n \n 2\n \n \n I\n \n )\n \n \n \n {\\displaystyle {\\tilde {x}}_{t}\\sim N\\left({\\sqrt {{\\bar {\\alpha }}_{t}}}{\\tilde {x}},\\sigma _{t}^{2}I\\right)}\n \n, a noisy version of \n \n \n \n \n \n \n x\n ~\n \n \n \n \n \n {\\displaystyle {\\tilde {x}}}\n \n, then replacing \n \n \n \n \n x\n \n t\n \n \n \n \n {\\displaystyle x_{t}}\n \n with \n \n \n \n (\n 1\n −\n m\n )\n ⊙\n \n x\n \n t\n \n \n +\n m\n ⊙\n \n \n \n \n x\n ~\n \n \n \n \n t\n \n \n \n \n {\\displaystyle (1-m)\\odot x_{t}+m\\odot {\\tilde {x}}_{t}}\n \n, where \n \n \n \n ⊙\n \n \n {\\displaystyle \\odot }\n \n means elementwise multiplication. Another application of cross-attention mechanism is prompt-to-prompt image editing.\nConditioning is not limited to just generating images from a specific category, or according to a specific caption (as in text-to-image). For example, demonstrated generating human motion, conditioned on an audio clip of human walking (allowing syncing motion to a soundtrack), or video of human running, or a text description of human motion, etc. For how conditional diffusion models are mathematically formulated, see a methodological summary in.\n\n\nUpscaling\nAs generating an image takes a long time, one can try to generate a small image by a base diffusion model, then upscale it by other models. Upscaling can be done by GAN, Transformer, or signal processing methods like Lanczos resampling.\nDiffusion models themselves can be used to perform upscaling. Cascading diffusion model stacks multiple diffusion models one after another, in the style of Progressive GAN. The lowest level is a standard diffusion model that generate 32x32 image, then the image would be upscaled by a diffusion model specifically trained for upscaling, and the process repeats.\nIn more detail, the diffusion upscaler is trained as follows:\n\nSample \n \n \n \n (\n \n x\n \n 0\n \n \n ,\n \n z\n \n 0\n \n \n ,\n c\n )\n \n \n {\\displaystyle (x_{0},z_{0},c)}\n \n, where \n \n \n \n \n x\n \n 0\n \n \n \n \n {\\displaystyle x_{0}}\n \n is the high-resolution image, \n \n \n \n \n z\n \n 0\n \n \n \n \n {\\displaystyle z_{0}}\n \n is the same image but scaled down to a low-resolution, and \n \n \n \n c\n \n \n {\\displaystyle c}\n \n is the conditioning, which can be the caption of the image, the class of the image, etc.\nSample two white noises \n \n \n \n \n ϵ\n \n x\n \n \n ,\n \n ϵ\n \n z\n \n \n \n \n {\\displaystyle \\epsilon _{x},\\epsilon _{z}}\n \n, two time-steps \n \n \n \n \n t\n \n x\n \n \n ,\n \n t\n \n z\n \n \n \n \n {\\displaystyle t_{x},t_{z}}\n \n. Compute the noisy versions of the high-resolution and low-resolution images: \n \n \n \n \n \n {\n \n \n \n \n x\n \n \n t\n \n x\n \n \n \n \n \n \n =\n \n \n \n \n \n \n α\n ¯\n \n \n \n \n \n t\n \n x\n \n \n \n \n \n \n \n x\n \n 0\n \n \n +\n \n σ\n \n \n t\n \n x\n \n \n \n \n \n ϵ\n \n x\n \n \n \n \n \n \n \n z\n \n \n t\n \n z\n \n \n \n \n \n \n =\n \n \n \n \n \n \n α\n ¯\n \n \n \n \n \n t\n \n z\n \n \n \n \n \n \n \n z\n \n 0\n \n \n +\n \n σ\n \n \n t\n \n z\n \n \n \n \n \n ϵ\n \n z\n \n \n \n \n \n \n \n \n \n \n {\\displaystyle {\\begin{cases}x_{t_{x}}&={\\sqrt {{\\bar {\\alpha }}_{t_{x}}}}x_{0}+\\sigma _{t_{x}}\\epsilon _{x}\\\\z_{t_{z}}&={\\sqrt {{\\bar {\\alpha }}_{t_{z}}}}z_{0}+\\sigma _{t_{z}}\\epsilon _{z}\\end{cases}}}\n \n.\nTrain the denoising network to predict \n \n \n \n \n ϵ\n \n x\n \n \n \n \n {\\displaystyle \\epsilon _{x}}\n \n given \n \n \n \n \n x\n \n \n t\n \n x\n \n \n \n \n ,\n \n z\n \n \n t\n \n z\n \n \n \n \n ,\n \n t\n \n x\n \n \n ,\n \n t\n \n z\n \n \n ,\n c\n \n \n {\\displaystyle x_{t_{x}},z_{t_{z}},t_{x},t_{z},c}\n \n. That is, apply gradient descent on \n \n \n \n θ\n \n \n {\\displaystyle \\theta }\n \n on the L2 loss \n \n \n \n ‖\n \n ϵ\n \n θ\n \n \n (\n \n x\n \n \n t\n \n x\n \n \n \n \n ,\n \n z\n \n \n t\n \n z\n \n \n \n \n ,\n \n t\n \n x\n \n \n ,\n \n t\n \n z\n \n \n ,\n c\n )\n −\n \n ϵ\n \n x\n \n \n \n ‖\n \n 2\n \n \n 2\n \n \n \n \n {\\displaystyle \\|\\epsilon _{\\theta }(x_{t_{x}},z_{t_{z}},t_{x},t_{z},c)-\\epsilon _{x}\\|_{2}^{2}}\n \n.\n\n\nExamples\nThis section collects some notable diffusion models, and briefly describes their architecture.\n\n\nOpenAI\n\nThe DALL-E series by OpenAI are text-conditional diffusion models of images.\nThe first version of DALL-E (2021) is not actually a diffusion model. Instead, it uses a Transformer architecture that autoregressively generates a sequence of tokens, which is then converted to an image by the decoder of a discrete VAE. Released with DALL-E was the CLIP classifier, which was used by DALL-E to rank generated images according to how close the image fits the text.\nGLIDE (2022–03) is a 3.5-billion diffusion model, and a small version was released publicly. Soon after, DALL-E 2 was released (2022–04). DALL-E 2 is a 3.5-billion cascaded diffusion model that generates images from text by \"inverting the CLIP image encoder\", the technique which they termed \"unCLIP\".\nThe unCLIP method contains 4 models: a CLIP image encoder, a CLIP text encoder, an image decoder, and a \"prior\" model (which can be a diffusion model, or an autoregressive model). During training, the prior model is trained to convert CLIP image encodings to CLIP text encodings. The image decoder is trained to convert CLIP image encodings back to images. During inference, a text is converted by the CLIP text encoder to a vector, then it is converted by the prior model to an image encoding, then it is converted by the image decoder to an image.\nSora (2024–02) is a diffusion Transformer model (DiT).\n\n\nLightricks\n\nLTX is a family of open source artificial intelligence video foundation models developed by Lightricks, first released in November 2024. The latest models, LTX-2, create videos based on user prompts, conditioned on text, images, video or audio - and capable of generating audio and visual in a unified way. They were preceded by LTX Video, which was released in 2024 as the company's first text-to-video model.\n\n\nStability AI\n\nStable Diffusion (2022–08), released by Stability AI, consists of a denoising latent diffusion model (860 million parameters), a VAE, and a text encoder. The denoising network is a U-Net, with cross-attention blocks to allow for conditional image generation.\nStable Diffusion 3 (2024–03) changed the latent diffusion model from the UNet to a Transformer model, and so it is a DiT. It uses rectified flow.\nStable Video 4D (2024–07) is a latent diffusion model for videos of 3D objects.\n\n\nGoogle\nImagen (2022) uses a T5-XXL language model to encode the input text into an embedding vector. It is a cascaded diffusion model with three sub-models. The first step denoises a white noise to a 64×64 image, conditional on the embedding vector of the text. This model has 2B parameters. The second step upscales the image by 64×64→256×256, conditional on embedding. This model has 650M parameters. The third step is similar, upscaling by 256×256→1024×1024. This model has 400M parameters. The three denoising networks are all U-Nets.\nMuse (2023–01) is not a diffusion model, but an encoder-only Transformer that is trained to predict masked image tokens from unmasked image tokens.\nImagen 2 (2023–12) is also diffusion-based. It can generate images based on a prompt that mixes images and text. No further information available. Imagen 3 (2024–05) is too. No further information available.\nVeo (2024) generates videos by latent diffusion. The diffusion is conditioned on a vector that encodes both a text prompt and an image prompt.\n\n\nMeta\nMake-A-Video (2022) is a text-to-video diffusion model.\nCM3leon (2023) is not a diffusion model, but an autoregressive causally masked Transformer, with mostly the same architecture as LLaMa-2.\n\nTransfusion (2024) is a Transformer that combines autoregressive text generation and denoising diffusion. Specifically, it generates text autoregressively (with causal masking), and generates images by denoising multiple times over image tokens (with all-to-all attention).\nMovie Gen (2024) is a series of Diffusion Transformers operating on latent space and by flow matching.\n\n\nSee also\nDiffusion process\nMarkov chain\nVariational inference\nVariational autoencoder\n\n\nFurther reading\nReview papers\nYang, Ling (2024-09-06), YangLing0818/Diffusion-Models-Papers-Survey-Taxonomy, retrieved 2024-09-06\nYang, Ling; Zhang, Zhilong; Song, Yang; Hong, Shenda; Xu, Runsheng; Zhao, Yue; Zhang, Wentao; Cui, Bin; Yang, Ming-Hsuan (2023-11-09). \"Diffusion Models: A Comprehensive Survey of Methods and Applications\". ACM Comput. Surv. 56 (4): 105:1–105:39. arXiv:2209.00796. doi:10.1145/3626235. ISSN 0360-0300.\nAustin, Jacob; Johnson, Daniel D.; Ho, Jonathan; Tarlow, Daniel; Rianne van den Berg (2021). \"Structured Denoising Diffusion Models in Discrete State-Spaces\". arXiv:2107.03006 [cs.LG].\nCroitoru, Florinel-Alin; Hondru, Vlad; Ionescu, Radu Tudor; Shah, Mubarak (2023-09-01). \"Diffusion Models in Vision: A Survey\". IEEE Transactions on Pattern Analysis and Machine Intelligence. 45 (9): 10850–10869. arXiv:2209.04747. Bibcode:2023ITPAM..4510850C. doi:10.1109/TPAMI.2023.3261988. ISSN 0162-8828. PMID 37030794.\nMathematical details omitted in the article.\n\"Power of Diffusion Models\". AstraBlog. 2022-09-25. Retrieved 2023-09-25.\nLuo, Calvin (2022-08-25). \"Understanding Diffusion Models: A Unified Perspective\". arXiv:2208.11970 [cs.LG].\nWeng, Lilian (2021-07-11). \"What are Diffusion Models?\". lilianweng.github.io. Retrieved 2023-09-25.\nTutorials\nNakkiran, Preetum; Bradley, Arwen; Zhou, Hattie; Advani, Madhu (2024). \"Step-by-Step Diffusion: An Elementary Tutorial\". arXiv:2406.08929 [cs.LG].\n\"Guidance: a cheat code for diffusion models\". 26 May 2022. Overview of classifier guidance and classifier-free guidance, light on mathematical details.\nCatherine Higham, Desmond J. Higham, and Peter Grindrod: \"Diffusion Models for Generative Artificial Intelligence: An Introduction for Applied Mathematicians\", SIAM Review, Vol.67, No.3 (2025).\n\n\nReferences", "categories": ["All articles containing potentially dated statements", "All articles with specifically marked weasel-worded phrases", "Articles containing potentially dated statements from 2024", "Articles with short description", "Articles with specifically marked weasel-worded phrases from December 2025", "CS1 errors: generic name", "Machine learning algorithms", "Markov models", "Short description is different from Wikidata", "Wikipedia articles needing clarification from February 2026"], "references": ["http://proceedings.mlr.press/v37/sohl-dickstein15.pdf", "https://arxiv.org/abs/2111.14822", "https://arxiv.org/abs/2209.04747", "https://arxiv.org/abs/2204.06125", "https://benanne.github.io/2022/05/26/guidance.html", "https://arxiv.org/abs/2011.13456", "https://arxiv.org/abs/2105.05233", "https://arxiv.org/abs/2207.12598", "https://arxiv.org/abs/2112.10741", "https://arxiv.org/archive/cs.LG", "https://arxiv.org/archive/cs.CV", "https://proceedings.neurips.cc/paper/2020/hash/4c5bcfec8584af0d967f1ab10179ca4b-Abstract.html", "https://lilianweng.github.io/posts/2021-07-11-diffusion-models/", "https://yang-song.net/blog/2021/score/", "https://yang-song.net/blog/2019/ssm/"], "images": ["File:Diffusion Architecture.png"], "sub_niche": "International Conference on Machine Learning"} {"title": "Active learning (machine learning)", "url": "https://en.wikipedia.org/wiki/Active_learning_(machine_learning)", "summary": "Active learning is a special case of machine learning in which a learning algorithm can interactively query a human user (or some other information source) to label new data points with the desired outputs. The human user must possess expertise in the problem domain, including the ability to consult authoritative sources when necessary. In statistics literature, it is sometimes also called optimal experimental design. The information source is also called teacher or oracle.\nThere are situations in which unlabeled data is abundant but manual labeling is expensive. In such a scenario, learning algorithms can actively query the teacher for labels. Since the learner chooses the examples, the number of examples to learn a concept can often be much lower than the number required in normal superv", "content": "Active learning is a special case of machine learning in which a learning algorithm can interactively query a human user (or some other information source) to label new data points with the desired outputs. The human user must possess expertise in the problem domain, including the ability to consult authoritative sources when necessary. In statistics literature, it is sometimes also called optimal experimental design. The information source is also called teacher or oracle.\nThere are situations in which unlabeled data is abundant but manual labeling is expensive. In such a scenario, learning algorithms can actively query the teacher for labels. Since the learner chooses the examples, the number of examples to learn a concept can often be much lower than the number required in normal supervised learning. However, there is a risk that the algorithm is overwhelmed by uninformative examples. Recent developments are dedicated to multi-label active learning, hybrid active learning and active learning in a single-pass (on-line) context, combining concepts from the field of machine learning (e.g. conflict and ignorance) with adaptive, incremental learning policies in the field of online machine learning. Using active learning allows for faster development of a machine learning algorithm, when comparative updates would require a quantum or super computer.\nLarge-scale active learning projects may benefit from crowdsourcing frameworks such as Amazon Mechanical Turk that include many humans in the active learning loop.\n\n\nDefinitions\nLet T be the total set of all data under consideration. For example, in a protein engineering problem, T would include all proteins that are known to have a certain interesting activity and all additional proteins that one might want to test for that activity.\nDuring each iteration, i, T is broken up into three subsets\n\n \n \n \n \n \n T\n \n \n K\n ,\n i\n \n \n \n \n {\\displaystyle \\mathbf {T} _{K,i}}\n \n: Data points where the label is known.\n\n \n \n \n \n \n T\n \n \n U\n ,\n i\n \n \n \n \n {\\displaystyle \\mathbf {T} _{U,i}}\n \n: Data points where the label is unknown.\n\n \n \n \n \n \n T\n \n \n C\n ,\n i\n \n \n \n \n {\\displaystyle \\mathbf {T} _{C,i}}\n \n: A subset of TU,i that is chosen to be labeled.\nMost of the current research in active learning involves the best method to choose the data points for TC,i.\n\n\nScenarios\nPool-based sampling: In this approach, which is the most well known scenario, the learning algorithm attempts to evaluate the entire dataset before selecting data points (instances) for labeling. It is often initially trained on a fully labeled subset of the data using a machine-learning method such as logistic regression or SVM that yields class-membership probabilities for individual data instances. The candidate instances are those for which the prediction is most ambiguous. Instances are drawn from the entire data pool and assigned a confidence score, a measurement of how well the learner \"understands\" the data. The system then selects the instances for which it is the least confident and queries the teacher for the labels. The theoretical drawback of pool-based sampling is that it is memory-intensive and is therefore limited in its capacity to handle enormous datasets, but in practice, the rate-limiting factor is that the teacher is typically a (fatiguable) human expert who must be paid for their effort, rather than computer memory.\nStream-based selective sampling: Here, each consecutive unlabeled instance is examined one at a time with the machine evaluating the informativeness of each item against its query parameters. The learner decides for itself whether to assign a label or query the teacher for each datapoint. As contrasted with Pool-based sampling, the obvious drawback of stream-based methods is that the learning algorithm does not have sufficient information, early in the process, to make a sound assign-label-vs ask-teacher decision, and it does not capitalize as efficiently on the presence of already labeled data. Therefore, the teacher is likely to spend more effort in supplying labels than with the pool-based approach.\nMembership query synthesis: This is where the learner generates synthetic data from an underlying natural distribution. For example, if the dataset are pictures of humans and animals, the learner could send a clipped image of a leg to the teacher and query if this appendage belongs to an animal or human. This is particularly useful if the dataset is small. The challenge here, as with all synthetic-data-generation efforts, is in ensuring that the synthetic data is consistent in terms of meeting the constraints on real data. As the number of variables/features in the input data increase, and strong dependencies between variables exist, it becomes increasingly difficult to generate synthetic data with sufficient fidelity. For example, to create a synthetic data set for human laboratory-test values, the sum of the various white blood cell (WBC) components in a white blood cell differential must equal 100, since the component numbers are really percentages. Similarly, the enzymes alanine transaminase (ALT) and aspartate transaminase (AST) measure liver function (though AST is also produced by other tissues, e.g., lung, pancreas) A synthetic data point with AST at the lower limit of normal range (8–33 units/L) with an ALT several times above normal range (4–35 units/L) in a simulated chronically ill patient would be physiologically impossible.\n\n\nQuery strategies\nAlgorithms for determining which data points should be labeled can be organized into a number of different categories, based upon their purpose:\n\nBalance exploration and exploitation: the choice of examples to label is seen as a dilemma between the exploration and the exploitation over the data space representation. This strategy manages this compromise by modelling the active learning problem as a contextual bandit problem. For example, Bouneffouf et al. propose a sequential algorithm named Active Thompson Sampling (ATS), which, in each round, assigns a sampling distribution on the pool, samples one point from this distribution, and queries the oracle for this sample point label.\nExpected model change: label those points that would most change the current model.\nExpected error reduction: label those points that would most reduce the model's generalization error.\nExponentiated Gradient Exploration for Active Learning: In this paper, the author proposes a sequential algorithm named exponentiated gradient (EG)-active that can improve any active learning algorithm by an optimal random exploration.\nUncertainty sampling: label those points for which the current model is least certain as to what the correct output should be.\nQuery by committee: a variety of models are trained on the current labeled data, and vote on the output for unlabeled data; label those points for which the \"committee\" disagrees the most\nQuerying from diverse subspaces or partitions: When the underlying model is a forest of trees, the leaf nodes might represent (overlapping) partitions of the original feature space. This offers the possibility of selecting instances from non-overlapping or minimally overlapping partitions for labeling.\nVariance reduction: label those points that would minimize output variance, which is one of the components of error.\nConformal prediction: predicts that a new data point will have a label similar to old data points in some specified way and degree of the similarity within the old examples is used to estimate the confidence in the prediction.\nMismatch-first farthest-traversal: The primary selection criterion is the prediction mismatch between the current model and nearest-neighbour prediction. It targets on wrongly predicted data points. The second selection criterion is the distance to previously selected data, the farthest first. It aims at optimizing the diversity of selected data.\nUser-centered labeling strategies: Learning is accomplished by applying dimensionality reduction to graphs and figures like scatter plots. Then the user is asked to label the compiled data (categorical, numerical, relevance scores, relation between two instances).\nA wide variety of algorithms have been studied that fall into these categories. While the traditional AL strategies can achieve remarkable performance, it is often challenging to predict in advance which strategy is the most suitable in a particular situation. In recent years, meta-learning algorithms have been gaining in popularity. Some of them have been proposed to tackle the problem of learning AL strategies instead of relying on manually designed strategies. A benchmark which compares 'meta-learning approaches to active learning' to 'traditional heuristic-based Active Learning' may give intuitions if 'Learning active learning' is at the crossroads \n\n\nMinimum marginal hyperplane\nSome active learning algorithms are built upon support-vector machines (SVMs) and exploit the structure of the SVM to determine which data points to label. Such methods usually calculate the margin, W, of each unlabeled datum in TU,i and treat W as an n-dimensional distance from that datum to the separating hyperplane.\nMinimum Marginal Hyperplane methods assume that the data with the smallest W are those that the SVM is most uncertain about and therefore should be placed in TC,i to be labeled. Other similar methods, such as Maximum Marginal Hyperplane, choose data with the largest W. Tradeoff methods choose a mix of the smallest and largest Ws.\n\n\nSee also\nList of datasets for machine learning research\nSample complexity\nBayesian optimization\nReinforcement learning\n\n\nLiterature\nImproving Generalization with Active Learning, David Cohn, Les Atlas & Richard Ladner, Machine Learning 15, 201–221 (1994). https://doi.org/10.1007/BF00993277\nBalcan, Maria-Florina & Hanneke, Steve & Wortman, Jennifer. (2008). The True Sample Complexity of Active Learning.. 45-56. https://link.springer.com/article/10.1007/s10994-010-5174-y\nActive Learning and Bayesian Optimization: a Unified Perspective to Learn with a Goal, Francesco Di Fiore, Michela Nardelli, Laura Mainini, https://arxiv.org/abs/2303.01560v2\nLearning how to Active Learn: A Deep Reinforcement Learning Approach, Meng Fang, Yuan Li, Trevor Cohn, https://arxiv.org/abs/1708.02383v1\n\n\nReferences", "categories": ["Articles with short description", "Machine learning", "Short description is different from Wikidata"], "references": ["https://hal.archives-ouvertes.fr/hal-01069802", "https://github.com/shubhomoydas/ad_examples#query-diversity-with-compact-descriptions", "http://espace.library.uq.edu.au/view/UQ:344582/UQ344582_OA.pdf", "https://hal.archives-ouvertes.fr/hal-01069802/file/Contextual_Bandit_for_Active_Learning.pdf", "https://api.semanticscholar.org/CorpusID:11569603", "https://api.semanticscholar.org/CorpusID:15285595", "https://api.semanticscholar.org/CorpusID:14313852", "https://api.semanticscholar.org/CorpusID:115384000", "http://machinelearning202.pbworks.com/f/Rubens-Active-Learning-RecSysHB2010.pdf", "https://api.semanticscholar.org/CorpusID:3027214", "https://api.semanticscholar.org/CorpusID:1701357", "https://api.semanticscholar.org/CorpusID:51875861", "https://doi.org/10.1007%2F978-1-4899-7637-6", "https://hdl.handle.net/11311%2F1006123", "https://doi.org/10.1109%2FICDM.2016.0102"], "images": [], "sub_niche": "Active learning (machine learning)"} {"title": "Supervised learning", "url": "https://en.wikipedia.org/wiki/Supervised_learning", "summary": "In machine learning, supervised learning (SL) is a type of machine learning paradigm where an algorithm learns to map input data to a specific output based on example input-output pairs. This process involves training a statistical model using labeled data, meaning each piece of input data is provided with the correct output. The term \"supervised\" refers to the role of a teacher or supervisor who provides this training data, guiding the algorithm towards correct predictions. For instance, if you want a model to identify cats in images, supervised learning would involve feeding it many images of cats (inputs) that are explicitly labeled \"cat\" (outputs).\nThe goal of supervised learning is for the trained model to accurately predict the output for new, unseen data. This requires the algorithm", "content": "In machine learning, supervised learning (SL) is a type of machine learning paradigm where an algorithm learns to map input data to a specific output based on example input-output pairs. This process involves training a statistical model using labeled data, meaning each piece of input data is provided with the correct output. The term \"supervised\" refers to the role of a teacher or supervisor who provides this training data, guiding the algorithm towards correct predictions. For instance, if you want a model to identify cats in images, supervised learning would involve feeding it many images of cats (inputs) that are explicitly labeled \"cat\" (outputs).\nThe goal of supervised learning is for the trained model to accurately predict the output for new, unseen data. This requires the algorithm to effectively generalize from the training examples, a quality measured by its generalization error. Supervised learning is commonly used for tasks such as classification (predicting a category, e.g., spam or not spam), regression (predicting a numerical value, e.g., a house price), and conditional density estimation (predicting the probability distribution of the output given an input, denoted by \n \n \n \n p\n (\n y\n ∣\n x\n )\n \n \n {\\displaystyle p(y\\mid x)}\n \n).\n\n\nSteps to follow\nTo solve a given problem of supervised learning, the following steps must be performed:\n\nDetermine the type of training samples. Before doing anything else, the user should decide what kind of data is to be used as a training set. In the case of handwriting analysis, for example, this might be a single handwritten character, an entire handwritten word, an entire sentence of handwriting, or a full paragraph of handwriting.\nGather a training set. The training set needs to be representative of the real-world use of the function. Thus, a set of input objects is gathered together with corresponding outputs, either from human experts or from measurements.\nDetermine the input feature representation of the learned function. The accuracy of the learned function depends strongly on how the input object is represented. Typically, the input object is transformed into a feature vector, which contains a number of features that are descriptive of the object. The number of features should not be too large, because of the curse of dimensionality; but should contain enough information to accurately predict the output.\nDetermine the structure of the learned function and corresponding learning algorithm. For example, one may choose to use support-vector machines or decision trees.\nComplete the design. Run the learning algorithm on the gathered training set. Some supervised learning algorithms require the user to determine certain control parameters. These parameters may be adjusted by optimizing performance on a subset (called a validation set) of the training set, or via cross-validation.\nEvaluate the accuracy of the learned function. After parameter adjustment and learning, the performance of the resulting function should be measured on a test set that is separate from the training set.\n\n\nAlgorithm choice\nA wide range of supervised learning algorithms are available, each with its strengths and weaknesses. There is no single learning algorithm that works best on all supervised learning problems (see the No free lunch theorem).\nThere are four major issues to consider in supervised learning:\n\n\nBias–variance tradeoff\n\nA first issue is the tradeoff between bias and variance. Imagine that we have available several different, but equally good, training data sets. A learning algorithm is biased for a particular input \n \n \n \n x\n \n \n {\\displaystyle x}\n \n if, when trained on each of these data sets, it is systematically incorrect when predicting the correct output for \n \n \n \n x\n \n \n {\\displaystyle x}\n \n. A learning algorithm has high variance for a particular input \n \n \n \n x\n \n \n {\\displaystyle x}\n \n if it predicts different output values when trained on different training sets. The prediction error of a learned classifier is related to the sum of the bias and the variance of the learning algorithm. Generally, there is a tradeoff between bias and variance. A learning algorithm with low bias must be \"flexible\" so that it can fit the data well. But if the learning algorithm is too flexible, it will fit each training data set differently, and hence have high variance. A key aspect of many supervised learning methods is that they are able to adjust this tradeoff between bias and variance (either automatically or by providing a bias/variance parameter that the user can adjust).\n\n\nFunction complexity and amount of training data\nThe second issue is of the amount of training data available relative to the complexity of the \"true\" function (classifier or regression function). If the true function is simple, then an \"inflexible\" learning algorithm with high bias and low variance will be able to learn it from a small amount of data. But if the true function is highly complex (e.g., because it involves complex interactions among many different input features and behaves differently in different parts of the input space), then the function will only be able to learn with a large amount of training data paired with a \"flexible\" learning algorithm with low bias and high variance.\n\n\nDimensionality of the input space\nA third issue is the dimensionality of the input space. If the input feature vectors have large dimensions, learning the function can be difficult even if the true function only depends on a small number of those features. This is because the many \"extra\" dimensions can confuse the learning algorithm and cause it to have high variance. Hence, input data of large dimensions typically requires tuning the classifier to have low variance and high bias. In practice, if the engineer can manually remove irrelevant features from the input data, it will likely improve the accuracy of the learned function. In addition, there are many algorithms for feature selection that seek to identify the relevant features and discard the irrelevant ones. This is an instance of the more general strategy of dimensionality reduction, which seeks to map the input data into a lower-dimensional space prior to running the supervised learning algorithm.\n\n\nNoise in the output values\nA fourth issue is the degree of noise in the desired output values (the supervisory target variables). If the desired output values are often incorrect (because of human error or sensor errors), then the learning algorithm should not attempt to find a function that exactly matches the training examples. Attempting to fit the data too carefully leads to overfitting. You can overfit even when there are no measurement errors (stochastic noise) if the function you are trying to learn is too complex for your learning model. In such a situation, the part of the target function that cannot be modeled \"corrupts\" your training data – this phenomenon has been called deterministic noise. When either type of noise is present, it is better to go with a higher bias, lower variance estimator.\nIn practice, there are several approaches to alleviate noise in the output values such as early stopping to prevent overfitting as well as detecting and removing the noisy training examples prior to training the supervised learning algorithm. There are several algorithms that identify noisy training examples and removing the suspected noisy training examples prior to training has decreased generalization error with statistical significance.\n\n\nOther factors to consider\nOther factors to consider when choosing and applying a learning algorithm include the following:\n\nHeterogeneity of the data. If the feature vectors include features of many different kinds (discrete, discrete ordered, counts, continuous values), some algorithms are easier to apply than others. Many algorithms, including support-vector machines, linear regression, logistic regression, neural networks, and nearest neighbor methods, require that the input features be numerical and scaled to similar ranges (e.g., to the [-1,1] interval). Methods that employ a distance function, such as nearest neighbor methods and support-vector machines with Gaussian kernels, are particularly sensitive to this. An advantage of decision trees is that they easily handle heterogeneous data.\nRedundancy in the data. If the input features contain redundant information (e.g., highly correlated features), some learning algorithms (e.g., linear regression, logistic regression, and distance-based methods) will perform poorly because of numerical instabilities. These problems can often be solved by imposing some form of regularization.\nPresence of interactions and non-linearities. If each of the features makes an independent contribution to the output, then algorithms based on linear functions (e.g., linear regression, logistic regression, support-vector machines, naive Bayes) and distance functions (e.g., nearest neighbor methods, support-vector machines with Gaussian kernels) generally perform well. However, if there are complex interactions among features, then algorithms such as decision trees and neural networks work better, because they are specifically designed to discover these interactions. Linear methods can also be applied, but the engineer must manually specify the interactions when using them.\nWhen considering a new application, the engineer can compare multiple learning algorithms and experimentally determine which one works best on the problem at hand (see cross-validation). Tuning the performance of a learning algorithm can be very time-consuming. Given fixed resources, it is often better to spend more time collecting additional training data and more informative features than it is to spend extra time tuning the learning algorithms.\n\n\nAlgorithms\nThe most widely used learning algorithms are: \n\nSupport-vector machines\nLinear regression\nLogistic regression\nNaive Bayes\nLinear discriminant analysis\nDecision trees\nk-nearest neighbors algorithm\nNeural networks (e.g., Multilayer perceptron)\nSimilarity learning\n\n\nHow supervised learning algorithms work\nGiven a set of \n \n \n \n N\n \n \n {\\displaystyle N}\n \n training examples of the form \n \n \n \n {\n (\n \n x\n \n 1\n \n \n ,\n \n y\n \n 1\n \n \n )\n ,\n .\n .\n .\n ,\n (\n \n x\n \n N\n \n \n ,\n \n \n y\n \n N\n \n \n )\n }\n \n \n {\\displaystyle \\{(x_{1},y_{1}),...,(x_{N},\\;y_{N})\\}}\n \n such that \n \n \n \n \n x\n \n i\n \n \n \n \n {\\displaystyle x_{i}}\n \n is the feature vector of the \n \n \n \n i\n \n \n {\\displaystyle i}\n \n-th example and \n \n \n \n \n y\n \n i\n \n \n \n \n {\\displaystyle y_{i}}\n \n is its label (i.e., class), a learning algorithm seeks a function \n \n \n \n g\n :\n X\n →\n Y\n \n \n {\\displaystyle g:X\\to Y}\n \n, where \n \n \n \n X\n \n \n {\\displaystyle X}\n \n is the input space and \n \n \n \n Y\n \n \n {\\displaystyle Y}\n \n is the output space. The function \n \n \n \n g\n \n \n {\\displaystyle g}\n \n is an element of some space of possible functions \n \n \n \n G\n \n \n {\\displaystyle G}\n \n, usually called the hypothesis space. It is sometimes convenient to represent \n \n \n \n g\n \n \n {\\displaystyle g}\n \n using a scoring function \n \n \n \n f\n :\n X\n ×\n Y\n →\n \n R\n \n \n \n {\\displaystyle f:X\\times Y\\to \\mathbb {R} }\n \n such that \n \n \n \n g\n \n \n {\\displaystyle g}\n \n is defined as returning the \n \n \n \n y\n \n \n {\\displaystyle y}\n \n value that gives the highest score: \n \n \n \n g\n (\n x\n )\n =\n \n \n \n arg\n ⁡\n max\n \n y\n \n \n \n f\n (\n x\n ,\n y\n )\n \n \n {\\displaystyle g(x)={\\underset {y}{\\arg \\max }}\\;f(x,y)}\n \n. Let \n \n \n \n F\n \n \n {\\displaystyle F}\n \n denote the space of scoring functions.\nAlthough \n \n \n \n G\n \n \n {\\displaystyle G}\n \n and \n \n \n \n F\n \n \n {\\displaystyle F}\n \n can be any space of functions, many learning algorithms are probabilistic models where \n \n \n \n g\n \n \n {\\displaystyle g}\n \n takes the form of a conditional probability model \n \n \n \n g\n (\n x\n )\n =\n \n \n \n arg\n ⁡\n max\n \n y\n \n \n \n P\n (\n y\n \n |\n \n x\n )\n \n \n {\\displaystyle g(x)={\\underset {y}{\\arg \\max }}\\;P(y|x)}\n \n, or \n \n \n \n f\n \n \n {\\displaystyle f}\n \n takes the form of a joint probability model \n \n \n \n f\n (\n x\n ,\n y\n )\n =\n P\n (\n x\n ,\n y\n )\n \n \n {\\displaystyle f(x,y)=P(x,y)}\n \n. For example, naive Bayes and linear discriminant analysis are joint probability models, whereas logistic regression is a conditional probability model.\nThere are two basic approaches to choosing \n \n \n \n f\n \n \n {\\displaystyle f}\n \n or \n \n \n \n g\n \n \n {\\displaystyle g}\n \n: empirical risk minimization and structural risk minimization. Empirical risk minimization seeks the function that best fits the training data. Structural risk minimization includes a penalty function that controls the bias/variance tradeoff.\nIn both cases, it is assumed that the training set consists of a sample of independent and identically distributed pairs, \n \n \n \n (\n \n x\n \n i\n \n \n ,\n \n \n y\n \n i\n \n \n )\n \n \n {\\displaystyle (x_{i},\\;y_{i})}\n \n. In order to measure how well a function fits the training data, a loss function \n \n \n \n L\n :\n Y\n ×\n Y\n →\n \n \n R\n \n \n ≥\n 0\n \n \n \n \n {\\displaystyle L:Y\\times Y\\to \\mathbb {R} ^{\\geq 0}}\n \n is defined. For training example \n \n \n \n (\n \n x\n \n i\n \n \n ,\n \n \n y\n \n i\n \n \n )\n \n \n {\\displaystyle (x_{i},\\;y_{i})}\n \n, the loss of predicting the value \n \n \n \n \n \n \n y\n ^\n \n \n \n \n \n {\\displaystyle {\\hat {y}}}\n \n is \n \n \n \n L\n (\n \n y\n \n i\n \n \n ,\n \n \n \n y\n ^\n \n \n \n )\n \n \n {\\displaystyle L(y_{i},{\\hat {y}})}\n \n.\nThe risk \n \n \n \n R\n (\n g\n )\n \n \n {\\displaystyle R(g)}\n \n of function \n \n \n \n g\n \n \n {\\displaystyle g}\n \n is defined as the expected loss of \n \n \n \n g\n \n \n {\\displaystyle g}\n \n. This can be estimated from the training data as\n\n \n \n \n \n R\n \n e\n m\n p\n \n \n (\n g\n )\n =\n \n \n 1\n N\n \n \n \n ∑\n \n i\n \n \n L\n (\n \n y\n \n i\n \n \n ,\n g\n (\n \n x\n \n i\n \n \n )\n )\n \n \n {\\displaystyle R_{emp}(g)={\\frac {1}{N}}\\sum _{i}L(y_{i},g(x_{i}))}\n \n.\n\n\nEmpirical risk minimization\n\nIn empirical risk minimization, the supervised learning algorithm seeks the function \n \n \n \n g\n \n \n {\\displaystyle g}\n \n that minimizes \n \n \n \n R\n (\n g\n )\n \n \n {\\displaystyle R(g)}\n \n. Hence, a supervised learning algorithm can be constructed by applying an optimization algorithm to find \n \n \n \n g\n \n \n {\\displaystyle g}\n \n.\nWhen \n \n \n \n g\n \n \n {\\displaystyle g}\n \n is a conditional probability distribution \n \n \n \n P\n (\n y\n \n |\n \n x\n )\n \n \n {\\displaystyle P(y|x)}\n \n and the loss function is the negative log likelihood: \n \n \n \n L\n (\n y\n ,\n \n \n \n y\n ^\n \n \n \n )\n =\n −\n log\n ⁡\n P\n (\n y\n \n |\n \n x\n )\n \n \n {\\displaystyle L(y,{\\hat {y}})=-\\log P(y|x)}\n \n, then empirical risk minimization is equivalent to maximum likelihood estimation.\nWhen \n \n \n \n G\n \n \n {\\displaystyle G}\n \n contains many candidate functions or the training set is not sufficiently large, empirical risk minimization leads to high variance and poor generalization. The learning algorithm is able to memorize the training examples without generalizing well (overfitting).\n\n\nStructural risk minimization\nStructural risk minimization seeks to prevent overfitting by incorporating a regularization penalty into the optimization. The regularization penalty can be viewed as implementing a form of Occam's razor that prefers simpler functions over more complex ones.\nA wide variety of penalties have been employed that correspond to different definitions of complexity. For example, consider the case where the function \n \n \n \n g\n \n \n {\\displaystyle g}\n \n is a linear function of the form\n\n \n \n \n g\n (\n x\n )\n =\n \n ∑\n \n j\n =\n 1\n \n \n d\n \n \n \n β\n \n j\n \n \n \n x\n \n j\n \n \n \n \n {\\displaystyle g(x)=\\sum _{j=1}^{d}\\beta _{j}x_{j}}\n \n.\nA popular regularization penalty is \n \n \n \n \n ∑\n \n j\n \n \n \n β\n \n j\n \n \n 2\n \n \n \n \n {\\displaystyle \\sum _{j}\\beta _{j}^{2}}\n \n, which is the squared Euclidean norm of the weights, also known as the \n \n \n \n \n L\n \n 2\n \n \n \n \n {\\displaystyle L_{2}}\n \n norm. Other norms include the \n \n \n \n \n L\n \n 1\n \n \n \n \n {\\displaystyle L_{1}}\n \n norm, \n \n \n \n \n ∑\n \n j\n \n \n \n |\n \n \n β\n \n j\n \n \n \n |\n \n \n \n {\\displaystyle \\sum _{j}|\\beta _{j}|}\n \n, and the \n \n \n \n \n L\n \n 0\n \n \n \n \n {\\displaystyle L_{0}}\n \n \"norm\", which is the number of non-zero \n \n \n \n \n β\n \n j\n \n \n \n \n {\\displaystyle \\beta _{j}}\n \ns. The penalty will be denoted by \n \n \n \n C\n (\n g\n )\n \n \n {\\displaystyle C(g)}\n \n.\nThe supervised learning optimization problem is to find the function \n \n \n \n g\n \n \n {\\displaystyle g}\n \n that minimizes\n\n \n \n \n J\n (\n g\n )\n =\n \n R\n \n e\n m\n p\n \n \n (\n g\n )\n +\n λ\n C\n (\n g\n )\n .\n \n \n {\\displaystyle J(g)=R_{emp}(g)+\\lambda C(g).}\n \n\nThe parameter \n \n \n \n λ\n \n \n {\\displaystyle \\lambda }\n \n controls the bias-variance tradeoff. When \n \n \n \n λ\n =\n 0\n \n \n {\\displaystyle \\lambda =0}\n \n, this gives empirical risk minimization with low bias and high variance. When \n \n \n \n λ\n \n \n {\\displaystyle \\lambda }\n \n is large, the learning algorithm will have high bias and low variance. The value of \n \n \n \n λ\n \n \n {\\displaystyle \\lambda }\n \n can be chosen empirically via cross-validation.\nThe complexity penalty has a Bayesian interpretation as the negative log prior probability of \n \n \n \n g\n \n \n {\\displaystyle g}\n \n, \n \n \n \n −\n log\n ⁡\n P\n (\n g\n )\n \n \n {\\displaystyle -\\log P(g)}\n \n, in which case \n \n \n \n J\n (\n g\n )\n \n \n {\\displaystyle J(g)}\n \n is the posterior probability of \n \n \n \n g\n \n \n {\\displaystyle g}\n \n.\n\n\nGenerative training\nThe training methods described above are discriminative training methods, because they seek to find a function \n \n \n \n g\n \n \n {\\displaystyle g}\n \n that discriminates well between the different output values (see discriminative model). For the special case where \n \n \n \n f\n (\n x\n ,\n y\n )\n =\n P\n (\n x\n ,\n y\n )\n \n \n {\\displaystyle f(x,y)=P(x,y)}\n \n is a joint probability distribution and the loss function is the negative log likelihood \n \n \n \n −\n \n ∑\n \n i\n \n \n log\n ⁡\n P\n (\n \n x\n \n i\n \n \n ,\n \n y\n \n i\n \n \n )\n ,\n \n \n {\\displaystyle -\\sum _{i}\\log P(x_{i},y_{i}),}\n \n a risk minimization algorithm is said to perform generative training, because \n \n \n \n f\n \n \n {\\displaystyle f}\n \n can be regarded as a generative model that explains how the data were generated. Generative training algorithms are often simpler and more computationally efficient than discriminative training algorithms. In some cases, the solution can be computed in closed form as in naive Bayes and linear discriminant analysis.\n\n\nGeneralizations\nThere are several ways in which the standard supervised learning problem can be generalized:\nSemi-supervised learning or weak supervision: the desired output values are provided only for a subset of the training data. The remaining data is unlabeled or imprecisely labeled.\nActive learning: Instead of assuming that all of the training examples are given at the start, active learning algorithms interactively collect new examples, typically by making queries to a human user. Often, the queries are based on unlabeled data, which is a scenario that combines semi-supervised learning with active learning.\nStructured prediction: When the desired output value is a complex object, such as a parse tree or a labeled graph, then standard methods must be extended.\nLearning to rank: When the input is a set of objects and the desired output is a ranking of those objects, then again the standard methods must be extended.\n\n\nApproaches and algorithms\nAnalytical learning\nArtificial neural network\nBackpropagation\nBoosting (meta-algorithm)\nBayesian statistics\nCase-based reasoning\nDecision tree learning\nInductive logic programming\nGaussian process regression\nGenetic programming\nGroup method of data handling\nKernel estimators\nLearning automata\nLearning classifier systems\nLearning vector quantization\nMinimum message length (decision trees, decision graphs, etc.)\nMultilinear subspace learning\nNaive Bayes classifier\nMaximum entropy classifier\nConditional random field\nNearest neighbor algorithm\nProbably approximately correct learning (PAC) learning\nRipple down rules, a knowledge acquisition methodology\nSymbolic machine learning algorithms\nSubsymbolic machine learning algorithms\nSupport vector machines\nMinimum complexity machines (MCM)\nRandom forests\nEnsembles of classifiers\nOrdinal classification\nData pre-processing\nHandling imbalanced datasets\nStatistical relational learning\nProaftn, a multicriteria classification algorithm\n\n\nApplications\nBioinformatics\nCheminformatics\nQuantitative structure–activity relationship\nDatabase marketing\nHandwriting recognition\nInformation retrieval\nLearning to rank\nInformation extraction\nObject recognition in computer vision\nOptical character recognition\nSpam detection\nPattern recognition\nSpeech recognition\nSupervised learning is a special case of downward causation in biological systems\nLandform classification using satellite imagery\nSpend classification in procurement processes\n\n\nGeneral issues\nComputational learning theory\nInductive bias\nOverfitting\n(Uncalibrated) class membership probabilities\nVersion spaces\n\n\nSee also\nList of datasets for machine-learning research\nUnsupervised learning\n\n\nReferences\n\n\nExternal links\nMachine Learning Open Source Software (MLOSS)", "categories": ["Articles with short description", "Short description is different from Wikidata", "Supervised learning"], "references": ["http://www-bcf.usc.edu/~gareth/research/bv.pdf", "http://jair.org/media/606/live-606-1803-jair.pdf", "http://www.mloss.org/", "http://delta-apache-vm.cs.tau.ac.il/~nin/Courses/NC06/VarbiasBiasGeman.pdf", "https://publication.sipmm.edu.sg/key-technologies-agile-procurement/", "https://doi.org/10.1109%2FIJCNN.2011.6033571", "https://arxiv.org/abs/1608.00501", "https://books.google.com/books?id=EqgACAAAQBAJ&q=%22empirical+risk+minimization%22+OR+%22structural+risk+minimization%22", "https://id.loc.gov/authorities/sh94008290", "https://arxiv.org/archive/cs.CV", "https://www.nli.org.il/en/authorities/987007561023305171", "https://lux.collections.yale.edu/view/concept/cf583102-236b-4653-a870-fc87150b4484"], "images": ["File:Supervised and unsupervised learning.png", "File:Task-guidance.png"], "sub_niche": "Active learning (machine learning)"} {"title": "Attention (machine learning)", "url": "https://en.wikipedia.org/wiki/Attention_(machine_learning)", "summary": "In machine learning, attention is a method that determines the importance of each component in a sequence relative to the other components in that sequence. In natural language processing, importance is represented by \"soft\" weights assigned to each word in a sentence. More generally, attention encodes vectors called token embeddings across a fixed-width sequence that can range from tens to millions of tokens in size.\nUnlike \"hard\" weights, which are computed during the backwards training pass, \"soft\" weights exist only in the forward pass and therefore change with every step of the input. Earlier designs implemented the attention mechanism in a serial recurrent neural network (RNN) language translation system, but a more recent design, namely the transformer, removed the slower sequential", "content": "In machine learning, attention is a method that determines the importance of each component in a sequence relative to the other components in that sequence. In natural language processing, importance is represented by \"soft\" weights assigned to each word in a sentence. More generally, attention encodes vectors called token embeddings across a fixed-width sequence that can range from tens to millions of tokens in size.\nUnlike \"hard\" weights, which are computed during the backwards training pass, \"soft\" weights exist only in the forward pass and therefore change with every step of the input. Earlier designs implemented the attention mechanism in a serial recurrent neural network (RNN) language translation system, but a more recent design, namely the transformer, removed the slower sequential RNN and relied more heavily on the faster parallel attention scheme.\nInspired by ideas about attention in humans, the attention mechanism was developed to address the weaknesses of using information from the hidden layers of recurrent neural networks. Recurrent neural networks favor information contained in words at the end of a sentence and thus deemed more recent, thereby tending to attenuate the significance and associated predictive weight assigned to information earlier in the sentence. Attention allows a token equal access to any part of a sentence directly, rather than only through the previous state.\n\n\nHistory\n\nAdditional surveys of the attention mechanism in deep learning are provided by Niu et al. and Soydaner.\nThe major breakthrough came with self-attention, where each element in the input sequence attends to all others, enabling the model to capture global dependencies. This idea was central to the Transformer architecture, which replaced recurrence with attention mechanisms. As a result, Transformers became the foundation for models like BERT, T5 and generative pre-trained transformers (GPT).\n\n\nOverview\n\nThe modern era of machine attention was revitalized by grafting an attention mechanism (Fig 1. orange) to an Encoder-Decoder.\n\nFigure 2 shows the internal step-by-step operation of the attention block (A) in Fig 1.\n\n\nInterpreting attention weights\nIn translating between languages, alignment is the process of matching words from the source sentence to words of the translated sentence. Networks that perform verbatim translation without regard to word order would show the highest scores along the (dominant) diagonal of the matrix. The off-diagonal dominance shows that the attention mechanism is more nuanced.\nConsider an example of translating I love you to French. On the first pass through the decoder, 94% of the attention weight is on the first English word I, so the network offers the word je. On the second pass of the decoder, 88% of the attention weight is on the third English word you, so it offers t'. On the last pass, 95% of the attention weight is on the second English word love, so it offers aime.\nIn the I love you example, the second word love is aligned with the third word aime. Stacking soft row vectors together for je, t', and aime yields an alignment matrix:\n\nSometimes, alignment can be multiple-to-multiple. For example, the English phrase look it up corresponds to cherchez-le. Thus, \"soft\" attention weights work better than \"hard\" attention weights (setting one attention weight to 1, and the others to 0), as we would like the model to make a context vector consisting of a weighted sum of the hidden vectors, rather than \"the best one\", as there may not be a best hidden vector.\n\n\nVariants\n\nMany variants of attention implement soft weights, such as\n\nfast weight programmers, or fast weight controllers (1992). A \"slow\" neural network outputs the \"fast\" weights of another neural network through outer products. The slow network learns by gradient descent. It was later renamed as \"linearized self-attention\".\nBahdanau-style attention, also referred to as additive attention,\nLuong-style attention, which is known as multiplicative attention,\nEarly attention mechanisms similar to modern self-attention were proposed using recurrent neural networks. However, the highly parallelizable self-attention was introduced in 2017 and successfully used in the Transformer model,\npositional attention and factorized positional attention.\nFor convolutional neural networks, attention mechanisms can be distinguished by the dimension on which they operate, namely: spatial attention, channel attention, or combinations.\nThese variants recombine the encoder-side inputs to redistribute those effects to each target output. Often, a correlation-style matrix of dot products provides the re-weighting coefficients. In the figures below, W is the matrix of context attention weights, similar to the formula in Overview section above.\n\n\nOptimizations\n\n\nFlash attention\nThe size of the attention matrix is proportional to the square of the number of input tokens. Therefore, when the input is long, calculating the attention matrix requires a lot of GPU memory. Flash attention is an implementation that reduces the memory needs and increases efficiency without sacrificing accuracy. It achieves this by partitioning the attention computation into smaller blocks that fit into the GPU's faster on-chip memory, reducing the need to store large intermediate matrices and thus lowering memory usage while increasing computational efficiency.\n\n\nFlexAttention\nFlexAttention is an attention kernel developed by Meta that allows users to modify attention scores prior to softmax and dynamically chooses the optimal attention algorithm.\n\n\nApplications\nAttention is widely used in natural language processing, computer vision, and speech recognition. In natural language processing, it improves context understanding in tasks like question answering and summarization. In vision, visual attention helps models focus on relevant image regions, enhancing object detection and image captioning.\n\n\nAttention maps as explanations for vision transformers\n\nFrom the original paper on vision transformers (ViT), visualizing attention scores as a heat map (called saliency maps or attention maps) has become an important and routine way to inspect the decision making process of ViT models. One can compute the attention maps with respect to any attention head at any layer, while the deeper layers tend to show more semantically meaningful visualization. Attention rollout is a recursive algorithm to combine attention scores across all layers, by computing the dot product of successive attention maps.\nBecause vision transformers are typically trained in a self-supervised manner, attention maps are generally not class-sensitive. When a classification head is attached to the ViT backbone, class-discriminative attention maps (CDAM) combines attention maps and gradients with respect to the class [CLS] token. Some class-sensitive interpretability methods originally developed for convolutional neural networks can be also applied to ViT, such as GradCAM, which back-propagates the gradients to the outputs of the final attention layer.\nUsing attention as basis of explanation for the transformers in language and vision is not without debate. While some pioneering papers analyzed and framed attention scores as explanations, higher attention scores do not always correlate with greater impact on model performances.\n\n\nMathematical representation\n\n\nStandard scaled dot-product attention\nFor matrices: \n \n \n \n Q\n ∈\n \n \n R\n \n \n m\n ×\n \n d\n \n k\n \n \n \n \n ,\n K\n ∈\n \n \n R\n \n \n n\n ×\n \n d\n \n k\n \n \n \n \n \n \n {\\displaystyle Q\\in \\mathbb {R} ^{m\\times d_{k}},K\\in \\mathbb {R} ^{n\\times d_{k}}}\n \n and \n \n \n \n V\n ∈\n \n \n R\n \n \n n\n ×\n \n d\n \n v\n \n \n \n \n \n \n {\\displaystyle V\\in \\mathbb {R} ^{n\\times d_{v}}}\n \n, the scaled dot-product, or QKV attention, is defined as:\n\n \n \n \n \n Attention\n \n (\n Q\n ,\n K\n ,\n V\n )\n =\n \n softmax\n \n \n (\n \n \n \n Q\n \n K\n \n T\n \n \n \n \n \n d\n \n k\n \n \n \n \n \n )\n \n V\n ∈\n \n \n R\n \n \n m\n ×\n \n d\n \n v\n \n \n \n \n \n \n {\\displaystyle {\\text{Attention}}(Q,K,V)={\\text{softmax}}\\left({\\frac {QK^{T}}{\\sqrt {d_{k}}}}\\right)V\\in \\mathbb {R} ^{m\\times d_{v}}}\n \n\nwhere \n \n \n \n \n \n\n \n \n T\n \n \n \n \n {\\displaystyle {}^{T}}\n \n denotes transpose and the softmax function is applied independently to every row of its argument. The matrix \n \n \n \n Q\n \n \n {\\displaystyle Q}\n \n contains \n \n \n \n m\n \n \n {\\displaystyle m}\n \n queries, while matrices \n \n \n \n K\n ,\n V\n \n \n {\\displaystyle K,V}\n \n jointly contain an unordered set of \n \n \n \n n\n \n \n {\\displaystyle n}\n \n key-value pairs. Value vectors in matrix \n \n \n \n V\n \n \n {\\displaystyle V}\n \n are weighted using the weights resulting from the softmax operation, so that the rows of the \n \n \n \n m\n \n \n {\\displaystyle m}\n \n-by-\n \n \n \n \n d\n \n v\n \n \n \n \n {\\displaystyle d_{v}}\n \n output matrix are confined to the convex hull of the points in \n \n \n \n \n \n R\n \n \n \n d\n \n v\n \n \n \n \n \n \n {\\displaystyle \\mathbb {R} ^{d_{v}}}\n \n given by the rows of \n \n \n \n V\n \n \n {\\displaystyle V}\n \n.\nTo understand the permutation invariance and permutation equivariance properties of QKV attention, let \n \n \n \n A\n ∈\n \n \n R\n \n \n m\n ×\n m\n \n \n \n \n {\\displaystyle A\\in \\mathbb {R} ^{m\\times m}}\n \n and \n \n \n \n B\n ∈\n \n \n R\n \n \n n\n ×\n n\n \n \n \n \n {\\displaystyle B\\in \\mathbb {R} ^{n\\times n}}\n \n be permutation matrices; and \n \n \n \n D\n ∈\n \n \n R\n \n \n m\n ×\n n\n \n \n \n \n {\\displaystyle D\\in \\mathbb {R} ^{m\\times n}}\n \n an arbitrary matrix. The softmax function is permutation equivariant in the sense that:\n\n \n \n \n \n softmax\n \n (\n A\n D\n B\n )\n =\n A\n \n \n softmax\n \n (\n D\n )\n B\n \n \n {\\displaystyle {\\text{softmax}}(ADB)=A\\,{\\text{softmax}}(D)B}\n \n\nBy noting that the transpose of a permutation matrix is also its inverse, it follows that:\n\n \n \n \n \n Attention\n \n (\n A\n Q\n ,\n B\n K\n ,\n B\n V\n )\n =\n A\n \n \n Attention\n \n (\n Q\n ,\n K\n ,\n V\n )\n \n \n {\\displaystyle {\\text{Attention}}(AQ,BK,BV)=A\\,{\\text{Attention}}(Q,K,V)}\n \n\nwhich shows that QKV attention is equivariant with respect to re-ordering the queries (rows of \n \n \n \n Q\n \n \n {\\displaystyle Q}\n \n); and invariant to re-ordering of the key-value pairs in \n \n \n \n K\n ,\n V\n \n \n {\\displaystyle K,V}\n \n. These properties are inherited when applying linear transforms to the inputs and outputs of QKV attention blocks. For example, a simple self-attention function defined as:\n\n \n \n \n X\n ↦\n \n Attention\n \n (\n X\n \n T\n \n q\n \n \n ,\n X\n \n T\n \n k\n \n \n ,\n X\n \n T\n \n v\n \n \n )\n \n \n {\\displaystyle X\\mapsto {\\text{Attention}}(XT_{q},XT_{k},XT_{v})}\n \n \nis permutation equivariant with respect to re-ordering the rows of the input matrix \n \n \n \n X\n \n \n {\\displaystyle X}\n \n in a non-trivial way, because every row of the output is a function of all the rows of the input. Similar properties hold for multi-head attention, which is defined below.\n\n\nMasked attention\nWhen QKV attention is used as a building block for an autoregressive decoder, and when at training time all input and output matrices have \n \n \n \n n\n \n \n {\\displaystyle n}\n \n rows, a masked attention variant is used:\n\n \n \n \n \n Attention\n \n (\n Q\n ,\n K\n ,\n V\n )\n =\n \n softmax\n \n \n (\n \n \n \n \n Q\n \n K\n \n T\n \n \n \n \n \n d\n \n k\n \n \n \n \n \n +\n M\n \n )\n \n V\n \n \n {\\displaystyle {\\text{Attention}}(Q,K,V)={\\text{softmax}}\\left({\\frac {QK^{T}}{\\sqrt {d_{k}}}}+M\\right)V}\n \n\nwhere the mask, \n \n \n \n M\n ∈\n \n \n {\n 0\n ,\n −\n ∞\n }\n \n \n n\n ×\n n\n \n \n \n \n {\\displaystyle M\\in \\mathbb {\\{0,-\\infty \\}} ^{n\\times n}}\n \n is a strictly upper triangular matrix, with zeros on and below the diagonal and \n \n \n \n −\n ∞\n \n \n {\\displaystyle -\\infty }\n \n in every element above the diagonal. The softmax output, in \n \n \n \n \n \n R\n \n \n n\n ×\n n\n \n \n \n \n {\\displaystyle \\mathbb {R} ^{n\\times n}}\n \n is then lower triangular, with zeros in all elements above the diagonal. The masking ensures that for all \n \n \n \n 1\n ≤\n i\n <\n j\n ≤\n n\n \n \n {\\displaystyle 1\\leq i