I guess Intel Realsense D435 camera just start pipeline.start () function, will begin transmission frame, whether we call wait_for_frames () or poll_for_frames () function, it will transfer, but I have no way to verify this I guess, to go Advisory official customer service, I do not really understand them give me a reply. . .
After running pipeline.start (), will the camera continuously transmit frames to my computer, or will the camera only transmit frames to my computer when I call wait_for_frames ()? # 6100
At first I would like to use USB traffic monitoring tool to view the current rate of USB data transmission: how the windows system to detect real-time data transfer rate of USB? But looks like too much trouble, if we can determine whether memory changes after starting pipeline.start (), the camera will be immediately transmitted frame it?
First of all, I connect a camera on a computer, this is the memory on the current Task Manager shows:
Preparation of test procedures in accordance with the current situation:
# 导包
import pyrealsense2 as rs
import numpy as np
import cv2 as cv
import time
ctx = rs.context()
cam_serials = [dev.get_info(rs.camera_info.serial_number) for dev in ctx.query_devices()]
# print(cam_serials)
# ['838212073249', '827312070790', '826212070395']
for serial in cam_serials:
locals()['pipeline' + serial] = rs.pipeline(ctx)
locals()['config' + serial] = rs.config()
locals()['config' + serial].enable_device(serial)
locals()['pipeline' + serial].start(locals()['config' + serial])
while True:
for serial in cam_serials:
locals()['frames' + serial] = locals()['pipeline' + serial].wait_for_frames()
locals()['color_frame' + serial] = locals()['frames' + serial].get_color_frame()
locals()['color_image' + serial] = np.asanyarray(locals()['color_frame' + serial].get_data())
cv.imshow('{}'.format(serial), locals()['color_image' + serial])
cv.waitKey(1)
# time.sleep(10000)
The following data is recorded in accordance with different conditions of operation of the camera:
The number of camera head | pipeline.start() | wait_for_frames() | Framing delay | Whether the display screen | Memory / submitted | Remark | |
---|---|---|---|---|---|---|---|
1 | no | no | 0 | no | 6.9 | Insert the camera instantly rise to 7.0 | |
2 | no | no | 0 | no | 6.9 | ||
3 | no | no | 0 | no | 6.9 | ||
1 | Yes | no | 0 | no | 7.5 | ||
2 | Yes | no | 0 | no | 7.6 | ||
3 | Yes | no | 0 | no | 7.7 | ||
1 | Yes | Yes | 0 | no | 7.4 | ||
2 | Yes | Yes | 0 | no | 7.6 | ||
3 | Yes | Yes | 0 | no | 7.7 | ||
1 | Yes | Yes | 0 | Yes | 7.5 | ||
2 | Yes | Yes | 0 | Yes | 7.6 | ||
3 | Yes | Yes | 0 | Yes | 7.7 | ||
1 | Yes | Yes | 5000ms | no | 7.5 | ||
2 | Yes | Yes | 5000ms | no | 7.6 | ||
3 | Yes | Yes | 5000ms | no | 7.7 | ||
1 | Yes | Yes | 5000ms | Yes | 7.4 | ||
2 | Yes | Yes | 5000ms | Yes | 7.6 | ||
3 | Yes | Yes | 5000ms | Yes | 7.7 |
If we use poll_for_frames () function instead wait_for_frames () function, the data are consistent with substantially above
Does it mean, as long as we start pipeline.start () function, the camera can began streaming to our computer transmission frame, whether we call wait_for_frames () function (or poll_for_frames () function), it will take up our USB bandwidth?