gstpylonsrc.c : Error in the image processing loop
Opened this issue · 11 comments
I am using gst-pylonsrc for streaming Basler 1920 40 gm camera. I have added pylonsrc element and streaming video successfully. But after few min/few seconds stream stops and getting the following error.
"Error in the image processing loop"
I found that this error is coming when the grabresult is equal to failed even for single frame.
I want to skip this error and need to stream video continuously without any errors.
(Sometimes camera will stream for an hour and then throwing the error, and sometimes this happen within few seconds also.)
Kindly help me .
It's interesting that it fails to grab the frame. Have you tried debugging it by adding GST_DEBUG=*:5
in front of the gst-launch-1.0 command and seeing if there's anything interesting there?
Either way, to achieve what want you will need to modify the source file (gstpylonsrc.c) and recompile the plugin.
One option would be to simply replace the line at
gst-pylonsrc/plugins/gstpylonsrc.c
Line 2101 in 2073177
return GST_FLOW_OK;
, but I'm not quite sure how other gstreamer plugins will react if they receive an empty buffer.
A better alternative would be to set a label (syntax - name:
) earlier in the function (like line 2056) and replace this line with a goto to this label (goto name;
) so that it just pulls a new frame instead. You will probably need to add
gst-pylonsrc/plugins/gstpylonsrc.c
Line 2097 in 2073177
Sadly I no longer have access to Basler cameras and I can't really test it myself.
FYI if it helps, when I use GStreamer & pylon together, I use pylon's GrabStrategy_LatestImageOnly and try to set the framerate of the camera faster than what my pipeline needs. That way, the camera is always acquiring and transmitting, and Pylon is only holding the most recent image for retrieval. When the next one comes in, if the previous hasn't been retrieved it's just overwritten in memory. This can kind of give the best of both worlds (ignore the error and run with no errors is actually mutually exclusive :)) - if I'm acquiring at 60fps and running my pipeline at 30fps, then if I come across a bad image, I can log the error and hopefully the next good image comes in before the pipeline actually requests it.
Thanks for the reply.
I modified the code as below. seems like issue is fixed.
if(grabResult.Status == Grabbed) {
//TODO: See if I can avoid memcopy and record directly into the gst buffer map.
// Copy the image into the buffer that will be passed onto the next GStreamer element
*buf = gst_buffer_new_and_alloc(pylonsrc->payloadSize);
gst_buffer_map(*buf, &mapInfo, GST_MAP_WRITE);
orc_memcpy(mapInfo.data, grabResult.pBuffer, mapInfo.size);
gst_buffer_unmap(*buf, &mapInfo);
// Release frame's memory
res = PylonStreamGrabberQueueBuffer( pylonsrc->streamGrabber, grabResult.hBuffer, (void*) bufferIndex );
PYLONC_CHECK_ERROR(pylonsrc, res);
// Set frame offset
GST_BUFFER_OFFSET(*buf) = pylonsrc->frameNumber;
pylonsrc->frameNumber += 1;
GST_BUFFER_OFFSET_END(*buf) = pylonsrc->frameNumber;
} else if ( grabResult.Status == Failed ){
GST_ERROR_OBJECT(pylonsrc, "Error in the image processing loop.");
*buf = gst_buffer_new_and_alloc(pylonsrc->payloadSize);
gst_buffer_map(*buf, &mapInfo, GST_MAP_WRITE);
orc_memcpy(mapInfo.data, grabResult.pBuffer, mapInfo.size);
gst_buffer_unmap(*buf, &mapInfo);
// Release frame's memory
res = PylonStreamGrabberQueueBuffer( pylonsrc->streamGrabber, grabResult.hBuffer, (void*) bufferIndex );
PYLONC_CHECK_ERROR(pylonsrc, res);
// Set frame offset
GST_BUFFER_OFFSET(*buf) = pylonsrc->frameNumber;
GST_BUFFER_OFFSET_END(*buf) = pylonsrc->frameNumber;
}
Actually I could not find the grab strategy currently using in pylonsrc. How can I set the grabbing strategy?
Thanks very much.
Hi all,
Please see the gst pipeline I am using for streaming Basler camera,
GST_DEBUG=pylonsrc:5 gst-launch-1.0 -v pylonsrc height=720 width=1280 fps=25 imageformat=mono8 ! videoconvert ! video/x-raw,format=BGR ! videoconvert ! autovideosink
with this I am able to stream vidoe successfully. But I want to feed the video frames to my application for further processing (using appsink _pylonsrc height=720 width=1280 fps=25 imageformat=mono8 ! videoconvert ! video/x-raw,format=BGR ! appsink max-buffers=5 drop=1 ).But its not working ,it seems like application is not receiving video frames at all. I can see few warning messages in the log. attaching the log below:
chevron@chevron-desktop:~/live$ GST_DEBUG=pylonsrc:5 gst-launch-1.0 -v pylonsrc height=720 width=1280 fps=25 imageformat=mono8 ! videoconvert ! video/x-raw,format=BGR ! videoconvert ! autovideosink
0:00:00.029706852 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:397:gst_pylonsrc_init:<GstPylonsrc@0x561cc1c518e0> Initialising defaults
0:00:00.029764255 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:477:gst_pylonsrc_set_property:<pylonsrc0> Setting a property.
0:00:00.029799369 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:477:gst_pylonsrc_set_property:<pylonsrc0> Setting a property.
0:00:00.029837221 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:477:gst_pylonsrc_set_property:<pylonsrc0> Setting a property.
0:00:00.029854555 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:477:gst_pylonsrc_set_property:<pylonsrc0> Setting a property.
0:00:00.031227094 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:871:gst_pylonsrc_get_caps:<pylonsrc0> Received a request for caps.
0:00:00.031239356 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:873:gst_pylonsrc_get_caps:<pylonsrc0> Could not send caps - no camera connected.
0:00:00.032089216 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:871:gst_pylonsrc_get_caps:<pylonsrc0> Received a request for caps.
0:00:00.032099055 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:873:gst_pylonsrc_get_caps:<pylonsrc0> Could not send caps - no camera connected.
0:00:00.032999994 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:871:gst_pylonsrc_get_caps:<pylonsrc0> Received a request for caps.
0:00:00.033010432 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:873:gst_pylonsrc_get_caps:<pylonsrc0> Could not send caps - no camera connected.
0:00:00.033841967 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:871:gst_pylonsrc_get_caps:<pylonsrc0> Received a request for caps.
0:00:00.033851298 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:873:gst_pylonsrc_get_caps:<pylonsrc0> Could not send caps - no camera connected.
0:00:00.035556670 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:871:gst_pylonsrc_get_caps:<pylonsrc0> Received a request for caps.
0:00:00.035567870 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:873:gst_pylonsrc_get_caps:<pylonsrc0> Could not send caps - no camera connected.
0:00:00.037238205 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:871:gst_pylonsrc_get_caps:<pylonsrc0> Received a request for caps.
0:00:00.037247912 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:873:gst_pylonsrc_get_caps:<pylonsrc0> Could not send caps - no camera connected.
0:00:00.038153616 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:871:gst_pylonsrc_get_caps:<pylonsrc0> Received a request for caps.
0:00:00.038163139 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:873:gst_pylonsrc_get_caps:<pylonsrc0> Could not send caps - no camera connected.
Setting pipeline to PAUSED ...
0:00:00.299778583 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:953:gst_pylonsrc_start:<pylonsrc0> pylonsrc: found 1 Basler device(s).
0:00:00.299841045 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:2198:pylonc_connect_camera:<pylonsrc0> Connecting to the camera...
0:00:00.709894608 454 0x561cc1c2eac0 pylonsrc gstpylonsrc.c:2243:pylonc_print_camera_info:<pylonsrc0> Status: Using camera "acA1920-40gm" (serial number: 0, id: 0). Custom ID: None
0:00:00.714194329 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:1064:gst_pylonsrc_start:<pylonsrc0> Max resolution is 1936x1216.
0:00:00.719126222 454 0x561cc1c2eac0 pylonsrc gstpylonsrc.c:1093:gst_pylonsrc_start:<pylonsrc0> Setting resolution to 1280x720.
0:00:00.724120310 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:1111:gst_pylonsrc_start:<pylonsrc0> Centering X: False, Centering Y: False.
0:00:00.726741083 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:1157:gst_pylonsrc_start:<pylonsrc0> Flipping X: False, Flipping Y: False.
0:00:00.727963224 454 0x561cc1c2eac0 pylonsrc gstpylonsrc.c:1217:gst_pylonsrc_start:<pylonsrc0> Using Mono8 image format.
0:00:00.731420001 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:1228:gst_pylonsrc_start:<pylonsrc0> Pixel is 8 bits large.
0:00:00.733565240 454 0x561cc1c2eac0 WARN pylonsrc gstpylonsrc.c:1269:gst_pylonsrc_start:<pylonsrc0> Camera does not support changing the readout mode.
0:00:00.733624418 454 0x561cc1c2eac0 WARN pylonsrc gstpylonsrc.c:1284:gst_pylonsrc_start:<pylonsrc0> Camera does not support disabling the throughput limit.
0:00:00.733676064 454 0x561cc1c2eac0 WARN pylonsrc gstpylonsrc.c:1299:gst_pylonsrc_start:<pylonsrc0> Camera does not support changing the throughput limit.
0:00:00.735001973 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:1313:gst_pylonsrc_start:<pylonsrc0> Enabled custom framerate limiter. See below for current framerate.
0:00:00.735048279 454 0x561cc1c2eac0 WARN pylonsrc gstpylonsrc.c:1350:gst_pylonsrc_start:<pylonsrc0> This camera doesn't have any lightsource presets
0:00:00.736303914 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:1357:gst_pylonsrc_start:<pylonsrc0> Disabling automatic exposure.
0:00:00.738188303 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:1381:gst_pylonsrc_start:<pylonsrc0> Disabling automatic gain.
0:00:00.739650242 454 0x561cc1c2eac0 WARN pylonsrc gstpylonsrc.c:1422:gst_pylonsrc_start:<pylonsrc0> This camera doesn't support automatic white balance.
0:00:00.739684876 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:1493:gst_pylonsrc_start:<pylonsrc0> Using the auto profile currently saved on the device.
0:00:00.743299402 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:1664:gst_pylonsrc_start:<pylonsrc0> This camera doesn't support adjusting colours. Skipping...
0:00:00.748142850 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:1786:gst_pylonsrc_start:<pylonsrc0> This camera doesn't support transforming colours. Skipping...
0:00:00.748213002 454 0x561cc1c2eac0 WARN pylonsrc gstpylonsrc.c:1803:gst_pylonsrc_start:<pylonsrc0> This camera doesn't support setting manual exposure.
0:00:00.748253287 454 0x561cc1c2eac0 WARN pylonsrc gstpylonsrc.c:1816:gst_pylonsrc_start:<pylonsrc0> This camera doesn't support setting manual gain.
0:00:00.748286853 454 0x561cc1c2eac0 WARN pylonsrc gstpylonsrc.c:1825:gst_pylonsrc_start:<pylonsrc0> This camera doesn't support setting black level.
0:00:00.748974170 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:1830:gst_pylonsrc_start:<pylonsrc0> Setting gamma to 1.00
0:00:00.752944772 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:1874:gst_pylonsrc_start:<pylonsrc0> Basler's PGI is not supported. Skipping.
0:00:00.752985511 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:1878:gst_pylonsrc_start:<pylonsrc0> Setting trigger mode.
0:00:00.758807385 454 0x561cc1c2eac0 DEBUG pylonsrc gstpylonsrc.c:1922:gst_pylonsrc_start:<pylonsrc0> Using "FrameStart" trigger selector. Software trigger mode is Off.
0:00:00.772015746 454 0x561cc1c2eac0 WARN pylonsrc gstpylonsrc.c:2003:gst_pylonsrc_start:<pylonsrc0> Couldn't determine link speed.
0:00:00.772075465 454 0x561cc1c2eac0 WARN pylonsrc gstpylonsrc.c:2015:gst_pylonsrc_start:<pylonsrc0> Couldn't determine sensor readout time.
0:00:00.772115774 454 0x561cc1c2eac0 WARN pylonsrc gstpylonsrc.c:2028:gst_pylonsrc_start:<pylonsrc0> Couldn't determine the resulting framerate.
0:00:00.773114811 454 0x561cc1c2eac0 pylonsrc gstpylonsrc.c:2040:gst_pylonsrc_start:<pylonsrc0> Initialised successfully.
Pipeline is live and does not need PREROLL ...
0:00:00.773790647 454 0x561cc1c5fd90 DEBUG pylonsrc gstpylonsrc.c:871:gst_pylonsrc_get_caps:<pylonsrc0> Received a request for caps.
0:00:00.773874700 454 0x561cc1c5fd90 DEBUG pylonsrc gstpylonsrc.c:910:gst_pylonsrc_get_caps:<pylonsrc0> The following caps were sent: video/x-raw, GRAY8, 1280x720, variable fps.
Setting pipeline to PLAYING ...
New clock: GstSystemClock
0:00:00.775111169 454 0x561cc1c5fd90 DEBUG pylonsrc gstpylonsrc.c:921:gst_pylonsrc_set_caps:<pylonsrc0> Setting caps to video/x-raw, format=(string)GRAY8, width=(int)1280, height=(int)720, framerate=(fraction)0/1
/GstPipeline:pipeline0/GstPylonsrc:pylonsrc0.GstPad:src: caps = video/x-raw, format=(string)GRAY8, width=(int)1280, height=(int)720, framerate=(fraction)0/1
/GstPipeline:pipeline0/GstVideoConvert:videoconvert0.GstPad:src: caps = video/x-raw, width=(int)1280, height=(int)720, framerate=(fraction)0/1, format=(string)BGR
/GstPipeline:pipeline0/GstCapsFilter:capsfilter0.GstPad:src: caps = video/x-raw, width=(int)1280, height=(int)720, framerate=(fraction)0/1, format=(string)BGR
/GstPipeline:pipeline0/GstVideoConvert:videoconvert1.GstPad:src: caps = video/x-raw, width=(int)1280, height=(int)720, framerate=(fraction)0/1, format=(string)YV12
/GstPipeline:pipeline0/GstAutoVideoSink:autovideosink0.GstGhostPad:sink.GstProxyPad:proxypad0: caps = video/x-raw, width=(int)1280, height=(int)720, framerate=(fraction)0/1, format=(string)YV12
/GstPipeline:pipeline0/GstAutoVideoSink:autovideosink0/GstXvImageSink:autovideosink0-actual-sink-xvimage.GstPad:sink: caps = video/x-raw, width=(int)1280, height=(int)720, framerate=(fraction)0/1, format=(string)YV12
/GstPipeline:pipeline0/GstAutoVideoSink:autovideosink0.GstGhostPad:sink: caps = video/x-raw, width=(int)1280, height=(int)720, framerate=(fraction)0/1, format=(string)YV12
/GstPipeline:pipeline0/GstVideoConvert:videoconvert1.GstPad:sink: caps = video/x-raw, width=(int)1280, height=(int)720, framerate=(fraction)0/1, format=(string)BGR
/GstPipeline:pipeline0/GstCapsFilter:capsfilter0.GstPad:sink: caps = video/x-raw, width=(int)1280, height=(int)720, framerate=(fraction)0/1, format=(string)BGR
/GstPipeline:pipeline0/GstVideoConvert:videoconvert0.GstPad:sink: caps = video/x-raw, format=(string)GRAY8, width=(int)1280, height=(int)720, framerate=(fraction)0/1
I am totally unsure of what is going wrong. I hope you can guide me on this issue that I am facing. I really appreciate your help.
Code
It seems that you just copied the buffer copying code from the above block, at which point it was easier to just get rid of the if block altogether. The thing is, there's probably a reason why Pylon didn't mark the frame as grabbed, and you're probably getting incomplete frame there. That said, if it works for you, it's fine.
Actually I could not find the grab strategy currently using in pylonsrc. How can I set the grabbing strategy?
From what I can see in the docs GrabStrategy is a setting for the C++ API, while this plugin implements the C API. My guess the analogue would be to switch to trigger mode (continuous=false
) as it would explicitly request frames from the camera as opposed to copying the current frame in the camera's buffer.
Log
There doesn't seem to be anything wrong in the log. Is this log from a normal run?
Also a suggestion for the future, put all code and logs inbetween triple grave accents (```).
I.e.
```
something
/GstPipeline:pipeline0/GstAutoVideoSink:autovideosink0.GstGhostPad:sink: caps = video/x-raw, width=(int)1280, height=(int)720, framerate=(fraction)0/1, format=(string)YV12
something
```
becomes
something
/GstPipeline:pipeline0/GstAutoVideoSink:autovideosink0.GstGhostPad:sink: caps = video/x-raw, width=(int)1280, height=(int)720, framerate=(fraction)0/1, format=(string)YV12
something
This will make things slightly more readable as it doesn't wrap the lines.
Hi zingmars,
code
In else block I have omitted the line
pylonsrc->frameNumber += 1;
Log
What you mean by normal run? This log I generated by running the gst-launch-1.0 command.
I have to feed gstreamer pipeline (as below) to my application, which is not working.
pylonsrc height=720 width=1280 fps=25 imageformat=mono8 ! videoconvert ! video/x-raw,format=BGR ! appsink max-buffers=5 drop=1
Please let me know if you need anything else from me.
There doesn't seem to be anything that indicates an error in that log. In fact, the command you used for that log sent all output to autovideosink (which as I understand works for you) and not appskink. It's also a bit hard to tell what's going on with your appsink without knowing how you're pulling data and what's happening (is no data being buffered? can you even get GstSample out of it?). Tbf even then I'm not sure if I can help much with appsink, as we used this plugin to write to shared memory instead.
we used this plugin to write to shared memory instead.
Does this mean that pylonsrc plugin has limitations to use with appsink?
Camera: Basler acA1300-75gc
I do also have this error running:
GST_DEBUG=pylonsrc:5 gst-launch-1.0 -v \
pylonsrc continuous=false ! \
bayer2rgb ! \
videoconvert ! \
x264enc noise-reduction=10000 pass=4 quantizer=22 bitrate=32768 speed-preset=0 byte-stream=true tune="zerolatency" ! \
mpegtsmux ! \
tcpserversink port=8888
Error:
0:01:19.582882347 3385 0x5583ecf48590 ERROR pylonsrc gstpylonsrc.c:2100:gst_pylonsrc_create:<pylonsrc0> Error in the image processing loop.
BŁĄD: od elementu /GstPipeline:pipeline0/GstPylonsrc:pylonsrc0: Internal data stream error.
Dodatkowe informacje diagnostyczne:
gstbasesrc.c(3055): gst_base_src_loop (): /GstPipeline:pipeline0/GstPylonsrc:pylonsrc0:
streaming stopped, reason error (-5)
UPD: Adding height=480 width=640
causes no error.
UPD2: Adding height=720 width=1280
causes also no error.
UPD3: height=720 width=1280
still errors after some time.
Full output
0:00:00.015060193 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:477:gst_pylonsrc_set_property:<pylonsrc0> Setting a property.
0:00:00.017282033 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:871:gst_pylonsrc_get_caps:<pylonsrc0> Received a request for caps.
0:00:00.017289906 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:873:gst_pylonsrc_get_caps:<pylonsrc0> Could not send caps - no camera connected.
0:00:00.017313213 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:871:gst_pylonsrc_get_caps:<pylonsrc0> Received a request for caps.
0:00:00.017316646 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:873:gst_pylonsrc_get_caps:<pylonsrc0> Could not send caps - no camera connected.
0:00:00.017336392 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:871:gst_pylonsrc_get_caps:<pylonsrc0> Received a request for caps.
0:00:00.017340337 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:873:gst_pylonsrc_get_caps:<pylonsrc0> Could not send caps - no camera connected.
0:00:00.017816227 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:871:gst_pylonsrc_get_caps:<pylonsrc0> Received a request for caps.
0:00:00.017820650 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:873:gst_pylonsrc_get_caps:<pylonsrc0> Could not send caps - no camera connected.
0:00:00.018254393 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:871:gst_pylonsrc_get_caps:<pylonsrc0> Received a request for caps.
0:00:00.018258704 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:873:gst_pylonsrc_get_caps:<pylonsrc0> Could not send caps - no camera connected.
0:00:00.018357013 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:871:gst_pylonsrc_get_caps:<pylonsrc0> Received a request for caps.
0:00:00.018361043 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:873:gst_pylonsrc_get_caps:<pylonsrc0> Could not send caps - no camera connected.
Ustawianie potoku na PAUZOWANIE...
0:00:00.273060743 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:953:gst_pylonsrc_start:<pylonsrc0> pylonsrc: found 1 Basler device(s).
0:00:00.273103149 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:2188:pylonc_connect_camera:<pylonsrc0> Connecting to the camera...
0:00:00.473368073 3385 0x5583ecf0d2c0 pylonsrc gstpylonsrc.c:2233:pylonc_print_camera_info:<pylonsrc0> Status: Using camera "acA1300-75gc" (serial number: 0, id: 0). Custom ID: None
0:00:00.477034939 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1064:gst_pylonsrc_start:<pylonsrc0> Max resolution is 1280x1024.
0:00:00.481273156 3385 0x5583ecf0d2c0 pylonsrc gstpylonsrc.c:1093:gst_pylonsrc_start:<pylonsrc0> Setting resolution to 1280x1024.
0:00:00.485881141 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1111:gst_pylonsrc_start:<pylonsrc0> Centering X: False, Centering Y: False.
0:00:00.488374367 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1157:gst_pylonsrc_start:<pylonsrc0> Flipping X: False, Flipping Y: False.
0:00:00.489560803 3385 0x5583ecf0d2c0 pylonsrc gstpylonsrc.c:1217:gst_pylonsrc_start:<pylonsrc0> Using BayerBG8 image format.
0:00:00.492192190 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1228:gst_pylonsrc_start:<pylonsrc0> Pixel is 8 bits large.
0:00:00.493892864 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1256:gst_pylonsrc_start:<pylonsrc0> Setting the sensor readout mode to normal.
0:00:00.494498153 3385 0x5583ecf0d2c0 WARN pylonsrc gstpylonsrc.c:1284:gst_pylonsrc_start:<pylonsrc0> Camera does not support disabling the throughput limit.
0:00:00.494505389 3385 0x5583ecf0d2c0 WARN pylonsrc gstpylonsrc.c:1299:gst_pylonsrc_start:<pylonsrc0> Camera does not support changing the throughput limit.
0:00:00.498893516 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1320:gst_pylonsrc_start:<pylonsrc0> Disabled custom framerate limiter.
0:00:00.498932364 3385 0x5583ecf0d2c0 WARN pylonsrc gstpylonsrc.c:1350:gst_pylonsrc_start:<pylonsrc0> This camera doesn't have any lightsource presets
0:00:00.500183630 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1357:gst_pylonsrc_start:<pylonsrc0> Disabling automatic exposure.
0:00:00.503408401 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1381:gst_pylonsrc_start:<pylonsrc0> Disabling automatic gain.
0:00:00.508993249 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1405:gst_pylonsrc_start:<pylonsrc0> Disabling automatic white balance.
0:00:00.509689683 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1493:gst_pylonsrc_start:<pylonsrc0> Using the auto profile currently saved on the device.
0:00:00.512860435 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1546:gst_pylonsrc_start:<pylonsrc0> Using saved colour red's hue.
0:00:00.512868480 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1556:gst_pylonsrc_start:<pylonsrc0> Using saved colour red's saturation.
0:00:00.512871710 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1567:gst_pylonsrc_start:<pylonsrc0> Using saved colour yellow's hue.
0:00:00.512874355 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1577:gst_pylonsrc_start:<pylonsrc0> Using saved colour yellow's saturation.
0:00:00.512876838 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1588:gst_pylonsrc_start:<pylonsrc0> Using saved colour green's hue.
0:00:00.512879386 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1598:gst_pylonsrc_start:<pylonsrc0> Using saved colour green's saturation.
0:00:00.512881854 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1609:gst_pylonsrc_start:<pylonsrc0> Using saved colour cyan's hue.
0:00:00.512884283 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1619:gst_pylonsrc_start:<pylonsrc0> Using saved colour cyan's saturation.
0:00:00.512886690 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1630:gst_pylonsrc_start:<pylonsrc0> Using saved colour blue's hue.
0:00:00.512889373 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1640:gst_pylonsrc_start:<pylonsrc0> Using saved colour blue's saturation.
0:00:00.512893010 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1651:gst_pylonsrc_start:<pylonsrc0> Using saved colour magenta's hue.
0:00:00.512896200 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1661:gst_pylonsrc_start:<pylonsrc0> Using saved colour magenta's saturation.
0:00:00.517760135 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1695:gst_pylonsrc_start:<pylonsrc0> Using saved Gain00 transformation value.
0:00:00.517806350 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1706:gst_pylonsrc_start:<pylonsrc0> Using saved Gain01 transformation value.
0:00:00.517813720 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1717:gst_pylonsrc_start:<pylonsrc0> Using saved Gain02 transformation value.
0:00:00.517816556 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1728:gst_pylonsrc_start:<pylonsrc0> Using saved Gain10 transformation value.
0:00:00.517821924 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1739:gst_pylonsrc_start:<pylonsrc0> Using saved Gain11 transformation value.
0:00:00.517824713 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1750:gst_pylonsrc_start:<pylonsrc0> Using saved Gain12 transformation value.
0:00:00.517829234 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1761:gst_pylonsrc_start:<pylonsrc0> Using saved Gain20 transformation value.
0:00:00.517833589 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1772:gst_pylonsrc_start:<pylonsrc0> Using saved Gain21 transformation value.
0:00:00.517838167 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1783:gst_pylonsrc_start:<pylonsrc0> Using saved Gain22 transformation value.
0:00:00.517877955 3385 0x5583ecf0d2c0 WARN pylonsrc gstpylonsrc.c:1803:gst_pylonsrc_start:<pylonsrc0> This camera doesn't support setting manual exposure.
0:00:00.517887724 3385 0x5583ecf0d2c0 WARN pylonsrc gstpylonsrc.c:1816:gst_pylonsrc_start:<pylonsrc0> This camera doesn't support setting manual gain.
0:00:00.517893073 3385 0x5583ecf0d2c0 WARN pylonsrc gstpylonsrc.c:1825:gst_pylonsrc_start:<pylonsrc0> This camera doesn't support setting black level.
0:00:00.518667604 3385 0x5583ecf0d2c0 WARN pylonsrc gstpylonsrc.c:1834:gst_pylonsrc_start:<pylonsrc0> This camera doesn't support setting gamma values.
0:00:00.519954039 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1871:gst_pylonsrc_start:<pylonsrc0> Usage of PGI is not permitted with bayer output. Skipping.
0:00:00.519983809 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1878:gst_pylonsrc_start:<pylonsrc0> Setting trigger mode.
0:00:00.537937251 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:1922:gst_pylonsrc_start:<pylonsrc0> Using "FrameStart" trigger selector. Software trigger mode is On.
0:00:00.552930310 3385 0x5583ecf0d2c0 WARN pylonsrc gstpylonsrc.c:2003:gst_pylonsrc_start:<pylonsrc0> Couldn't determine link speed.
0:00:00.552994677 3385 0x5583ecf0d2c0 WARN pylonsrc gstpylonsrc.c:2015:gst_pylonsrc_start:<pylonsrc0> Couldn't determine sensor readout time.
0:00:00.553025127 3385 0x5583ecf0d2c0 WARN pylonsrc gstpylonsrc.c:2028:gst_pylonsrc_start:<pylonsrc0> Couldn't determine the resulting framerate.
0:00:00.555551939 3385 0x5583ecf0d2c0 pylonsrc gstpylonsrc.c:2040:gst_pylonsrc_start:<pylonsrc0> Initialised successfully.
Potok jest na żywo i nie wymaga PRZEWINIĘCIA...
/GstPipeline:pipeline0/GstTCPServerSink:tcpserversink0: current-port = 8888
0:00:00.555731864 3385 0x5583ecf48590 DEBUG pylonsrc gstpylonsrc.c:871:gst_pylonsrc_get_caps:<pylonsrc0> Received a request for caps.
0:00:00.555810807 3385 0x5583ecf48590 DEBUG pylonsrc gstpylonsrc.c:910:gst_pylonsrc_get_caps:<pylonsrc0> The following caps were sent: video/x-bayer, bggr, 1280x1024, variable fps.
Ustawianie potoku na ODTWARZANIE...
New clock: GstSystemClock
0:00:00.556138586 3385 0x5583ecf48590 DEBUG pylonsrc gstpylonsrc.c:921:gst_pylonsrc_set_caps:<pylonsrc0> Setting caps to video/x-bayer, format=(string)bggr, width=(int)1280, height=(int)1024, framerate=(fraction)0/1
/GstPipeline:pipeline0/GstPylonsrc:pylonsrc0.GstPad:src: caps = video/x-bayer, format=(string)bggr, width=(int)1280, height=(int)1024, framerate=(fraction)0/1
/GstPipeline:pipeline0/GstBayer2RGB:bayer2rgb0.GstPad:src: caps = video/x-raw, width=(int)1280, height=(int)1024, framerate=(fraction)0/1, format=(string)RGBx
/GstPipeline:pipeline0/GstVideoConvert:videoconvert0.GstPad:src: caps = video/x-raw, width=(int)1280, height=(int)1024, framerate=(fraction)0/1, format=(string)Y444
Rozprzestrzenianie opóźnień...
/GstPipeline:pipeline0/GstX264Enc:x264enc0.GstPad:sink: caps = video/x-raw, width=(int)1280, height=(int)1024, framerate=(fraction)0/1, format=(string)Y444
/GstPipeline:pipeline0/GstVideoConvert:videoconvert0.GstPad:sink: caps = video/x-raw, width=(int)1280, height=(int)1024, framerate=(fraction)0/1, format=(string)RGBx
/GstPipeline:pipeline0/GstBayer2RGB:bayer2rgb0.GstPad:sink: caps = video/x-bayer, format=(string)bggr, width=(int)1280, height=(int)1024, framerate=(fraction)0/1
/GstPipeline:pipeline0/GstX264Enc:x264enc0.GstPad:src: caps = video/x-h264, stream-format=(string)byte-stream, alignment=(string)au, level=(string)3.2, profile=(string)high-4:4:4, width=(int)1280, height=(int)1024, pixel-aspect-ratio=(fraction)1/1, framerate=(fraction)0/1, interlace-mode=(string)progressive, colorimetry=(string)bt709, chroma-site=(string)mpeg2
/GstPipeline:pipeline0/MpegTsMux:mpegtsmux0.GstPad:sink_65: caps = video/x-h264, stream-format=(string)byte-stream, alignment=(string)au, level=(string)3.2, profile=(string)high-4:4:4, width=(int)1280, height=(int)1024, pixel-aspect-ratio=(fraction)1/1, framerate=(fraction)0/1, interlace-mode=(string)progressive, colorimetry=(string)bt709, chroma-site=(string)mpeg2
/GstPipeline:pipeline0/MpegTsMux:mpegtsmux0.GstPad:src: caps = video/mpegts, systemstream=(boolean)true, packetsize=(int)188
/GstPipeline:pipeline0/GstTCPServerSink:tcpserversink0.GstPad:sink: caps = video/mpegts, systemstream=(boolean)true, packetsize=(int)188
/GstPipeline:pipeline0/MpegTsMux:mpegtsmux0.GstPad:src: caps = video/mpegts, systemstream=(boolean)true, packetsize=(int)188, streamheader=(buffer)< 47400030a600ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000b00d0001c100000001e020a2c32941, 474020308b00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0002b0280001c10000e041f00c050448444d5688040ffffcfc1be041f00a050848444d56ff1b443f5a3175c0 >
/GstPipeline:pipeline0/GstTCPServerSink:tcpserversink0.GstPad:sink: caps = video/mpegts, systemstream=(boolean)true, packetsize=(int)188, streamheader=(buffer)< 47400030a600ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000b00d0001c100000001e020a2c32941, 474020308b00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0002b0280001c10000e041f00c050448444d5688040ffffcfc1be041f00a050848444d56ff1b443f5a3175c0 >
0:01:19.582882347 3385 0x5583ecf48590 ERROR pylonsrc gstpylonsrc.c:2100:gst_pylonsrc_create:<pylonsrc0> Error in the image processing loop.
BŁĄD: od elementu /GstPipeline:pipeline0/GstPylonsrc:pylonsrc0: Internal data stream error.
Dodatkowe informacje diagnostyczne:
gstbasesrc.c(3055): gst_base_src_loop (): /GstPipeline:pipeline0/GstPylonsrc:pylonsrc0:
streaming stopped, reason error (-5)
Execution ended after 0:01:19.027259694
Ustawianie potoku na PAUZOWANIE...
Ustawianie potoku na GOTOWOŚĆ...
0:01:19.633256663 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:2118:gst_pylonsrc_stop:<pylonsrc0> stop
0:01:19.644673865 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:2164:pylonc_disconnect_camera:<pylonsrc0> Camera disconnected.
Ustawianie potoku na NULL...
Zwalnianie potoku...
0:01:19.645409035 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:2129:gst_pylonsrc_dispose:<pylonsrc0> dispose
0:01:19.645417914 3385 0x5583ecf0d2c0 DEBUG pylonsrc gstpylonsrc.c:2137:gst_pylonsrc_finalize:<pylonsrc0> finalize
I've merged pylonsrc into gst-plugins-vision, and have been making some modifications including more comprehensive pixel format support, GStreamer caps negotiation instead of manually setting imageformat
, removed the mempcy by wrapping buffers, but I have been seeing this same error reported here.
As best I can tell, the Grabbed
result indicates the entire frame was received without errors. If there's any corruption in the image, the result will be Failed
, even if most of the image was copied successfully. I can make this problem worse by reducing the packet size on my network adapter.
I'm thinking the best way to handle this is to have a property that will continue grabbing frames even if one is corrupted, and maybe another property that determines whether to pass or drop the corrupted frame.
I created a new issue on gst-plugins-vision for anyone who wants to give input.