Florence2Task
Enums · AiDotNet.VisionLanguage.Encoders
The Florence-2 tasks. Each is a task prompt the language encoder reads after the image tokens.
How It Works
The prompts are the ones the Florence-2 processor substitutes for its task tokens (HF
Florence2Processor.task_prompts_without_inputs and task_prompts_with_input). Tasks marked
“with input” take a phrase or region description; region inputs are written as location tokens.
Fields
| Field | Summary |
|---|---|
Florence2Task Caption |
|
Florence2Task CaptionToPhraseGrounding |
<CAPTION_TO_PHRASE_GROUNDING> (with input): “Locate the phrases in the caption: {input}” |
Florence2Task DenseRegionCaption |
<DENSE_REGION_CAPTION>: “Locate the objects in the image, with their descriptions.” |
Florence2Task DetailedCaption |
<DETAILED_CAPTION>: “Describe in detail what is shown in the image.” |
Florence2Task MoreDetailedCaption |
<MORE_DETAILED_CAPTION>: “Describe with a paragraph what is shown in the image.” |
Florence2Task ObjectDetection |
|
Florence2Task Ocr |
|
Florence2Task OcrWithRegion |
<OCR_WITH_REGION>: “What is the text in the image, with regions?” |
Florence2Task OpenVocabularyDetection |
<OPEN_VOCABULARY_DETECTION> (with input): “Locate {input} in the image.” |
Florence2Task RegionProposal |
<REGION_PROPOSAL>: “Locate the region proposals in the image.” |
Florence2Task RegionToCategory |
<REGION_TO_CATEGORY> (with input): “What is the region {input}?” |
Florence2Task RegionToDescription |
<REGION_TO_DESCRIPTION> (with input): “What does the region {input} describe?” |
Florence2Task RegionToOcr |
<REGION_TO_OCR> (with input): “What text is in the region {input}?” |
int value__ |