class_docstr: William's episodic REINFORCE.
  
  Args:
      model (Policy): Model to train. It must be a callable that accepts
          observations as input and return action distributions
          (Distribution).
      optimizer (chainer.Optimizer): optimizer used to train the model
      beta (float): Weight coefficient for the entropy regularizaiton term.
      normalize_loss_by_steps (bool): If set true, losses are normalized by
          the number of steps taken to accumulate the losses
      act_deterministically (bool): If set true, choose most probable actions
          in act method.
      batchsize (int): Number of episodes used for each update
      backward_separately (bool): If set true, call backward separately for
          each episode and accumulate only gradients.
      average_entropy_decay (float): Decay rate of average entropy. Used only
          to record statistics.
      batch_states (callable): Method which makes a batch of observations.
          default is `chainerrl.misc.batch_states`
      logger (logging.Logger): Logger to be used.
class_docstr_tok: ["William","'s","episodic","REINFORCE",".","Args",":","model","(","Policy",")",":","Model","to","train",".","It","must","be","a","callable","that","accepts","observations","as","input","and","return","action","distributions","(","Distribution",")",".","optimizer","(","chainer.Optimizer",")",":","optimizer","used","to","train","the","model","beta","(","float",")",":","Weight","coefficient","for","the","entropy","regularizaiton","term",".","normalize_loss_by_steps","(","bool",")",":","If","set","true",",","losses","are","normalized","by","the","number","of","steps","taken","to","accumulate","the","losses","act_deterministically","(","bool",")",":","If","set","true",",","choose","most","probable","actions","in","act","method",".","batchsize","(","int",")",":","Number","of","episodes","used","for","each","update","backward_separately","(","bool",")",":","If","set","true",",","call","backward","separately","for","each","episode","and","accumulate","only","gradients",".","average_entropy_decay","(","float",")",":","Decay","rate","of","average","entropy",".","Used","only","to","record","statistics",".","batch_states","(","callable",")",":","Method","which","makes","a","batch","of","observations",".","default","is","`","chainerrl.misc.batch_states","`","logger","(","logging.Logger",")",":","Logger","to","be","used","."]
code: def stop_episode(self):
      if isinstance(self.model, Recurrent):
          self.model.reset_state()
  
imports: from logging import getLogger
  import warnings
  import chainer
  import chainer.functions
  import numpy
  import chainerrl
  from chainerrl import agent
  from chainerrl.recurrent import Recurrent
label_desc: Use image node_id 8 for calling the REINFORCE obj's underlying member method code with example usage: obj.stop_episode() without return types