code: def add_weight_regularization_to_loss_dict(self, loss_dict, weights):
      if self.weight_regularizer is not None:
          loss_dict[
              "weight_reg_loss"
          ] = self.weight_regularization_loss(weights)
  
file_path: pytorch-metric-learning/src/pytorch_metric_learning/losses/mixins.py
imports: import torch
  from ..utils import common_functions
label_desc: Use image node_id 3 for calling the WeightRegularizerMixin obj's underlying member method code with example usage: obj.add_weight_regularization_to_loss_dict(loss_dict, weights) without return types