Learned Greedy Method (LGM): A Novel Neural Architecture for Sparse Coding and Beyond