8.1 OCI Vision Service: Computer Vision, Classification & Object Detection
Key Takeaways
- OCI Vision is a fully managed, serverless artificial intelligence service providing pre-built and custom computer vision models for image analysis and video processing without requiring machine learning or infrastructure expertise.
- The three primary pre-trained computer vision capabilities are Image Classification (assigning scene-level category labels with confidence scores), Object Detection (identifying and locating distinct objects using 2D normalized bounding boxes), and Text Detection (extracting printed and handwritten text with spatial bounding polygons via Image OCR).
- Custom models enable organizations to address specialized enterprise domains by training custom image classifiers for proprietary defect categorization or custom object detectors for locating bespoke items, such as Personal Protective Equipment (PPE) compliance monitoring.
- The end-to-end custom vision training workflow requires uploading images to OCI Object Storage, annotating images with single/multi-labels or bounding boxes in OCI Data Labeling, running a managed training job, evaluating performance via Precision, Recall, and Mean Average Precision (mAP), and deploying to an inference endpoint.
- OCI Vision seamlessly integrates into event-driven cloud architectures where OCI Object Storage uploads emit OCI Events that trigger OCI Functions to invoke Vision REST APIs, evaluate business rules, and dispatch alerts via OCI Notifications.
8.1 OCI Vision Service: Computer Vision, Classification & Object Detection
[!NOTE] Exam Grounding: The OCI AI Foundations Associate (1Z0-1122-26) examination evaluates foundational knowledge of the OCI Vision service as part of the pre-built, perceptual AI services tier. Candidates must master the core operational differences between Image Classification (assigning semantic labels to an entire image) and Object Detection (identifying object categories and their exact spatial coordinates via 2D normalized bounding boxes). You must also understand how Text Detection (Image OCR) extracts printed and handwritten text from natural scene images, how custom models are trained using OCI Data Labeling, and how OCI Vision integrates into serverless event-driven architectures utilizing OCI Object Storage, OCI Events, and OCI Functions.
OCI Vision Overview: Managed Serverless Computer Vision
The Oracle Cloud Infrastructure (OCI) Vision service is a fully managed, serverless Artificial Intelligence (AI) service designed to perform automated image analysis and video frame inspection at enterprise scale. By abstracting the underlying deep learning engineering complexities, OCI Vision enables developers, data practitioners, and business analysts to incorporate advanced Computer Vision (CV) capabilities into cloud-native applications without provisioning Graphics Processing Unit (GPU) compute infrastructure, designing Convolutional Neural Network (CNN) architectures, or managing complex training clusters.
Key architectural characteristics of the OCI Vision service include:
- Serverless & Fully Managed: Users interact with the service through standard Representational State Transfer (REST) Application Programming Interfaces (APIs), official OCI Software Development Kits (SDKs for Python, Java, TypeScript, and Go), and the interactive OCI Console. Infrastructure provisioning, auto-scaling, hardware patching, and high availability are managed entirely by Oracle.
- Dual-Tier Model Strategy: OCI Vision offers pre-trained, general-purpose models for immediate out-of-the-box visual recognition, alongside custom model capabilities that allow enterprises to fine-tune vision algorithms on proprietary operational datasets.
- Multi-Modality Media Support: The service accepts common image formats (including JPEG, PNG, and TIFF) as well as single and multi-page PDF documents for visual text extraction. In addition, OCI Vision supports video analysis for video files (such as MP4 and AVI) stored in OCI Object Storage.
- Enterprise Security & Governance: All visual data, model training artifacts, and inference outputs remain strictly isolated within the customer's tenancy and compartment. OCI Vision adheres to OCI Identity and Access Management (IAM) role-based access control policies and enforces data encryption both in transit (TLS 1.3) and at rest (AES-256).
+-----------------------------------------------------------------------------+
| OCI VISION SERVICE ARCHITECTURE |
| |
| Client Applications (Mobile, Edge Devices, Web Apps, Enterprise ERP/SCM) |
| │ |
| HTTPS / REST APIs / OCI SDKs |
| ▼ |
| OCI Identity and Access Management (IAM) |
| │ |
| ┌────────────────────────────┴────────────────────────────┐ |
| ▼ ▼ |
| PRE-TRAINED VISION MODELS CUSTOM VISION MODELS|
| - Image Classification - Custom Classifiers|
| - Object Detection (2D Boxes) - Custom Detectors |
| - Text Detection (Image OCR) - Data Labeling Sync|
+-----------------------------------------------------------------------------+
Core Pre-Trained Computer Vision Capabilities
OCI Vision provides three pre-trained computer vision capabilities that can be invoked immediately without requiring training data or model calibration:
1. Image Classification
Image Classification analyzes an entire image and assigns one or more descriptive semantic labels that characterize the overall scene, visual concepts, or dominant subject matter:
- Whole-Image Scope: Classification assesses the overall context rather than locating individual constituent items. For example, a photograph of a warehouse is labeled as
Warehouse(98% confidence),Industrial Facility(94% confidence), andIndoor(89% confidence). - Confidence Scores: Every predicted label is accompanied by a statistical confidence score ranging from
0.0to1.0(or0%to100%). Applications can configure confidence thresholds to filter out low-certainty predictions. - Multi-Label Categorization: Images often contain multiple overlapping themes. OCI Vision supports multi-label outputs, returning all visual tags that exceed the specified confidence cutoff.
- Exam Distinction: Image Classification answers the question: "What is this image depicting as a whole?" It does not provide spatial location coordinates, pixel boundaries, or object counts.
2. Object Detection
Object Detection identifies individual objects within an image, determines their object class, and provides the precise spatial location of each object using 2D normalized bounding boxes:
- Localization & Identification: Unlike classification, object detection pinpoints exactly where each item resides within the frame. If an image contains three forklifts and four workers, the model detects and demarcates all seven distinct entities.
- 2D Normalized Bounding Boxes: The spatial boundaries are returned as normalized coordinates between
0.0and1.0relative to the total image dimensions (x_min,y_min,x_max,y_maxornormalizedVertices). Because coordinates are normalized, client applications can render bounding boxes accurately regardless of display scaling or screen resolution. - Entity Counting & Density: Because each detected item receives an individual bounding box and confidence score, object detection enables automated counting, crowd density estimation, and asset tracking.
- Exam Distinction: Object Detection answers the question: "Where are specific objects located in this image, and how many are there?"
3. Text Detection (Image OCR)
Text Detection applies computer vision-based Optical Character Recognition (OCR) to locate and transcribe printed and handwritten alphanumeric text present within natural scene images:
- In-The-Wild Natural Scenes: The text detection engine is optimized for text appearing in complex, unconstrained environments—such as street signs, packaging shipping marks, machinery serial plates, billboard advertisements, vehicle license plates, and container barcodes.
- Spatial Bounding Polygons: Extracted text is mapped to spatial bounding polygons (four-point polygon vertices), capturing angled, tilted, or curved text alignments.
- Granular Text Hierarchy: The service returns structured text hierarchies containing individual words, combined text lines, bounding coordinates, and word-level confidence ratings.
- Exam Distinction: OCI Vision Text Detection is engineered for scene text found within photographs and videos. In contrast, OCI Document Understanding is specialized for structured, multi-page business documents, forms, receipts, and invoices.
Custom Models in OCI Vision: Domain-Specific Visual AI
While pre-trained models excel at recognizing everyday objects (such as vehicles, animals, and common furniture), enterprise operations frequently require detecting specialized components, proprietary equipment, or microscopic manufacturing flaws. To solve these bespoke domain challenges, OCI Vision enables users to train Custom Models.
Types of Custom Vision Models
- Custom Image Classification: Categorizes proprietary images into custom classes. For example, an agricultural enterprise can train a classifier to distinguish between healthy crops and five distinct fungal leaf diseases, or a semiconductor manufacturer can classify wafer images into
Normal,Particle Defect, orScratch Defect. - Custom Object Detection: Identifies and bounds custom objects that pre-trained models do not recognize. The classic enterprise exam scenario is Workplace Safety & Personal Protective Equipment (PPE) Compliance Monitoring. Organizations train custom object detectors to identify whether personnel on construction sites or oil rigs are wearing required safety gear (
Hard Hat,Safety Vest,Safety Goggles,Steel-Toe Boots).
The 5-Stage Custom Vision Lifecycle
Creating, deploying, and maintaining a custom vision model follows a structured five-stage workflow:
+-----------------------------------------------------------------------------+
| OCI CUSTOM VISION TRAINING LIFECYCLE |
| |
| [1. Ingest Data] --> Upload images/videos to OCI Object Storage bucket |
| │ |
| ▼ |
| [2. Label Data] --> Annotate images in OCI Data Labeling Service |
| │ (Single/multi-labels or 2D Bounding Boxes) |
| ▼ |
| [3. Train Model] --> Submit OCI Vision Training Job |
| │ (Automated transfer learning on managed GPUs) |
| ▼ |
| [4. Evaluate] --> Review Precision, Recall, and mAP metrics |
| │ |
| ▼ |
| [5. Deploy/Serve] --> Deploy to Vision Endpoint for real-time inference |
+-----------------------------------------------------------------------------+
- Data Ingestion: High-resolution training and validation images representing real-world operating conditions (varying angles, lighting, backgrounds) are uploaded to an OCI Object Storage bucket.
- Data Annotation with OCI Data Labeling: A dataset is created in the OCI Data Labeling service. For classification, human annotators assign one or more categorical labels to each image. For object detection, annotators draw 2D rectangular bounding boxes tightly around each target object and assign the appropriate class tag. OCI Data Labeling integrates directly with OCI Vision, maintaining JSON-formatted annotation manifests.
- Managed Model Training: The practitioner initiates a custom training job in OCI Vision, referencing the labeled dataset. The user specifies the training duration limit (budget in hours). OCI Vision automatically provisions GPU compute clusters, applies transfer learning from advanced deep learning backbones, performs data augmentation, and trains the model.
- Model Evaluation: Upon completion, OCI Vision generates a comprehensive evaluation report featuring key performance metrics:
- Precision: The percentage of positive detections that were correct ($ ext{True Positives} / (\text{True Positives} + \text{False Positives})$). High precision indicates minimal false alarms.
- Recall: The percentage of actual objects that were successfully detected by the model ($ ext{True Positives} / (\text{True Positives} + \text{False Negatives})$). High recall indicates few missed targets.
- Mean Average Precision (mAP): The definitive benchmark metric for object detection, calculating the mean of the average precision scores across all classes and Intersection over Union (IoU) overlap thresholds.
- F1-Score: The harmonic mean of Precision and Recall, providing a balanced metric when class distributions are uneven.
- Deployment & Inference: Once validated, the custom model is deployed to a managed Vision Endpoint for low-latency synchronous REST inference, or invoked through asynchronous batch jobs for large-scale offline image catalogs.
Integration with the OCI Cloud Ecosystem & Event-Driven Workflows
OCI Vision achieves its greatest operational impact when integrated into automated, serverless cloud workflows. Rather than requiring applications to continuously poll storage buckets, the OCI platform facilitates reactive, event-driven architectures:
- OCI Object Storage: Acts as the centralized landing zone for incoming image and video assets generated by edge cameras, mobile devices, or web portals.
- OCI Events: The OCI Events service monitors changes across tenancy resources. When a new image is written to an Object Storage bucket, it emits an event (
com.oraclecloud.objectstorage.createobject). - OCI Functions: A lightweight, serverless function built on the open-source Fn project subscribes to the event. The function automatically triggers, receives the object metadata, and invokes the OCI Vision REST API (
analyzeImage). - OCI Notifications (ONS): If the Vision service detects an anomaly—such as a worker without a required hard hat or an assembled component with a crack—the function publishes an alert message to an OCI Notifications topic, instantly alerting shift supervisors via email, SMS, or PagerDuty.
- OCI Streaming: In high-throughput visual environments, edge devices stream video frame metadata into OCI Streaming (a managed, Apache Kafka-compatible service) for sequential buffering and decoupled computer vision processing.
- Oracle Autonomous Database: Analyzed metadata, detection coordinates, timestamps, and confidence ratings are persisted into Oracle Autonomous Database tables for historical compliance auditing and visual analytics.
Enterprise Use Cases & Industry Implementations
- Manufacturing Quality Assurance & Defect Detection: High-speed cameras capture images of electronic circuit boards or automotive body panels on an assembly line. Custom vision classifiers and detectors identify solder bridge defects, surface scratches, or missing fasteners in sub-second inference windows, routing defective parts off the line automatically.
- Workplace Safety & Hazard Monitoring: Security cameras at chemical plants and construction sites stream video frames into OCI Vision custom object detectors. The system verifies whether employees comply with mandatory Personal Protective Equipment (PPE) policies, detecting missing hard hats, reflective vests, or safety goggles in real time.
- Retail Merchandising & Shelf Monitoring: Store shelf cameras capture retail display racks. Pre-trained and custom object detectors identify brand products, detect out-of-stock empty shelf spaces, and verify planogram compliance, triggering automated restocking alerts to store associates.
- Infrastructure & Asset Inspection: Drones capture high-resolution imagery of electrical transmission towers, wind turbine blades, and railway tracks. OCI Vision detects corrosion spots, micro-fractures, and structural deformations across remote utility networks without requiring human inspectors to climb hazardous towers.
Vision Features & Capabilities Comparison
| Vision Capability | Primary Analytical Objective | Spatial Geometry Returned | Custom Model Support | Primary Exam Use Case |
|---|---|---|---|---|
| Image Classification | Categorizes overall image scene or concept | None (image-level labels only) | Yes (Custom Image Classification via OCI Data Labeling) | Categorizing scenes (e.g., factory vs. office) or defect types (scratch vs. dent) |
| Object Detection | Locates and counts distinct objects within image | 2D Normalized Bounding Boxes (x_min, y_min, x_max, y_max) | Yes (Custom Object Detection with bounding box annotations) | Counting items, locating parts, and PPE safety compliance (hard hats, vests) |
| Text Detection (Image OCR) | Transcribes printed and handwritten text in natural scenes | Spatial Bounding Polygons (4-point polygon vertices) | No (Uses pre-trained scene OCR engine) | Reading street signs, container serial numbers, license plates, and machinery tags |
A safety compliance officer needs to monitor workplace safety across an industrial warehouse facility. The AI solution must automatically verify whether workers are wearing required safety helmets and determine their exact physical locations within video snapshots. Which computer vision capability in the OCI Vision service is specifically designed to identify object classes and return their spatial locations using 2D normalized bounding boxes?
A quality engineering team at an aerospace manufacturing facility needs to detect microscopic hairline fractures on turbine blades. Because these proprietary defect types are unique to their alloy components, pre-trained models cannot detect them. What is the correct end-to-end workflow to build, validate, and deploy a bespoke detector using OCI visual AI services?
A systems architect is designing a serverless visual inspection pipeline in Oracle Cloud Infrastructure. Whenever security cameras upload new surveillance images into an OCI Object Storage bucket, the architecture must automatically trigger image analysis in OCI Vision, evaluate detection results, and alert safety supervisors if unauthorized personnel enter a restricted area. Which combination of OCI cloud-native services enables this automated, event-driven pattern without provisioning persistent compute servers?