code: def test_output_transform():
      class CustomOutputTransform(OutputTransform):
          @staticmethod
          def per_batch_transform(batch):
              return batch * 2
  
          @staticmethod
          def per_sample_transform(sample):
              return sample + 1
  
      output_transform = CustomOutputTransform()
      transformed = output_transform(torch.ones(10))
      assert all(
          torch.isclose(t, torch.tensor(3.0)) for t in transformed
      )
  
imports: import pytest
  import torch
  from flash.core.data.io.output_transform import OutputTransform
  from flash.core.utilities.imports import _TOPIC_CORE_AVAILABLE
label_desc: Use image node_id 1 for calling a global function with example usage: test_output_transform() and returns: unknown, unknown