OCR Model¶
Class: OCRModelBlockV1
Source: inference.core.workflows.core_steps.models.foundation.ocr.v1.OCRModelBlockV1
Retrieve the characters in an image using Optical Character Recognition (OCR).
This block returns the text within an image.
You may want to use this block in combination with a detections-based block (i.e. ObjectDetectionBlock). An object detection model could isolate specific regions from an image (i.e. a shipping container ID in a logistics use case) for further processing. You can then use a DynamicCropBlock to crop the region of interest before running OCR.
Using a detections model then cropping detections allows you to isolate your analysis on particular regions of an image.
Type identifier¶
Use the following identifier in step "type"
field: roboflow_core/ocr_model@v1
to add the block as
as step in your workflow.
Properties¶
Name | Type | Description | Refs |
---|---|---|---|
name |
str |
Unique name of step in workflows. | ❌ |
The Refs column marks possibility to parametrise the property with dynamic values available
in workflow
runtime. See Bindings for more info.
Available Connections¶
Compatible Blocks
Check what blocks you can connect to OCR Model
in version v1
.
- inputs:
Stitch Images
,Pixelate Visualization
,SIFT Comparison
,Corner Visualization
,Blur Visualization
,Mask Visualization
,Perspective Correction
,SIFT
,Polygon Zone Visualization
,Polygon Visualization
,Halo Visualization
,Grid Visualization
,Image Slicer
,Model Comparison Visualization
,Trace Visualization
,Camera Focus
,Image Threshold
,Keypoint Visualization
,Crop Visualization
,Image Preprocessing
,Image Blur
,Relative Static Crop
,Circle Visualization
,Image Convert Grayscale
,Dot Visualization
,Background Color Visualization
,Bounding Box Visualization
,Ellipse Visualization
,Image Contours
,Label Visualization
,Classification Label Visualization
,Line Counter Visualization
,Stability AI Inpainting
,Reference Path Visualization
,Dynamic Crop
,Color Visualization
,Triangle Visualization
,Absolute Static Crop
- outputs:
Path Deviation
,LMM For Classification
,Line Counter
,Instance Segmentation Model
,CLIP Embedding Model
,Mask Visualization
,Line Counter
,YOLO-World Model
,Model Monitoring Inference Aggregator
,Cache Get
,Polygon Visualization
,Halo Visualization
,Google Vision OCR
,Model Comparison Visualization
,Email Notification
,CogVLM
,Image Threshold
,Keypoint Visualization
,Image Preprocessing
,Roboflow Dataset Upload
,Slack Notification
,Background Color Visualization
,Bounding Box Visualization
,Ellipse Visualization
,Classification Label Visualization
,Label Visualization
,Line Counter Visualization
,LMM
,Stability AI Inpainting
,Reference Path Visualization
,Dynamic Crop
,Triangle Visualization
,Distance Measurement
,Time in Zone
,Detections Stitch
,Florence-2 Model
,SIFT Comparison
,Corner Visualization
,Perspective Correction
,Local File Sink
,Polygon Zone Visualization
,Twilio SMS Notification
,Trace Visualization
,Webhook Sink
,Size Measurement
,OpenAI
,Roboflow Custom Metadata
,Cache Set
,Crop Visualization
,Instance Segmentation Model
,Roboflow Dataset Upload
,Clip Comparison
,Anthropic Claude
,Image Blur
,Circle Visualization
,Dot Visualization
,Google Gemini
,Segment Anything 2 Model
,Florence-2 Model
,Time in Zone
,Path Deviation
,OpenAI
,Color Visualization
,Pixel Color Count
,Llama 3.2 Vision
Input and Output Bindings¶
The available connections depend on its binding kinds. Check what binding kinds
OCR Model
in version v1
has.
Bindings
-
input
images
(image
): The image to infer on.
-
output
result
(string
): String value.parent_id
(parent_id
): Identifier of parent for step output.root_parent_id
(parent_id
): Identifier of parent for step output.prediction_type
(prediction_type
): String value with type of prediction.
Example JSON definition of step OCR Model
in version v1
{
"name": "<your_step_name_here>",
"type": "roboflow_core/ocr_model@v1",
"images": "$inputs.image"
}