+ findcurve_epsilon = dist_pq_plane * 0.01
+
+ if findcurve_subproc is None:
+ findcurve_subproc = subprocess.Popen(
+ ['./findcurve'],
+ bufsize=1,
+ stdin=subprocess.PIPE,
+ stdout=subprocess.PIPE,
+ stderr=None,
+ close_fds=False,
+ restore_signals=True,
+ universal_newlines=True,
+ )
+
+ findcurve_input = np.hstack((findcurve_target,
+ findcurve_start,
+ [findcurve_epsilon])))
+ dbg('RUNNING FINDCURVE', *findcurve_input)
+ print(findcurve_subproc.stdin, *findcurve_input)
+ findcurve_subproc.stdin.flush()
+
+ while True:
+ l = findcurve_subproc.stdout.readline()
+ l = l.rstrip()
+ dbg('GOT ', l)
+ l = eval(l)
+ if l is None: break
+ findcurve_result = l[0:5]
+