LIBUSB_TRANSFER_STALL with EVK2 cameras using EventsIterator

LIBUSB_TRANSFER_STALL with EVK2 cameras using EventsIterator

Hello,

I am experiencing a reproducible issue with two EVK2 (Gen4.1) cameras using Metavision SDK 4.6.2 on Windows.

Initially, I thought the problem was related to camera synchronization, since my stereo recorder would sometimes record only the master camera. However, after simplifying the code, I found that the issue occurs even with a single camera, so it does not appear to be related to synchronization.

To isolate the problem, I created the attached minimal Python script (test_one_camera_10_runs.py), which simply:

  1. Opens a single camera using initiate_device().
  2. Applies the camera biases.
  3. Creates an EventsIterator.
  4. Records events for a few seconds.
  5. Stops the stream and releases the device.
  6. Repeats the process 10 times.

The results are very consistent:

  • Both EVK2 cameras behave similarly.
  • The first one or two runs work correctly.
  • After that, every subsequent run fails with:

RuntimeError:

LibUSB

Error 4: LibUSB connection error: LIBUSB_TRANSFER_STALL

The exception occurs inside poll_buffer() while iterating over the events.

I also tested:

  • Recording with and without log_raw_data().
  • Longer and shorter recording durations.
  • Aggressive cleanup (stream.stop(), deleting the iterator and device, gc.collect(), and waiting several seconds between runs).

None of these changes resolved the issue.

Interestingly, I also tested a CenturyArks camera SilkyEvCam IMX636 (I'm guessing similar to EVK4) using the exact same script, computer, USB ports, and workflow. It successfully completed all 10 runs without any failures.

Therefore, the issue seems to be specific to the EVK2 cameras.

My environment is:

  • Metavision SDK / Studio 4.6.2
  • Windows 11
  • Python 3.9.13
  • Cameras connected directly to independent USB ports (no USB hub)

Could you please let me know if this is a known issue with EVK2 cameras or the Gen4.1 USB driver? Is there a recommended way to fully reset or release the device between acquisitions, or any driver/firmware update that addresses this behavior?

The minimal reproducible script is attached for reference.

Thank you very much for your help.

Best regards,

Luisa Maya



    As a Prophesee customer, join the community conversation. 
    Request your free access today.

      Information

      In this Community Forum, you can discuss products, technology and applications. Only registred users can post but everyone can read. To ask a private question, enter a support ticket in My Area https://support.prophesee.ai/portal/en/newticket