Quantum Information Processing with Finite Resources