Detect objects in images
State-of-the-art Zero-shot Object Detection
Detect objects in your images
Count objects in an image by drawing a region of interest
Upload an image to detect objects
Identify and label objects in images using YOLO models
Find and label objects in images
Identify labels in an image with a score threshold
Upload image to detect objects
Stream webcam video and detect objects in real-time
Detect traffic signs in uploaded images
Identify objects in images
Detect objects in uploaded images
Transformers.js is a lightweight JavaScript library designed for object detection in images. It allows developers to easily integrate deep learning models into web applications, enabling real-time detection and analysis of objects within images. Built with modern web technologies, Transformers.js provides a seamless and efficient way to leverage pre-trained models for accurate object detection.
• Real-time object detection: Detect objects in images instantly with high accuracy. • Support for popular models: Compatible with widely-used models such as YOLO, SSD, and more. • Web-friendly: Optimized for web applications, ensuring smooth integration with JavaScript frameworks. • Customizable: Allows fine-tuning of detection parameters to suit specific use cases. • Cross-browser compatibility: Works across modern web browsers for broader reach.
npm install transformers.js
import Transformers from 'transformers.js';
const detector = new Transformers.Detector('yolo');
detector.loadImage('path/to/image.jpg');
detector.detect().then(results => {
console.log(results); // Array of detected objects with bounding boxes
});
What browsers are supported by Transformers.js?
Transformers.js is designed to work with modern web browsers, including Chrome, Firefox, Safari, and Edge. Older browsers may require additional polyfills.
Can I use custom models with Transformers.js?
Yes, Transformers.js supports custom models. You can load your own pre-trained models by providing the model weights and configuration files.
How does Transformers.js ensure performance for real-time detection?
Transformers.js leverages WebGL and modern JavaScript optimizations to deliver fast inference times, making it suitable for real-time object detection tasks.