A Configurable and Efficient Memory Hierarchy for Neural Network Hardware Accelerator