Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Some fixes #11

Merged
merged 22 commits into from
May 19, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
try to pass pylints with py.typed
  • Loading branch information
zrezke committed May 18, 2023
commit 4860bfdf482a33e0e498dee5b12af5307e87b483
1 change: 1 addition & 0 deletions crates/re_viewer/src/depthai/depthai.rs
Original file line number Diff line number Diff line change
Expand Up @@ -264,6 +264,7 @@ pub struct CameraSensorConfig {
kind: CameraSensorType,
width: i64,
}

#[derive(serde::Serialize, serde::Deserialize)]
pub struct CameraFeatures {
configs: Vec<CameraSensorConfig>,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ def __init__(self, **v) -> None: # type: ignore[no-untyped-def]
v["resolution"] = getattr(dai.ColorCameraProperties.SensorResolution, v["resolution"])
if v.get("board_socket"):
v["board_socket"] = getattr(dai.CameraBoardSocket, v["board_socket"])
return super().__init__(**v)
return super().__init__(**v) # type: ignore[no-any-return]

@property
# Make this select the queue based on ui, also probably not just one queue
Expand Down Expand Up @@ -66,7 +66,7 @@ def __init__(self, **v) -> None: # type: ignore[no-untyped-def]
v["resolution"] = getattr(dai.MonoCameraProperties.SensorResolution, v["resolution"])
if v.get("board_socket"):
v["board_socket"] = getattr(dai.CameraBoardSocket, v["board_socket"])
return super().__init__(**v)
return super().__init__(**v) # type: ignore[no-any-return]

@property
def out_queue_name(self) -> str:
Expand Down
6 changes: 3 additions & 3 deletions rerun_py/rerun_sdk/depthai_viewer/_backend/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -96,19 +96,19 @@ def get_device_properties(self) -> Dict[str, Any]:
)
device_properties["supported_color_resolutions"] = list(
map(
lambda x: color_wh_to_enum[x].name, # type: ignore[index]
lambda x: color_wh_to_enum[x].name, # type: ignore[index, no-any-return]
sorted(device_properties["supported_color_resolutions"], key=lambda x: int(x[0]) * int(x[1])),
)
)
device_properties["supported_left_mono_resolutions"] = list(
map(
lambda x: color_wh_to_enum[x].name, # type: ignore[index]
lambda x: color_wh_to_enum[x].name, # type: ignore[index, no-any-return]
sorted(device_properties["supported_left_mono_resolutions"], key=lambda x: int(x[0]) * int(x[1])),
)
)
device_properties["supported_right_mono_resolutions"] = list(
map(
lambda x: color_wh_to_enum[x].name, # type: ignore[index]
lambda x: color_wh_to_enum[x].name, # type: ignore[index, no-any-return]
sorted(device_properties["supported_right_mono_resolutions"], key=lambda x: int(x[0]) * int(x[1])),
)
)
Expand Down
Empty file.