stereolabs / zed-python-api

Python API for the ZED SDK
https://www.stereolabs.com/docs/app-development/python/install/
MIT License
209 stars 95 forks source link

enable_image_validity_check spams compute fern and compute color print statements #236

Closed krishkribo closed 6 months ago

krishkribo commented 6 months ago

Preliminary Checks

Description

When "enable_image_validity_check" is enabled from the camera init parameters. The console is flooded with "compute Fern" and "Compute Color" print statements.

Even when setting the sdk_verbose = 0 does not solve the issue.

This especially makes it hard to debug the application.

The issue can be only resolved when disabling the "enable_image_validity_check".

Configuration used for initParameters :

def set_init_params(self) -> sl.InitParameters:
        input_type = sl.InputType()
        if self.config["svo"] is not None:
            input_type.set_from_svo_file(self.config["svo"])

        svo_real_time_mode = True if self.config["svo"] is not None else False

        init_params = sl.InitParameters(input_t=input_type, svo_real_time_mode=svo_real_time_mode)

        init_params.camera_resolution = self.resolution[self.config["resolution"]]
        init_params.camera_fps = float(self.config["fps"])
        init_params.coordinate_units = sl.UNIT.METER
        init_params.depth_mode = self.depth_mode[self.config["depth"]["mode"]]
        init_params.coordinate_system = sl.COORDINATE_SYSTEM.RIGHT_HANDED_Z_UP_X_FWD
        init_params.depth_minimum_distance = self.config["depth"]["min_distance"]
        init_params.depth_maximum_distance = self.config["depth"]["max_distance"]
        init_params.camera_disable_self_calib = True # default False. ! Do not change !
        init_params.depth_stabilization = self.config["depth"]["smoothness"]
        init_params.enable_image_enhancement = True # default True. ! Do not change !
        init_params.enable_image_validity_check = True # default False. ! Do not change ! 
        init_params.async_grab_camera_recovery = True # default False. ! Do not change ! 
        init_params.sdk_verbose = 0 # default 0. ! Do not change ! 
        return init_params

Steps to Reproduce

  1. Set "enable_image_validity_check" parameter to True in init parameters
  2. Run base example ...

Expected Result

Run without "Compute Fern" and "Compute Color" print spans.

Actual Result

Screenshot from 2024-03-06 10-08-03

ZED Camera model

ZED

Environment

OS: Ubuntu 20.04.6 LTS
SDK_Version : 4.0.7
CPU: aarch64
Kernel: 5.10.120-tegra
GPU: Jetson AGX Orin Developer Kit

Anything else?

No response

adujardin commented 6 months ago

This is fixed in 4.0.8, sorry about that. It was a QA leftover from enable_image_validity_check