Git Product home page Git Product logo

shi-labs / oneformer-colab Goto Github PK

View Code? Open in Web Editor NEW
13.0 2.0 8.0 6.71 MB

[Colab Demo Code] OneFormer: One Transformer to Rule Universal Image Segmentation.

Home Page: https://praeclarumjj3.github.io/oneformer

License: MIT License

Python 84.59% Shell 0.22% C++ 1.51% Cuda 13.68%
ade20k cityscapes coco image-segmentation instance-segmentation oneformer panoptic-segmentation semantic-segmentation transformer universal-segmentation

oneformer-colab's Issues

Get one segment using label or index

Hello my question is how can i get a single segment of image by passing either class index or class name.

#@title C. Run Inference (CPU)
#@markdown Specify the task. Default: panoptic. Execution may take upto 2 minutes

task = "panoptic" #@param
%load_ext autotime
out = TASK_INFER[task](img, predictor, metadata).get_image()
cv2_imshow(out[:, :, ::-1])

This code returns me an image with segmentation and labeled image.

But lets say i just want to extract the specific segment of a target class from this image.. for example segment of tree from whole picture. how can i do that.

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.