Optimal Allocation of Inspection Effort in a Multi-Stage production process