made pattern recognition work
backprop removed