For now, I am just starting off on a 'tutorial' [on a MacBook Pro 2015, OS X El Capitan, 10.11.6], learning to get GetDist to make plots (e.g. contour plots seen in cosmology papers). I have encountered a couple of problems regarding the plotting. First of all, I should note that I obtained the chain files from http://irsa.ipac.caltech.edu/data/Planc ... lary-data/ (using the Full Grid).
I am trying to use this Python code (Python 2.7.13, from the Anaconda distribution, so Spyder IDE):
Code: Select all
g = plots.getSubplotPlotter(chain_dir='/Users/masonng/Documents/Honours Project/Chains/base_nnu_mnu/plikHM_TT_lowTEB/')
roots = ['plikHM_TT_lowTEB']
params = ['omegabh2', 'omegach2', 'theta']
param_3d = None
g.triangle_plot(roots, params, plot_3d_with_param=param_3d, filled_compare=True, shaded=True)
g.export()
but I get a "chain not found" error from GetDistPlot
Code: Select all
runfile('/Users/masonng/.spyder/temp.py', wdir='/Users/masonng/.spyder')
Traceback (most recent call last):
File "<ipython-input-42-fb250905188c>", line 1, in <module>
runfile('/Users/masonng/.spyder/temp.py', wdir='/Users/masonng/.spyder')
File "/Users/masonng/anaconda2/lib/python2.7/site-packages/spyder/utils/site/sitecustomize.py", line 880, in runfile
execfile(filename, namespace)
File "/Users/masonng/anaconda2/lib/python2.7/site-packages/spyder/utils/site/sitecustomize.py", line 94, in execfile
builtins.execfile(filename, *where)
File "/Users/masonng/.spyder/temp.py", line 11, in <module>
g.triangle_plot(roots, params, plot_3d_with_param=param_3d, filled_compare=True, shaded=True)
File "/Users/masonng/anaconda2/lib/python2.7/site-packages/getdist/plots.py", line 1784, in triangle_plot
params = self.get_param_array(roots[0], params)
File "/Users/masonng/anaconda2/lib/python2.7/site-packages/getdist/plots.py", line 1380, in get_param_array
return self.paramNamesForRoot(root).parsWithNames(params, error=True, renames=renames)
File "/Users/masonng/anaconda2/lib/python2.7/site-packages/getdist/plots.py", line 763, in paramNamesForRoot
labelParams=self.settings.param_names_for_labels)
File "/Users/masonng/anaconda2/lib/python2.7/site-packages/getdist/plots.py", line 576, in paramsForRoot
samples = self.samplesForRoot(root)
File "/Users/masonng/anaconda2/lib/python2.7/site-packages/getdist/plots.py", line 462, in samplesForRoot
raise GetDistPlotError('chain not found: ' + root)
[b]GetDistPlotError: chain not found: plikHM_TT_lowTEB[/b]
Regarding the GUI, I tried running GetDistGUI.py itself from the python folder of cosmomc (July 2015 version) but:
Qt (package) wasn’t working it seems; in particular, even though PySide was imported without problem, PySide.QtCore had an issue:
Code: Select all
ImportError: dlopen(/Users/masonng/anaconda2/lib/python2.7/site-packages/PySide/QtCore.so, 2): Library not loaded: /usr/local/lib/QtCore.framework/Versions/4/QtCore
Referenced from: /Users/masonng/anaconda2/lib/python2.7/site-packages/PySide/QtCore.so
Reason: image not found
It turns out that I did not have Qt4/PyQt4 in my system, but conda can’t find this even though
Code: Select all
pip search qt
They are long questions - please feel free to answer in separately if appropriate. Additionally, any input is valuable. Thanks in advance!