Accelerating AI-Powered Stool Analysis with High-Precision Medical Image Annotation

Discover how Shaip helps healthcare AI teams build computer vision models for stool image analysis, smart toilets, and health monitoring with accurate image annotation

Vehicle damage detection & body part annotation

Project Overview

Building an AI model for automatic stool analysis requires more than image collection alone. It demands highly consistent, clinically relevant labeling that captures stool shape, basin context, and scene-level attributes with precision.

The client partnered with Shaip to annotate a large-scale image containing stool imagery captured in real-world toilet environments. The project required a multi-layered labeling strategy combining polygon-based stool annotation, basin bounding box creation, and classification-driven AOI labeling.

The ultimate goal is to create a robust training dataset that support computer vision models for stool detection, Bristol stool classification, urination context recognition, & future digestive-health insights.

Key Stats

End Use

AI-powered stool analysis for healthcare & gastroenterology

Data Volume

700,000+ images

AOI Taxonomy

10 classification labels

Project Timeline

Ongoing since November 2023 

Challenges

  • Ensuring stool objects were segmented with tight polygon boundaries despite varied lighting, toilet conditions, and image composition.
  • Standardizing basin bounding box labeling while applying visit-level logic only to the first valid image in each visit.
  • Managing a multi-class AOI labeling workflow across labels such as stool, urine, urination, flushing, toilet paper, and Bristol number.
  • Maintaining consistency and throughput across a very large image volume exceeding 700,000 files.
  • Supporting healthcare-oriented AI use cases where annotation quality directly affects downstream model accuracy.

Solution

Shaip designed a railway-focused annotation workflow tailored to the project’s technical requirements.

Data Strategy

Defined a structured annotation framework that combined segmentation, object localization, and classification to support multiple model objectives from a unified image pipeline.

Stool Annotation

Annotated visible stool instances using precise polygon masks, tracing tightly around each stool piece to preserve edge detail, shape, and texture.

Basin Bounding Box

Marked the toilet basin using a bounding box rather than water-level segmentation. Basin boxes were applied only to the first image of each visit unless the image was marked as ignore or color.

AOI Labeling

Classified images into a controlled taxonomy including Non Toilet, Ignore, Empty, Toilet Paper, Flushing, Urine, Urination, Stool, Toilet Soap, and Bristol Number.

ID & Relationship Integrity

Ensured every annotation had a unique annotation ID and each object had a unique object ID in UUID format, with bidirectional connectedTo relationships in a sensor-aware manner.

Quality Assurance

Applied review workflows designed to meet a 95% batch acceptance threshold, with quality checks focused on annotation tightness, correct class assignment, and visit-level labeling rules.

AI Enablement

Structured the output dataset to support segmentation, object detection, and classification pipelines for automated stool analysis, digestive health monitoring, and future smart- health applications.

Project Scope

Dataset / Task Type Annotation Method Key Rule AI Value
Stool Images Polygon annotation Annotate stool tightly around visible edges Supports stool segmentation and morphology analysis
Toilet Basin Bounding box Mark only in the first valid image of each visit Helps the model learn basin context and scene framing
AOI Labels Classification only Apply the correct scene/event label without object annotation Enables scene understanding and event categorization

Outcomes

  • Built a structured annotation pipeline across 700,000+ healthcare-relevant images
  • Standardized 3 distinct workflows for segmentation, localization, and classification
  • Enabled AI training for automated stool detection and Bristol-scale-related classification
  • Supported model development for gastrointestinal analysis, hydration context, and disease prediction workflows
  • Created a scalable data foundation aligned to a 95% batch acceptance target

By combining high-volume delivery with precise medical-image labeling logic, Shaip helped the client move from raw image capture to a production-ready data foundation for next-generation automated stool analysis. The project established the structure needed to scale future AI development in digestive health monitoring and preventative care applications.

Shaip brought the annotation precision and operational scale we needed for a highly specialized healthcare AI initiative. Their ability to manage complex stool segmentation, basin localization, and AOI classification at volume gave us a strong foundation for model development.

– Head of AI

Golden-5-star