fix: wait for process obsdata (p.wait())

This commit is contained in:
Marcel Paffrath 2016-08-04 10:35:09 +02:00
parent 471cfe755b
commit 3efb237452

View File

@ -50,13 +50,14 @@ class Tomo3d(object):
def buildObsdata(self): def buildObsdata(self):
p = subprocess.Popen(os.path.join(self.cwd, 'obsdata'), shell=True) p = subprocess.Popen(os.path.join(self.cwd, 'obsdata'), shell=True)
os.waitpid(p.pid) p.wait()
os.system('mv sources.in sourcesref.in') os.system('mv sources.in sourcesref.in')
def defFMMParas(self): def defFMMParas(self):
''' '''
Initiates parameters for the forward calculation. Initiates parameters for the forward calculation.
''' '''
# Comments coppied from FMTOMO.
# Name of fast marching program # Name of fast marching program
self.fmm = os.path.join(self.cwd, 'fm3d') self.fmm = os.path.join(self.cwd, 'fm3d')
# Name of program calculating Frechet derivatives # Name of program calculating Frechet derivatives