Neidio i'r cynnwys

ERNIE-Image Trainer

Integreiddio

ID y model ernie-image-trainer
# Run the model; wait up to 20 s for the finished result in the same call
curl -X POST "https://api.doitong.com/v1/run/ernie-image-trainer?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "images_data_url": "https://content.doitong.com/images/showcase/v3/gen_fox_cartoon.jpg"
  }'

# Still "queued" or "running"? Poll with the id from the response:
curl "https://api.doitong.com/v1/requests/REQUEST_ID?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY"

Y cais hwn: $2.40 2,400 o gredydau API Ei redeg ar y dudalen hon

Cael allwedd API
Baidu Hyfforddi #lora#personalization#trainer

Yn hyfforddi LoRA ar gyfer Ernie Image o archif zip o ddelweddau â chapsiynau

Baidu · Ffeil

Mae eich canlyniad cyntaf yn mynd yma

Adeiladwch gais isod a'i redeg gyda'ch allwedd API. Mae allbynnau'n cael eu copïo i'n storio, wedi'u cadw am byth neu am 7 diwrnod am ddim.

Adeiladu cais

Cynhyrchir rheolyddion o sgema'r model. Mae'r cod a'r pris yn diweddaru wrth i chi eu newid.

•gofynnol

URL archif ZIP sy'n cynnwys delweddau mewnbwn wedi'u paru â ffeiliau capsiynau. Defnyddiwch ROOT.EXT ar gyfer enwau ffeiliau delwedd, fel 001.jpg, a ROOT.txt ar gyfer capsiynau cyfatebol, fel 001.txt. Mae delweddau heb ffeil testun capsiwn yn defnyddio default_caption.

rhagosodedig 2000

Cyfanswm y camau hyfforddi.

Uwch default_caption · learning_rate

Capsiwn a ddefnyddir yn lle ffeiliau capsiynau coll, gyda None yn gwneud eu habsenoldeb yn wall yn lle hynny.

rhagosodedig 0.0005

Cyfradd dysgu'r hyfforddiant.

POST /run/ernie-image-trainer?wait=20 dyfynbris → $2.40
# Run the model; wait up to 20 s for the finished result in the same call
curl -X POST "https://api.doitong.com/v1/run/ernie-image-trainer?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "images_data_url": "https://content.doitong.com/images/showcase/v3/gen_fox_cartoon.jpg"
  }'

# Still "queued" or "running"? Poll with the id from the response:
curl "https://api.doitong.com/v1/requests/REQUEST_ID?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY"

Rhedeg y cais hwn

Mae'ch allwedd yn aros yn y porwr hwn: caiff ei hanfon at Doitong API yn unig a'i chadw (localStorage) dim ond os ticiwch Cofio. Cael allwedd API

Ynglŷn â ERNIE-Image Trainer

Yn mireinio LoRA o `images_data_url`, archif zip o ddelweddau â ffeiliau testun capsiynau cyfatebol. Mae `steps` yn amrywio o 10 i 40000 (rhagosodiad 2000), ac mae `learning_rate` yn 0.0005 yn ddiofyn. Mae `default_caption` yn llenwi ffeiliau capsiynau coll. Ffeil ffurfweddu a phwysau LoRA diffusers yw'r allbynnau.

Paramedrau

EnwMath RhagosodedigCaniateir Disgrifiad
images_data_urlgofynnol
Mathstring
URL archif ZIP sy'n cynnwys delweddau mewnbwn wedi'u paru â ffeiliau capsiynau. Defnyddiwch ROOT.EXT ar gyfer enwau ffeiliau delwedd, fel 001.jpg, a ROOT.txt ar gyfer capsiynau cyfatebol, fel 001.txt. Mae delweddau heb ffeil testun capsiwn yn defnyddio default_caption.
stepsdewisol
Mathinteger
Rhagosodedig2000
10 – 40,000
Cyfanswm y camau hyfforddi.
default_captiondewisol
Mathstring | null
Capsiwn a ddefnyddir yn lle ffeiliau capsiynau coll, gyda None yn gwneud eu habsenoldeb yn wall yn lle hynny.
learning_ratedewisol
Mathnumber
Rhagosodedig0.0005
Cyfradd dysgu'r hyfforddiant.
gofynnol

Allbwn

GET /requests/req_8k2m4q7x1z9c3v5b6n0p2r4t
{
  "id": "req_8k2m4q7x1z9c3v5b6n0p2r4t",
  "object": "request",
  "model": "ernie-image-trainer",
  "status": "succeeded",
  "created_at": "2026-10-20T12:00:00Z",
  "started_at": "2026-10-20T12:00:02Z",
  "completed_at": "2026-10-20T12:00:09Z",
  "queue_position": null,
  "cost": {
    "credits": 2400,
    "usd": "2.40",
    "charged": 2400,
    "refunded": 0
  },
  "input": {
    "images_data_url": "https://content.doitong.com/images/showcase/v3/gen_fox_cartoon.jpg"
  },
  "output": {
    "diffusers_lora_file": {
      "url": "https://content.doitong.com/dev-api/2026/10/20/req_8k2m4q7x1z9c3v5b6n0p2r4t/0-output.jpeg",
      "content_type": "image/jpeg",
      "file_name": "0-output.jpeg",
      "file_size": 1843200
    },
    "config_file": {
      "url": "https://content.doitong.com/dev-api/2026/10/20/req_8k2m4q7x1z9c3v5b6n0p2r4t/0-output.jpeg",
      "content_type": "image/jpeg",
      "file_name": "0-output.jpeg",
      "file_size": 1843200
    }
  },
  "outputs": [
    {
      "type": "file",
      "url": "https://content.doitong.com/dev-api/2026/10/20/req_8k2m4q7x1z9c3v5b6n0p2r4t/0-output.jpeg",
      "content_type": "image/jpeg",
      "file_size": 1843200,
      "stored": true
    }
  ],
  "error": null,
  "metrics": {
    "inference_seconds": 6.8
  },
  "urls": {
    "self": "https://api.doitong.com/v1/requests/req_8k2m4q7x1z9c3v5b6n0p2r4t",
    "cancel": "https://api.doitong.com/v1/requests/req_8k2m4q7x1z9c3v5b6n0p2r4t/cancel"
  }
}
Eich ffeiliau, eich dewisMae pob outputs[].url yn gopi ar ein storio: wedi'i gadw am byth (telir fesul GB-mis) neu am 7 diwrnod am ddim, yn ôl gosodiad eich cyfrif neu ?storage=.
Yr un siâp ar bob modeltype, url, content_type, width, height a duration, ar gyfer delweddau, fideo a sain fel ei gilydd. Gwrthrych canlyniad y model ei hun yw output.
Meysydd yr allbwn
diffusers_lora_file
object {url, content_type, file_name, file_size}URL sy'n pwyntio at bwysau LoRA hyfforddedig mewn fformat diffusers.
config_file
object {url, content_type, file_name, file_size}URL sy'n pwyntio at ffeil ffurfweddu'r model hyfforddedig.

Ar gyfer asiantau AI: mae'r dudalen hon fel Markdown ar gael yn https://doitong.com/cy/developers/models/ernie-image-trainer.md. Pob model a chanllaw: https://doitong.com/developers/llms.txt