Skip to main content

bop-bootstrap-ci

Bootstrap percentile confidence intervals (95 %, B = 1000) for BOP Challenge 6-DoF object pose estimation metrics: ADD, ADD-S, AUC, Recall@N mm.

Python License: MIT BOP Challenge

Why this exists

BOP submissions typically report point estimates of AUC ADD-S, Recall@10 mm and similar metrics, but rarely include confidence intervals. This package provides a reproducible, semi-standard bootstrap percentile CI (B = 1000, 95 %) over any user-supplied set of per-instance pose errors — turning a single number into a defensible range that supports statistical comparisons across methods.

It was extracted from a TFM at UNIR (2026) on bin-picking with FoundationPose + Diffusion Policy, where bootstrap CIs were used to validate AUC ADD-S 0.908 [0.901, 0.916] on YCB-Video and 0.957 [0.954, 0.959] on T-LESS.

Install

pip install bop-bootstrap-ci

Quick start

import numpy as np
from bop_bootstrap_ci import bootstrap_auc_adds, bootstrap_recall

# Your per-instance ADD-S errors in millimetres, from your BOP run
add_s_errors_mm = np.array([2.1, 5.3, 8.9, 1.4, 22.0, 7.5, 3.2, 14.8, ...])

auc = bootstrap_auc_adds(add_s_errors_mm, max_threshold_mm=50.0, B=1000, seed=42)
print(f"AUC ADD-S @50mm: {auc.point:.4f} [{auc.lo:.4f}, {auc.hi:.4f}]")

recall10 = bootstrap_recall(add_s_errors_mm, threshold=10.0, B=1000, seed=42)
print(f"Recall ADD-S @10mm: {recall10.point:.1%} "
      f"[{recall10.lo:.1%}, {recall10.hi:.1%}]")

API

bootstrap_ci(values, statistic=np.mean, B=1000, alpha=0.05, seed=42)

Generic percentile bootstrap CI for any 1-D array and statistic. Returns a BootstrapResult with fields .point, .lo, .hi, .B, .alpha.

bootstrap_recall(errors, threshold, ...)

Bootstrap CI for the fraction of errors strictly below threshold. Equivalent to Recall@N mm as defined in BOP.

bootstrap_auc_adds(errors, max_threshold_mm=50.0, ...)

Bootstrap CI for the Area Under the Recall Curve in [0, max_threshold_mm], normalised to [0, 1]. The standard BOP AUC ADD-S @50 mm convention.

recall_at_threshold(errors, threshold) and auc_from_errors(errors, ...)

Direct (non-bootstrapped) point estimates.

Compatibility with bop_toolkit

This package consumes raw per-instance errors as numpy.ndarray. To use it with the official BOP toolkit, run your evaluation as usual, then pass the resulting per-instance ADD/ADD-S errors to the bootstrap functions:

from bop_toolkit_lib import inout, pose_error
# ... compute add_s_errors_mm as you normally would ...

from bop_bootstrap_ci import bootstrap_auc_adds
ci = bootstrap_auc_adds(add_s_errors_mm).as_dict()
print(ci)  # {"point": 0.908, "lo": 0.901, "hi": 0.916, "B": 1000, "alpha": 0.05}

Reproducibility

All public functions are deterministic given the seed argument and reproduce the underlying TFM's results bit-exactly. Default seed = 42, default B = 1000, default alpha = 0.05 (95 % CI), default method = percentile.

Limitations

  • Percentile method only, not BCa. BCa would correct for skew but is rarely reported in BOP-style papers and would break compatibility with our TFM.
  • i.i.d. assumption: the bootstrap assumes per-instance errors are drawn i.i.d. from the underlying error distribution. If your evaluation has strong per-scene correlations, consider a block bootstrap instead.
  • No multiple-comparisons correction built in. If comparing many methods, apply Bonferroni or Holm-Sidak externally.

Citation

If you use this in academic work, please cite the underlying TFM:

@mastersthesis{godoy2026pose6dof,
  title  = {Estimaci\'on de Pose 6-DoF mediante Transformers y Modelos de
            Difusi\'on para Bin Picking Rob\'otico},
  author = {Godoy Bonillo, Giocrisrai and Carrasco, Jos\'e Miguel},
  school = {Universidad Internacional de La Rioja (UNIR)},
  year   = {2026},
  url    = {https://github.com/Giocrisrai/pose6dof-transformers-diffusion}
}

License

MIT.

Metadata

Release files for bop-bootstrap-ci 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for bop-bootstrap-ci 0.1.0
File Size Uploaded Provenance Actions
bop_bootstrap_ci-0.1.0.tar.gz 9.2 kB Without provenance Details for bop_bootstrap_ci-0.1.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for bop-bootstrap-ci 0.1.0
File Interpreter ABI Platform Actions
bop_bootstrap_ci-0.1.0-py3-none-any.whl Python 3 none any Details for bop_bootstrap_ci-0.1.0-py3-none-any.whl

Total release size: 15.9 kB

Release files / bop_bootstrap_ci-0.1.0.tar.gz

Download URL bop_bootstrap_ci-0.1.0.tar.gz
Size 9.2 kB
Tags Source
SHA-256 checksum
How to use checksums
3168d1ac8e1395c15e75cc0d9378424704d7c1e50ecc3195b90bd738b4e351cd
BLAKE2b-256 checksum
How to use checksums
17999ff43f60e4ab39485c36da5f30076c5c5799d6ff0b73c668e73ea81e0313
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.13

Release files / bop_bootstrap_ci-0.1.0-py3-none-any.whl

Download URL bop_bootstrap_ci-0.1.0-py3-none-any.whl
Size 6.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f179f2ed8499b96539ecfa4b373736b5fe2d8ea1aa122926735e296920c82dd0
BLAKE2b-256 checksum
How to use checksums
be772b342b87e7252150e52e5a10cb88cca70d72bbc4dd123a7f5d6241437705
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.13

Security for bop-bootstrap-ci 0.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page