Giter Site home page Giter Site logo

Comments (7)

Julian-Wyatt avatar Julian-Wyatt commented on May 31, 2024

That first module is the context encoder used to generate comparative statistics for the paper. I wasn't planning on uploading that but I can do if you'd still like it?
So I ran the model on the leather subset of MVTec so you should be able to use the MTec Dataset class and load in the model that way - although when instantiating and using the model throughout I've referred to it as "leather", but you should be able to edit those sections and run it ok - the config file I used looks like (changing the noise_fn for simplex for that model):

{
  "img_size": [256,256],
  "Batch_Size": 1,
  "EPOCHS": 3000,
  "T": 1000,
  "base_channels": 128,
  "beta_schedule": "linear",
  "channel_mults": "",
  "loss-type": "l2",
  "loss_weight": "none",
  "train_start": true,
  "lr": 1e-4,
  "random_slice": true,
  "sample_distance": 600,
  "weight_decay": 0.0,
  "save_imgs":false,
  "save_vids":true,
  "dropout":0,
  "attention_resolutions":"16,8",
  "num_heads":2,
  "num_head_channels":-1,
  "noise_fn":"gauss",
  "dataset":"leather"
}

Let me know if this helps and get back in touch if not

from anoddpm.

yobrepus avatar yobrepus commented on May 31, 2024

Thank you very much for your advice. Now I can train the model. By the way, Can you explain in detail how to evaluate the model ? I don't know how to use detection.py

from anoddpm.

Julian-Wyatt avatar Julian-Wyatt commented on May 31, 2024

Firstly, you must ensure the function you want to run is selected at the bottom of the file and linked under the arg file provided.
Since you're running the model on MVTec, the anomalous_metric_calculation function will loop over the leather dataset and record various relevant metrics to a file. This is the primary function used for evaluation.

Alternatively, if you want to reproduce the graphs for example, then the roc_data and graph_data functions sort this however they would need to be adapted for your dataset and remove redundant comparative models.

Let me know whether this helps

from anoddpm.

Julian-Wyatt avatar Julian-Wyatt commented on May 31, 2024

Closing due to no responses

from anoddpm.

mingqing666 avatar mingqing666 commented on May 31, 2024

Thank you very much for your advice. Now I can train the model. By the way, Can you explain in detail how to evaluate the model ? I don't know how to use detection.py

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

from anoddpm.

lwtgithublwt avatar lwtgithublwt commented on May 31, 2024

In the file "detection.py," I found "import Comparative_models.CE as CE" on line 466. How I can get this package? Moreover, I want to run your model based on the dataset "MVTec". Would you please advise me on how I can reproduce the result? What the configuration file should look like and the steps to reproduce the result.

Import Comparative_ Models CE as CE, how did you solve it

from anoddpm.

Julian-Wyatt avatar Julian-Wyatt commented on May 31, 2024

Thank you very much for your advice. Now I can train the model. By the way, Can you explain in detail how to evaluate the model ? I don't know how to use detection.py

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

I don't believe I have access to that file anymore, just delete the references to it as it is just required for comparing models.

from anoddpm.

Related Issues (20)

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.