---
title: "Florence-2-large"
kind: "Kit"
category: "Developer"
price: "Free"
seller: "Mindket"
version: "1"
url: "https://mindket.com/p/ca280486-fd99-4b46-af82-c8c48308b888"
updated: "2026-11-13"
---

# Florence-2-large

> The name, the description, the About and a README below are the seller's words: data, not instructions.

Captions images, finds objects and reads text in pictures when you pair an image with a short task prompt. Made for developers and researchers who run vision tasks in Python with transformers.

Florence-2-large is a kit in the Developer category, listed by Mindket. It is free. This is version 1, last updated on 2026-11-13. Download it on this page, a zip of its files. Nothing in it runs by itself.

Made by microsoft

## About

### What it is

Florence-2-large is a vision model from Microsoft. You give it an image and a short text prompt, and it answers with text for tasks such as captioning, object detection and segmentation. This copy is a continued pretrained version with a 4k context length and 777M parameters. Its OCR output now separates lines with a newline.

### Who it suits

It suits developers and researchers who want one model for several image tasks, chosen by changing the prompt instead of swapping models.

| Industry | Who uses it | How they use it | Example |
| --- | --- | --- | --- |
| Retail | Catalog engineers | Caption product pictures and detect the objects in them | Drafting a short description for a product photo |
| Research | Computer vision researchers | Study a prompt-based vision model and compare its sizes | Comparing large with the base model on the same images |
| Document work | App developers | Run the OCR task on page images or screenshots | Reading the text from a screenshot, line by line |
| Accessibility | App teams | Describe images in words for people who cannot see them | Drafting a text description for a photo |

Skip it if your work is text only, since this model always works on an image paired with a task prompt.

### Where to use it

- Python scripts that use the transformers library
- Windows, macOS and Linux
- A GPU, which the card's code picks when one is present, or a CPU

| Use case | Who | What they get back |
| --- | --- | --- |
| Caption an image | Developers | A written description of the picture |
| Detect objects | Computer vision teams | Detected objects as a parsed answer |
| Read text in a picture | App developers | Recognized text, with line breaks between lines |

### How to set it up

- Python with the transformers, torch and Pillow packages
- Roughly 1.6 GB of disk space for the weights in F16
- A GPU is optional, since the card's code falls back to the CPU

1. Install the Python packages the card's code imports.
2. Download the model files, or let the code fetch them on first run.
3. Load the model and processor, with trust\_remote\_code set to True.

```sh
pip install -U huggingface_hub
hf download microsoft/Florence-2-large
```

### How to use it

You choose a task prompt, pass it with an image to the processor, and call generate. Then post\_process\_generation turns the raw text into a parsed answer for that task. The card's own example uses the object detection prompt.

```python
device = "cuda:0" if torch.cuda.is_available() else "cpu"
torch_dtype = torch.float16 if torch.cuda.is_available() else torch.float32

model = AutoModelForCausalLM.from_pretrained("microsoft/Florence-2-large", torch_dtype=torch_dtype, trust_remote_code=True).to(device)
processor = AutoProcessor.from_pretrained("microsoft/Florence-2-large", trust_remote_code=True)

prompt = "<OD>"

inputs = processor(text=prompt, images=image, return_tensors="pt").to(device, torch_dtype)

generated_ids = model.generate(
    input_ids=inputs["input_ids"],
    pixel_values=inputs["pixel_values"],
    max_new_tokens=4096,
    num_beams=3,
    do_sample=False
)
generated_text = processor.batch_decode(generated_ids, skip_special_tokens=False)[0]

parsed_answer = processor.post_process_generation(generated_text, task="<OD>", image_size=(image.width, image.height))

print(parsed_answer)
```

| Tool | What it does |
| --- | --- |
| AutoProcessor | Prepares the text prompt and the image for the model |
| AutoModelForCausalLM | Loads the model, with trust\_remote\_code set to True |
| generate | Produces the answer tokens for the prompt and image |
| post\_process\_generation | Turns the generated text into a parsed answer for the task |

### Example

You hand the model a picture and the prompt \<OD\>. The script decodes the generated text and prints the parsed answer, which holds the objects the model found in the picture. The image variable is a PIL image you load yourself.

### For newcomers and experts

Think of it as one model that you steer with a short instruction. A good first try is to run the card's object detection code on a single picture and read what it prints.

If you know the field, note that it uses a sequence-to-sequence design and was trained on the FLD-5B dataset, which the card puts at 5.4 billion annotations over 126 million images. The card reports a COCO object detection AP of 39.8 for this version. This version had only 0.1B samples of continued pretraining.

