mangushev / mtad-gat Goto Github PK
View Code? Open in Web Editor NEWImplementation of MTAD-GAT: Multivariate Time-series Anomaly Detection via Graph Attention Network
License: MIT License
Implementation of MTAD-GAT: Multivariate Time-series Anomaly Detection via Graph Attention Network
License: MIT License
Thank you for your excellent work!
I've both read the paper (MTAD-GAT: Multivariate Time-series Anomaly Detection via Graph Attention Network) and your source code,
and was wondering about _reconstruction_loss_
part, especially about the pdf(data, mu, var)
function.
From your source code, reconstruction loss is calculated by adding -self._reconstruction_log_probability
(finally indicates -pdf
function) and -self._minusDkl
.
_reconstruction_loss1 = -(self._reconstruction_log_probability + self._minusDkl)
And from the paper, reconstruction loss is calculated by adding two terms.
(First: the expected negative log-likelihood of the given input
, Second: Kullback-Leibler divergence
).
I have problem with understanding how does this -pdf
function serves same role as the first term(expected NLLloss) from the paper.
I was trying to implement the reconstruction loss same as the paper but had problem with implementing the arguments of NLLloss, and found your work..!
Can you explain how does the -pdf
function works as NLLloss (the expected negative log-likelihood of the given input)?
Traceback (most recent call last):
File "F:/mtad-gat-master/training.py", line 379, in
main()
File "F:/mtad-gat-master/training.py", line 267, in main
scores = list(results)
File "D:\Anaconda\envs\tf114\lib\site-packages\tensorflow_estimator\python\estimator\tpu\tpu_estimator.py", line 2919, in predict
rendezvous.raise_errors()
File "D:\Anaconda\envs\tf114\lib\site-packages\tensorflow_estimator\python\estimator\tpu\error_handling.py", line 131, in raise_errors
six.reraise(typ, value, traceback)
File "D:\Anaconda\envs\tf114\lib\site-packages\six.py", line 719, in reraise
raise value
File "D:\Anaconda\envs\tf114\lib\site-packages\tensorflow_estimator\python\estimator\tpu\tpu_estimator.py", line 2913, in predict
yield_single_examples=yield_single_examples):
File "D:\Anaconda\envs\tf114\lib\site-packages\tensorflow_estimator\python\estimator\estimator.py", line 637, in predict
preds_evaluated = mon_sess.run(predictions)
File "D:\Anaconda\envs\tf114\lib\site-packages\tensorflow\python\training\monitored_session.py", line 754, in run
run_metadata=run_metadata)
File "D:\Anaconda\envs\tf114\lib\site-packages\tensorflow\python\training\monitored_session.py", line 1252, in run
run_metadata=run_metadata)
File "D:\Anaconda\envs\tf114\lib\site-packages\tensorflow\python\training\monitored_session.py", line 1353, in run
raise six.reraise(*original_exc_info)
File "D:\Anaconda\envs\tf114\lib\site-packages\six.py", line 719, in reraise
raise value
File "D:\Anaconda\envs\tf114\lib\site-packages\tensorflow\python\training\monitored_session.py", line 1338, in run
return self._sess.run(*args, **kwargs)
File "D:\Anaconda\envs\tf114\lib\site-packages\tensorflow\python\training\monitored_session.py", line 1411, in run
run_metadata=run_metadata)
File "D:\Anaconda\envs\tf114\lib\site-packages\tensorflow\python\training\monitored_session.py", line 1169, in run
return self._sess.run(*args, **kwargs)
File "D:\Anaconda\envs\tf114\lib\site-packages\tensorflow\python\client\session.py", line 950, in run
run_metadata_ptr)
File "D:\Anaconda\envs\tf114\lib\site-packages\tensorflow\python\client\session.py", line 1173, in _run
feed_dict_tensor, options, run_metadata)
File "D:\Anaconda\envs\tf114\lib\site-packages\tensorflow\python\client\session.py", line 1350, in _do_run
run_metadata)
File "D:\Anaconda\envs\tf114\lib\site-packages\tensorflow\python\client\session.py", line 1370, in _do_call
raise type(e)(node_def, op, message)
tensorflow.python.framework.errors_impl.InvalidArgumentError: 2 root error(s) found.
(0) Invalid argument: Key: input. Can't parse serialized Example.
[[{{node ParseSingleExample/ParseSingleExample}}]]
[[IteratorGetNext]]
[[IteratorGetNext/_221]]
(1) Invalid argument: Key: input. Can't parse serialized Example.
[[{{node ParseSingleExample/ParseSingleExample}}]]
[[IteratorGetNext]]
0 successful operations.
0 derived errors ignored.
Process finished with exit code 1
It works fine during training, but starts reporting errors at the file - inference_score.csv.generation step.
Do you have this problem?
作者大大您好,我是一名研二学生,拜读了您的文章,因为使用matlab居多而对python不是很了解,所以想请教如何读取文本文件中的数据然后使程序正常运行的。readme中“python prepare_data.py --files_path=ServerMachineDataset/train--tfrecords_file=gs://anomaly_detection/mtad_tf/data/train/{}.tfrecords”没看懂,是给出路径就能自动读取文本数据了吗?可有偿请较,如有赐教不胜感激!
请问有大佬实现了代码吗???
我按照readme的代码运行,没有模型产生。。也没有图片生成
@mangushev Thanks for your work.Is this the official implementation of MTAD-GAT about your repository.The model of my implementation gets good performence in MSL.but the performence is very pool in SMAP dataset.I would like to konw if you eval the model in SMAP dataset
Hi,
Thanks for your wonderful work, I wonder whether this repo is the official code of
“Multivariate Time-series Anomaly Detection via Graph Attention Network“
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.