Faery supports direct streaming from event cameras, enabling real-time data processing and visualization. Note that this requires additional driver installations.
5.4.1Supported cameras¶
Faery supports event cameras from two major manufacturers through different driver systems:
5.4.1.1Inivation cameras¶
- DVXplorer (640×480)
- DAVIS346 (346×260)
- Requires:
event_camera_drivers
orneuromorphic_drivers
5.4.1.2Prophesee cameras¶
- EVK4 (1280×720)
- EVK3 HD (1280×720)
- Requires:
neuromorphic_drivers
5.4.2Driver installation¶
Faery supports two driver systems. Install at least one:
5.4.2.1Option 1: event_camera_drivers¶
pip install event_camera_drivers
- Works well with Inivation cameras
- Uses existing libcaer drivers under the hood
5.4.2.2Option 2: neuromorphic_drivers¶
pip install neuromorphic_drivers
- Custom drivers
- Supports both Inivation and Prophesee cameras
5.4.3Usage¶
5.4.3.1Command line¶
# Stream from any detected camera to file
faery input inivation camera output file recording.es
# Stream to UDP for real-time processing
faery input inivation camera output udp localhost:7777
# Create real-time visualization
faery input inivation camera filter regularize 30.0 filter render exponential "00:00:00.100000" starry_night output mp4 live.mp4
5.4.3.2Python¶
import faery
# Auto-detect and connect to camera
stream = faery.events_stream_from_camera()
# Specify driver system
stream = faery.events_stream_from_camera(driver="EventCameraDrivers")
stream = faery.events_stream_from_camera(driver="NeuromorphicDrivers")
# Specify manufacturer (helps with faster detection)
stream = faery.events_stream_from_camera(manufacturer="Inivation")
stream = faery.events_stream_from_camera(manufacturer="Prophesee")
# Configure buffer size for performance tuning
stream = faery.events_stream_from_camera(buffer_size=2048)
# Use in a processing pipeline
faery.events_stream_from_camera() \
.time_slice(0 * faery.s, 10 * faery.s) \
.regularize(frequency_hz=30.0) \
.render(tau="00:00:00.002000", decay="exponential", colormap=faery.colormaps.starry_night) \
.to_file("live.mp4")
5.4.4Camera detection and selection¶
Faery automatically detects available cameras and drivers:
# Check driver availability
import faery.event_camera_input as eci
if eci.has_event_camera_drivers():
print("event_camera_drivers available")
if eci.has_neuromorphic_drivers():
print("neuromorphic_drivers available")
# Auto-detection tries drivers in order of preference
stream = faery.events_stream_from_camera(driver="Auto") # Default behavior
5.4.5Configuration options¶
5.4.5.1Buffer size¶
Controls the internal buffer size for event streaming:
# Larger buffers reduce latency spikes but use more memory
stream = faery.events_stream_from_camera(buffer_size=4096) # Default: 1024
5.4.5.2Manufacturer hint¶
Speeds up camera detection by specifying the expected manufacturer:
# Skip detection time by specifying manufacturer
stream = faery.events_stream_from_camera(manufacturer="Inivation")
5.4.6Real-time processing examples¶
5.4.6.1Live visualization¶
import faery
# Record 10 seconds of camera data as video
faery.events_stream_from_camera() \
.time_slice(0 * faery.s, 10 * faery.s) \
.regularize(frequency_hz=30.0) \
.render(decay="exponential", tau="00:00:00.200000", colormap=faery.colormaps.starry_night) \
.to_file("live.mp4")
5.4.6.2Network streaming¶
# Stream events over UDP for distributed processing
faery.events_stream_from_camera() \
.to_udp(("localhost", 7777))
5.4.7Troubleshooting¶
5.4.7.1No camera detected¶
ValueError: No Event Camera found
Solutions:
- Check physical camera connection (USB)
- Verify driver installation:
pip list | grep -E "(event_camera|neuromorphic)"
- For neuromorphic_drivers: ensure udev rules are installed
- Try specifying manufacturer:
manufacturer="Inivation"
5.4.7.2Permission issues (Linux)¶
PermissionError: [Errno 13] Permission denied
Solutions:
- Install udev rules for your camera - see the guide on NeuromorphicDrivers’ GitHub
- Add user to appropriate groups (dialout, plugdev)
- Restart or re-login after group changes
5.4.7.3Driver import errors¶
ImportError: No module named 'event_camera_drivers' / 'neuromorphic_drivers'
Solutions:
- Install missing driver:
pip install event_camera_drivers
orpip install neuromorphic_drivers
- Check virtual environment activation
- Verify compatible Python version
5.4.8Hardware requirements¶
- USB 3.0 or higher recommended for high-resolution cameras
- Available USB ports (cameras may require significant bandwidth)
- Sufficient RAM for buffering (especially at high event rates)
- Linux/Windows/macOS support varies by driver system. Please submit issues in the respective driver repositories