def _run_monitor_thread(self):
        """Background task to collect output from the child process.

        This is primarily necessary to keep the child process from hanging,
        which would occur if it produces too much output that the current
        process doesn't read, but the collected output is also made available
        for convenience.
        """
        while True:
            chunk = self.stream.read(1024)
            if not chunk:
                # EOF - subprocess has exited, so trigger shutdown
                trigger_exit(ExitMode.CHILD)
                break
            self.output_deque.appendleft(chunk)
Background task to collect output from the child process.

        This is primarily necessary to keep the child process from hanging,
        which would occur if it produces too much output that the current
        process doesn't read, but the collected output is also made available
        for convenience.
        
fiftyone/service/main.py