def get_cost(self, inputs, targets):
        self.outputs[:] = self.costfunc(inputs, targets)
        self.cost[:] = self.be.mean(self.outputs, axis=1)
        return self.cost
Ensure the node (WrittenAction/WrittenMessage) is referenced by parent
dataset/ETHPy150Open NervanaSystems/neon/neon/layers/layer.py/GeneralizedCost.get_cost--crossover with--dataset/ETHPy150Open ClusterHQ/eliot/eliot/_parse.py/Task._ensure_node_parents