code: def test_nan():
      assert check_nan_observation(
          generate_nan_observation(_test_space)
      )
      assert not check_nan_observation(_test_space.sample())
  
imports: from collections import Counter
  import gym
  import numpy
  from tianshou.data import Batch, Collector
  from tianshou.policy import BasePolicy
  from torch.utils.data import DataLoader, Dataset, DistributedSampler
  from qlib.rl.utils.finite_env import LogWriter, FiniteDummyVectorEnv, FiniteShmemVectorEnv, FiniteSubprocVectorEnv, check_nan_observation, generate_nan_observation
label_desc: Use image node_id 5 for calling a global function with example usage: test_nan() without return types