def _call(self, inputs):
    x = inputs
    if self.sparse_inputs:
        x = sparse_dropout(x, (1 - self.dropout), self.num_features_nonzero)
    else:
        x = tf.nn.dropout(x, (1 - self.dropout))
    supports = list()
    for i in range(len(self.support)):
        if (not self.featureless):
            pre_sup = dot(x, self.vars[('weights_' + str(i))], sparse=self.sparse_inputs)
        else:
            pre_sup = self.vars[('weights_' + str(i))]
        support = dot(self.support[i], pre_sup, sparse=True)
        supports.append(support)
    output = tf.add_n(supports)
    if self.bias:
        output += self.vars['bias']
    return self.act(output)
def _call(self, inputs):
    x = inputs
    if self.sparse_inputs:
        x = sparse_dropout(x, (1 - self.dropout), self.num_features_nonzero)
    else:
        x = tf.nn.dropout(x, (1 - self.dropout))
    supports = list()
    for i in range(len(self.support)):
        if (not self.featureless):
            pre_sup = dot(x, self.vars[('weights_' + str(i))], sparse=self.sparse_inputs)
        else:
            pre_sup = self.vars[('weights_' + str(i))]
        support = dot(self.support[i], pre_sup, sparse=True)
        supports.append(support)
    output = tf.add_n(supports)
    if self.bias:
        output += self.vars['bias']
    return self.act(output)