VizDoom-Keras-RL
VizDoom-Keras-RL copied to clipboard
How to understand the following Lambda sentence in dueling_dqn?
Hi Felix,
I am a beginner who learning your code. Could you please kindly tell me how to understand the following Lambda sentence? Thanks for your help.
def dueling_dqn(input_shape, action_size, learning_rate): ... state_value = Lambda(lambda s: K.expand_dims(s[:, 0], dim=-1), output_shape=(action_size,))(state_value) ... action_advantage = Lambda(lambda a: a[:, :] - K.mean(a[:, :], keepdims=True), output_shape=(action_size,))(action_advantage)