Compute- and Process-in-Memory Modules for Machine Learning and Neuromorphic Computing