code: def test_preprocessing(self):
      self.start_tests(name="preprocessing")
  
      states = dict(
          type="float", shape=(), min_value=-1.0, max_value=2.0
      )
      state_preprocessing = [
          dict(type="sequence", length=3, concatenate=False),
          dict(type="clipping", lower=-1.0, upper=1.0),
          dict(type="linear_normalization"),
      ]
      reward_processing = [dict(type="clipping", upper=1.0)]
      network = [dict(type="dense", size=8)]
      self.unittest(
          states=states,
          experience_update=False,
          policy=network,
          reward_estimation=dict(
              horizon=3,
              estimate_advantage=True,
              predict_horizon_values="late",
              reward_processing=reward_processing,
              return_processing=dict(
                  type="clipping", lower=-1.0, upper=1.0
              ),
              advantage_processing="batch_normalization",
          ),
          state_preprocessing=state_preprocessing,
      )
  
      states = dict(
          state1=dict(
              type="float",
              shape=(4, 4, 3),
              min_value=1.0,
              max_value=2.0,
          ),
          state2=dict(
              type="float", shape=(), min_value=-1.0, max_value=2.0
          ),
      )
      state_preprocessing = dict(
          state1=[
              dict(type="image", height=2, width=2, grayscale=True),
              dict(type="deltafier", concatenate=0),
              dict(type="sequence", length=4),
              dict(type="linear_normalization"),
          ],
          state2=None,
      )
      reward_processing = dict(type="deltafier")
      network = [
          dict(type="retrieve", tensors="state1"),
          dict(type="reshape", shape=32),
      ]
      # TODO: buffer_observe incompatible with Deltafier/Sequence expecting single-step inputs
      self.unittest(
          states=states,
          experience_update=False,
          policy=network,
          reward_estimation=dict(
              horizon=3,
              estimate_advantage=True,
              predict_horizon_values="late",
              reward_processing=reward_processing,
              return_processing=dict(
                  type="clipping", lower=-1.0, upper=1.0
              ),
              advantage_processing="batch_normalization",
          ),
          state_preprocessing=state_preprocessing,
          config=dict(
              buffer_observe=1,
              device="CPU",
              eager_mode=True,
              create_debug_assertions=True,
              tf_log_level=20,
          ),
      )
  
file_path: tensorforce/test/test_layers.py
imports: import unittest
  from test.unittest_base import UnittestBase
label_desc: Use image node_id 11 for calling the TestLayers obj's underlying member method code with example usage: obj.test_preprocessing() without return types