class_docstr: Generic vision network.
class_docstr_tok: ["Generic","vision","network","."]
code: def _hidden_layers(self, obs: TensorType) -> TensorType:
      res = self._convs(
          obs.permute(0, 3, 1, 2)
      )  # switch to channel-major
      res = res.squeeze(3)
      res = res.squeeze(2)
      return res
  
file_path: ray/python/ray/rllib/models/torch/visionnet.py
imports: import numpy
  from typing import Dict, List
  import gymnasium
  from ray.rllib.models.torch.torch_modelv2 import TorchModelV2
  from ray.rllib.models.torch.misc import normc_initializer, same_padding, SlimConv2d, SlimFC
  from ray.rllib.models.utils import get_activation_fn, get_filter_config
  from ray.rllib.utils.annotations import override
  from ray.rllib.utils.framework import try_import_torch
  from ray.rllib.utils.typing import ModelConfigDict, TensorType
label_desc: Use image node_id 4 for calling the VisionNetwork obj's underlying member method code with example usage: obj._hidden_layers(obs) and returns: res