User Tools

Site Tools


exercises:2020_uzh_acpc2:installation

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
exercises:2020_uzh_acpc2:installation [2020/04/06 10:16] – created jglanexercises:2020_uzh_acpc2:installation [2020/08/21 10:15] (current) – external edit 127.0.0.1
Line 1: Line 1:
-===== 0.3 First CP2K simulation ===== +===== First CP2K simulation ===== 
-It is possible to run cp2k from any directory on your own machine by adding a line to your ''.bashrc'' filewithout having to specify the location of the ''cp2k.sopt'' file+ 
 +==== Module loading ==== 
 + 
 +Since there are numerous applications with different and possibly conflicting requirements, the //module// system is usedThis means that only basic commands are available until **explicitly** loaded. 
 + 
 +To list all available modules:
  
-To do this change to the directory where the ''cp2k.sopt'' binary is located and type ''pwd''. Copy the output of this command and edit the ''.bashrc'' file located on your home directory: 
-To edit the ''.bashrc'' file type 
 <code> <code>
-vim ~/.bashrc+$ module avail
 </code> </code>
-Add the following line, replacing ''/path_of_cp2k_binary/'' with the actual path where ''cp2k.sopt'' is located.+ 
 +while using 
 <code> <code>
-export PATH=${PATH}:/path_of_cp2k_binary/+module list
 </code> </code>
-Save the ''.bashrc'' file and quit. You can do this by typing '':wq'' in normal mode if you use vim. + 
-In the terminal after typing +gives the list of loaded moules. 
 + 
 +To load the CP2K module used in this course, use: 
 <code> <code>
-source ~/.bashrc+$ module load cp2k/6.1-gcc-7.3.1-d43qc6l
 </code> </code>
 +
 +When you list the loaded modules again at this point (see command above), you will notice that the list has changed.
 +
 +
 you can run cp2k from any directory. To do this enter you can run cp2k from any directory. To do this enter
 <code> <code>
-cp2k.sopt --help+cp2k.popt --help
 </code> </code>
  
Line 57: Line 69:
 </code> </code>
  
-Now, make a new directory, for instance called ''exercise0''. Download and extract the file {{argon.zip|}} into this directory and run cp2k by typing+Now, make a new directory, for instance called ''exercise0''. Download and extract the file {{ :exercises:2019_uzh_acpc2:argon.zip |argon.inp}} into this directory and run cp2k by typing 
 + 
 +To download the file and extract the zip:
 <code> <code>
-cp2k.sopt -i argon.inp -o out_ex0.out+wget https://www.cp2k.org/_media/exercises:2019_uzh_acpc2:argon.zip 
 + 
 +mv exercises:2019_uzh_acpc2:argon.zip argon.zip 
 + 
 +unzip argon.zip 
 </code> </code>
 +
 +<code>
 +cp2k.popt -i argon.inp -o out_ex0.out
 +</code>
 +
 +To run cp2k with MPI, for instance with 2 CPU, one can use
 +<code>
 +mpirun -n 2 cp2k.popt -i argon.inp -o out_ex0.out
 +</code>
 +
 You just ran a short Molecular Dynamics trajectory of liquid argon.  You just ran a short Molecular Dynamics trajectory of liquid argon. 
  
  
