Linker IT Software
Google
Web www.oraxcel.com
menubar-top-links menubar-top-rechts
Home Help Search Login
Welcome, Guest. Please Login.
SQL*XL: Database to Excel bridge litLIB: Excel power functions pack ExcelLock: Locking and securing your valuable Excel spreadsheets encOffice: Protect your Excel file easy and safe encOffice: Protect your Excel file easy and safe
Pages: 1
MOLCAS environment tips and tricks (Read 15518 times)
Gerrit-Jan Linker
YaBB Administrator
*****




Posts: 75
MOLCAS environment tips and tricks
18.09.08 at 16:37:31
 
MOLCAS environment tips and tricks
 
Since MOLCAS is not at all a black box program part of your success with MOLCAS  will depend on how you will be able to let it do what you want. There are several hints, tips and tricks that may be useful. I will try to add my hints and tips to this tread.
Back to top
 
« Last Edit: 22.09.08 at 19:43:13 by Gerrit-Jan Linker »  

Gerrit-Jan Linker
Linker IT Software
Email WWW Gerrit-Jan Linker   IP Logged
Gerrit-Jan Linker
YaBB Administrator
*****




Posts: 75
Setting MOLCASMEM
Reply #1 - 18.09.08 at 16:42:20
 
Setting MOLCASMEM
 
MOLCASMEM is set in your job file and determines how many MB's MOLCAS can use for its calculations:
 
MOLCASMEM=1024
 
This specifies MOLCAS to use up to 1024 MB's of memory.
 
You cannot give MOLCAS unlimited memory. The memory is constraint to the size of the physical memory on the machine. You need to reserve some memory for overhead and the operating system too. A rule of thumb is to allocate 75% of the total physical memory.
 
What happens when you specify too much memory?
When you specify more than 2047 MB of memory something in MOLCAS overflows and it results in a negative amount of memory.
Using MOLCASMEM=8047 caused SEWARD to crash with the message: MOLCAS executing module SEWARD with -145 MB of memory.  
 
What happens when you specify too little memory?
When you specify less memory than MOLCAS needs the MOLCAS programs will eventually complain.  
 
Examples of an insufficient memory error in SEWARD:
Quote:
 *** Error in MKSRT1 ***
 Insufficient memory
 nBin exceeds limits (nBin>mxBin)

nBin= 6436
mxBin= 2048

Increase MOLCASMEM and try again!

--- Stop Module: seward at Sun Sep 21 13:37:24 2008 /rc= 143 ---

  Execution terminated due to memory problems

 
Quote:
--- Start Module: seward at Sun Sep 21 16:32:53 2008
MA error: MA_init: could not allocate 1572864152 bytes

 
Quote:
The initialization of the memory manager failed ( iRc=  1 ).
--- Stop Module: seward at Sun Sep 21 16:32:53 2008 /rc= 143 ---

  Execution terminated due to memory problems

Non-zero return code - check program input/output

 
Quote:
Cho_GnVc_Drv: insufficient memory for batch  77
Cho_GnVc_Drv: at least   39699756 double precision words needed.
Cho_GnVc_Drv: available  36863893 double precision words.
Cho_X_GenVec: Cho_GnVc_Drv returned  101
CHO_DRV: decomposition failed!
CHO_DRV: CHO_X_GENVEC returned 101


***
*** Error in Cholesky Core Routine
*** Message: Error
*** Code   :   104
***


--- Stop Module: seward at Thu Sep 25 03:22:37 2008 /rc= 136 ---

 
Examples of an insufficient memory error in RASSCF:
Quote:
--- Start Module: rasscf at Sun Sep 21 20:08:42 CEST 2008
   Input File:   autoinput.rasscf.1 ---
MA error: MA_init: could not allocate 1572864152 bytes

 
Quote:
Iter CI SX CI RASSCF Energy max BLB max BLB max ROT Level Ln srch Step QN Time(min)
iter iter root energy change element value param shift minimum type update CPU
MA failed to allocate a memory block.

Memory allocation map
Back to top
 
« Last Edit: 26.09.08 at 22:23:43 by Gerrit-Jan Linker »  

Gerrit-Jan Linker
Linker IT Software
Email WWW Gerrit-Jan Linker   IP Logged
Gerrit-Jan Linker
YaBB Administrator
*****




Posts: 75
Re: MOLCAS environment
Reply #2 - 20.09.08 at 14:42:20
 
Disk full?
 
Error message:
Quote:
Premature abort while writing buffer to disk: Disk full?

--- Stop Module: seward at Sat Sep 20 11:19:20 2008 /rc=130 ---
Non-zero return code - check program input/output

 
 
When this happened the disk was indeed full. The options are to use a computer with a bigger disk, to use less basisfunctions or to use the CHOLESKY method to generate the integrals. Using the CHOLESKY keyword in SEWARD will generate the integrals in a different way and hopefully it leads to smaller files.
Back to top
 
 

Gerrit-Jan Linker
Linker IT Software
Email WWW Gerrit-Jan Linker   IP Logged
Gerrit-Jan Linker
YaBB Administrator
*****




Posts: 75
File too large?
Reply #3 - 20.09.08 at 15:18:15
 
File too large?
 
SEWARD Error message:
Quote:
***    Extensions out of range! increase MOLCASDISK value ***
***    or MaxSplitFile in fio.inc    

--- Stop Module: seward at Sat Sep 20 11:35:08 2008 /rc= 97 ---

 
With the MOLCASDISK variable you can set the maximum size for a file. It is machine dependent but on 32bits machines it is 2GB.
 
