code: def bc_point(ctxt=None):
      """Run Behavioral Cloning on garage.envs.PointEnv.
  
      Args:
          ctxt (ExperimentContext): Provided by wrap_experiment.
  
      """
      trainer = Trainer(ctxt)
      goal = np.array([1.0, 1.0])
      env = PointEnv(goal=goal, max_episode_length=200)
      expert = OptimalPolicy(env.spec, goal=goal)
      policy = DeterministicMLPPolicy(env.spec, hidden_sizes=[8, 8])
      batch_size = 1000
      sampler = RaySampler(
          agents=expert,
          envs=env,
          max_episode_length=env.spec.max_episode_length,
      )
      algo = BC(
          env.spec,
          policy,
          batch_size=batch_size,
          source=expert,
          sampler=sampler,
          policy_lr=1e-2,
          loss="mse",
      )
      trainer.setup(algo, env)
      trainer.train(100, batch_size=batch_size)
  
file_path: garage/src/garage/examples/torch/bc_point_deterministic_policy.py
imports: import numpy
  from garage import wrap_experiment
  from garage.envs import PointEnv
  from garage.sampler import RaySampler
  from garage.torch.algos import BC
  from garage.torch.policies import DeterministicMLPPolicy, Policy
  from garage.trainer import Trainer
label_desc: Use image node_id 1 for calling a global function with example usage: bc_point(ctxt) without return types