meso-unimpressed / darknet-net

A fork of darknet that is able to send detection data out via osc and websockets.
http://meso.design
Other
7 stars 1 forks source link

Segmentation fault when launching simple example #8

Closed artynet closed 5 years ago

artynet commented 5 years ago

I am getting this error when launching the simplest example with :

$ ./darknet detector demo cfg/voc.data cfg/yolo-voc.cfg yolo-voc.weights -c 1 -address 

the stdout returns :

"ws://localhost" -port 8080
videoPath:./output.avi, namedPipe:0, writeVideo:0, showWindow:0
using comm protocol ws
address:ws://localhost, port:8080 
setting up ws
ws onerror: (-2): Could connect to any address returned by getaddrinfo
comm setup done
Segmentation error (core dump created)

I am running a system with Ubuntu 18.10, Nvidia GeForce GTX 1050Ti, and CUDA SDK 10.1. The same error happens on a default Jetson TX2 standard setup.

this executable should be working together with this node package :

https://github.com/moovel/lab-opendatacam

but it isn't since the node hook here is calling the first command line. Any hints ?

timonsku commented 5 years ago

Likely because it can not connect to the websocket server provided. In this case you provided none and it defaulted to localhost. Then it threw an error: ws onerror: (-2): Could connect to any address returned by getaddrinfo

The error handling could be better here, it should throw an exception instead of continuing and then segfaulting due to the missing connection.

timonsku commented 5 years ago

I added a some error handling for this case. It now exits gracefully instead of segfaulting.