Code Monkey home page Code Monkey logo

Comments (4)

alexriedel1 avatar alexriedel1 commented on September 10, 2024

Why would you do this? You can pass multiple image one after another to the anomalib models via a datamodule.

One (RGB) image already has 3 channels. If you are working with grayscale image, you could try to concatenate 3 single-channel images to one 3-channel image, but I'm not sure if that helps you with anomaly detection accuracy (would be interesting to know though!)

from anomalib.

garima-mahato avatar garima-mahato commented on September 10, 2024

I have 4 RGB images representing the same defect in different lighting conditions. Each lighting condition highlights a different aspect of the defect. In total 12 channels. They have to be passed together because they represent the same example.

In timm models (which is being used in anomalib), we can pass in_channels. In pytorch dataset module, we can customize the channels. How can we do the same in anomalib?

from anomalib.

alexriedel1 avatar alexriedel1 commented on September 10, 2024

Ahh ok so the timm model loading function is already designed in a way to support more than three channels even with pre-trained models: https://timm.fast.ai/models#How-is-timm-able-to-use-pretrained-weights-and-handle-images-that-are-not-3-channel-RGB-images?

There is no interface to this functionality in anomalib built-in at the moment but you can do it yourself by modifying how the timm models are created in anomalib

self.feature_extractor = timm.create_model(

give it a try and tell us how this changed the anomaly detection performance!

from anomalib.

bujoi avatar bujoi commented on September 10, 2024

If camera and object in fixed position, you can use stereo photometric to generate one image form multiple light.

from anomalib.

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.