Project

General

Profile

Install Appion Packages » History » Revision 21

Revision 20 (Anchi Cheng, 05/18/2010 07:46 PM) → Revision 21/41 (Jim Pulokas, 05/21/2010 02:01 PM)

h1. Install Appion/Leginon Packages 

 h3. Install all the python packages included package in _each folder_ with myami as follows: 

 commands like these 


 <pre> 
 cd /your_download_area/ 

 cd myami/leginon 
 sudo python setup.py install 

 cd myami ../pyami 
 ./pysetup.py sudo python setup.py install 

 cd ../pyscope 
 </pre> sudo python setup.py install 

 That will cd ../sinedon 
 sudo python setup.py install each package, and report any failures.    To determine the cause of failure, see the generated log file "pysetup.log".    If necessary, you can enter a specific package directory and run the 

 cd ../imageviewer 
 sudo python setup command manually.    For example: setup.py install 

 <pre> cd ../appion 
 sudo python setup.py install --install-scripts=/usr/local/bin 

 #binary packages 

 cd sinedon ../numextension 
 python setup.py build 
 sudo python setup.py install 

 cd ../libcv 
 python setup.py build 
 sudo python setup.py install 

 cd ../appion/radermacher 
 python setup.py build 
 sudo python setup.py install 
 </pre> 

 h3. python-site-package-path: where the installed python packages went: 

 Python installer put the packages you installed into its site-packages directory. This enables all users on the same computer to access them. The easiest way to discover where your installed package is loaded from by python is to load a module from the package using interactive python command lines like this: 

 Start the python command line from shell: 
  <pre>python</pre> 

 Import a module from the package. Let's try sinedon here. All packages installed through the above setup.py script should go to the same place. 
  <pre>python> import sinedon</pre> 


 If the module is loaded successfully, call the module attribute __path__ (two underscrolls before "path" and two underscrolls after) will return the location of the module it is loaded from 
 <pre> 
 python> sinedon.__path__ 
 ['/usr/lib/python2.4/site-packages/sinedon'] 
 </pre> 

 In this case, /usr/lib/python2.4/site-packages/ is your python-site-package-path. If you go to that directory, you will find all the packages you just installed. 

 Save this value for use later, for bash: 
 <pre> 
 export PYTHONSITEPKG='/usr/lib/python2.4/site-packages' 
 </pre> 
 or C shell 
 <pre> 
 setenv PYTHONSITEPKG '/usr/lib/python2.4/site-packages' 
 </pre> 

 ______ 

 [[Perform system check|< Perform system check]] | [[Configure leginon.cfg|Configure leginon.cfg >]] 

 ______