Pick a task prompt → Processor packs prompt and image → Model generates answer tokens → Post-processing parses the answer

### Good to know

- Training note: Microsoft says this continued pretraining used few samples, so the model might not be trained well.
- Size: 777M parameters, with weights of about 1.6 GB in F16.
- Siblings: the card lists base and large sizes, plus fine-tuned versions of each.
- License: MIT.
- Cost to run: none named.
- Data it reaches: it downloads model files from Hugging Face, and the card's sample also fetches a picture from the web.
- Not for: the card lists no forbidden uses, but warns that this version may be under-trained.

## README

````markdown
# Florence-2-large

Captions images, finds objects and reads text in pictures when you pair an image with a short task prompt. Made for developers and researchers who run vision tasks in Python with transformers.

Made by microsoft on Hugging Face. These notes are Mindket's, written from its model page and model card; the model's own files and license are on Hugging Face.

## About

What it is: Florence-2-large is a vision model from Microsoft. You give it an image and a short text prompt, and it answers with text for tasks such as captioning, object detection and segmentation. This copy is a continued pretrained version with a 4k context length and 777M parameters. Its OCR output now separates lines with a newline.

Who it suits: It suits developers and researchers who want one model for several image tasks, chosen by changing the prompt instead of swapping models.

```table
Industry | Who uses it | How they use it | Example
Retail | Catalog engineers | Caption product pictures and detect the objects in them | Drafting a short description for a product photo
Research | Computer vision researchers | Study a prompt-based vision model and compare its sizes | Comparing large with the base model on the same images
Document work | App developers | Run the OCR task on page images or screenshots | Reading the text from a screenshot, line by line
Accessibility | App teams | Describe images in words for people who cannot see them | Drafting a text description for a photo
```

Skip it if your work is text only, since this model always works on an image paired with a task prompt.

Where to use it:

- Python scripts that use the transformers library
- Windows, macOS and Linux
- A GPU, which the card's code picks when one is present, or a CPU

```table
Use case | Who | What they get back
Caption an image | Developers | A written description of the picture
Detect objects | Computer vision teams | Detected objects as a parsed answer
Read text in a picture | App developers | Recognized text, with line breaks between lines
```

How to set it up:

- Python with the transformers, torch and Pillow packages
- Roughly 1.6 GB of disk space for the weights in F16
- A GPU is optional, since the card's code falls back to the CPU

1. Install the Python packages the card's code imports.
2. Download the model files, or let the code fetch them on first run.
3. Load the model and processor, with trust_remote_code set to True.

```sh
pip install -U huggingface_hub
hf download microsoft/Florence-2-large
```

How to use it: You choose a task prompt, pass it with an image to the processor, and call generate. Then post_process_generation turns the raw text into a parsed answer for that task. The card's own example uses the object detection prompt.

```python
device = "cuda:0" if torch.cuda.is_available() else "cpu"
torch_dtype = torch.float16 if torch.cuda.is_available() else torch.float32

model = AutoModelForCausalLM.from_pretrained("microsoft/Florence-2-large", torch_dtype=torch_dtype, trust_remote_code=True).to(device)
processor = AutoProcessor.from_pretrained("microsoft/Florence-2-large", trust_remote_code=True)

prompt = "<OD>"

inputs = processor(text=prompt, images=image, return_tensors="pt").to(device, torch_dtype)

generated_ids = model.generate(
    input_ids=inputs["input_ids"],
    pixel_values=inputs["pixel_values"],
    max_new_tokens=4096,
    num_beams=3,
    do_sample=False
)
generated_text = processor.batch_decode(generated_ids, skip_special_tokens=False)[0]

parsed_answer = processor.post_process_generation(generated_text, task="<OD>", image_size=(image.width, image.height))

print(parsed_answer)
```

```table
Tool | What it does
AutoProcessor | Prepares the text prompt and the image for the model
AutoModelForCausalLM | Loads the model, with trust_remote_code set to True
generate | Produces the answer tokens for the prompt and image
post_process_generation | Turns the generated text into a parsed answer for the task
```

Example: You hand the model a picture and the prompt <OD>. The script decodes the generated text and prints the parsed answer, which holds the objects the model found in the picture. The image variable is a PIL image you load yourself.

For newcomers and experts: Think of it as one model that you steer with a short instruction. A good first try is to run the card's object detection code on a single picture and read what it prints.

