Algorithm-hardware co-optimization for neural network efficiency improvement