Giter VIP home page Giter VIP logo

patch-index-extractor's Introduction

Patch Index Extractor

Introduction

众所周知,vision transformer会将一张图像划分为许多patch,然后提取每个patch的特征,但是在研究各个patch间的关系时,将图像中的一个区域与patch对应是一个比较麻烦的事,比如下图,我想知道左边的狮子头部与右边狮子的头部处的特征是否相同,但是我不能直观地获取两个狮子头对应的patch,于是乎,这个demo出现了,仅需点一点即可获取想要区域的patch索引。

As we all know, vision transformer can divide an image into many patches and then extract the features of each patch. However, when studying the relationship between different patches, it is troublesome to map an intuitive area in the image to patch. As shown in the following figure, I want to know whether the features of the head of the lion on the left are the same as those of the head of the right lion, but I cannot intuitively know which patches correspond to the two lion heads. Therefore, this demo appears, and the patch index of the desired area can be obtained by just clicking.

Usage

Running main.py directly is recommended because main.exe is slow.

step1:

Click File in the menu to load the image.

step2:

Set the width and height of the image, change the image resolution, default to the original image size.

step3:

Set the patch size to divide the resized image into many patches.

step4:

Click on any patch to display the index of that patch below the image.

patch-index-extractor's People

Contributors

xrli-u avatar

Stargazers

 avatar  avatar

Watchers

 avatar

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.