-===== 0.4 Visualization with VMD =====+===== Visualization with VMD ===== 
 + 
 + 
 +===== Part II: Loading and running a program ===== 
 + 
 + 
 +We need for visualization is [[http://www.ks.uiuc.edu/Research/vmd/|VMD]]. 
 + 
 +Load the respective module (since there is only one version available, the shorthand ''vmd'' can be used when specifying the module to load) and start it using: 
 + 
 +<code> 
 +$ vmd 
 +</code> 
 + 
 +Two new windows named ''VMD Main'' and ''VMD 1.9.2 ... Display'' should open on your local machine while the server shows: 
 + 
 +<code> 
 +Info) VMD for LINUXAMD64, version 1.9.2 (December 29, 2014) 
 +Info) http://www.ks.uiuc.edu/Research/vmd/                          
 +Info) Email questions and bug reports to vmd@ks.uiuc.edu            
 +Info) Please include this reference in published work using VMD:    
 +Info)    Humphrey, W., Dalke, A. and Schulten, K., `VMD - Visual    
 +Info)    Molecular Dynamics', J. Molec. Graphics 1996, 14.1, 33-38. 
 +Info) ------------------------------------------------------------- 
 +Info) Multithreading available, 32 CPUs detected. 
 +Info) Free system memory: 256213MB (99%) 
 +Warning) Detected a mismatch between CUDA runtime and GPU driver 
 +Warning) Check to make sure that GPU drivers are up to date. 
 +Info) No CUDA accelerator devices available. 
 +Warning) Detected X11 'Composite' extension: if incorrect display occurs 
 +Warning) try disabling this X server option.  Most OpenGL drivers 
 +Warning) disable stereoscopic display when 'Composite' is enabled. 
 +libGL error: failed to load driver: swrast 
 +libGL error: Try again with LIBGL_DEBUG=verbose for more details. 
 +Info) OpenGL renderer: GeForce GTX 760 (192-bit)/PCIe/SSE2 
 +Info)   Features: STENCIL MSAA(4) MDE MTX NPOT PP PS  
 +Info)   GLSL rendering mode is NOT available. 
 +Info)   Textures: 2-D (16384x16384), 3-D (2048x2048x2048), Multitexture (4) 
 +Info) Dynamically loaded 2 plugins in directory: 
 +Info) /sw/build/generic/app/vmd/vmd-1.9.2/lib/vmd/plugins/LINUXAMD64/molfile 
 +vmd > 
 +</code> 
 + 
 +If you only get the output on the server but not the 2 windows there is something wrong with your setup and you should check the lecture notes again. You can exit VMD by either closing the ''VMD Main'' or by giving the ''quit'' command at the ''vmd >'' prompt: 
 + 
 +<code> 
 +vmd > quit 
 +</code> 
 + 
 +<note tip>The module loading is **not** persistent. You have to reload the modules every time you log back in.</note> 
 + 
 + 
 + 
 + 
 +We will visualize this trajectory with VMD, a molecular visualization program. First of all, download and install VMD for your operating system as indicated [[http://www.ks.uiuc.edu/Development/Download/download.cgi?PackageName=VMD|here]].The current official release doesn't support MacOS Catalina. For those who have Catalina OS, please download VMD [[https://www.dropbox.com/s/700vi9kkpglf6m6/VMD%201.9.4a38.zip?dl=0|here]].
  
-We will visualize this trajectory with VMD, a molecular visualization program. First of all, download and install VMD for your operating system as indicated [[http://www.ks.uiuc.edu/Development/Download/download.cgi?PackageName=VMD|here]]. 
  
 Open VMD. From ''File -> New molecule...'' open the file with the ''.xyz'' extension. Go to ''Graphics -> Representations..'' and change the Drawing Method to VDW. On the VMD shell type the following commands to define the unit cell of the system and wrap the atoms back to their original unit cell. Open VMD. From ''File -> New molecule...'' open the file with the ''.xyz'' extension. Go to ''Graphics -> Representations..'' and change the Drawing Method to VDW. On the VMD shell type the following commands to define the unit cell of the system and wrap the atoms back to their original unit cell.
Line 80: Line 162:
  
  
-===== 0.5 Plotting tools ===== 
  
-Throughout the course you will also need to plot some graphs. You can use any tool you like for that. ''gnuplot'' and ''Xmgrace'' are two programmes often used in Linux environments that are rather easy to use, but you can also use ''MS Office'', ''Numbers'', the plotting library of python ''Matplotlib'', etc. Take care to install any of these software on your machine as needed.+=====  Plotting tools ===== 
 + 
 +Throughout the courseyou will also need to plot some graphs. You can use any tool you like for that. ''gnuplot'' and ''Xmgrace'' are two programs often used in Linux environments that are rather easy to use, but you can also use ''MS Office'', ''Numbers'', the plotting library of python ''Matplotlib'', etc. Take care to install any of these software on your machine as needed.
exercises/2020_uzh_acpc2/installation.1586168165.txt.gz · Last modified: 2020/08/21 10:15 (external edit)