Enabling criticality-aware optimized machine perception at the edge