Exemple #1
0
import Globals
import PhaseSpace
import Writer
import TestResults
from pybdsim import Writer as _pybdsimWriter
from pybdsim import Options as _options

# data type with multiple entries that can be handled by the functions.
multiEntryTypes = [tuple, list, _np.ndarray]

GlobalData = Globals.Globals()

# result utility functions for checking output log files.
# Needed by Run function, so instantiate here.
ResultUtils = TestResults.ResultsUtilities()



def _runBDSIM(inputDict, timeout):

    # Start the BDSIM process
    process = Popen([GlobalData._bdsimExecutable,
                    "--file=" + inputDict['testFile'],
                    "--output=rootevent",
                    "--outfile="+inputDict['outputFile'],
                    "--batch",
                    "--seed=2017"],
                    stdout=open(inputDict['bdsimLogFile'], 'a'),
                    stderr=open(inputDict['bdsimLogFile'], 'a'))