Deep Learning for Compute in Memory