At the time of the crash I had 20 ORDINT files named ORDINT, ORDINT1, ORDINT2, ..., ORDINT19.
The cause will likely be that the maximum splits of a file is 20.
Back to top
 
« Last Edit: 22.09.08 at 19:43:39 by Gerrit-Jan Linker »  

Gerrit-Jan Linker
Linker IT Software
Email WWW Gerrit-Jan Linker   IP Logged
Gerrit-Jan Linker
YaBB Administrator
*****




Posts: 75
Re: MOLCAS environment tips and tricks
Reply #4 - 22.09.08 at 19:48:58
 
Copying integrals instead of recalculating them
 
Copying the integral files generated with SEWARD can result in much quicker calculations and experimentation. For example, when experimenting with RASSCF with different active spaces you can just reuse the SEWARD output. I use the technique to run an inline UNIX command to copy the files to a subdirectory where I can access them again in future calculations.
 
Back to top
 
« Last Edit: 25.09.08 at 14:14:57 by Gerrit-Jan Linker »  

Gerrit-Jan Linker
Linker IT Software
Email WWW Gerrit-Jan Linker   IP Logged
Gerrit-Jan Linker
YaBB Administrator
*****




Posts: 75
Receiving no output
Reply #5 - 19.10.08 at 11:39:41
 
Receiving no output
 
Sometimes ti takes a long time to get output in the MOLCAS output file. There must be some buffering going on somewhere as the job is usually progressed further than the output file shows. It is my experience that sometimes output is not written for a very long time. In such a case I find it useful to inspect the extract.xml file. This file is one of the MOLCAS job files that resides on the machine where the MOLCAS job is running.
 
Extract:
   <CurrIter>
     44
   </CurrIter>
   <OneEn>
     -5480.279144
   </OneEn>
   <TwoEn>
     2087.504714
   </TwoEn>
   <TotEn>
     -2039.389840
   </TotEn>
   <CurrIter>
     45
   </CurrIter>
   <OneEn>
     -5480.279486
   </OneEn>
   <TwoEn>
     2087.504796
   </TwoEn>
   <TotEn>
     -2039.390101
   </TotEn>
 
 
TotEn is the total energy
CurrIter is the current iteration
 
This way you can still monitor the progress of the SCF even when you do not see any output coming through.
Back to top
 
 

Gerrit-Jan Linker
Linker IT Software
Email WWW Gerrit-Jan Linker   IP Logged
Gerrit-Jan Linker
YaBB Administrator
*****




Posts: 75
Job output and errors to the output file
Reply #6 - 10.11.08 at 11:17:35
 
Job output and errors to the output file
 
It is a good idea to redirect both the MOLCAS job output as well as the errors to the same output file. Errors, logging and output are then all part of the same file and you can judge precisely which modules were executed and where any problems arose.
 
In my job file I call molcas like this:
 
 molcas $JOBDIR/$MOLCAS_PROJECT.input &> $JOBDIR/$MOLCAS_PROJECT.output
 
Note that the &> will redirect  both the errors and the output to the same output file.
Back to top
 
 

Gerrit-Jan Linker
Linker IT Software
Email WWW Gerrit-Jan Linker   IP Logged
tranvantan
YaBB Newbies
*


I Love SQL*XL

Posts: 2
Re: MOLCAS environment tips and tricks
Reply #7 - 15.07.10 at 10:31:40
 
Quote from Gerrit-Jan Linker on 22.09.08 at 19:48:58:
Copying integrals instead of recalculating them

Copying the integral files generated with SEWARD can result in much quicker calculations and experimentation. For example, when experimenting with RASSCF with different active spaces you can just reuse the SEWARD output. I use the technique to run an inline UNIX command to copy the files to a subdirectory where I can access them again in future calculations.


 That's great
Back to top
 
 
  IP Logged
tranvantan
YaBB Newbies
*


I Love SQL*XL

Posts: 2
Re: MOLCAS environment tips and tricks
Reply #8 - 15.07.10 at 10:43:39
 
Dear,
 
I am doing a CASSCF/CASPT2 for a large molecule in MOLCAS 7.4 and seward program is too slow to calculate the integrals. I know in this forum that you can save and restart the integral for seward calculation with unix command in shell-scripts. I am very interested in the way you are doing so can you share your experience to me?
Thank in advance
 
Tran Van Tan
Back to top
 
 
  IP Logged
Gerrit-Jan Linker
YaBB Administrator
*****




Posts: 75
Re: MOLCAS environment tips and tricks
Reply #9 - 27.07.10 at 11:38:41
 
Hi,
 
What I did was a copy command (using EMIL  you can do a !cp or >copy) after the SEWARD program to copy all the files to a temporary directory. The next time when I performed the calculation I skipped SEWARD but instead I did a copy again but then from the temporary directory back to the work directory where the calculation is done.
 
Actually I rarely do this anymore. I find it is usually better to use a Cholesky decomposition of the integrals (keyword CHOLESKY in SEWARD). It will reduce the time and disk space needed for the integrals tremendously. I have not experienced any problems using SCF or CASSCF / CASPT2 after that. The only thing you cannot do with Cholesky decomposed integrals is a geometry optimisation as there are no analytic gradients.  
 
Good luck!
Back to top
 
 

Gerrit-Jan Linker
Linker IT Software
Email WWW Gerrit-Jan Linker   IP Logged
Pages: 1