import tensorflow as tf

			# self.bc_loss          = 0.5 * tf.reduce_mean(tf.contrib.keras.backend.categorical_crossentropy(self.optimal_actions_onehot,self.policy))
                        # self.next_loc_loss_il = 0.2 * tf.reduce_sum(tf.sqrt(tf.square(self.next_loc_mean[:-1,:] - self.il_nextloc)))

			# self.imitation_loss   = self.bc_loss    #+ self.next_loc_loss_il

			# Get gradients from local network using local losses and
			# normalize the gradients using clipping
			local_vars         = tf.get_collection(tf.GraphKeys.TRAINABLE_VARIABLES, scope+'/qvalues')
			self.gradients     = tf.gradients(self.loss, local_vars)
			self.var_norms     = tf.global_norm(local_vars)
			grads, self.grad_norms = tf.clip_by_global_norm(self.gradients, GRAD_CLIP)

			# Apply local gradients to global network
			global_vars        = tf.get_collection(tf.GraphKeys.TRAINABLE_VARIABLES, GLOBAL_NET_SCOPE+'/qvalues')
