Julian-Wyatt / AnoDDPM

CVPR Workshop paper - AnoDDPM: Anomaly Detection with Denoising Diffusion Probabilistic Models using Simplex Noise
https://julianwyatt.co.uk/anoddpm
MIT License
174 stars 28 forks source link

Two issues about AnoDDPM paper and code #11

Closed Chopper-233 closed 1 year ago

Chopper-233 commented 1 year ago

Thank you for your good work(AnoDDPM)!When i try to recurrent your job ,i got some problems can't be solved . It's my honor if you can help me out. 1.In the paper AnoDDPM,figure1,3,5 shows you have ever used gaussian noise for reconstruct in brain tumor datasets and mvtec leather classes.However,when i try to apply your code to have the same result of figure 1,3,5,i found the denoise process is too awful to recognize the original image,not to mention reconstruction.So i'm wondering how you train the DDPM with gaussian.It's better if you can show me the test args you used.Here it is my result EPOCH=1400 2.In your paper AnoDDPM 3 section methodology part,you explained the reason why gaussian noise can't work.Not intended to be offensive,i can't really understand it ,especially the illustration that"This limits the discriminatory power of an AnoDDPM model as low frequency components are inferred to be relatively corruption free, resulting in large anomalous regions being reconstructed in the reverse process.'

Julian-Wyatt commented 1 year ago
  1. I would make sure you're clear about what you're about outputting. That figure is showing the $x_0$ approximation which directly calculates this approximation rather than through $t$ time steps. Because of this, I'm hopeful that what you've got there seems ok. Also, the title relates to rows 1,2,3 so the top is real, the second is the noise applied to the sample and lastly is the prediction of $x_0$. I would also note here, that it seems as though the image isn't being normalised properly (as the background is grey rather than black)- likely a bug left over on my part. the background should be jet black - like in the paper. If you need me to explain that further let me know.
  2. So to explain that further gaussian noise reconstructs at the highest frequency level, which in the case of images is pixel-wise. Whereas simplex noise has the ability to utilise multi-frequency noise (see Fig 2 from the paper). Then, by training our model to remove noise with simplex noise the high-frequency regions that are near the training distribution are deemed non-anomalous, however, the larger low-frequency components that are far from the training distribution are corrected in the reconstruction process. This consequently lets us focus solely on larger low-frequency anomalous regions. Does that make sense?
Lee-Gao commented 1 year ago

Hello! Thank you very much for your work. Recently, I'm learning the code. I see "import Comparative_models.CE as CE" in some modules. And I can't find the module in the AnoDDPM repo. So I want to know how to get this module? Looking forward to your reply! Thank you!

Julian-Wyatt commented 1 year ago

Hello! Thank you very much for your work. Recently, I'm learning the code. I see "import Comparative_models.CE as CE" in some modules. And I can't find the module in the AnoDDPM repo. So I want to know how to get this module? Looking forward to your reply! Thank you!

Hi Thanks very much for asking; Please see this previous issue who asked a similar question: https://github.com/Julian-Wyatt/AnoDDPM/issues/3

Lee-Gao commented 1 year ago

Hello! Thank you very much for your work. Recently, I'm learning the code. I see "import Comparative_models.CE as CE" in some modules. And I can't find the module in the AnoDDPM repo. So I want to know how to get this module? Looking forward to your reply! Thank you!

Hi Thanks very much for asking; Please see this previous issue who asked a similar question: #3

OK,Thank you for your reply.

mingqing666 commented 1 year ago

Hello! Thank you very much for your work. Recently, I'm learning the code. I see "import Comparative_models.CE as CE" in some modules. And I can't find the module in the AnoDDPM repo. So I want to know how to get this module? Looking forward to your reply! Thank you!

Hi Thanks very much for asking; Please see this previous issue who asked a similar question: #3

OK,Thank you for your reply.

Hello, I am also facing the issue with "import Comparitive_models.CE as CE". I checked the previous thread but couldn't find the uploaded Comparitive_models. Have you found a solution to it?