48d178cfbb60e5b0004f63b2eca37b2449bb6c67,a2c/a2c.py,Model,__init__,#Model#Any#Any#Any#Any#Any#Any#Any#Any#Any#Any#Any#Any#Any#Any#Any#Any#Any#,26
Before Change
vf_loss = tf.reduce_mean(mse(tf.squeeze(train_model.vf), R))
self.params = params = tf.get_collection(tf.GraphKeys.TRAINABLE_VARIABLES, scope="model")
self.params_common = params_common = tf.get_collection(tf.GraphKeys.TRAINABLE_VARIABLES, scope="model/common")
After Change
loss = pg_loss - entropy*ent_coef + vf_loss * vf_coef
params = find_trainable_variables("model")
grads = tf.gradients(loss, params)
if max_grad_norm is not None:
grads, _ = tf.clip_by_global_norm(grads, max_grad_norm)
grads = list(zip(grads, params))
trainer = tf.train.RMSPropOptimizer(learning_rate=lr, decay=alpha, epsilon=epsilon)
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 4
Instances
Project Name: chris-chris/pysc2-examples
Commit Name: 48d178cfbb60e5b0004f63b2eca37b2449bb6c67
Time: 2017-10-31
Author: sjhshy@gmail.com
File Name: a2c/a2c.py
Class Name: Model
Method Name: __init__
Project Name: HyperGAN/HyperGAN
Commit Name: 691e0b50d0b15665df5ec77eeec7c605c4283e1f
Time: 2020-03-08
Author: mikkel@255bits.com
File Name: hypergan/trainers/alternating_trainer.py
Class Name: AlternatingTrainer
Method Name: _step
Project Name: rlworkgroup/garage
Commit Name: 5c42053fcd6821eb39eded56526cfe5f2070418a
Time: 2018-05-25
Author: 35857569+gonzaiva@users.noreply.github.com
File Name: sandbox/rocky/tf/optimizers/penalty_lbfgs_optimizer.py
Class Name: PenaltyLbfgsOptimizer
Method Name: update_opt