class_docstr: Implementation of the visual foraging environment used for scene construction simulations 
class_docstr_tok: ["Implementation","of","the","visual","foraging","environment","used","for","scene","construction","simulations"]
code: def __init__(self, scenes=None, n_features=2):
      if scenes is None:
          self.scenes = self._construct_default_scenes()
      else:
          self.scenes = scenes
  
      self.n_scenes = len(self.scenes)
      self.n_features = n_features + 1
      self.n_states = [
          np.prod(self.scenes[0].shape) + 1,
          self.scenes.shape[0],
      ]
      self.n_locations = self.n_states[LOCATION_ID]
      self.n_control = [self.n_locations, 1]
      self.n_observations = [self.n_locations, self.n_features]
      self.n_factors = len(self.n_states)
      self.n_modalities = len(self.n_observations)
  
      self._transition_dist = self._construct_transition_dist()
      self._likelihood_dist = self._construct_likelihood_dist()
      self._true_scene = None
      self._state = None
  
imports: from pymdp.envs import Env
  from pymdp import utils, maths
  import numpy
  from itertools import permutations, product
label_desc: Use image node_id 1 to create a new VisualForagingEnv object from inherited base classes: Env with example: obj = VisualForagingEnv(scenes, n_features)