Skip to content
Permalink
Browse files

feat(parser): add ctrl_with_ipc to cli

  • Loading branch information...
hanxiao committed Oct 15, 2019
1 parent 38147fe commit 02941b6c6e28ba3b5f392937cb6c03ac6f6774b7
Showing with 3 additions and 1 deletion.
  1. +2 −0 gnes/cli/parser.py
  2. +1 −1 gnes/service/base.py
@@ -202,6 +202,8 @@ def set_service_parser(parser=None):
parser.add_argument('--squeeze_pb', action=ActionNoYes, default=True,
help='sending bytes and ndarray separately apart from the protobuf message, '
'usually yields better network efficiency')
parser.add_argument('--ctrl_with_ipc', action='store_true', default=False,
help='use ipc protocol for control socket')
return parser


@@ -346,7 +346,7 @@ def __init__(self, args):
self.last_dump_time = time.perf_counter()
self._model = None
self.use_event_loop = True
self.ctrl_with_ipc = (os.name != 'nt')
self.ctrl_with_ipc = (os.name != 'nt') and self.args.ctrl_with_ipc
if self.ctrl_with_ipc:
self.ctrl_addr = get_random_ipc()
else:

0 comments on commit 02941b6

Please sign in to comment.
You can’t perform that action at this time.