MCPcopy Create free account

hub / github.com/PacktPublishing/Hands-On-Reinforcement-Learning-for-Games / functions

Functions857 in github.com/PacktPublishing/Hands-On-Reinforcement-Learning-for-Games

↓ 3 callersMethodv
(self, x)
Chapter09/Chapter_9/Chapter_9_PPO.py:32
↓ 3 callersMethodv
(self, x)
Chapter09/Chapter_9/Chapter_9_A3C.py:37
↓ 3 callersMethodv
(self, x)
Chapter08/Chapter_8/Chapter_8_ActorCritic.py:28
↓ 3 callersMethodvalue_predictions
Get the value predictions from the model at each timestep.
Chapter13/Chapter_13/obs_tower2/rollout.py:59
↓ 2 callersMethod_cur_obs
(self)
Chapter13/Chapter_13/obs_tower2/util.py:316
↓ 2 callersMethod_die_by_ghost
(self)
Chapter14/Chapter_14/deepmind.py:317
↓ 2 callersMethod_encode_sample
(self, idxes)
Chapter10/Chapter_10/common/replay_buffer.py:170
↓ 2 callersMethod_encode_sample
(self, idxes)
Chapter11/Chapter_11/common/replay_buffer.py:170
↓ 2 callersMethod_get_ob
(self)
Chapter07/Chapter_7/wrappers.py:171
↓ 2 callersMethod_get_ob
(self)
Chapter10/Chapter_10/common/wrappers.py:171
↓ 2 callersMethod_get_ob
(self)
Chapter11/Chapter_11/common/wrappers.py:171
↓ 2 callersMethod_image_path
(self)
Chapter13/Chapter_13/obs_tower2/labels.py:74
↓ 2 callersMethod_kill_ghost
(self, ghost_index)
Chapter14/Chapter_14/deepmind.py:311
↓ 2 callersMethod_load_json
(self, name)
Chapter13/Chapter_13/obs_tower2/recording.py:270
↓ 2 callersMethod_make_actor
Creates an actor. An actor is a `ConfigDict` with a positions `pos` and a direction `dir`. The position is an array with two elements, the he
Chapter14/Chapter_14/deepmind.py:234
↓ 2 callersMethodact
(self, x, deterministic=False)
Chapter14/Chapter_14/Chapter_14_Imagine_A2C.py:26
↓ 2 callersMethodact
(self, state, epsilon)
Chapter07/Chapter_7/Chapter_7_DDQN_wprority.py:145
↓ 2 callersMethodact
(self, state, epsilon)
Chapter07/Chapter_7/Chapter_7_DDQN.py:75
↓ 2 callersMethodact
(self, state, epsilon)
Chapter07/Chapter_7/Chapter_7_DQN_CNN.py:91
↓ 2 callersMethodact
(self, state, epsilon)
Chapter07/Chapter_7/Chapter_7_DoubleDQN.py:63
↓ 2 callersMethodact
(self, state, epsilon)
Chapter06/Chapter_6/Chapter_6_DQN_lunar.py:63
↓ 2 callersMethodact
(self, state, epsilon)
Chapter06/Chapter_6/Chapter_6_DQN_wplay.py:63
↓ 2 callersMethodact
(self, state, epsilon)
Chapter10/Chapter_10/Chapter_10_HDQN.py:44
↓ 2 callersMethodact
(self, x)
Chapter08/Chapter_8/Chapter_8_REINFORCE.py:21
↓ 2 callersMethodaction
(self, act)
Chapter13/Chapter_13/obs_tower2/util.py:257
↓ 2 callersMethodactions
Get the integer actions from the model at each timestep.
Chapter13/Chapter_13/obs_tower2/rollout.py:66
↓ 2 callersMethodadd_fields
(self, output)
Chapter13/Chapter_13/obs_tower2/model.py:97
↓ 2 callersMethodadvantages
Generate a [num_steps x batch_size] array of generalized advantages using GAE.
Chapter13/Chapter_13/obs_tower2/rollout.py:87
↓ 2 callersFunctionclassification_loss
(pool, model, dataset)
Chapter13/Chapter_13/obs_tower2/scripts/run_classifier.py:61
↓ 2 callersFunctioncloning_loss
(model, rollout)
Chapter13/Chapter_13/obs_tower2/scripts/run_clone.py:64
↓ 2 callersFunctioncompute_loss
(task, device, learner, loss_func, batch=5)
Chapter14/Chapter_14/Chapter_14_learn.py:42
↓ 2 callersFunctioncookie_path
(rec)
Chapter13/Chapter_13/obs_tower2/bugs/fix_seed_nums.py:35
↓ 2 callersMethoddensity
(self, state)
Chapter14/Chapter_14/policies.py:39
↓ 2 callersFunctiondisplayImage
(image, step, reward)
Chapter14/Chapter_14/Chapter_14_MiniPacman.py:6
↓ 2 callersMethodevaluate_actions
(self, x, action)
Chapter14/Chapter_14/actor_critic.py:26
↓ 2 callersMethodfeature_size
(self)
Chapter14/Chapter_14/Chapter_14_I2A.py:164
↓ 2 callersFunctionfetch_leaderboard
()
Chapter13/Chapter_13/obs_tower2/scripts/legacy/leaderboard.py:30
↓ 2 callersFunctionfind_rec_frame
(name)
Chapter13/Chapter_13/obs_tower2/labeler/main.py:110
↓ 2 callersMethodforward
(self, x)
Chapter14/Chapter_14/actor_critic.py:12
↓ 2 callersMethodforward
(self, x)
Chapter14/Chapter_14/Chapter_14_Imagine_A2C.py:23
↓ 2 callersMethodforward
(self, x)
Chapter06/Chapter_6/Chapter_6_DQN.py:58
↓ 2 callersMethodforward
(self, x)
Chapter10/Chapter_10/Chapter_10_QRDQN.py:44
↓ 2 callersMethodforward
Run the model for one timestep and return a dict of outputs. Args: states: a Tensor of previous states.
Chapter13/Chapter_13/obs_tower2/model.py:28
↓ 2 callersFunctionget_action
(state)
Chapter14/Chapter_14/Chapter_14_Imagination.py:185
↓ 2 callersFunctionget_action
(observation,t)
Chapter05/Chapter_5/Chapter_5_2.py:36
↓ 2 callersFunctionget_action
(observation,t)
Chapter05/Chapter_5/Chapter_5_4.py:35
↓ 2 callersFunctionget_action
(observation,t)
Chapter05/Chapter_5/Chapter_5_3.py:36
↓ 2 callersFunctionget_action
(observation,t)
Chapter05/Chapter_5/Chapter_5_5y.py:39
↓ 2 callersFunctionget_action
(observation,t)
Chapter05/Chapter_5/Chapter_5_1.py:36
↓ 2 callersFunctionget_flat_params_from
(model)
Chapter08/Chapter_8/TRPO/utils.py:21
↓ 2 callersMethodimage
(self)
Chapter13/Chapter_13/obs_tower2/labels.py:62
↓ 2 callersMethodinner_loop
(self, rollout_pi, rollout_expert, num_steps=12, batch_size=None)
Chapter13/Chapter_13/obs_tower2/gail.py:69
↓ 2 callersFunctionlabeled_data
(pool, model, dataset)
Chapter13/Chapter_13/obs_tower2/scripts/run_classifier.py:104
↓ 2 callersFunctionload_labeled_images
(**kwargs)
Chapter13/Chapter_13/obs_tower2/labels.py:17
↓ 2 callersFunctionmaml_a2c_loss
(train_episodes, learner, baseline, gamma, tau)
Chapter14/Chapter_14/Chapter_14_MAML_Dice.py:46
↓ 2 callersFunctionmaml_a2c_loss
(train_episodes, learner, baseline, gamma, tau)
Chapter14/Chapter_14/Chapter_14_MetaSGG-VPG.py:38
↓ 2 callersMethodmirror
Copy this recording, but flip it left-to-right.
Chapter13/Chapter_13/obs_tower2/recording.py:176
↓ 2 callersFunctionmodel_outs_to_cpu
(model_outs)
Chapter13/Chapter_13/obs_tower2/model.py:346
↓ 2 callersFunctionnormal_log_density
(x, mean, log_std, std)
Chapter08/Chapter_8/TRPO/utils.py:14
↓ 2 callersFunctionobservation_as_rgb
Reduces the 6 channels of `obs` to 3 RGB. Args: obs: the observation as a numpy array. Returns: An RGB image in the form of a numpy arra
Chapter14/Chapter_14/deepmind.py:95
↓ 2 callersMethodpi
(self, x, softmax_dim = 0)
Chapter09/Chapter_9/Chapter_9_ACER.py:65
↓ 2 callersMethodpi
(self, x, hidden)
Chapter09/Chapter_9/Chapter_9_PPO_LSTM.py:29
↓ 2 callersFunctionplay
(env, episodes, policy)
Chapter02/Chapter_2/Chapter_2_8.py:80
↓ 2 callersFunctionplay_game
(render_game)
Chapter04/Chapter_4/Chapter_4_4.py:39
↓ 2 callersFunctionplay_game
(render_game)
Chapter04/Chapter_4/Chapter_4_5.py:39
↓ 2 callersFunctionplay_game
(env, policy, display=True)
Chapter03/Chapter_3/Chapter_3_3.py:28
↓ 2 callersFunctionprint_stats
(data)
Chapter13/Chapter_13/obs_tower2/recorder/stats.py:22
↓ 2 callersMethodpush
(self, state, action, reward, next_state, done, goal)
Chapter14/Chapter_14/Chapter_14_HER.py:27
↓ 2 callersFunctionrecord_episode
(seed, env, viewer, obs, tmp_dir=TMP_DIR, res_dir=RES_DIR, max_steps=None, min_floors=1)
Chapter13/Chapter_13/obs_tower2/recorder/record.py:40
↓ 2 callersMethodreduce
Returns result of applying `self.operation` to a contiguous subsequence of the array. self.operation(arr[start], operation(arr[sta
Chapter10/Chapter_10/common/replay_buffer.py:54
↓ 2 callersMethodreduce
Returns result of applying `self.operation` to a contiguous subsequence of the array. self.operation(arr[start], operation(arr[sta
Chapter11/Chapter_11/common/replay_buffer.py:54
↓ 2 callersMethodreset
Reset all the environments and return an array of observations, or a tuple of observation arrays. If step_async is still doin
Chapter14/Chapter_14/multiprocessing_env.py:40
↓ 2 callersMethodreset
(self)
Chapter14/Chapter_14/multiprocessing_env.py:129
↓ 2 callersMethodreset
(self)
Chapter14/Chapter_14/minipacman.py:23
↓ 2 callersMethodreset_noise
(self)
Chapter10/Chapter_10/Chapter_10_Rainbow.py:58
↓ 2 callersMethodreset_noise
(self)
Chapter10/Chapter_10/Chapter_10_NDQN.py:89
↓ 2 callersMethodreset_noise
(self)
Chapter11/Chapter_11/Chapter_10_Rainbow.py:58
↓ 2 callersMethodreset_noise
(self)
Chapter11/Chapter_11/Chapter_11_Unity_Rainbow.py:68
↓ 2 callersMethodreset_task
(self)
Chapter14/Chapter_14/multiprocessing_env.py:134
↓ 2 callersMethodrollout
(self)
Chapter13/Chapter_13/obs_tower2/roller.py:36
↓ 2 callersMethodrun_for_rollout
Run the model on the rollout and create a new rollout with the filled-in model_outs. This may be more efficient than using s
Chapter13/Chapter_13/obs_tower2/model.py:49
↓ 2 callersMethodsample
(self, batch_size)
Chapter06/Chapter_6/Chapter_6_DQN.py:27
↓ 2 callersMethodsample
Sample a batch of experiences. Parameters ---------- batch_size: int How many transitions to sample. Retur
Chapter11/Chapter_11/common/replay_buffer.py:182
↓ 2 callersFunctionsample_recordings
Sample recordings such that recordings are weighted in proportion to their number of frames.
Chapter13/Chapter_13/obs_tower2/recording.py:87
↓ 2 callersFunctionselect_seed
(res_dir=RES_DIR, floor=0)
Chapter13/Chapter_13/obs_tower2/recorder/record.py:87
↓ 2 callersFunctionsoft_update
(net, net_target)
Chapter08/Chapter_8/Chapter_8_DDPG.py:100
↓ 2 callersMethodstd
(self)
Chapter08/Chapter_8/TRPO/running_state.py:38
↓ 2 callersMethodstep
(self, action)
Chapter14/Chapter_14/Chapter_14_wo_HER.py:48
↓ 2 callersMethodstep
(self, action)
Chapter14/Chapter_14/minipacman.py:16
↓ 2 callersMethodstep
(self, actions)
Chapter13/Chapter_13/obs_tower2/batched_env.py:37
↓ 2 callersMethodterms
(self, states, obses, advs, targets, actions, log_probs)
Chapter13/Chapter_13/obs_tower2/ppo.py:66
↓ 2 callersFunctiontest_policy
(policy, env)
Chapter03/Chapter_3/Chapter_3_3.py:63
↓ 2 callersFunctiontrain
(model, optimizer, memory, on_policy=False)
Chapter09/Chapter_9/Chapter_9_ACER.py:76
↓ 2 callersFunctiontruncate_recordings
Truncate the recordings so that they never exceed a given floor. This can be used, for example, to train an agent to solve the begin
Chapter13/Chapter_13/obs_tower2/recording.py:59
↓ 2 callersFunctionupdate
(model, optimizer, replay_buffer, batch_size)
Chapter10/Chapter_10/Chapter_10_HDQN.py:76
↓ 2 callersFunctionupdateForName
(name)
Chapter13/Chapter_13/obs_tower2/labeler/assets/script.js:22
↓ 2 callersFunctionupdate_target
(current_model, target_model)
Chapter07/Chapter_7/Chapter_7_DDQN_wprority.py:161
↓ 2 callersFunctionupdate_target
(current_model, target_model)
Chapter07/Chapter_7/Chapter_7_DDQN.py:90
↓ 2 callersFunctionupdate_target
(current_model, target_model)
Chapter07/Chapter_7/Chapter_7_DoubleDQN.py:78
↓ 2 callersFunctionupdate_target
(current_model, target_model)
Chapter10/Chapter_10/Chapter_10_Rainbow.py:82
← previousnext →101–200 of 857, ranked by callers