The Vector and Matrix training code is available here.