code: def test_ignore_row(self):
      # If a sample has no valid targets, it should be ignored in the reduction.
      config = self._get_config()
      crit = SoftTargetCrossEntropyLoss.from_config(config)
      outputs = torch.tensor(
          [[1.0, 7.0, 0.0, 0.0, 2.0], [4.0, 2.0, 1.0, 6.0, 0.5]]
      )
      targets = torch.tensor([[1, 0, 0, 0, 1], [-1, -1, -1, -1, -1]])
      self.assertAlmostEqual(
          crit(outputs, targets).item(), self._get_loss()
      )
  
file_path: ClassyVision/test/losses_soft_target_cross_entropy_loss_test.py
imports: import copy
  import unittest
  import torch
  from classy_vision.losses import build_loss, SoftTargetCrossEntropyLoss
label_desc: Use image node_id 10 for calling the TestSoftTargetCrossEntropyLoss obj's underlying member method code with example usage: obj.test_ignore_row() without return types