Methexis-Inc Img2prompt API on Replicate

Replicate.com: Generate text prompts that closely match an image with style using Methexis Inc's Img2Prompt tool. Optimized for stable-diffusion (clip ViT-L/14).

Methexis-Inc Img2prompt API on Replicate

Introduction

What is methexis-inc/img2prompt?

methexis-inc/img2prompt is a model that generates an approximate text prompt, with style, matching an image. It is optimized for stable-diffusion (clip ViT-L/14).

How to use methexis-inc/img2prompt

You can use methexis-inc/img2prompt through various methods, including Node.js, Python, Elixir, HTTP, Cog, and Docker. Here are some examples of how to use the model:

Node.js

const replicate = new Replicate({
  auth: process.env.REPLICATE_API_TOKEN,
});

const output = await replicate.run(
  "methexis-inc/img2prompt:50adaf2d3ad20a6f911a8a9e3ccf777b263b8596fbd2c8fc26e8888f8a0edbb5",
  {
    input: {
      image: "https://replicate.delivery/mgxm/8b4d747d-feca-477d-8069-ee4d5f89ad8e/a_high_detail_shot_of_a_cat_wearing_a_suit_realism_8k_-n_9_.png"
    }
  }
);
console.log(output);

Python

import replicate

output = replicate.run(
    "methexis-inc/img2prompt:50adaf2d3ad20a6f911a8a9e3ccf777b263b8596fbd2c8fc26e8888f8a0edbb5",
    input={
        "image": "https://replicate.delivery/mgxm/8b4d747d-feca-477d-8069-ee4d5f89ad8e/a_high_detail_shot_of_a_cat_wearing_a_suit_realism_8k_-n_9_.png"
    }
)
print(output)

Elixir

output = Replicate.run(
  "methexis-inc/img2prompt:50adaf2d3ad20a6f911a8a9e3ccf777b263b8596fbd2c8fc26e8888f8a0edbb5",
  %{
    image: "https://replicate.delivery/mgxm/8b4d747d-feca-477d-8069-ee4d5f89ad8e/a_high_detail_shot_of_a_cat_wearing_a_suit_realism_8k_-n_9_.png"
  }
)
IO.inspect(output)

HTTP

curl -s -X POST \
  -H "Authorization: Bearer $REPLICATE_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d $'{
    "version": "50adaf2d3ad20a6f911a8a9e3ccf777b263b8596fbd2c8fc26e8888f8a0edbb5",
    "input": {
      "image": "https://replicate.delivery/mgxm/8b4d747d-feca-477d-8069-ee4d5f89ad8e/a_high_detail_shot_of_a_cat_wearing_a_suit_realism_8k_-n_9_.png"
    }
  }' \
  https://api.replicate.com/v1/predictions

Cog

cog predict r8.im/methexis-inc/img2prompt@sha256:50adaf2d3ad20a6f911a8a9e3ccf777b263b8596fbd2c8fc26e8888f8a0edbb5 \
  -i 'image="https://replicate.delivery/mgxm/8b4d747d-feca-477d-8069-ee4d5f89ad8e/a_high_detail_shot_of_a_cat_wearing_a_suit_realism_8k_-n_9_.png"'

Docker

docker run -d -p 5000:5000 --gpus=all r8.im/methexis-inc/img2prompt@sha256:50adaf2d3ad20a6f911a8a9e3ccf777b263b8596fbd2c8fc26e8888f8a0edbb5
curl -s -X POST \
  -H "Content-Type: application/json" \
  -d $'{
    "input": {
      "image": "https://replicate.delivery/mgxm/8b4d747d-feca-477d-8069-ee4d5f89ad8e/a_high_detail_shot_of_a_cat_wearing_a_suit_realism_8k_-n_9_.png"
    }
  }' \
  http://localhost:5000/predictions

Features of methexis-inc/img2prompt

The model provides approximate text prompts that can be used with stable diffusion to re-create similar looking versions of the image/painting. It is a slightly adapted version of the CLIP Interrogator notebook by @pharmapsychotic.

Pricing of methexis-inc/img2prompt

The pricing of methexis-inc/img2prompt is not specified. However, the model runs on Nvidia T4 GPU hardware, and predictions typically complete within 51 seconds. The predict time for this model varies significantly based on the inputs.

Methexis-Inc - Alternative

AI Photo Generator | Photo AI™

Generate photorealistic images of people with AI. Take stunning photos of people with the first AI Photographer! Generate photo and video content for your so...

476.6 K
Drag Your GAN: Interactive Point-based Manipulation on the Generative Image Manifold

Synthesizing visual content that meets users' needs often requires flexible and precise controllability of the pose, shape, expression, and layout of the generated objects. Existing approaches gain controllability of generative adversarial networks (GANs) via manually annotated training data or a prior 3D model, which often lack flexibility, precision, and generality. In this work, we study a powerful yet much less explored way of controlling GANs, that is, to

--
100% Free AI Anime Generator | No Signup, No Credits, No Upgrades Needed! | 24/7 Live Access to over 100+ Stable Diffusion Anime Models - Anime Art Studio

100% Free AI Anime Generator No Signup, No Credits, No Upgrades Needed! 24/7 Live Access to over 100+ Stable Diffusion Anime Models 100% Free AI Anime Generator No Signup, No Credits, No Upgrades Needed! Welcome to AnimeArt.Studio, your ultimate destination for stunning AI-generated Anime. Our curated library boasts an extensive collection of opensource AI Anime

47.1 K
More Categories