GithubHelp home page GithubHelp logo

iops's People

Contributors

iopsai avatar lizeyan avatar weibinmeng avatar

Stargazers

Qinghua Liu avatar  avatar  avatar E-Tiger Studio avatar Feng Tan avatar Xu Hong Bo avatar  avatar 王嘉楠 avatar  avatar Wancheng Chen avatar 八月的蠢 avatar 0x000 avatar Yuanpeng Li avatar  avatar Deliwe avatar Nguyễn Ngọc Đăng avatar zhangzhijie avatar Zhenyu Chen avatar Albert Millan avatar Bill avatar Jenny Chen avatar  avatar 蔡徐坤 avatar  avatar Yukun Zheng avatar  avatar hx avatar Guowei Huang avatar MikeChen avatar zawabest avatar Xinkun Chu avatar Leo.niu avatar jiaxin avatar  avatar  avatar Alvin Yao avatar  avatar peterz3g avatar

Watchers

Jumping Qu avatar zawabest avatar freecisco avatar  avatar Nengwen Zhao avatar SONG avatar MikeChen avatar anonymous avatar

iops's Issues

评估脚本算法的疑惑

假设有如下标注的数据集:

00110 00100 00000 ...

算法输出的结果为:

00000 11000 00000 ...

根据大赛的评估规则描述:

如果异常检测算法在该连续异常区间开始后的 不晚于T 个时间点内检测到了该连续异常区间,本挑战赛认为此异常检测算法成功地检测到了整段连续异常区间

如果delay为7,那么调整后的结果应该为:

00110 11000 00000 ...

而根据评估脚本的代码,调整后的结果却是:

00000 11000 00000 ...

这是因为evaluation.py脚本的第18行代码中,对于异常区间长度delay值做了一个取最小值的min()操作:

def get_range_proba(predict, label, delay=7):
    splits = np.where(label[1:] != label[:-1])[0] + 1
    is_anomaly = label[0] == 1
    new_predict = np.array(predict)
    pos = 0

    for sp in splits:
        if is_anomaly:
            if 1 in predict[pos:min(pos + delay + 1, sp)]:    # 这一行
                new_predict[pos: sp] = 1
            else:
                new_predict[pos: sp] = 0
        is_anomaly = not is_anomaly
        pos = sp
    sp = len(label)

    if is_anomaly:  # anomaly in the end
        if 1 in predict[pos: min(pos + delay + 1, sp)]:
            new_predict[pos: sp] = 1
        else:
            new_predict[pos: sp] = 0

    return new_predict

这种情况发生的条件是:

  • 异常区间长度 < delay值
  • 异常区间长度 < 算法的预测的延迟时间T < delay值

个人看法是,这里不应该取min,直接采用pos+delay+1,才不会遗漏小于delay值的异常区间。
亦或是,我对评估规则的理解有偏差?

希望解答,感谢。

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.