class_docstr: Replay memory to store samples of experience.
  
  Each transition is represented as (state, action, reward, next_state,
  priority) tuple. 'priority' is ignored for non-prioritized experience
  replay.
class_docstr_tok: ["Replay","memory","to","store","samples","of","experience",".","Each","transition","is","represented","as","(","state",",","action",",","reward",",","next_state",",","priority",")","tuple",".","'priority","'","is","ignored","for","non-prioritized","experience","replay","."]
docstr: Update priority of transitions.
  
  Args:
      map_from_position_to_priority: dictionary mapping position of
          transition to its new priority. position should come from
          tuples returned by sample_minibatch().
docstr_tok: ["Update","priority","of","transitions",".","Args",":","map_from_position_to_priority",":","dictionary","mapping","position","of","transition","to","its","new","priority",".","position","should","come","from","tuples","returned","by","sample_minibatch","(",")","."]
code: def update_priority(self, map_from_position_to_priority):
      """Update priority of transitions.
  
      Args:
          map_from_position_to_priority: dictionary mapping position of
              transition to its new priority. position should come from
              tuples returned by sample_minibatch().
      """
      if not self._use_prioritized_replay:
          return
      for (
          position,
          new_priority,
      ) in map_from_position_to_priority.items():
          old_priority = self._memory[position].priority
          self._memory[position] = _Transition(
              self._memory[position].state,
              self._memory[position].action,
              self._memory[position].reward,
              self._memory[position].next_state,
              new_priority,
          )
          self._update_internal_nodes(
              position, new_priority - old_priority
          )
  
file_path: CNTK/bindings/python/cntk/contrib/deeprl/agent/shared/replay_memory.py
imports: from __future__ import division
  import math
  import random
  from collections import namedtuple
label_desc: Use image node_id 3 for calling the ReplayMemory obj's underlying member method code with example usage: obj.update_priority(map_from_position_to_priority) without return types