def oracle(self, dimfun):
        (dim, funcId) = dimfun

        # What is the best reachable target?
        bestfinalfunval = max(np.median(self.bestalg(dimfun).bestfinalfunvals), 1e-8)

        # How fast do various algorithms reach it?
        algs = list(self.algds_dimfunc(dimfun))
        maxevals = np.max([ds.maxevals for (name, ds) in algs])
        evals = np.array([ds.detEvals([bestfinalfunval]) for (name, ds) in algs])

        # XXX: Gah, how to do this the numpy way?
        nanmask = np.isnan(evals)
        medevals = [maxevals]*len(algs)
        for i in range(len(algs)):
            algnanmask = ~np.isnan(evals)[i]
            if np.any(algnanmask):
                medevals[i] = np.median(evals[i, algnanmask])
            else:
                medevals[i] = maxevals
        nametarget = [(algs[i][0], medevals[i]) for i in range(len(algs))]

        # Pick the fastest!
        (name, target) = min(nametarget, key = lambda k: k[1])
        return self.algds[name].dictByDimFunc()[dim][funcId][0]
Stop the service.
dataset/ETHPy150Open pasky/cocopf/pproc.py/PortfolioDataSets.oracle--crossover with--dataset/ETHPy150Open twisted/twisted/twisted/application/service.py/IService.stopService