import tensorflow as tf

                        output_data = tf.nn.bias_add(tf.matmul(output_data, expand_W), expand_b)
                        output_data = tf.nn.elu(output_data)
                        current_size = output_sizes[i]
                    #expand_W = tf.get_variable("final_W", [current_size, 1])
                    #expand_b = tf.get_variable("final_b" , [1])
                    #output_data = tf.nn.bias_add(tf.matmul(output_data, expand_W), expand_b)
                    return output_data

            output_propensity_list = []
            for i in range(list_size):
                # Add position information (one-hot vector)
                click_feature = [tf.expand_dims(tf.zeros_like(self.labels[i]) , -1) for _ in range(4*list_size)]
                click_feature[i] = tf.expand_dims(tf.ones_like(self.labels[i]) , -1)
#                 click_feature[list_size:]=[tf.expand_dims(tf.zeros_like(self.labels[i]) , -1) for _ in range(3*list_size)]
                click_feature[list_size:list_size+i] =[tf.expand_dims(self.labels[k] , -1) for k in range(i-1,-1,-1)]
                click_feature[2*list_size:2*list_size+i+1]=[tf.expand_dims(self.types[k] , -1) for k in range(i,-1,-1)]
                click_feature[3*list_size:3*list_size+list_size-i-1]=[tf.expand_dims(self.types[k] , -1) for k in range(i+1,list_size)]
                # Predict propensity with a simple network
                output_propensity_list.append(propensity_network(tf.concat(click_feature, 1), i))
            self.click_show=[click_feature[h][0] for h in range(4*list_size)]
        return tf.concat(output_propensity_list,1)

    def step(self, session, input_feed, forward_only):
        """Run a step of the model feeding the given inputs.
