class_docstr: PendulumMassEnv varies the weight of the pendulum
  
  Tasks are defined to be weight uniformly sampled between [0.5,2]
class_docstr_tok: ["PendulumMassEnv","varies","the","weight","of","the","pendulum","Tasks","are","defined","to","be","weight","uniformly","sampled","between","[","0.5,2","]"]
code: def sample_tasks(self, n_tasks):
      # Sample new pendulum masses (random floats between 0.5 and 2).
      return np.random.uniform(low=0.5, high=2.0, size=(n_tasks,))
  
file_path: ray/rllib_contrib/maml/src/rllib_maml/envs/pendulum_mass.py
imports: import numpy
  from gymnasium.envs.classic_control.pendulum import PendulumEnv
  from gymnasium.utils import EzPickle
  from ray.rllib.env.apis.task_settable_env import TaskSettableEnv
label_desc: Use image node_id 1 for calling the PendulumMassEnv obj's underlying member method code with example usage: obj.sample_tasks(n_tasks) and returns: np