Skip to content
OpenTrain AIFor AI Companies

Count Anything

Mengqi Lei, Shuokun Cheng, Wei Bao, Shaoyi Du, Jun-Hai Yong +2 morePublished May 29, 2026
arXiv PDF
Researcher verdict
Starting point
Use as implementation starting point
Benchmark evidence
Thin evidence
Verify before relying
Time to first repro
A few hours
Fast first run
Risk flags
0
None detected

Abstract

Domain fit: AI-adjacent · Paper appears method- or tooling-adjacent to AI workflows with partial ecosystem coverage.

Object counting remains fragmented across domain-specific datasets and task formulations, despite rapid progress in generalist vision models. Existing counting models are often tailored to scenarios such as crowds, vehicles, cells, crops, or remote-sensing objects, and thus struggle to generalize across categories, visual domains, object scales, and density distributions. In this paper, we study text-guided object counting across domains, where a model takes an image and a natural-language query as input and returns an instance-grounded set of target points whose cardinality gives the count. This formulation unifies category-conditioned counting with interpretable spatial localization. To support this setting, we construct CLOC, a Cross-domain Large-scale Object Counting dataset that reorganizes diverse public data sources into a unified benchmark. CLOC covers six visual domains: General Scene, Remote Sensing, Histopathology, Cellular Microscopy, Agriculture, and Microbiology, with about 220K images, 619 categories, and 15M object instances. Based on CLOC, we propose Count Anything, a generalist model for text-guided object counting. Unlike density-map-based methods, which dominate counting models, Count Anything adopts discrete instance points and performs dual-granularity instance enumeration. A Region-level Sparse Counter provides object-level anchors for large and sparse targets, while a Pixel-level Dense Counter handles small, crowded, and weakly bounded targets via dense point prediction. A point-centric supervision strategy enables learning from heterogeneous annotations, and Complementary Count Fusion combines both counters in a parameter-free manner. Extensive experiments show that Count Anything achieves strong accuracy and multi-domain generalization, outperforming existing open-world counting methods. Code is available at: https://github.com/Mengqi-Lei/count-anything.

Results and benchmarks

Freshness tier: hot
Object counting remains fragmented across domain-specific datasets and task formulations, despite rapid progress in generalist vision models.
Task Dataset Metric Value Source
Computer vision CLIP-Count 39 Full Test MAE. 14.48 paper-derived
Computer vision 19.16 Full Test MAE. 7.24 paper-derived
Computer vision CountGD 3 Full Test MAE. 13.19 paper-derived
Computer vision 18.61 Full Test MAE. 4.81 paper-derived

Audit each benchmark finding before selecting an implementation path. Evidence refs map to the disclosure below.

Implementation

Best maintained implementation now

Recommended
Confidence: Medium
Reproducibility: Strong

Code and implementation guidelines for the paper ✨Counting Anything. Project Page: https://mengqi-lei.github.io/count-anything-projectpage/

534 stars · 44 forks · Last push Aug 12, 2026 · Apache-2.0 license

  • License
  • CI
  • Dependencies
  • Docker

Matched via arXiv identifier search · Strong overlap with paper title keywords · Community adoption signal (534 stars)

Why this implementation
Confidence: medium

Mengqi-Lei/count-anything is the best available implementation candidate based on ranking signals, but recommendation confidence is not yet high. CI workflows are present. License is declared (Apache-2.0).

Open Mengqi-Lei/count-anything
Reproduction risks
  • No repository-level red flags were detected, but paper-specific preprocessing and hyperparameter details may still be under-specified.
  • Selected Mengqi-Lei/count-anything as the strongest maintained implementation for new work.
  • Includes CI workflow signals.
  • Includes dependency/environment manifest signals.
  • Repository activity is within the last 24 months.

Reproduction readiness

Time to first repro: hours
Last checked: Aug 24, 2026

Ready to run

Ready to reproduce

  • Clone Mengqi-Lei/count-anything and install dependencies from requirements.txt.
  • CI pipeline detected, so automated tests are in place.
  • Last updated 13 days ago.
Open Mengqi-Lei/count-anything

Quick start

git clone https://github.com/Mengqi-Lei/count-anything.git
pip install -r requirements.txt

Hugging Face artifacts

No direct paper-linked artifacts were found. Showing strongest curated related artifacts for faster exploration.

Models

Curated Related

Datasets

No trustworthy datasets matches right now.

Search datasets on Hugging Face

Spaces

No trustworthy spaces matches right now.

Search spaces on Hugging Face

Research context

Tasks

Computer vision

Methods

None detected

Domains

Computer vision, Geospatial AI

Evaluation and human feedback data

Open this paper in HFEPX to review benchmark signals, evaluation modes, and human-feedback protocol context.

Open in HFEPX
Explore similar papers

Jump to Paper2Code search queries derived from this paper's research context.