docstr: Calculate losses, gradients, and update network weights; called in every training iteration
docstr_tok: ["Calculate","losses",",","gradients",",","and","update","network","weights",";","called","in","every","training","iteration"]
code: def backward(self):
      """Calculate losses, gradients, and update network weights; called in every training iteration"""
      # caculate the intermediate results if necessary; here self.output has been computed during function <forward>
      # calculate loss given the input and intermediate results
      self.loss_seg.backward()
  
file_path: torch-points3d/torch_points3d/models/segmentation/rsconv.py
imports: import logging
  import copy
  import queue
  import torch
  import torch.nn.functional
  from torch_points3d.datasets.segmentation import IGNORE_LABEL
  from torch_points3d.models.base_architectures import UnwrappedUnetBasedModel
  from torch_points3d.modules.RSConv import *
  from torch_points3d.core.common_modules.dense_modules import Conv1D
  from torch_points3d.core.common_modules.base_modules import Seq
  from .base import Segmentation_MP
label_desc: Use image node_id 4 for calling the RSConvLogicModel obj's underlying member method code with example usage: obj.backward() without return types