Skip to content

calib + image-quality: gate by --context, dedicate IQ depth test - #15015

Merged
Nir-Az merged 4 commits into
realsenseai:developmentfrom
AviaAv:calib-iq-context-gating
May 14, 2026
Merged

Nir-Az merged 4 commits into
realsenseai:developmentfrom
AviaAv:calib-iq-context-gating

Conversation

@AviaAv

@AviaAv AviaAv commented May 5, 2026

Copy link
Copy Markdown
Contributor

Tracked on: [RSDSO-21345]

@AviaAv
AviaAv requested a review from Nir-Az May 5, 2026 07:52
@AviaAv
AviaAv force-pushed the calib-iq-context-gating branch 5 times, most recently from d3cb545 to 43ce87d Compare May 6, 2026 14:07
@AviaAv
AviaAv force-pushed the calib-iq-context-gating branch from 43ce87d to bfd4e2a Compare May 12, 2026 09:08
Comment thread unit-tests/conftest.py Outdated
if not config.getoption("--timeout", default=None):
config.option.timeout = 200
config.option.timeout_method = "thread"
config.option.timeout_method = "thread" if sys.platform == "win32" else "signal"

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please add a comment explaining this

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

reverted, as change is expected in subprocess PR

Comment thread unit-tests/conftest.py Outdated
config.option.timeout_method = "thread"
config.option.timeout_method = "thread" if sys.platform == "win32" else "signal"
# pytest-timeout reads func_only from ini only, not the CLI option attribute
config.inicfg["timeout_func_only"] = "true"

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We want timeout for module and not func, is this the case?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

reverted, as change is expected in subprocess PR

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure we will merge the subprocess PR..

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

NP
Still leaving as reverted, can be handled in a separate PR as needed

# the OpenCV S = (V - min) / V calculation; tight values false-fail)


def is_color_close(actual, expected):

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lets make sure the color test is valid and blue is detected as blue and if it was red it would fail

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

added infra test checking different colors fail

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Now I understand why, since you verified it, I say lets remove the infra test and all hooks related
1 time verification that this mechanism works is enough IMO

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

removed infra test

@AviaAv
AviaAv force-pushed the calib-iq-context-gating branch from 440de62 to 25b2caf Compare May 13, 2026 11:29
@AviaAv
AviaAv requested a review from Nir-Az May 14, 2026 08:21

import sys, os, types

# CI runners don't ship pyrealsense2; iq_helper imports it at module top but

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please explain,
LibCI does have pyrealsense2, what happens here?

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

NVM just saw it's the test, we can remove IMO if you trust the coloring validation (don't trust claude here..)

# CI runners don't ship pyrealsense2; iq_helper imports it at module top but
# is_color_close itself only uses cv2+numpy, so a stub module is enough.
sys.modules.setdefault('pyrealsense2', types.ModuleType('pyrealsense2'))
sys.path.insert(0, os.path.join(os.path.dirname(__file__), '..', 'live', 'image-quality'))

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a helper python why do we need this magic?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

removed

@AviaAv
AviaAv force-pushed the calib-iq-context-gating branch from 4a83517 to cb84b9a Compare May 14, 2026 13:55

@Nir-Az Nir-Az left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great

@Nir-Az
Nir-Az merged commit 853b180 into realsenseai:development May 14, 2026
29 of 30 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants