Wald-Kernel: Learning to Aggregate Information for Sequential Inference