Giter Site home page Giter Site logo

forestsking / d3r Goto Github PK

View Code? Open in Web Editor NEW
31.0 31.0 4.0 654 KB

PyTorch implementation of "Drift doesn't Matter: Dynamic Decomposition with Dffusion Reconstruction for Unstable Multivariate Time Series Anomaly Detection" (NeurIPS 2023)

Python 99.81% Shell 0.19%
anomaly-detection diffusion time-series

d3r's Introduction

Hi, I'm Chengsen Wang 👋

  • 👨‍🎓 I'm a PhD student at BUPT, class of 2023.
  • 🎯 My primary research interests focus on time series analysis, along with LLM.
  • 📫 Feel free to contact me at [email protected] for discussions and collaborations!

 

d3r's People

Contributors

forestsking avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

d3r's Issues

关于PSM和SWaT数据集复现结果的问题

作者您好:
我按照您发布的代码和数据集进行了PSM、SMD和SWaT的复现实验,现在得到SMD的实验结果与您论文中发布的结果相当,但是PSM和SWaT数据集的复现实验结果分别比论文中低了5.7%和10%。请问您在进行这两个数据集的实验中是否调整了部分实验参数?

Why only use the last time step of each window to find the threshold?

你好,感谢提供如此杰出且创新的工作!

在阅读exp\exp.py中的test 部分代码时对这里有一些困惑:

init_src, init_rec = [], []
for (batch_data, batch_time, batch_stable, batch_label) in tqdm(self.init_loader):
    _, _, recon = self._process_one_batch(batch_data, batch_time, batch_stable, train=False)
    init_src.append(batch_data.detach().cpu().numpy()[:, -1, :])
    init_rec.append(recon.detach().cpu().numpy()[:, -1, :])

test_label, test_src, test_rec = [], [], []
for (batch_data, batch_time, batch_stable, batch_label) in tqdm(self.test_loader):
    _, _, recon = self._process_one_batch(batch_data, batch_time, batch_stable, train=False)
    test_label.append(batch_label.detach().cpu().numpy()[:, -1, :])
    test_src.append(batch_data.detach().cpu().numpy()[:, -1, :])
    test_rec.append(recon.detach().cpu().numpy()[:, -1, :])

为什么只用每个window的最后一步来计算threshold呢?
期待得到你的解答,谢谢!

About threshold

你好,我刚开始研究时间序列的异常检测,我发现你代码里面的 threshold 是通过 SPOT 类计算得到的,这个类的计算有些复杂且缺乏注释和参考资料。请问您能解释一下这个类或者提供一些参考资料吗?

About the Threshold

Hi, thanks for making the code public. I find that you use grid search to obtain the best SPOT parameters for each dataset and record the results with the highest F1 scores. I'm confused about the parameter search space for SPOT. Can you show it? I'm also confused if you have used the same parameter for each datasets.

数据集问题

您好,请问:
def getData(path='./dataset/', dataset='SWaT', period=1440, train_rate=0.8):
init_data = np.load(path + '/'+dataset + '/' + dataset + '_train_data.npy')
init_time = getTimeEmbedding(np.load(path + dataset + '/' + dataset + '_train_time.npy'))

test_data = np.load(path + dataset + '/' + dataset + '_test_data.npy')
test_time = getTimeEmbedding(np.load(path + dataset + '/' + dataset + '_test_time.npy'))
test_label = np.load(path + dataset + '/' + dataset + '_test_label.npy')

在您所给的数据集链接中文件后缀data.npy和date.npy。请问time.npy是不是就是date.npy呢?

Why the results obtained are inconsistent

Why the results obtained are inconsistent

When using the evaluate function in the code, the result is as follows:
p:0.3486 R:0.9993 F1:0.4920
When tested with sklearn's classification_report function, the result is:
PRF1 : 0
The above results were tested on our own dataset

About metric

你好,我对你的工作很感兴趣。我注意到你使用的 metric 是论文 Local Evaluation of Time Series Anomaly Detection Algorithms 中所提到的。但是我发现原论文好像没有提供代码,你们的代码是自己实现的对吗?

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.