From 89082b2f1e0eee3a587530c42f536f6f4621f53a Mon Sep 17 00:00:00 2001 From: Paul Matthew Sutter Date: Tue, 14 Jan 2014 11:06:29 +0100 Subject: [PATCH] merger --- c_tools/mock/generateMock.cpp | 8 ++++++++ python_tools/void_python_tools/backend/launchers.py | 9 ++++++--- zobov/jozov.c | 4 ++-- 3 files changed, 16 insertions(+), 5 deletions(-) diff --git a/c_tools/mock/generateMock.cpp b/c_tools/mock/generateMock.cpp index 1635a05..8192f42 100644 --- a/c_tools/mock/generateMock.cpp +++ b/c_tools/mock/generateMock.cpp @@ -116,6 +116,11 @@ void metricTransform(SimuData *data, int axis, bool reshift, bool pecvel, double baseComovingDistance = LIGHT_SPEED/100.* gslIntegrate(e_computer, 0, z0, 1e-3); cout << "Comoving distance = " << baseComovingDistance << " Mpc/h" << endl; + if (cosmo_flag) cout << "Will place particles on a lightcone..." << endl; + + float minZ = 1.e99; + float maxZ = 0; + for (uint32_t i = 0; i < data->NumPart; i++) { float& x = data->Pos[x0][i]; @@ -148,8 +153,11 @@ void metricTransform(SimuData *data, int axis, bool reshift, bool pecvel, double cout << "The offending value is z=" << reduced_red << endl; abort(); } + if (z > maxZ) maxZ = z; + if (z < minZ) minZ = z; } + printf("Range of z: %.2f - %.2f\n", minZ, maxZ); } // slightly perturb particle positions diff --git a/python_tools/void_python_tools/backend/launchers.py b/python_tools/void_python_tools/backend/launchers.py index d9b2525..83873b4 100644 --- a/python_tools/void_python_tools/backend/launchers.py +++ b/python_tools/void_python_tools/backend/launchers.py @@ -1451,11 +1451,14 @@ def launchHubble(dataPortions=None, dataSampleList=None, logDir=None, #vp.do_all_obs(zbase, expList, workDir+"/avedistortion_", vp.do_all_obs(zbase, expList, aveDistList, rlist, plotTitle=plotTitle, plotAve=True) - figure(1).savefig(figDir+"/hubble_"+sampleName+"_"+thisDataPortion+\ + figure(1).savefig(figDir+"/hubble_"+setName+"_"+sampleName+"_"+\ + thisDataPortion+\ ".eps",bbox_inches='tight') - figure(1).savefig(figDir+"/hubble_"+sampleName+"_"+thisDataPortion+\ + figure(1).savefig(figDir+"/hubble_"+setName+"_"+sampleName+"_"+\ + thisDataPortion+\ ".pdf",bbox_inches='tight') - figure(1).savefig(figDir+"/hubble_"+sampleName+"_"+thisDataPortion+\ + figure(1).savefig(figDir+"/hubble_"+setName+"_"+sampleName+"_"+\ + thisDataPortion+\ ".png",bbox_inches='tight') else: print "Skipping plot" diff --git a/zobov/jozov.c b/zobov/jozov.c index a4ee12b..e2ed619 100644 --- a/zobov/jozov.c +++ b/zobov/jozov.c @@ -131,7 +131,7 @@ int main(int argc,char **argv) { printf("OVERFLOW for particle %d (pending %d). List of accepted:\n", i, j); for (q=0;q