cjwbw
/
instructcv
Instruction tuned text-to-image diffusion models as vision generalists
Prediction
cjwbw/instructcv:3258454aID4io4o3dbkmossdei7vqlkn4vhaStatusSucceededSourceWebHardwareA40 (Large)Total durationCreatedInput
{ "image": "https://replicate.delivery/pbxt/JfcQVKRWgew5Rzpti9VyJyG4Dfa6JfPx3xIV1wGBH6UVLbLs/pCrb5DS.jpg", "instruction": "Detect Berkeley's Sather tower.", "text_guidance_scale": 7.5, "image_guidance_scale": 1.5 }
Install Replicate’s Node.js client library:npm install replicate
Set theREPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
Import and set up the client:import Replicate from "replicate"; const replicate = new Replicate({ auth: process.env.REPLICATE_API_TOKEN, });
Run cjwbw/instructcv using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
const output = await replicate.run( "cjwbw/instructcv:3258454a0f4011005f51886a8d2c4015d5ec146652f2a28f042e5cc7e4ef85b4", { input: { image: "https://replicate.delivery/pbxt/JfcQVKRWgew5Rzpti9VyJyG4Dfa6JfPx3xIV1wGBH6UVLbLs/pCrb5DS.jpg", instruction: "Detect Berkeley's Sather tower.", text_guidance_scale: 7.5, image_guidance_scale: 1.5 } } ); console.log(output);
To learn more, take a look at the guide on getting started with Node.js.
Install Replicate’s Python client library:pip install replicate
Set theREPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
Import the client:import replicate
Run cjwbw/instructcv using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
output = replicate.run( "cjwbw/instructcv:3258454a0f4011005f51886a8d2c4015d5ec146652f2a28f042e5cc7e4ef85b4", input={ "image": "https://replicate.delivery/pbxt/JfcQVKRWgew5Rzpti9VyJyG4Dfa6JfPx3xIV1wGBH6UVLbLs/pCrb5DS.jpg", "instruction": "Detect Berkeley's Sather tower.", "text_guidance_scale": 7.5, "image_guidance_scale": 1.5 } ) print(output)
To learn more, take a look at the guide on getting started with Python.
Set theREPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
Run cjwbw/instructcv 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": "3258454a0f4011005f51886a8d2c4015d5ec146652f2a28f042e5cc7e4ef85b4", "input": { "image": "https://replicate.delivery/pbxt/JfcQVKRWgew5Rzpti9VyJyG4Dfa6JfPx3xIV1wGBH6UVLbLs/pCrb5DS.jpg", "instruction": "Detect Berkeley\'s Sather tower.", "text_guidance_scale": 7.5, "image_guidance_scale": 1.5 } }' \ https://api.replicate.com/v1/predictions
To learn more, take a look at Replicate’s HTTP API reference docs.
Output
{ "completed_at": "2023-10-09T16:12:20.441556Z", "created_at": "2023-10-09T16:12:18.500587Z", "data_removed": false, "error": null, "id": "4io4o3dbkmossdei7vqlkn4vha", "input": { "image": "https://replicate.delivery/pbxt/JfcQVKRWgew5Rzpti9VyJyG4Dfa6JfPx3xIV1wGBH6UVLbLs/pCrb5DS.jpg", "instruction": "Detect Berkeley's Sather tower.", "text_guidance_scale": 7.5, "image_guidance_scale": 1.5 }, "logs": "Using seed: 38141\n 0%| | 0/50 [00:00<?, ?it/s]\n 4%|▍ | 2/50 [00:00<00:03, 14.77it/s]\n 10%|█ | 5/50 [00:00<00:02, 19.05it/s]\n 16%|█▌ | 8/50 [00:00<00:02, 20.39it/s]\n 22%|██▏ | 11/50 [00:00<00:01, 21.02it/s]\n 28%|██▊ | 14/50 [00:00<00:01, 21.35it/s]\n 34%|███▍ | 17/50 [00:00<00:01, 21.57it/s]\n 40%|████ | 20/50 [00:00<00:01, 21.72it/s]\n 46%|████▌ | 23/50 [00:01<00:01, 21.76it/s]\n 52%|█████▏ | 26/50 [00:01<00:01, 21.76it/s]\n 58%|█████▊ | 29/50 [00:01<00:00, 21.80it/s]\n 64%|██████▍ | 32/50 [00:01<00:00, 21.83it/s]\n 70%|███████ | 35/50 [00:01<00:00, 21.83it/s]\n 76%|███████▌ | 38/50 [00:01<00:00, 21.83it/s]\n 82%|████████▏ | 41/50 [00:01<00:00, 21.84it/s]\n 88%|████████▊ | 44/50 [00:02<00:00, 21.86it/s]\n 94%|█████████▍| 47/50 [00:02<00:00, 21.86it/s]\n100%|██████████| 50/50 [00:02<00:00, 21.87it/s]\n100%|██████████| 50/50 [00:02<00:00, 21.49it/s]", "metrics": { "predict_time": 4.092894, "total_time": 1.940969 }, "output": "https://replicate.delivery/pbxt/7B09JVo3qwrILNlXQolxuMmYzbGTRMfJmOenmIK6lvjjhdsRA/out.png", "started_at": "2023-10-09T16:12:16.348662Z", "status": "succeeded", "urls": { "get": "https://api.replicate.com/v1/predictions/4io4o3dbkmossdei7vqlkn4vha", "cancel": "https://api.replicate.com/v1/predictions/4io4o3dbkmossdei7vqlkn4vha/cancel" }, "version": "38123d3d9aea7dc19796bcac6dae9667229247a8d39805fb71219e0d0a0b00e6" }
Generated inUsing seed: 38141 0%| | 0/50 [00:00<?, ?it/s] 4%|▍ | 2/50 [00:00<00:03, 14.77it/s] 10%|█ | 5/50 [00:00<00:02, 19.05it/s] 16%|█▌ | 8/50 [00:00<00:02, 20.39it/s] 22%|██▏ | 11/50 [00:00<00:01, 21.02it/s] 28%|██▊ | 14/50 [00:00<00:01, 21.35it/s] 34%|███▍ | 17/50 [00:00<00:01, 21.57it/s] 40%|████ | 20/50 [00:00<00:01, 21.72it/s] 46%|████▌ | 23/50 [00:01<00:01, 21.76it/s] 52%|█████▏ | 26/50 [00:01<00:01, 21.76it/s] 58%|█████▊ | 29/50 [00:01<00:00, 21.80it/s] 64%|██████▍ | 32/50 [00:01<00:00, 21.83it/s] 70%|███████ | 35/50 [00:01<00:00, 21.83it/s] 76%|███████▌ | 38/50 [00:01<00:00, 21.83it/s] 82%|████████▏ | 41/50 [00:01<00:00, 21.84it/s] 88%|████████▊ | 44/50 [00:02<00:00, 21.86it/s] 94%|█████████▍| 47/50 [00:02<00:00, 21.86it/s] 100%|██████████| 50/50 [00:02<00:00, 21.87it/s] 100%|██████████| 50/50 [00:02<00:00, 21.49it/s]
Prediction
cjwbw/instructcv:3258454aIDfru3ssdbqyregt4dq7b4cyq6aeStatusSucceededSourceWebHardwareA40 (Large)Total durationCreatedInput
- instruction
- Create a monocular depth map
- num_inference_steps
- 50
- text_guidance_scale
- 7.5
- image_guidance_scale
- 1.5
{ "image": "https://replicate.delivery/pbxt/JfcQVKRWgew5Rzpti9VyJyG4Dfa6JfPx3xIV1wGBH6UVLbLs/pCrb5DS.jpg", "instruction": "Create a monocular depth map", "num_inference_steps": 50, "text_guidance_scale": 7.5, "image_guidance_scale": 1.5 }
Install Replicate’s Node.js client library:npm install replicate
Set theREPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
Import and set up the client:import Replicate from "replicate"; const replicate = new Replicate({ auth: process.env.REPLICATE_API_TOKEN, });
Run cjwbw/instructcv using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
const output = await replicate.run( "cjwbw/instructcv:3258454a0f4011005f51886a8d2c4015d5ec146652f2a28f042e5cc7e4ef85b4", { input: { image: "https://replicate.delivery/pbxt/JfcQVKRWgew5Rzpti9VyJyG4Dfa6JfPx3xIV1wGBH6UVLbLs/pCrb5DS.jpg", instruction: "Create a monocular depth map", num_inference_steps: 50, text_guidance_scale: 7.5, image_guidance_scale: 1.5 } } ); console.log(output);
To learn more, take a look at the guide on getting started with Node.js.
Install Replicate’s Python client library:pip install replicate
Set theREPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
Import the client:import replicate
Run cjwbw/instructcv using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
output = replicate.run( "cjwbw/instructcv:3258454a0f4011005f51886a8d2c4015d5ec146652f2a28f042e5cc7e4ef85b4", input={ "image": "https://replicate.delivery/pbxt/JfcQVKRWgew5Rzpti9VyJyG4Dfa6JfPx3xIV1wGBH6UVLbLs/pCrb5DS.jpg", "instruction": "Create a monocular depth map", "num_inference_steps": 50, "text_guidance_scale": 7.5, "image_guidance_scale": 1.5 } ) print(output)
To learn more, take a look at the guide on getting started with Python.
Set theREPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
Run cjwbw/instructcv 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": "3258454a0f4011005f51886a8d2c4015d5ec146652f2a28f042e5cc7e4ef85b4", "input": { "image": "https://replicate.delivery/pbxt/JfcQVKRWgew5Rzpti9VyJyG4Dfa6JfPx3xIV1wGBH6UVLbLs/pCrb5DS.jpg", "instruction": "Create a monocular depth map", "num_inference_steps": 50, "text_guidance_scale": 7.5, "image_guidance_scale": 1.5 } }' \ https://api.replicate.com/v1/predictions
To learn more, take a look at Replicate’s HTTP API reference docs.
Output
{ "completed_at": "2023-10-09T16:23:06.288047Z", "created_at": "2023-10-09T16:22:59.670930Z", "data_removed": false, "error": null, "id": "fru3ssdbqyregt4dq7b4cyq6ae", "input": { "image": "https://replicate.delivery/pbxt/JfcQVKRWgew5Rzpti9VyJyG4Dfa6JfPx3xIV1wGBH6UVLbLs/pCrb5DS.jpg", "instruction": "Create a monocular depth map", "num_inference_steps": 50, "text_guidance_scale": 7.5, "image_guidance_scale": 1.5 }, "logs": "Using seed: 5188\n 0%| | 0/50 [00:00<?, ?it/s]\n 2%|▏ | 1/50 [00:00<00:08, 5.52it/s]\n 8%|▊ | 4/50 [00:00<00:03, 14.11it/s]\n 14%|█▍ | 7/50 [00:00<00:02, 17.40it/s]\n 20%|██ | 10/50 [00:00<00:02, 19.16it/s]\n 26%|██▌ | 13/50 [00:00<00:01, 20.16it/s]\n 32%|███▏ | 16/50 [00:00<00:01, 20.77it/s]\n 38%|███▊ | 19/50 [00:00<00:01, 21.18it/s]\n 44%|████▍ | 22/50 [00:01<00:01, 21.44it/s]\n 50%|█████ | 25/50 [00:01<00:01, 21.63it/s]\n 56%|█████▌ | 28/50 [00:01<00:01, 21.74it/s]\n 62%|██████▏ | 31/50 [00:01<00:00, 21.64it/s]\n 68%|██████▊ | 34/50 [00:01<00:00, 21.74it/s]\n 74%|███████▍ | 37/50 [00:01<00:00, 21.80it/s]\n 80%|████████ | 40/50 [00:01<00:00, 21.85it/s]\n 86%|████████▌ | 43/50 [00:02<00:00, 21.88it/s]\n 92%|█████████▏| 46/50 [00:02<00:00, 21.92it/s]\n 98%|█████████▊| 49/50 [00:02<00:00, 21.94it/s]\n100%|██████████| 50/50 [00:02<00:00, 20.72it/s]", "metrics": { "predict_time": 4.493101, "total_time": 6.617117 }, "output": "https://pbxt.replicate.delivery/Sw1H1blUqdJMHpsgigiQnBRi6iA9EFXHtqWUdLqF2qT6aHbE/out.png", "started_at": "2023-10-09T16:23:01.794946Z", "status": "succeeded", "urls": { "get": "https://api.replicate.com/v1/predictions/fru3ssdbqyregt4dq7b4cyq6ae", "cancel": "https://api.replicate.com/v1/predictions/fru3ssdbqyregt4dq7b4cyq6ae/cancel" }, "version": "3258454a0f4011005f51886a8d2c4015d5ec146652f2a28f042e5cc7e4ef85b4" }
Generated inUsing seed: 5188 0%| | 0/50 [00:00<?, ?it/s] 2%|▏ | 1/50 [00:00<00:08, 5.52it/s] 8%|▊ | 4/50 [00:00<00:03, 14.11it/s] 14%|█▍ | 7/50 [00:00<00:02, 17.40it/s] 20%|██ | 10/50 [00:00<00:02, 19.16it/s] 26%|██▌ | 13/50 [00:00<00:01, 20.16it/s] 32%|███▏ | 16/50 [00:00<00:01, 20.77it/s] 38%|███▊ | 19/50 [00:00<00:01, 21.18it/s] 44%|████▍ | 22/50 [00:01<00:01, 21.44it/s] 50%|█████ | 25/50 [00:01<00:01, 21.63it/s] 56%|█████▌ | 28/50 [00:01<00:01, 21.74it/s] 62%|██████▏ | 31/50 [00:01<00:00, 21.64it/s] 68%|██████▊ | 34/50 [00:01<00:00, 21.74it/s] 74%|███████▍ | 37/50 [00:01<00:00, 21.80it/s] 80%|████████ | 40/50 [00:01<00:00, 21.85it/s] 86%|████████▌ | 43/50 [00:02<00:00, 21.88it/s] 92%|█████████▏| 46/50 [00:02<00:00, 21.92it/s] 98%|█████████▊| 49/50 [00:02<00:00, 21.94it/s] 100%|██████████| 50/50 [00:02<00:00, 20.72it/s]
Prediction
cjwbw/instructcv:3258454aIDyxc5tz3bgvgmloo2nnlugdyjnyStatusSucceededSourceWebHardwareA40 (Large)Total durationCreatedInput
{ "image": "https://replicate.delivery/pbxt/JfcQVKRWgew5Rzpti9VyJyG4Dfa6JfPx3xIV1wGBH6UVLbLs/pCrb5DS.jpg", "instruction": "Segment all trees", "num_inference_steps": 50, "text_guidance_scale": 7.5, "image_guidance_scale": 1.5 }
Install Replicate’s Node.js client library:npm install replicate
Set theREPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
Import and set up the client:import Replicate from "replicate"; const replicate = new Replicate({ auth: process.env.REPLICATE_API_TOKEN, });
Run cjwbw/instructcv using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
const output = await replicate.run( "cjwbw/instructcv:3258454a0f4011005f51886a8d2c4015d5ec146652f2a28f042e5cc7e4ef85b4", { input: { image: "https://replicate.delivery/pbxt/JfcQVKRWgew5Rzpti9VyJyG4Dfa6JfPx3xIV1wGBH6UVLbLs/pCrb5DS.jpg", instruction: "Segment all trees", num_inference_steps: 50, text_guidance_scale: 7.5, image_guidance_scale: 1.5 } } ); console.log(output);
To learn more, take a look at the guide on getting started with Node.js.
Install Replicate’s Python client library:pip install replicate
Set theREPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
Import the client:import replicate
Run cjwbw/instructcv using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
output = replicate.run( "cjwbw/instructcv:3258454a0f4011005f51886a8d2c4015d5ec146652f2a28f042e5cc7e4ef85b4", input={ "image": "https://replicate.delivery/pbxt/JfcQVKRWgew5Rzpti9VyJyG4Dfa6JfPx3xIV1wGBH6UVLbLs/pCrb5DS.jpg", "instruction": "Segment all trees", "num_inference_steps": 50, "text_guidance_scale": 7.5, "image_guidance_scale": 1.5 } ) print(output)
To learn more, take a look at the guide on getting started with Python.
Set theREPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
Run cjwbw/instructcv 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": "3258454a0f4011005f51886a8d2c4015d5ec146652f2a28f042e5cc7e4ef85b4", "input": { "image": "https://replicate.delivery/pbxt/JfcQVKRWgew5Rzpti9VyJyG4Dfa6JfPx3xIV1wGBH6UVLbLs/pCrb5DS.jpg", "instruction": "Segment all trees", "num_inference_steps": 50, "text_guidance_scale": 7.5, "image_guidance_scale": 1.5 } }' \ https://api.replicate.com/v1/predictions
To learn more, take a look at Replicate’s HTTP API reference docs.
Output
{ "completed_at": "2023-10-09T16:23:52.495597Z", "created_at": "2023-10-09T16:23:48.445224Z", "data_removed": false, "error": null, "id": "yxc5tz3bgvgmloo2nnlugdyjny", "input": { "image": "https://replicate.delivery/pbxt/JfcQVKRWgew5Rzpti9VyJyG4Dfa6JfPx3xIV1wGBH6UVLbLs/pCrb5DS.jpg", "instruction": "Segment all trees", "num_inference_steps": 50, "text_guidance_scale": 7.5, "image_guidance_scale": 1.5 }, "logs": "Using seed: 41350\n 0%| | 0/50 [00:00<?, ?it/s]\n 4%|▍ | 2/50 [00:00<00:03, 14.84it/s]\n 10%|█ | 5/50 [00:00<00:02, 19.09it/s]\n 16%|█▌ | 8/50 [00:00<00:02, 20.49it/s]\n 22%|██▏ | 11/50 [00:00<00:01, 21.13it/s]\n 28%|██▊ | 14/50 [00:00<00:01, 21.47it/s]\n 34%|███▍ | 17/50 [00:00<00:01, 21.69it/s]\n 40%|████ | 20/50 [00:00<00:01, 21.76it/s]\n 46%|████▌ | 23/50 [00:01<00:01, 21.81it/s]\n 52%|█████▏ | 26/50 [00:01<00:01, 21.85it/s]\n 58%|█████▊ | 29/50 [00:01<00:00, 21.91it/s]\n 64%|██████▍ | 32/50 [00:01<00:00, 21.95it/s]\n 70%|███████ | 35/50 [00:01<00:00, 21.95it/s]\n 76%|███████▌ | 38/50 [00:01<00:00, 21.97it/s]\n 82%|████████▏ | 41/50 [00:01<00:00, 21.96it/s]\n 88%|████████▊ | 44/50 [00:02<00:00, 21.95it/s]\n 94%|█████████▍| 47/50 [00:02<00:00, 21.94it/s]\n100%|██████████| 50/50 [00:02<00:00, 21.96it/s]\n100%|██████████| 50/50 [00:02<00:00, 21.59it/s]", "metrics": { "predict_time": 4.019095, "total_time": 4.050373 }, "output": "https://pbxt.replicate.delivery/lWTuoQfBKLSjN6e9fVfWMvNOdzGjYO5DXgK8MHF2ig3cx2xGB/out.png", "started_at": "2023-10-09T16:23:48.476502Z", "status": "succeeded", "urls": { "get": "https://api.replicate.com/v1/predictions/yxc5tz3bgvgmloo2nnlugdyjny", "cancel": "https://api.replicate.com/v1/predictions/yxc5tz3bgvgmloo2nnlugdyjny/cancel" }, "version": "3258454a0f4011005f51886a8d2c4015d5ec146652f2a28f042e5cc7e4ef85b4" }
Generated inUsing seed: 41350 0%| | 0/50 [00:00<?, ?it/s] 4%|▍ | 2/50 [00:00<00:03, 14.84it/s] 10%|█ | 5/50 [00:00<00:02, 19.09it/s] 16%|█▌ | 8/50 [00:00<00:02, 20.49it/s] 22%|██▏ | 11/50 [00:00<00:01, 21.13it/s] 28%|██▊ | 14/50 [00:00<00:01, 21.47it/s] 34%|███▍ | 17/50 [00:00<00:01, 21.69it/s] 40%|████ | 20/50 [00:00<00:01, 21.76it/s] 46%|████▌ | 23/50 [00:01<00:01, 21.81it/s] 52%|█████▏ | 26/50 [00:01<00:01, 21.85it/s] 58%|█████▊ | 29/50 [00:01<00:00, 21.91it/s] 64%|██████▍ | 32/50 [00:01<00:00, 21.95it/s] 70%|███████ | 35/50 [00:01<00:00, 21.95it/s] 76%|███████▌ | 38/50 [00:01<00:00, 21.97it/s] 82%|████████▏ | 41/50 [00:01<00:00, 21.96it/s] 88%|████████▊ | 44/50 [00:02<00:00, 21.95it/s] 94%|█████████▍| 47/50 [00:02<00:00, 21.94it/s] 100%|██████████| 50/50 [00:02<00:00, 21.96it/s] 100%|██████████| 50/50 [00:02<00:00, 21.59it/s]
Prediction
cjwbw/instructcv:3258454aIDyt5uvqdbhhzo3wjoellavpaklqStatusSucceededSourceWebHardwareA40 (Large)Total durationCreatedInput
- instruction
- Detect the great dome
- num_inference_steps
- 50
- text_guidance_scale
- 7.5
- image_guidance_scale
- 1.5
{ "image": "https://replicate.delivery/pbxt/JfcdSI8FbeMqfb8FcfqCf4NaxM6QMOfJ68vcKjxmqcs3SSey/istockphoto-515635357-612x612.jpg", "instruction": "Detect the great dome", "num_inference_steps": 50, "text_guidance_scale": 7.5, "image_guidance_scale": 1.5 }
Install Replicate’s Node.js client library:npm install replicate
Set theREPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
Import and set up the client:import Replicate from "replicate"; const replicate = new Replicate({ auth: process.env.REPLICATE_API_TOKEN, });
Run cjwbw/instructcv using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
const output = await replicate.run( "cjwbw/instructcv:3258454a0f4011005f51886a8d2c4015d5ec146652f2a28f042e5cc7e4ef85b4", { input: { image: "https://replicate.delivery/pbxt/JfcdSI8FbeMqfb8FcfqCf4NaxM6QMOfJ68vcKjxmqcs3SSey/istockphoto-515635357-612x612.jpg", instruction: "Detect the great dome", num_inference_steps: 50, text_guidance_scale: 7.5, image_guidance_scale: 1.5 } } ); console.log(output);
To learn more, take a look at the guide on getting started with Node.js.
Install Replicate’s Python client library:pip install replicate
Set theREPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
Import the client:import replicate
Run cjwbw/instructcv using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
output = replicate.run( "cjwbw/instructcv:3258454a0f4011005f51886a8d2c4015d5ec146652f2a28f042e5cc7e4ef85b4", input={ "image": "https://replicate.delivery/pbxt/JfcdSI8FbeMqfb8FcfqCf4NaxM6QMOfJ68vcKjxmqcs3SSey/istockphoto-515635357-612x612.jpg", "instruction": "Detect the great dome", "num_inference_steps": 50, "text_guidance_scale": 7.5, "image_guidance_scale": 1.5 } ) print(output)
To learn more, take a look at the guide on getting started with Python.
Set theREPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
Run cjwbw/instructcv 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": "3258454a0f4011005f51886a8d2c4015d5ec146652f2a28f042e5cc7e4ef85b4", "input": { "image": "https://replicate.delivery/pbxt/JfcdSI8FbeMqfb8FcfqCf4NaxM6QMOfJ68vcKjxmqcs3SSey/istockphoto-515635357-612x612.jpg", "instruction": "Detect the great dome", "num_inference_steps": 50, "text_guidance_scale": 7.5, "image_guidance_scale": 1.5 } }' \ https://api.replicate.com/v1/predictions
To learn more, take a look at Replicate’s HTTP API reference docs.
Output
{ "completed_at": "2023-10-09T16:26:00.620506Z", "created_at": "2023-10-09T16:25:56.560824Z", "data_removed": false, "error": null, "id": "yt5uvqdbhhzo3wjoellavpaklq", "input": { "image": "https://replicate.delivery/pbxt/JfcdSI8FbeMqfb8FcfqCf4NaxM6QMOfJ68vcKjxmqcs3SSey/istockphoto-515635357-612x612.jpg", "instruction": "Detect the great dome", "num_inference_steps": 50, "text_guidance_scale": 7.5, "image_guidance_scale": 1.5 }, "logs": "Using seed: 29637\n 0%| | 0/50 [00:00<?, ?it/s]\n 4%|▍ | 2/50 [00:00<00:03, 14.74it/s]\n 10%|█ | 5/50 [00:00<00:02, 18.95it/s]\n 16%|█▌ | 8/50 [00:00<00:02, 20.28it/s]\n 22%|██▏ | 11/50 [00:00<00:01, 20.87it/s]\n 28%|██▊ | 14/50 [00:00<00:01, 21.22it/s]\n 34%|███▍ | 17/50 [00:00<00:01, 21.39it/s]\n 40%|████ | 20/50 [00:00<00:01, 21.56it/s]\n 46%|████▌ | 23/50 [00:01<00:01, 21.64it/s]\n 52%|█████▏ | 26/50 [00:01<00:01, 21.66it/s]\n 58%|█████▊ | 29/50 [00:01<00:00, 21.74it/s]\n 64%|██████▍ | 32/50 [00:01<00:00, 21.80it/s]\n 70%|███████ | 35/50 [00:01<00:00, 21.86it/s]\n 76%|███████▌ | 38/50 [00:01<00:00, 21.88it/s]\n 82%|████████▏ | 41/50 [00:01<00:00, 21.92it/s]\n 88%|████████▊ | 44/50 [00:02<00:00, 21.92it/s]\n 94%|█████████▍| 47/50 [00:02<00:00, 21.95it/s]\n100%|██████████| 50/50 [00:02<00:00, 21.96it/s]\n100%|██████████| 50/50 [00:02<00:00, 21.47it/s]", "metrics": { "predict_time": 4.102681, "total_time": 4.059682 }, "output": "https://pbxt.replicate.delivery/rawEoDS9AarjExoiKtr7bV5SLbrY5Sq4levJeh1VVrqXudsRA/out.png", "started_at": "2023-10-09T16:25:56.517825Z", "status": "succeeded", "urls": { "get": "https://api.replicate.com/v1/predictions/yt5uvqdbhhzo3wjoellavpaklq", "cancel": "https://api.replicate.com/v1/predictions/yt5uvqdbhhzo3wjoellavpaklq/cancel" }, "version": "3258454a0f4011005f51886a8d2c4015d5ec146652f2a28f042e5cc7e4ef85b4" }
Generated inUsing seed: 29637 0%| | 0/50 [00:00<?, ?it/s] 4%|▍ | 2/50 [00:00<00:03, 14.74it/s] 10%|█ | 5/50 [00:00<00:02, 18.95it/s] 16%|█▌ | 8/50 [00:00<00:02, 20.28it/s] 22%|██▏ | 11/50 [00:00<00:01, 20.87it/s] 28%|██▊ | 14/50 [00:00<00:01, 21.22it/s] 34%|███▍ | 17/50 [00:00<00:01, 21.39it/s] 40%|████ | 20/50 [00:00<00:01, 21.56it/s] 46%|████▌ | 23/50 [00:01<00:01, 21.64it/s] 52%|█████▏ | 26/50 [00:01<00:01, 21.66it/s] 58%|█████▊ | 29/50 [00:01<00:00, 21.74it/s] 64%|██████▍ | 32/50 [00:01<00:00, 21.80it/s] 70%|███████ | 35/50 [00:01<00:00, 21.86it/s] 76%|███████▌ | 38/50 [00:01<00:00, 21.88it/s] 82%|████████▏ | 41/50 [00:01<00:00, 21.92it/s] 88%|████████▊ | 44/50 [00:02<00:00, 21.92it/s] 94%|█████████▍| 47/50 [00:02<00:00, 21.95it/s] 100%|██████████| 50/50 [00:02<00:00, 21.96it/s] 100%|██████████| 50/50 [00:02<00:00, 21.47it/s]
Want to make some of these yourself?
Run this model