  Sparse signal recovery problems from noisy linear measurements appear in many
areas of wireless communications. In recent years, deep learning (DL) based
approaches have attracted interests of researchers to solve the sparse linear
inverse problem by unfolding iterative algorithms as neural networks.
Typically, research concerning DL assume a fixed number of network layers.
However, it ignores a key character in traditional iterative algorithms, where
the number of iterations required for convergence changes with varying sparsity
levels. By investigating on the projected gradient descent, we unveil the
drawbacks of the existing DL methods with fixed depth. Then we propose an
end-to-end trainable DL architecture, which involves an extra halting score at
each layer. Therefore, the proposed method learns how many layers to execute to
emit an output, and the network depth is dynamically adjusted for each task in
the inference phase. We conduct experiments using both synthetic data and
applications including random access in massive MTC and massive MIMO channel
estimation, and the results demonstrate the improved efficiency for the
proposed approach.
