Nano camera

nano 启动摄像头的时候 帧率特别低,只有两帧,摄像头是支持60帧的,而且每次都是最大的分辨率,画面无法观看,我该怎么处理?

hello 424128933,

please describe your issue in English for all users readability.
please also share more details about your environment settings.
for example,

  1. what’s the JetPack release version you’re working with.
  2. which sensor modules you’d use.

In the use of Nano, when USB camera is turned on, the frame rate is very low with a resolution of only 640480, the highest resolution is only 15FPS, and the resolution is only 2FPS with a resolution of 25921944. In Windows, the frame rate can reach at least 30Fps.Why is this happening?

hello 424128933,

please share your commands lines for reference, you may using incorrect pipeline settings to preview camera frames.
also, may I know which JetPack release version you’re working with.

I use the camera called by pytorch yolov3, and the command is yolo’s detection command. Python3 detects. Py – source 0

hello 424128933,

there’s post-process involved, you may confirm the sensor capability with v4l2 standard controls.
for example,
I’ve Logitech C615 connected to my board, it report different frame-rate with different pixel formats.
for example,

$ v4l2-ctl -d /dev/video0 --list-formats-ext
        Pixel Format: 'YUYV'
                Size: Discrete 1920x1080
                        Interval: Discrete 0.200s (5.000 fps)

        Pixel Format: 'MJPG' (compressed)
                Size: Discrete 1920x1080
                        Interval: Discrete 0.033s (30.000 fps)

you may refer to Applications Using V4L2 IOCTL Directly, please enable V4L2 IOCTL to verify basic functionality.
for example,

$ v4l2-ctl -d /dev/video0 --set-fmt-video=width=1920,height=1080,pixelformat=YUYV --stream-mmap --stream-count=100
<<<<<<< 5.04 fps
$ v4l2-ctl -d /dev/video0 --set-fmt-video=width=1920,height=1080,pixelformat=MJPG --stream-mmap --stream-count=100
<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< 30.09 fps

hei bro, how u mesure the fps of inference, i get the strange frame rate. 0.000122, ` t=cv2.getTickCount()
while l_frame is not None:
# Note that needs a cast to pyds.NvDsFrameMeta
# The casting is done by pyds.NvDsFrameMeta.cast()
# The casting also keeps ownership of the underlying memory
# in the C code, so the Python garbage collector will leave
# it alone.
frame_meta = pyds.NvDsFrameMeta.cast(
except StopIteration:
#frame_number = frame_meta.frame_num
#num_rects = frame_meta.num_obj_meta

    #excute time
    t = (cv2.getTickCount() -t)/cv2.getTickFrequency()
    fps = 1.0/t
    print("fps: ", fps)
    display_meta.num_lines = 17
    line_params = display_meta.line_params
    #obj_index = 0
    line_index = 0

    while l_obj is not None:
        obj_meta =  pyds.NvDsObjectMeta.cast(
        for i in range(17):
            if cocopair[i][0]==obj_meta.class_id:
                temp = l_obj
                while temp is not None:
                    temp_meta = pyds.NvDsObjectMeta.cast(
                    if temp_meta.class_id == cocopair[i][1]:                   
                        line_params[line_index].x1 = int(obj_meta.rect_params.left)
                        line_params[line_index].y1 = int(
                        line_params[line_index].x2 = int(temp_meta.rect_params.left)
                        line_params[line_index].y2 = int( 
                        line_params[line_index].line_color.set(1.0, 0, 0, 0.5)
                        line_params[line_index].line_width = 4
        print("Keypoint x: {} y: {}".format(obj_meta.rect_params.left,
    pyds.nvds_add_display_meta_to_frame(frame_meta, display_meta)
    except StopIteration:

result is like this
Keypoint x: 907.8261108398438 y: 325.7608642578125
Keypoint x: 688.6956787109375 y: 303.75
Keypoint x: 597.3912963867188 y: 444.61956787109375
Keypoint x: 550.4347534179688 y: 495.978271484375
Keypoint x: 871.3043212890625 y: 176.0869598388672
Frame rate: 0.00013409874654609738
fps: 0.00013409804647469305

and the camera got just 20fps