The literature of productive efficiency analysis is divided into two main branches: the parametric Stochastic Frontier Analysis (SFA) and nonparametric Data Envelopment Analysis (DEA). This paper attempts to combine the virtues of both approaches in a unified framework. We follow the SFA literature and introduce a stochastic component decomposed into idiosyncratic error and technical inefficiency components imposing the standard SFA assumptions. In contrast to the SFA, we do not make any prior assumptions about the functional form of the deterministic production function. In this respect, we follow the nonparametric route of DEA that only imposes free disposability, convexity, and some specification of returns to scale. From the postulated class of production functions, the proposed method identifies the production function with the best empirical fit to the data. The resulting function will always take a piece-wise linear form analogous to the DEA frontiers. We discuss the practical implementation of the method and illustrate its potential by means empirical examples.