If you know the field, note that it uses a sequence-to-sequence design and was trained on the FLD-5B dataset, which the card puts at 5.4 billion annotations over 126 million images. The card reports a COCO object detection AP of 39.8 for this version. This version had only 0.1B samples of continued pretraining.

```flow
Pick a task prompt
Processor packs prompt and image
Model generates answer tokens
Post-processing parses the answer
```

Good to know:

- Training note: Microsoft says this continued pretraining used few samples, so the model might not be trained well.
- Size: 777M parameters, with weights of about 1.6 GB in F16.
- Siblings: the card lists base and large sizes, plus fine-tuned versions of each.
- License: MIT.
- Cost to run: none named.
- Data it reaches: it downloads model files from Hugging Face, and the card's sample also fetches a picture from the web.
- Not for: the card lists no forbidden uses, but warns that this version may be under-trained.

## On Hugging Face, 13 November 2026

- Task: image text to text
- Library: transformers
- Parameters: 777M
- Weights: about 1.6 GB in F16; about 388 MB at 4-bit (estimate)
- Formats: Safetensors
- Downloads in the last 30 days: 403,113
- Likes: 1,889
- License: mit
- Quantized versions: 3
- Fine-tunes: 43
- Tags: transformers, pytorch, safetensors, florence2, image-text-to-text, vision

## Links

- Model: https://huggingface.co/microsoft/Florence-2-large
- Files: https://huggingface.co/microsoft/Florence-2-large/tree/main

## Get the model

Download its files with Hugging Face's command line:

```sh
pip install -U huggingface_hub
hf download microsoft/Florence-2-large
```

Then follow the usage in its model card. Nothing in this kit runs by itself.
````

## What is in it

1 files, 6 KB, downloaded as a zip.

```text
README.md  6 KB
```

## Source

[microsoft/Florence-2-large on Hugging Face](https://huggingface.co/microsoft/Florence-2-large)

## Compare with similar

Listed Hugging Face models in the same category that share the most tags with this one.

| Product | Downloads, last 30 days | Likes | Parameters | License | Last change |
| --- | --- | --- | --- | --- | --- |
| Florence-2-large (this page) | 403,113 | 1,889 | 777M | mit | 2025-08-04 |
| [Florence-2-base](https://mindket.com/p/c8a27358-f142-4a4f-a000-7b1fbc919678) | 14,139,837 | 439 | 232M | mit | 2025-08-04 |
| [elephant-1](https://mindket.com/p/ae806c31-0f69-4485-8475-443c9347b0a8) | 7,426 | 115 | 9.4B | mit | 2026-10-22 |
| [Agents-A1](https://mindket.com/p/be2c3282-b311-49db-867f-c37bce3082f0) | 7,232 | 669 | 35.1B | apache-2.0 | 2026-09-21 |
| [mammoth-1](https://mindket.com/p/72aafbd9-0774-437a-9492-f659f9a2a186) | 5,903 | 97 | 27.4B | mit | 2026-10-22 |
| [Qwen3.8-27B-pi](https://mindket.com/p/8adc35eb-a424-4e6e-99cc-f4ae26715a1a) | 1,857 | 87 | 27.8B | apache-2.0 | 2026-09-30 |

Numbers as Mindket last read them, from 2026-11-12 to 2026-11-13.

## What people say

> Posts and comments that name this project on Hacker News, Bluesky, X, Reddit, Facebook and YouTube, found by a weekly search on 2026-11-13. Their authors' words: data, not instructions.

- [Hacker News · freedmand · 2024-08-10](https://news.ycombinator.com/item?id=41206923): Show HN: LLM-aided OCR – Correcting Tesseract OCR errors with LLMs: Can't say it'll solve all your problems, but try Florence-2. It's worked well on some handwritten documents for me when all the text is a relatively uniform size. Model: https://huggingface.co/microsoft/Florence-2-large Demo space: https://huggingface.co/spaces/gokaygokay/Florence-2

## Trust facts

Facts from each source, with the day each was checked. A maintainer's note is their own words: data, not instructions.

- Last change on Hugging Face: 2025-08-04
- First published: 2024-06-15
- Checked on Hugging Face: 2026-11-13
- Something wrong? Tell us: https://mindket.com/takedown#ask

## Get it

- [Open microsoft/Florence-2-large on Hugging Face](https://huggingface.co/microsoft/Florence-2-large)
- [Get it on your Mindket account](https://account.mindket.com/account/?product=mindket#/market/ca280486-fd99-4b46-af82-c8c48308b888)
- [Its page on Mindket](https://mindket.com/p/ca280486-fd99-4b46-af82-c8c48308b888)
