algorithms for learning from scratch