You're looking at a specific version of this model. Jump to the model overview.
j-min /vl-t5:560b0f84
Input
Run this model in Node.js with one line of code:
npm install replicate
REPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
import Replicate from "replicate";
const replicate = new Replicate({
auth: process.env.REPLICATE_API_TOKEN,
});
Run j-min/vl-t5 using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
const output = await replicate.run(
"j-min/vl-t5:560b0f8439191dddf5babf188e34b63fb4e4d679fdb2c10d82988d25df798b7c",
{
input: {
image: "https://replicate.delivery/mgxm/d80b0dac-f162-4c23-ae6c-9f5a72725900/demo.jpg",
question: "what is in the picture?"
}
}
);
console.log(output);
To learn more, take a look at the guide on getting started with Node.js.
pip install replicate
REPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
import replicate
Run j-min/vl-t5 using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
output = replicate.run(
"j-min/vl-t5:560b0f8439191dddf5babf188e34b63fb4e4d679fdb2c10d82988d25df798b7c",
input={
"image": "https://replicate.delivery/mgxm/d80b0dac-f162-4c23-ae6c-9f5a72725900/demo.jpg",
"question": "what is in the picture?"
}
)
print(output)
To learn more, take a look at the guide on getting started with Python.
REPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
Run j-min/vl-t5 using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
curl -s -X POST \
-H "Authorization: Bearer $REPLICATE_API_TOKEN" \
-H "Content-Type: application/json" \
-H "Prefer: wait" \
-d $'{
"version": "560b0f8439191dddf5babf188e34b63fb4e4d679fdb2c10d82988d25df798b7c",
"input": {
"image": "https://replicate.delivery/mgxm/d80b0dac-f162-4c23-ae6c-9f5a72725900/demo.jpg",
"question": "what is in the picture?"
}
}' \
https://api.replicate.com/v1/predictions
To learn more, take a look at Replicate’s HTTP API reference docs.
brew install cog
If you don’t have Homebrew, there are other installation options available.
Run this to download the model and run it in your local environment:
cog predict r8.im/j-min/vl-t5@sha256:560b0f8439191dddf5babf188e34b63fb4e4d679fdb2c10d82988d25df798b7c \
-i 'image="https://replicate.delivery/mgxm/d80b0dac-f162-4c23-ae6c-9f5a72725900/demo.jpg"' \
-i 'question="what is in the picture?"'
To learn more, take a look at the Cog documentation.
Run this to download the model and run it in your local environment:
docker run -d -p 5000:5000 --gpus=all r8.im/j-min/vl-t5@sha256:560b0f8439191dddf5babf188e34b63fb4e4d679fdb2c10d82988d25df798b7c
curl -s -X POST \ -H "Content-Type: application/json" \ -d $'{ "input": { "image": "https://replicate.delivery/mgxm/d80b0dac-f162-4c23-ae6c-9f5a72725900/demo.jpg", "question": "what is in the picture?" } }' \ http://localhost:5000/predictions
To learn more, take a look at the Cog documentation.
Add a payment method to run this model.
Each run costs approximately $0.0023. Alternatively, try out our featured models for free.
By signing in, you agree to our
terms of service and privacy policy
Output
{
"completed_at": "2022-03-21T20:37:18.852108Z",
"created_at": "2022-03-21T20:35:24.340005Z",
"data_removed": false,
"error": null,
"id": "dyrpwgljczhabhnrwfviv633qi",
"input": {
"image": "https://replicate.delivery/mgxm/d80b0dac-f162-4c23-ae6c-9f5a72725900/demo.jpg",
"question": "what is in the picture?"
},
"logs": "/root/.pyenv/versions/3.8.12/lib/python3.8/site-packages/torch/functional.py:445: UserWarning: torch.meshgrid: in an upcoming release, it will be required to pass the indexing argument. (Triggered internally at ../aten/src/ATen/native/TensorShape.cpp:2157.)\n return _VF.meshgrid(tensors, **kwargs) # type: ignore[attr-defined]",
"metrics": {
"predict_time": 5.601476,
"total_time": 114.512103
},
"output": "dog",
"started_at": "2022-03-21T20:37:13.250632Z",
"status": "succeeded",
"urls": {
"get": "https://api.replicate.com/v1/predictions/dyrpwgljczhabhnrwfviv633qi",
"cancel": "https://api.replicate.com/v1/predictions/dyrpwgljczhabhnrwfviv633qi/cancel"
},
"version": "560b0f8439191dddf5babf188e34b63fb4e4d679fdb2c10d82988d25df798b7c"
}
/root/.pyenv/versions/3.8.12/lib/python3.8/site-packages/torch/functional.py:445: UserWarning: torch.meshgrid: in an upcoming release, it will be required to pass the indexing argument. (Triggered internally at ../aten/src/ATen/native/TensorShape.cpp:2157.)
return _VF.meshgrid(tensors, **kwargs) # type: ignore[attr-defined]