exceptions.py 文件源码

python
阅读 28 收藏 0 点赞 0 评论 0

项目:AutoML-Challenge 作者: postech-mlg-exbrain 项目源码 文件源码
def handler(signum, frame):
    # logs message with level debug on this logger
    if signum == signal.SIGXCPU:
        # when process reaches soft limit --> a SIGXCPU signal is sent
        # (it normally terminats the process)
        raise CpuTimeoutException
    elif signum == signal.SIGALRM:
        # SIGALRM is sent to process when the specified time limit to an alarm function elapses
        # (when real or clock time elapses)
        raise TimeoutException
    raise AnythingException
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号