Heterogeneous Photonic Integration with Accelerators and Memory