class_docstr: Buffer consecutive k observations and stack them on a new last axis.
  The output observation has shape `original_shape + (k, )`.
class_docstr_tok: ["Buffer","consecutive","k","observations","and","stack","them","on","a","new","last","axis",".","The","output","observation","has","shape","`","original_shape","+","(","k",",",")","`","."]
docstr: Clear buffer and re-fill by duplicating the first observation.
docstr_tok: ["Clear","buffer","and","re-fill","by","duplicating","the","first","observation","."]
code: def reset(self):
      """Clear buffer and re-fill by duplicating the first observation."""
      ob = self.env.reset()
      for _ in range(self.k - 1):
          self.frames.append(np.zeros_like(ob))
      self.frames.append(ob)
      return self.observation()
  
imports: import numpy
  from collections import deque
  import gym
label_desc: Use image node_id 2 for calling the FrameStack obj's underlying member method code with example usage: obj.reset() and returns: self