

def __recycle_expr(self, expr):
    'recycle expr\n\n        If it is a docker experiment , stop it ; else assign it to default user\n\n        :type expr: Experiment\n        :param expr: the exper which you want to recycle\n\n        :return:\n        '
    providers = map((lambda x: x.provider), expr.virtual_environments)
    if (VE_PROVIDER.DOCKER in providers):
        self.stop_expr(expr.id)
        self.log.debug((("it's stopping " + str(expr.id)) + ' inactive experiment now'))
    else:
        self.assign_expr_to_admin(expr)
        self.log.debug((('assign ' + str(expr.id)) + ' to default admin'))

dataset/ETHPy150Open msopentechcn/open-hackathon/open-hackathon-server/src/hackathon/expr/expr_mgr.py ExprManager.__recycle_expr/original