code: def test_image_from_tf_tensor(self):
      import tensorflow as tf
  
      # order of channels in tf.tensor => height, width, channels
  
      self.assertEqual(
          Image(tf.convert_to_tensor(self.img1, tf.uint8)),
          Image(self.img1),
      )
      self.assertEqual(
          Image(tf.convert_to_tensor(self.img2, tf.uint8)),
          Image(self.img2),
      )
      self.assertEqual(
          Image(tf.convert_to_tensor(self.img3, tf.uint8)),
          Image(self.img3),
      )
  
      self.assertEqual(
          Image(tf.convert_to_tensor(self.img1, tf.float32)),
          Image(255 * self.img1),
      )
      self.assertEqual(
          Image(tf.convert_to_tensor(self.img2, tf.float32)),
          Image(255 * self.img2),
      )
      self.assertEqual(
          Image(tf.convert_to_tensor(self.img3, tf.float32)),
          Image(255 * self.img3),
      )
  
file_path: aim/tests/sdk/test_image_construction.py
imports: import pytest
  from tests.base import TestBase
  from tests.utils import is_package_installed
  from aim.sdk import Image
  import numpy
label_desc: Use image node_id 2 for calling the TestImageConstruction obj's underlying member method code with example usage: obj.test_image_from_tf_tensor() without return types