LAMV: Learning to align and match videos with kernelized temporal layers