mirror of
https://bitbucket.org/cosmicvoids/vide_public.git
synced 2025-07-05 07:41:11 +00:00
Merge branch 'master' of bitbucket.org:cosmicvoids/void_identification
This commit is contained in:
commit
33d0cfa302
8 changed files with 76 additions and 45 deletions
|
@ -286,7 +286,7 @@ int main(int argc, char **argv) {
|
||||||
rdist = catalog1.voids[iVoid1].matches[0].dist;
|
rdist = catalog1.voids[iVoid1].matches[0].dist;
|
||||||
rdist /= catalog1.voids[iVoid1].radius;
|
rdist /= catalog1.voids[iVoid1].radius;
|
||||||
|
|
||||||
fprintf(fp, "%d %.2f %.2f %.2f %.2f %.2f %d %d\n", voidID,
|
fprintf(fp, "%d %.4f %.4f %.4f %.4f %.4f %d %d\n", voidID,
|
||||||
catalog1.voids[iVoid1].radiusMpc,
|
catalog1.voids[iVoid1].radiusMpc,
|
||||||
rRatio,
|
rRatio,
|
||||||
commonVolRatio,
|
commonVolRatio,
|
||||||
|
|
|
@ -370,7 +370,7 @@ void buildBox(SimuData *simu, long num_targets, long loaded,
|
||||||
for (uint32_t i = 0; i < num_targets; i++, loaded++)
|
for (uint32_t i = 0; i < num_targets; i++, loaded++)
|
||||||
{
|
{
|
||||||
long pid = particle_id[loaded];
|
long pid = particle_id[loaded];
|
||||||
assert(pid < simu->NumPart);
|
//assert(pid < simu->NumPart);
|
||||||
assert(loaded < boxed->NumPart);
|
assert(loaded < boxed->NumPart);
|
||||||
|
|
||||||
for (int j = 0; j < 3; j++)
|
for (int j = 0; j < 3; j++)
|
||||||
|
@ -545,6 +545,7 @@ void makeBoxFromParameter(SimuData *simu, SimuData* &boxed, generateMock_info& a
|
||||||
}
|
}
|
||||||
boxed->NumPart = pid_write;
|
boxed->NumPart = pid_write;
|
||||||
delete preselect;
|
delete preselect;
|
||||||
|
cout << "Num accepted here = " << pid_write << " / input = " << pid_read << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
void makeBoxFromSimulation(SimulationLoader *loader, SimuData* &boxed, MetricFunctor metric, generateMock_info& args_info)
|
void makeBoxFromSimulation(SimulationLoader *loader, SimuData* &boxed, MetricFunctor metric, generateMock_info& args_info)
|
||||||
|
@ -713,6 +714,9 @@ int main(int argc, char **argv)
|
||||||
args_info.output_arg);
|
args_info.output_arg);
|
||||||
delete preselector;
|
delete preselector;
|
||||||
|
|
||||||
printf("Done!\n");
|
double subsample = 1.0;
|
||||||
|
if (args_info.subsample_given) subsample = args_info.subsample_arg;
|
||||||
|
if (args_info.resubsample_given) subsample = args_info.resubsample_arg;
|
||||||
|
printf("Done! %5.2e\n", subsample);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
|
@ -21,15 +21,23 @@
|
||||||
|
|
||||||
|
|
||||||
workDir = "/home/psutter2/workspace/Voids/"
|
workDir = "/home/psutter2/workspace/Voids/"
|
||||||
dataDir = "/home/psutter2/workspace/Voids/multidark/crossCompare/mergerTree/"
|
dataDir = "/home/psutter2/workspace/Voids/crossCompare/mergerTree/"
|
||||||
|
|
||||||
|
|
||||||
CTOOLS_PATH = "../../c_tools/"
|
CTOOLS_PATH = "../../c_tools/"
|
||||||
|
|
||||||
baseSampleDir = "multidark/md_ss0.000175/sample_md_ss0.000175_z0.56_d00/"
|
baseSampleDir = "multidark/md_ss0.05/sample_md_ss0.05_z0.56_d00/"
|
||||||
|
|
||||||
sampleDirList = [
|
sampleDirList = [
|
||||||
"multidark/md_ss0.0004/sample_md_ss0.0004_z0.56_d00/",
|
"multidark/md_ss1e-05/sample_md_ss1e-05_z0.56_d00/",
|
||||||
|
#"multidark/md_ss0.000175/sample_md_ss0.000175_z0.56_d00/",
|
||||||
|
#"multidark/md_ss0.0004/sample_md_ss0.0004_z0.56_d00/",
|
||||||
|
#"multidark/md_ss0.001/sample_md_ss0.001_z0.56_d00/",
|
||||||
|
#"multidark/md_ss0.002/sample_md_ss0.002_z0.56_d00/",
|
||||||
|
"multidark/md_ss0.01/sample_md_ss0.01_z0.56_d00/",
|
||||||
|
"multidark/md_hod_dr72dim2/sample_md_hod_dr72dim2_z0.56_d00/",
|
||||||
|
"multidark/md_hod_dr9mid/sample_md_hod_dr9mid_z0.56_d00/",
|
||||||
|
"multidark/md_halos_min1.2e+13/sample_md_halos_min1.2e+13_z0.56_d00/",
|
||||||
]
|
]
|
||||||
|
|
||||||
dataPortion = "central"
|
dataPortion = "central"
|
||||||
|
|
|
@ -63,6 +63,7 @@ for (iSample, sampleDir) in enumerate(sampleDirList):
|
||||||
sample = pickle.load(input)
|
sample = pickle.load(input)
|
||||||
|
|
||||||
print " Working with", sample.fullName, "...",
|
print " Working with", sample.fullName, "...",
|
||||||
|
sys.stdout.flush()
|
||||||
|
|
||||||
sampleName = sample.fullName
|
sampleName = sample.fullName
|
||||||
|
|
||||||
|
@ -72,11 +73,12 @@ for (iSample, sampleDir) in enumerate(sampleDirList):
|
||||||
sampleName + "_"
|
sampleName + "_"
|
||||||
#stepOutputFileName = os.getcwd()+"/data/overlap_"
|
#stepOutputFileName = os.getcwd()+"/data/overlap_"
|
||||||
|
|
||||||
launchVoidOverlap(baseSample, sample, workDir+baseSampleDir,
|
launchVoidOverlap(sample, baseSample, workDir+sampleDir,
|
||||||
workDir+sampleDir, binPath,
|
workDir+baseSampleDir, binPath,
|
||||||
thisDataPortion="central", logFile=logFile,
|
thisDataPortion="central", logFile=logFile,
|
||||||
continueRun=False, workDir=workDir,
|
continueRun=False, workDir=workDir,
|
||||||
outputFile=stepOutputFileName)
|
outputFile=stepOutputFileName,
|
||||||
|
matchMethod="proximity")
|
||||||
|
|
||||||
# attach columns to summary file
|
# attach columns to summary file
|
||||||
#if iSample == 1:
|
#if iSample == 1:
|
||||||
|
|
|
@ -30,12 +30,12 @@ catalogDir = os.getenv("HOME")+"/workspace/Voids/catalogs/multidark/"
|
||||||
hodPath = os.getenv("HOME")+"/projects/Voids/hod/HOD.x"
|
hodPath = os.getenv("HOME")+"/projects/Voids/hod/HOD.x"
|
||||||
|
|
||||||
# where to put the final void catalog, figures, and output logs
|
# where to put the final void catalog, figures, and output logs
|
||||||
voidOutputDir = os.getenv("HOME")+"/workspace/Voids/multidark_nocone/"
|
voidOutputDir = os.getenv("HOME")+"/workspace/Voids/multidark/"
|
||||||
figDir = os.getenv("PWD")+"/../figs/multidark_nocone/"
|
figDir = os.getenv("PWD")+"/../figs/multidark/"
|
||||||
logDir = os.getenv("PWD")+"/../logs/multidark_nocone/"
|
logDir = os.getenv("PWD")+"/../logs/multidark/"
|
||||||
|
|
||||||
# where to place the pipeline scripts
|
# where to place the pipeline scripts
|
||||||
scriptDir = os.getenv("PWD")+"/multidark_nocone/"
|
scriptDir = os.getenv("PWD")+"/multidark/"
|
||||||
|
|
||||||
# simulation or observation?
|
# simulation or observation?
|
||||||
dataType = "simulation"
|
dataType = "simulation"
|
||||||
|
@ -49,15 +49,19 @@ useLightCone = False
|
||||||
|
|
||||||
# common filename of particle files
|
# common filename of particle files
|
||||||
particleFileBase = "mdr1_particles_z"
|
particleFileBase = "mdr1_particles_z"
|
||||||
|
particleFileDummy = ''
|
||||||
|
|
||||||
# list of file numbers for the particle files
|
# list of file numbers for the particle files
|
||||||
# to get particle file name, we take particleFileBase+fileNum
|
# to get particle file name, we take particleFileBase+fileNum
|
||||||
#fileNums = ["0.53"]
|
#fileNums = ["0.53"]
|
||||||
fileNums = ["0.0", "0.53", "1.0"]
|
fileNums = ["0.0"]
|
||||||
|
#fileNums = ["0.0", "0.53", "1.0"]
|
||||||
|
|
||||||
# redshift of each file in the above list
|
# redshift of each file in the above list
|
||||||
#redshifts = ["0.53"]
|
#redshifts = ["0.53"]
|
||||||
redshifts = ["0.0", "0.53", "1.0"]
|
redshifts = ["0.0"]
|
||||||
|
#redshifts = ["0.0", "0.53"]
|
||||||
|
#redshifts = ["0.0", "0.53", "1.0"]
|
||||||
|
|
||||||
# how many independent slices along the z-axis?
|
# how many independent slices along the z-axis?
|
||||||
numSlices = 1
|
numSlices = 1
|
||||||
|
@ -71,7 +75,7 @@ numSubvolumes = 1
|
||||||
prefix = "md_"
|
prefix = "md_"
|
||||||
|
|
||||||
# list of desired subsamples - these are in unts of h Mpc^-3!
|
# list of desired subsamples - these are in unts of h Mpc^-3!
|
||||||
#subSamples = [0.0004]
|
#subSamples = [0.01]
|
||||||
subSamples = [0.1, 0.05, 0.01, 0.002, 0.001, 0.0004, 0.000175, 0.00001]
|
subSamples = [0.1, 0.05, 0.01, 0.002, 0.001, 0.0004, 0.000175, 0.00001]
|
||||||
|
|
||||||
# common filename of halo files, leave blank to ignore halos
|
# common filename of halo files, leave blank to ignore halos
|
||||||
|
@ -97,11 +101,12 @@ haloFileNumComLines = 0
|
||||||
# adjust these two parameters given the memory contraints on your system:
|
# adjust these two parameters given the memory contraints on your system:
|
||||||
# numZobovDivisions: how many sub-volumes per dimension will zobov process
|
# numZobovDivisions: how many sub-volumes per dimension will zobov process
|
||||||
# numZobovThreads: how many sub-volumes to process at once?
|
# numZobovThreads: how many sub-volumes to process at once?
|
||||||
numZobovDivisions = 4
|
numZobovDivisions = 2
|
||||||
numZobovThreads = 2
|
numZobovThreads = 2
|
||||||
|
|
||||||
# simulation information
|
# simulation information
|
||||||
numPart = 2048*2048*2048
|
numPart = 100000000
|
||||||
|
#numPart = 2048*2048*2048
|
||||||
lbox = 1000 # Mpc/h
|
lbox = 1000 # Mpc/h
|
||||||
omegaM = 0.27
|
omegaM = 0.27
|
||||||
hubble = 0.70
|
hubble = 0.70
|
||||||
|
|
4
pipeline/generateCatalog.py
Normal file → Executable file
4
pipeline/generateCatalog.py
Normal file → Executable file
|
@ -1,3 +1,4 @@
|
||||||
|
#!/usr/bin/env python
|
||||||
#+
|
#+
|
||||||
# VIDE -- Void IDEntification pipeline -- ./pipeline/generateCatalog.py
|
# VIDE -- Void IDEntification pipeline -- ./pipeline/generateCatalog.py
|
||||||
# Copyright (C) 2010-2013 Guilhem Lavaux
|
# Copyright (C) 2010-2013 Guilhem Lavaux
|
||||||
|
@ -17,7 +18,6 @@
|
||||||
# with this program; if not, write to the Free Software Foundation, Inc.,
|
# with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
#+
|
#+
|
||||||
#!/usr/bin/env python
|
|
||||||
|
|
||||||
# does full void analysis. Also generates 2d/1d stacked plots and hubble diagram
|
# does full void analysis. Also generates 2d/1d stacked plots and hubble diagram
|
||||||
|
|
||||||
|
@ -88,7 +88,7 @@ for sample in dataSampleList:
|
||||||
if (sample.dataType == "simulation"):
|
if (sample.dataType == "simulation"):
|
||||||
fp.write("Particles placed on lightcone: %g\n" % sample.useLightCone)
|
fp.write("Particles placed on lightcone: %g\n" % sample.useLightCone)
|
||||||
fp.write("Peculiar velocities included: %g\n" % sample.usePecVel)
|
fp.write("Peculiar velocities included: %g\n" % sample.usePecVel)
|
||||||
fp.write("Additional subsampling fraction: %g\n" % sample.subsample)
|
fp.write("Additional subsampling fraction: %s\n" % sample.subsample[-1])
|
||||||
fp.write("Simulation box length (Mpc/h): %g\n" % sample.boxLen)
|
fp.write("Simulation box length (Mpc/h): %g\n" % sample.boxLen)
|
||||||
fp.write("Simulation Omega_M: %g\n" % sample.omegaM)
|
fp.write("Simulation Omega_M: %g\n" % sample.omegaM)
|
||||||
fp.write("Number of simulation subvolumes: %s\n" % sample.numSubvolumes)
|
fp.write("Number of simulation subvolumes: %s\n" % sample.numSubvolumes)
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
#!/usr/bin/env python
|
||||||
#+
|
#+
|
||||||
# VIDE -- Void IDEntification pipeline -- ./python_tools/pipeline_source/prepareCatalogs.in.py
|
# VIDE -- Void IDEntification pipeline -- ./python_tools/pipeline_source/prepareCatalogs.in.py
|
||||||
# Copyright (C) 2010-2013 Guilhem Lavaux
|
# Copyright (C) 2010-2013 Guilhem Lavaux
|
||||||
|
@ -17,7 +18,6 @@
|
||||||
# with this program; if not, write to the Free Software Foundation, Inc.,
|
# with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
#+
|
#+
|
||||||
#!/usr/bin/env python
|
|
||||||
|
|
||||||
# prepares input catalogs based on multidark simulations
|
# prepares input catalogs based on multidark simulations
|
||||||
# (borrows heavily from generateMock, but doesn't hold much in memory)
|
# (borrows heavily from generateMock, but doesn't hold much in memory)
|
||||||
|
@ -453,6 +453,7 @@ if (args.halos or args.all) and haloFileBase != "":
|
||||||
|
|
||||||
if dataFormat == "sdf":
|
if dataFormat == "sdf":
|
||||||
# TODO process halo file with SDFcvt
|
# TODO process halo file with SDFcvt
|
||||||
|
SDFcvt_PATH = "@CMAKE_BINARY_DIR@/ep_build/sdf/bin/SDFcvt/"
|
||||||
outFile = open(catalogDir+"/"+sampleName+".dat", 'w')
|
outFile = open(catalogDir+"/"+sampleName+".dat", 'w')
|
||||||
outFile.write("-99 -99 -99 -99 -99 -99 -99\n")
|
outFile.write("-99 -99 -99 -99 -99 -99 -99\n")
|
||||||
outFile.close()
|
outFile.close()
|
||||||
|
|
|
@ -124,20 +124,31 @@ def launchGenerate(sample, binPath, workDir=None, inputDataDir=None,
|
||||||
|
|
||||||
datafile = inputDataDir+"/"+sample.dataFile
|
datafile = inputDataDir+"/"+sample.dataFile
|
||||||
|
|
||||||
|
# check if the final subsampling is done
|
||||||
|
lastSample = sample.subsample.split(', ')[-1]
|
||||||
|
doneLine = "Done! %5.2e\n" % float(lastSample)
|
||||||
|
if (continueRun and jobSuccessful(logFile, doneLine)):
|
||||||
|
print "already done!"
|
||||||
|
return
|
||||||
|
|
||||||
prevSubSample = -1
|
prevSubSample = -1
|
||||||
for thisSubSample in sample.subsample.split(', '):
|
for thisSubSample in sample.subsample.split(', '):
|
||||||
|
|
||||||
if prevSubSample == -1:
|
if prevSubSample == -1:
|
||||||
inputParameterFlag = ""
|
inputParameterFlag = ""
|
||||||
outputFile = zobovDir+"/zobov_slice_" + sampleName + "_ss" + thisSubSample
|
outputFile = zobovDir+"/zobov_slice_" + sampleName + "_ss" + \
|
||||||
|
thisSubSample
|
||||||
keepFraction = float(thisSubSample)
|
keepFraction = float(thisSubSample)
|
||||||
subSampleLine = "subsample %g" % keepFraction
|
subSampleLine = "subsample %g" % keepFraction
|
||||||
|
resubSampleLine = ""
|
||||||
else:
|
else:
|
||||||
inputParameterFlag = "inputParameter " + zobovDir+"/zobov_slice_"+\
|
inputParameterFlag = "inputParameter " + zobovDir+"/zobov_slice_"+\
|
||||||
sampleName+"_ss"+prevSubSample+".par"
|
sampleName+"_ss"+prevSubSample+".par"
|
||||||
outputFile = zobovDir+"/_zobov_slice_" + sampleName + "_ss" + thisSubSample
|
outputFile = zobovDir+"/zobov_slice_" + sampleName + "_ss" + \
|
||||||
|
thisSubSample
|
||||||
keepFraction = float(thisSubSample)/float(prevSubSample)
|
keepFraction = float(thisSubSample)/float(prevSubSample)
|
||||||
subSampleLine = "resubsample %g" % keepFraction
|
subSampleLine = "subsample %g" % keepFraction
|
||||||
|
resubSampleLine = "resubsample %g" % keepFraction
|
||||||
|
|
||||||
includePecVelString = ""
|
includePecVelString = ""
|
||||||
if sample.usePecVel: includePecVelString = "peculiarVelocities"
|
if sample.usePecVel: includePecVelString = "peculiarVelocities"
|
||||||
|
@ -175,6 +186,7 @@ def launchGenerate(sample, binPath, workDir=None, inputDataDir=None,
|
||||||
rangeZ_max %g
|
rangeZ_max %g
|
||||||
%s
|
%s
|
||||||
%s
|
%s
|
||||||
|
%s
|
||||||
""" % (dataFileLine, outputFile,
|
""" % (dataFileLine, outputFile,
|
||||||
outputFile+".par",
|
outputFile+".par",
|
||||||
includePecVelString,
|
includePecVelString,
|
||||||
|
@ -182,33 +194,30 @@ def launchGenerate(sample, binPath, workDir=None, inputDataDir=None,
|
||||||
sample.dataUnit,
|
sample.dataUnit,
|
||||||
xMin, xMax, yMin, yMax,
|
xMin, xMax, yMin, yMax,
|
||||||
sample.zBoundaryMpc[0], sample.zBoundaryMpc[1],
|
sample.zBoundaryMpc[0], sample.zBoundaryMpc[1],
|
||||||
subSampleLine,inputParameterFlag)
|
subSampleLine,resubSampleLine,inputParameterFlag)
|
||||||
|
|
||||||
parmFile = os.getcwd()+"/generate_"+sample.fullName+".par"
|
parmFile = os.getcwd()+"/generate_"+sample.fullName+".par"
|
||||||
|
|
||||||
file(parmFile, mode="w").write(conf)
|
file(parmFile, mode="w").write(conf)
|
||||||
|
|
||||||
doneLine = "Done! %5.2e\n" % keepFraction
|
if (prevSubSample == -1):
|
||||||
print "TEST", doneLine
|
cmd = "%s --configFile=%s &> %s" % (binPath,parmFile,logFile)
|
||||||
if not (continueRun and jobSuccessful(logFile, doneLine)):
|
else:
|
||||||
if (prevSubSample == -1):
|
cmd = "%s --configFile=%s &>> %s" % (binPath,parmFile,logFile)
|
||||||
cmd = "%s --configFile=%s &> %s" % (binPath,parmFile,logFile)
|
os.system(cmd)
|
||||||
else:
|
|
||||||
cmd = "%s --configFile=%s &>> %s" % (binPath,parmFile,logFile)
|
|
||||||
os.system(cmd)
|
|
||||||
|
|
||||||
if not jobSuccessful(logFile, doneLine):
|
|
||||||
print "FAILED!"
|
|
||||||
exit(-1)
|
|
||||||
|
|
||||||
# remove intermediate files
|
# remove intermediate files
|
||||||
if (prevSubSample != -1):
|
if (prevSubSample != -1):
|
||||||
os.unlink(zobovDir+"/zobov_slice_"+sampleName+"_ss"+prevSubSample+".par")
|
os.unlink(zobovDir+"/zobov_slice_"+sampleName+"_ss"+prevSubSample+".par")
|
||||||
os.unlink(zobovDir+"/zobov_slice_"+sampleName+"_ss"+prevSubSample)
|
os.unlink(zobovDir+"/zobov_slice_"+sampleName+"_ss"+prevSubSample)
|
||||||
|
|
||||||
|
doneLine = "Done! %5.2e\n" % keepFraction
|
||||||
|
if not jobSuccessful(logFile, doneLine):
|
||||||
|
print "FAILED!"
|
||||||
|
exit(-1)
|
||||||
|
|
||||||
prevSubSample = thisSubSample
|
prevSubSample = thisSubSample
|
||||||
|
|
||||||
if (continueRun and jobSuccessful(logFile, doneLine)): print "already done!"
|
|
||||||
if jobSuccessful(logFile, doneLine): print "done"
|
if jobSuccessful(logFile, doneLine): print "done"
|
||||||
|
|
||||||
# place the final subsample
|
# place the final subsample
|
||||||
|
@ -690,7 +699,7 @@ def launchCombine(sample, stack, voidDir=None, logFile=None,
|
||||||
shutil.copy(workDir+"/sample_"+comboName+"/galaxies.txt", zobovDir)
|
shutil.copy(workDir+"/sample_"+comboName+"/galaxies.txt", zobovDir)
|
||||||
elif not doneGalUpdate:
|
elif not doneGalUpdate:
|
||||||
dataTemp = file(workDir+"/sample_"+comboName+"/galaxies.txt",
|
dataTemp = file(workDir+"/sample_"+comboName+"/galaxies.txt",
|
||||||
"r").read()
|
"r").read()
|
||||||
file(zobovDir+"/galaxies.txt", "a").write(dataTemp)
|
file(zobovDir+"/galaxies.txt", "a").write(dataTemp)
|
||||||
|
|
||||||
sourceStackDir = workDir+"/sample_"+comboName+"/stacks_"+\
|
sourceStackDir = workDir+"/sample_"+comboName+"/stacks_"+\
|
||||||
|
@ -758,8 +767,9 @@ def launchCombine(sample, stack, voidDir=None, logFile=None,
|
||||||
idxTemp = file(sourceStackDir+"/z_void_indexes.txt", "r").\
|
idxTemp = file(sourceStackDir+"/z_void_indexes.txt", "r").\
|
||||||
readlines()
|
readlines()
|
||||||
idxTemp = np.array(idxTemp, dtype='i')
|
idxTemp = np.array(idxTemp, dtype='i')
|
||||||
dataTemp = (NetCDFFile(voidDir+"/z_posx.nc").\
|
fp = NetCDFFile(voidDir+"/z_posx.nc")
|
||||||
variables['array'])[0:]
|
dataTemp = fp.variables['array'][0:]
|
||||||
|
fp.close()
|
||||||
idxTemp[:] += len(dataTemp)
|
idxTemp[:] += len(dataTemp)
|
||||||
fp = open(voidDir+"/z_void_indexes.txt", "a")
|
fp = open(voidDir+"/z_void_indexes.txt", "a")
|
||||||
for idx in idxTemp:
|
for idx in idxTemp:
|
||||||
|
@ -809,8 +819,9 @@ def launchCombine(sample, stack, voidDir=None, logFile=None,
|
||||||
idxTemp = file(sourceStackDir+"/void_indexes.txt", "r").\
|
idxTemp = file(sourceStackDir+"/void_indexes.txt", "r").\
|
||||||
readlines()
|
readlines()
|
||||||
idxTemp = np.array(idxTemp, dtype='i')
|
idxTemp = np.array(idxTemp, dtype='i')
|
||||||
dataTemp = (NetCDFFile(voidDir+"/posx.nc").\
|
fp = NetCDFFile(voidDir+"/posx.nc")
|
||||||
variables['array'])[0:]
|
dataTemp = fp.variables['array'][0:]
|
||||||
|
fp.close()
|
||||||
idxTemp[:] += len(dataTemp)
|
idxTemp[:] += len(dataTemp)
|
||||||
fp = open(voidDir+"/void_indexes.txt", "a")
|
fp = open(voidDir+"/void_indexes.txt", "a")
|
||||||
for idx in idxTemp:
|
for idx in idxTemp:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue