How make inference with Basler camera


I am trying make inference with a Basler acA5472-17UC using the examples of this repository

Moreover, i have installed all the required drivers from pypylon repsitory and the camera works ok

I just need make inference with pretrained models using the basler but i don’t know how get it. Could someone share with me how to get it?


Jetson-inference use GStreamer for the camera input.
Would you mind to check if your camera can be opened with GStreamer first?

We found several GStreamer plugin for basler.
But we don’t have a basler camera to verify on our side.


You can use and adopt deepstream-test2 example for this one.

I have been trying both solution but i think i am not understanding what should I do.
I can use the examples of pypylon repository like this

And the basler works fine. The problem is the format of the image because jetson-inference expect RGBA images in a ppycapsule format and then, when I want reverse the process the image is printed in white color.

It would ne great if i can make inference with camera = jetson.utils.gstCamera(1280, 720, “/dev/video0”) or something like that but it do nothing and It’s crashing my jetson.
I can see my basler camera with lsusb but it doesn’t appear with v4l2-ctl --list-formats-ext.
In fact with this last comand i can see

Index       : 0
	Type        : Video Capture
	Pixel Format: 'BG10'
	Name        : 10-bit Bayer BGBG/GRGR
		Size: Discrete 2592x1944
			Interval: Discrete 0.033s (30.000 fps)
		Size: Discrete 2592x1458
			Interval: Discrete 0.033s (30.000 fps)
		Size: Discrete 1280x720
			Interval: Discrete 0.008s (120.000 fps)

which make me think this is the wecam integrated on my jetson

Finally I solved the problem

Anyway i would like know whether exist a way of make it works with something silimar to

camera = jetson.utils.gstCamera(1280, 720, "/dev/video0")

I think this is the best way

Hi camprosromeromiguel, unless Basler camera provides V4L2 interface (e.g. /dev/video* device), I don’t think it’s possible. The Basler cameras seemed to be accessed through the Pylon library they use.