Hi!
I am having the exact same issue!
When trying to reintialize the server by sending another "initialize"-message, the server immediately terminates the communication with the client. I have tried several trackers and they behave identical in that respect.
When I look into the code of the trackers, I can completely understand why this happens. Here is an excerpt of the critical section which (from my point of view) causes the issue:
handle = vot.VOT("rectangle") # handles the first "initialize"-message
selection = handle.region()
imagefile = handle.frame()
p = p_config()
image = cv2.cvtColor(cv2.imread(imagefile), cv2.COLOR_BGR2RGB)
tracker = SomeTracker(image, selection, p=p) # creates tracker object with image and region of "initialize" message.
while True: # in this loop the "frame"-messages are handled.
imagefile = handle.frame()
if not imagefile:
break
image = cv2.cvtColor(cv2.imread(imagefile), cv2.COLOR_BGR2RGB)
region, confidence = tracker.tracking(image)
handle.report(region, confidence)
As you can see, after receiving the first "initialize"-message the trackes goes into an infinite loop to handle the "frame" messages. I can't see in this code how/where a second "initialize"-message would be handled.
In the call "handle.frame" there is a check for the type of message. In case of the reception of an "initialize"-message this call returns "None" - which will then result in the "break" to be executed. And that will terminate the tracker-Server process.
Could somebody please give a hint on how this code is supposed to handle secondary "initialize" messages?
Best regards and many thanks!