5

I'm using parallel python to run multiple dynamic simulations using a module called OrcFxAPI. The program works perfectly if it is run as a python program on my machine however if I convert it to an exe file using py2exe and then run I get the following error:

Traceback (most recent call last):
    File "Analysis.pyc", Line 500, in multiprocessor
    File "pp.pyc", Line 342, in __init__
    File "pp.pyc", Line 506, in set_ncpus
    File "pp.pyc", Line 140, in __init__
    File "pp.pyc", Line 152, in start
    File "pptransport.pyc", Line 140, in receive
RuntimeError: Communication pipe read error

It is failing at this line in my program:

job_server = pp.Server(ppservers=ppservers)

but I think it might be something to do with the path used to import the OrcFxAPI module when submitting the job:

job = job_server.submit(max_seastate, (gui_vars, case_list, case, line_info, output_vars), (), ("OrcFxAPI",), callback=finished, callbackargs=(case_no, no_of_cases,))
Raphael
  • 959
  • 7
  • 21
Gareth Fuller
  • 328
  • 2
  • 12
  • Did you try to use PyInstaller instead of Py2Exe? Py2Exe seems to be outdated if I'm not mistaken [read more](https://stackoverflow.com/questions/6235123/python-executables-py2exe-or-pyinstaller) – Raphael Nov 09 '19 at 00:30

0 Answers0