class_docstr: Riemannian Walk (RWalk) plugin.
  RWalk computes the importance of each weight at the end of every training
  iteration, and updates each parameter's importance online using moving
  average. During training on each minibatch, the loss is augmented
  with a penalty which keeps the value of a parameter close to the
  value it had on previous experiences, proportional to a score that has
  high values if small changes cause large improvements in the loss.
  This plugin does not use task identities.
  
  .. note::
      To reproduce the results of the paper in class-incremental scenarios,
      this plug-in should be used in conjunction with a replay strategy
      (e.g., :class:`ReplayPlugin`).
class_docstr_tok: ["Riemannian","Walk","(","RWalk",")","plugin",".","RWalk","computes","the","importance","of","each","weight","at","the","end","of","every","training","iteration",",","and","updates","each","parameter","'s","importance","online","using","moving","average",".","During","training","on","each","minibatch",",","the","loss","is","augmented","with","a","penalty","which","keeps","the","value","of","a","parameter","close","to","the","value","it","had","on","previous","experiences",",","proportional","to","a","score","that","has","high","values","if","small","changes","cause","large","improvements","in","the","loss",".","This","plugin","does","not","use","task","identities",".","..","note",":",":","To","reproduce","the","results","of","the","paper","in","class-incremental","scenarios",",","this","plug-in","should","be","used","in","conjunction","with","a","replay","strategy","(","e.g.",",",":","class",":","`","ReplayPlugin","`",")","."]
code: def before_training(self, strategy, *args, **kwargs):
      self.checkpoint_loss = zerolike_params_dict(strategy.model)
      self.checkpoint_scores = zerolike_params_dict(strategy.model)
      self.checkpoint_params = copy_params_dict(strategy.model)
  
file_path: avalanche/avalanche/training/plugins/rwalk.py
imports: from typing import Dict, Optional
  import warnings
  import torch
  import torch.nn.functional
  from avalanche.training.plugins.strategy_plugin import SupervisedPlugin
  from avalanche.training.utils import copy_params_dict, zerolike_params_dict, ParamData
  from avalanche.models.utils import avalanche_forward
label_desc: Use image node_id 7 for calling the RWalkPlugin obj's underlying member method code with example usage: obj.before_training(strategy) without return types