And gate thing mostly works. Added skeleton for backprop learning and logging.