Skip to content

[BUG] Keypoint confidence range filter hides all points when max bound is null #8152

Description

@korotaS

🗃️ Describe the problem

In the App, filtering a Keypoint / Keypoints list attribute such as confidence with the numeric range slider can hide all points even when some values fall inside the intended range.

Expected: Dragging the min thumb above the lower bound while leaving max at the upper bound keeps points whose confidence is ≥ min (and ≤ the field max).

Actual: That filter often shows no points. Filtering only the upper end (e.g. max ≈ 0.4 with min at the lower bound) still works and shows the low-confidence points.

Root cause (investigation):
The range slider stores null when a thumb sits on a field bound (RangeSlider onMinCommit / onMaxCommit). Per-point keypoint filtering in skeletonFilter compared values with:

value >= range[0] && value <= range[1]

In JavaScript, null coerces to 0, so a stored range like [0.2, null] becomes value <= 0 and drops every positive confidence. Other numeric filters already handle null ends via helperFunction in pathFilters/numeric.ts; keypoints did not.

🖥️ Operating System Platform & Distribution

  • Linux
  • MacOS
  • Windows
  • Other (please specify)

💻 System Details


MacOS:

Model Name: MacBook Pro
Model Identifier: MacBookPro17,1
Model Number: Z11B0004URU/A
Chip: Apple M1
Total Number of Cores: 8 (4 performance and 4 efficiency)
Memory: 16 GB
System Firmware Version: 10151.61.4
OS Loader Version: 10151.61.4
Activation Lock Status: Enabled

Linux:

---OS---
Linux akorotaevskiy-3-0 5.15.0-130-generic #140-Ubuntu SMP Wed Dec 18 17:59:53 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
---HWinfo---
/0/0 memory 130GiB System memory
/0/1 processor 12th Gen Intel(R) Core(TM) i5-12400F
/0/100/1/0 display NVIDIA Corporation
/0/100/6/0 storage Samsung Electronics Co Ltd
/0/100/6/0/0 nvme0 storage Samsung SSD 990 PRO 2TB
/0/100/14.2 memory RAM memory
/0/100/17 storage Intel Corporation
/0/100/1c.7/0 display NVIDIA Corporation

🌐 Browser

Not applicable, Chrome (or Chromium-based)

⤵️ Installation type


  • Package (pip)
  • Source (git)

⌨️ Code to reproduce issue


import fiftyone as fo

dataset = fo.Dataset("keypoint-confidence-bug")
dataset.persistent = True
dataset.default_skeleton = fo.KeypointSkeleton(
    labels=["p0", "p1", "p2", "p3"],
    edges=[[0, 1, 2, 3]],
)

sample = fo.Sample(
    filepath="/path/to/any/image.jpg",
    keypoints=fo.Keypoints(
        keypoints=[
            fo.Keypoint(
                label="person",
                points=[(0.2, 0.3), (0.4, 0.5), (0.6, 0.4), (0.8, 0.6)],
                confidence=[0.1, 0.3, 0.5, 0.7],
            )
        ]
    ),
)
dataset.add_sample(sample)

session = fo.launch_app(dataset)
  1. Open the sample (modal).
  2. In the sidebar, expand keypointsconfidence and use the range slider.
  3. Drag min to ~0.2 and leave max at the upper bound.
  4. Observe: no keypoints are drawn (expected: 3 points with confidences 0.3, 0.5, 0.7).
  5. Reset, then drag max to ~0.4 and leave min at the lower bound.
  6. Observe: 2 points show correctly (0.1, 0.3).

🐍 What version of Python?


Python 3.12.4

🔖 What version of FiftyOne?

Version: 1.21.0 (develop branch)

🪵 Other info/logs


  • Affects per-point list attributes on keypoints (e.g. confidence), because looker uses pointFilterskeletonFilter.
  • Regular detection confidence filters are unaffected (they use helperFunction).
  • Leaving a slider thumb on a bound is intentional: the App stores null for that end so the filter means “unbounded” on that side.

🚀 Willingness to contribute


Yes, I can contribute a fix for this bug independently

📸 Upload screenshots


Снимок экрана 2026-07-31 в 14.43.52.png
Снимок экрана 2026-07-31 в 14.44.01.png

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions