class_docstr: Softmax regression is a generalization of logistic regression to multiple classes.
  
  Softmax regression is also known as "multinomial logistic regression". There are a set weights
  for each class, hence the `weights` attribute is a nested `collections.defaultdict`. The main
  advantage of using this instead of a one-vs-all logistic regression is that the probabilities
  will be calibrated. Moreover softmax regression is more robust to outliers.
  
  Parameters
  ----------
  optimizer
      The sequential optimizer used to tune the weights.
  loss
      The loss function to optimize for.
  l2
      Amount of L2 regularization used to push weights towards 0.
  
  Attributes
  ----------
  weights : collections.defaultdict
  
  Examples
  --------
  
  >>> from river import datasets
  >>> from river import evaluate
  >>> from river import linear_model
  >>> from river import metrics
  >>> from river import optim
  >>> from river import preprocessing
  
  >>> dataset = datasets.ImageSegments()
  
  >>> model = preprocessing.StandardScaler()
  >>> model |= linear_model.SoftmaxRegression()
  
  >>> metric = metrics.MacroF1()
  
  >>> evaluate.progressive_val_score(dataset, model, metric)
  MacroF1: 81.88%
  
  References
  ----------
  [^1]: [Course on classification stochastic gradient descent](https://www.inf.ed.ac.uk/teaching/courses/mlp/2016/mlp02-sln.pdf)
  [^2]: [Binary vs. Multi-Class Logistic Regression](https://chrisyeh96.github.io/2018/06/11/logistic-regression.html)
class_docstr_tok: ["Softmax","regression","is","a","generalization","of","logistic","regression","to","multiple","classes",".","Softmax","regression","is","also","known","as","``","multinomial","logistic","regression","''",".","There","are","a","set","weights","for","each","class",",","hence","the","`","weights","`","attribute","is","a","nested","`","collections.defaultdict","`",".","The","main","advantage","of","using","this","instead","of","a","one-vs-all","logistic","regression","is","that","the","probabilities","will","be","calibrated",".","Moreover","softmax","regression","is","more","robust","to","outliers",".","Parameters","--","--","--","--","--","optimizer","The","sequential","optimizer","used","to","tune","the","weights",".","loss","The","loss","function","to","optimize","for",".","l2","Amount","of","L2","regularization","used","to","push","weights","towards","0",".","Attributes","--","--","--","--","--","weights",":","collections.defaultdict","Examples","--","--","--","--",">",">",">","from","river","import","datasets",">",">",">","from","river","import","evaluate",">",">",">","from","river","import","linear_model",">",">",">","from","river","import","metrics",">",">",">","from","river","import","optim",">",">",">","from","river","import","preprocessing",">",">",">","dataset","=","datasets.ImageSegments","(",")",">",">",">","model","=","preprocessing.StandardScaler","(",")",">",">",">","model","|=","linear_model.SoftmaxRegression","(",")",">",">",">","metric","=","metrics.MacroF1","(",")",">",">",">","evaluate.progressive_val_score","(","dataset",",","model",",","metric",")","MacroF1",":","81.88","%","References","--","--","--","--","--","[","^1","]",":","[","Course","on","classification","stochastic","gradient","descent","]","(","https",":","\/\/www.inf.ed.ac.uk\/teaching\/courses\/mlp\/2016\/mlp02-sln.pdf",")","[","^2","]",":","[","Binary","vs.","Multi-Class","Logistic","Regression","]","(","https",":","\/\/chrisyeh96.github.io\/2018\/06\/11\/logistic-regression.html",")"]
code: def _multiclass(self):
      return True
  
file_path: river/river/linear_model/softmax.py
imports: from __future__ import annotations
  import collections
  import copy
  import functools
  from river import base, optim, utils
label_desc: Use image node_id 2 for calling the SoftmaxRegression obj's underlying member method code with example usage: obj._multiclass() and returns: True