CosmoCoffee Forum Index CosmoCoffee

 
 FAQFAQ   SearchSearch  MemberlistSmartFeed   MemberlistMemberlist    RegisterRegister 
   ProfileProfile   Log inLog in 
Arxiv New Filter | Bookmarks & clubs | Arxiv ref/author:

"ImportError: No module named" during python plotting in CosmoMc
 
Post new topic   Reply to topic    CosmoCoffee Forum Index -> Computers and software
View previous topic :: View next topic  
Author Message
Alessandro Di Marco



Joined: 01 Apr 2015
Posts: 15
Affiliation: University of Rome - Tor Vergata

PostPosted: December 05 2015  Reply with quote

Hi Antony!
I have a little trouble:
I process chains in /chains with the way ./getdist distparams.ini and here I set no_plots = F, producing the 1d,2d,3d and triangular plots.
When I use the python command

python filename.py

to generate the corrispondent .pdf file I get the following:

Traceback (most recent call last):
File "test_2D.py", line 2, in <module>
import GetDistPlots, os
ImportError: No module named GetDistPlots

Would you help me?(I have installed the July's CosmoMc version)
Thank you in advance!!!
Back to top
View user's profile  
Antony Lewis



Joined: 23 Sep 2004
Posts: 1351
Affiliation: University of Sussex

PostPosted: December 05 2015  Reply with quote

Did you set up the PYTHONPATH as in the python readme instructions?
Back to top
View user's profile [ Hidden ] Visit poster's website
Alessandro Di Marco



Joined: 01 Apr 2015
Posts: 15
Affiliation: University of Rome - Tor Vergata

PostPosted: December 06 2015  Reply with quote

Yes, I did :

export PYTHONPATH=.../cosmomc/python:$PYTHONPATH

(where ... is the path in which I have installed CosmoMc) in my bashrc file.
In particulare I put this command at the end of bashrc.
I don't know if I have neglected something else in this procedure!
In any case I will try to compile again the whole code.
Thank you in advance!

The best,
Back to top
View user's profile  
Alessandro Di Marco



Joined: 01 Apr 2015
Posts: 15
Affiliation: University of Rome - Tor Vergata

PostPosted: December 09 2015  Reply with quote

Hi Antony I'm writing this new message because I have resolved the previous question.
I was having errors because I did not have the numpy,scipy and matplotlib libraries for my python version.
Now I can produce the standard the pdf files from the standard .py files.
Nevetheless I have a little problem:
when I plot the for example the test.pdf or test_3D from the corrispondent .py I have no problem but when I do the same thing for test_2D and test_tri I get only the marginalization.
Any suggestion?
Could be a library-problem again!?
Thank you in advance for the response!

The Best,

Alessandro
Back to top
View user's profile  
Alessandro Di Marco



Joined: 01 Apr 2015
Posts: 15
Affiliation: University of Rome - Tor Vergata

PostPosted: December 09 2015  Reply with quote

Ps: In this sense for test_2D.pdf I get only "empty plot" while for test_tri.pdf I get figures only along the diagonal and the others are again blanks!
Back to top
View user's profile  
Display posts from previous:   
Post new topic   Reply to topic    CosmoCoffee Forum Index -> Computers and software All times are GMT + 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group. Sponsored by WordWeb online dictionary and dictionary software.