depthai-python: Processing failed, potentially unsupported config
Hello, can someone please explain me why this script does not work? It gives me
[14442C10D13799CD00] [55.888] [ImageManip(3)] [error] Processing failed, potentially unsupported config
Here is the code
import depthai as dai
pipeline = dai.Pipeline()
pipeline.setOpenVINOVersion(version=dai.OpenVINO.Version.VERSION_2021_3)
cam = pipeline.create(dai.node.ColorCamera)
cam.setResolution(dai.ColorCameraProperties.SensorResolution.THE_1080_P)
cam.setIspScale(2,3)
cam.setInterleaved(False)
cam.setPreviewSize(1280, 720)
preview_rotate_manip = pipeline.create(dai.node.ImageManip)
rotation_cfg = dai.RotatedRect()
rotation_cfg.center.x, rotation_cfg.center.y = 0.5, 0.5
rotation_cfg.size.width, rotation_cfg.size.height = 1,1
rotation_cfg.angle = 0
preview_rotate_manip.initialConfig.setCropRotatedRect(rotation_cfg, True)
preview_rotate_manip.setMaxOutputFrameSize(1280*720*3)
cam.preview.link(preview_rotate_manip.inputImage)
preview_zoom_manip = pipeline.create(dai.node.ImageManip)
zoom_cfg = dai.RotatedRect()
zoom_cfg.center.x, rotation_cfg.center.y = 0.5, 0.5
zoom_cfg.size.width, rotation_cfg.size.height = 1,1
preview_zoom_manip.initialConfig.setCropRotatedRect(zoom_cfg, True)
preview_zoom_manip.setMaxOutputFrameSize(1280*720*3)
preview_rotate_manip.out.link(preview_zoom_manip.inputImage)
preview_resize_manip = pipeline.create(dai.node.ImageManip)
preview_resize_manip.initialConfig.setResize(300,300)
preview_resize_manip.initialConfig.setKeepAspectRatio(False)
preview_resize_manip.setMaxOutputFrameSize(1280*720*3)
preview_zoom_manip.out.link(preview_resize_manip.inputImage)
cam_xout = pipeline.create(dai.node.XLinkOut)
cam_xout.setStreamName("RGB")
preview_resize_manip.out.link(cam_xout.input)
with dai.Device(pipeline) as device:
q_rgb_out = device.getOutputQueue("RGB", maxSize=1, blocking=True)
while True:
in_rgb = q_rgb_out.get()
cv2.imshow("RGB", in_rgb.getCvFrame())
cv2.waitKey(5)
I know this is a very weird example, but that would be the base for my application. I’m on
- Windows 10
- VSCode
- Depthai 2.13.1.0
- Python 3.9.2
Thank you
About this issue
- Original URL
- State: open
- Created 2 years ago
- Comments: 19 (6 by maintainers)
@f-alemauro The reason you received the mentioned error
[14442C10D13799CD00] [166.178] [ImageManip(3)] [error] Processing failed, potentially unsupported config
is regarding the unsupported config we discuss above. So, a crop and a resizingThumbnail operation are incompatible in the same ImageManip pipeline config. The solution in the mainline version is to do those 2 operations in separated pipelines, something like this:And even with the above script, you will receive soon other errors in the mainline ImageManip version because of the know issues regarding random scaling input/output resolutions. This is one of the many reasons why we are trying to integrate the image_manip_refactor branch into develop/main. I had tried the above script in the image_manip_refactor version and it ends successfully. I kindly recommend you try this experiment there. Sorry for not having a workaround in the mainline version this time. We are concentrating our efforts to integrate the image_manip_refactor branch into develop/main as soon as possible because this version resolves a lot of bugs/restrictions from the mainline version and adds new features, but keep in mind that the image_manip_refactor version rewrites almost 80% of the current version, we cannot integrate the bug fixes and features one by one. If there is anything we can do to unlock your development in the meantime( (until the image_manip_refactor version is integrated), please let us know.
Ok, sorry for this script, I had already forgotten the unsupported config we discuss above… 😄 The script now runs smoothly.
I do think that this discussion is really helpful to everybody using Luxonis device!