can not use Cut3d

MULTIBINIT, aTDEP, ANADDB, optics, cut3d, mrg* postprocessors

Moderators: MMNSchmitt, gonze

Locked
jiabo
Posts: 11
Joined: Sat Nov 22, 2014 2:32 am

can not use Cut3d

Post by jiabo » Thu Dec 04, 2014 2:16 am

Dear every ABINIT user

I got a really urgent problem that I can not use Cut3d on ARCHER (High performance computer centre in UK) to transfer my unformatted POT file into formatted one. According to what I have known, maybe the ABINIT on ARCHER is a paralleled version that leads me not to use it just typing 'cut3d', can anyone give me some instruction how to deal with this?

The file is too big to upload, I would really appreciate if someone can do me a favour to try to transfer it for me, please leave me an email address so that I can send the file to you.

Thank you

Jiabo

Jordan
Posts: 282
Joined: Tue May 07, 2013 9:47 am

Re: can not use Cut3d

Post by Jordan » Thu Dec 04, 2014 9:21 am

This will depend on you HPC.
If you compiled abinit with MPI and you administrator does not allow you to run a MPI program even in sequentiel on you login node then you have at least 2 possibilites :
1) submit a job and put all the things you would type on the keyboard in a file - let say cut3d.file - and run cut3d as

Code: Select all

cut3d < cut3d.file

2) recompile abinit (with no optimization not special features so the compilation is much faster) without mpi so you can use it on the login node.
3) export you POT file to you local machine and do the post processing on it.

Jordan

jiabo
Posts: 11
Joined: Sat Nov 22, 2014 2:32 am

Re: can not use Cut3d

Post by jiabo » Thu Dec 04, 2014 12:58 pm

Hi Jordan

Thank you for your reply. I have tried the first method, it seems cut3d can be used, but still have something wrong. You can see the first and last few lines below, I do not know why it stopped after the first option.

And there is a sequential version of ABINIT in my another account, but still not work.

Jiabo

What is the name of the 3D function (density, potential or wavef) file ?
=> Your 3D function file is : Pt_xo_TIM3_POT

Does this file contain formatted 3D ASCII data (=0)
or unformatted binary header + 3D data (=1) ?
or ETSF binary (=2) ?
1 => Your file contains unformatted binary header + 3D data
The information it contains should be sufficient.
cut3d : read file Pt_xo_TIM3_POT from unit number 19.


End the ECHO of the ABINIT file header
===============================================================================

===========================================================

ECHO important input variables ...

Dimensional primitive vectors (ABINIT equivalent : rprimd):
1.071097E+01 0.000000E+00 0.000000E+00
-5.355484E+00 9.275970E+00 0.000000E+00
3.233235E-15 5.600127E-15 5.280273E+01
Grid density (ABINIT equivalent : ngfft): 54 54 270
Number of atoms : 16
Number of atomic types: 1

# Atomic positions (cartesian coordinates - Bohr)
1 -1.100271E-19 6.376265E-04 -1.242070E-02
2 -5.812424E-21 -9.984450E-04 1.313095E+01
3 2.677742E+00 1.543855E+00 8.724622E+00
4 4.700827E-17 3.094770E+00 4.393967E+00
5 5.355484E+00 6.376265E-04 -1.242070E-02
6 5.355484E+00 -9.984450E-04 1.313095E+01
7 8.033226E+00 1.543855E+00 8.724622E+00
8 5.355484E+00 3.094770E+00 4.393967E+00
9 -2.677742E+00 4.638504E+00 -1.222914E-02
10 -2.677742E+00 4.636737E+00 1.313073E+01
11 -3.539525E-16 6.181875E+00 8.724572E+00
12 -2.677742E+00 7.732728E+00 4.393732E+00
13 2.677742E+00 4.638504E+00 -1.222914E-02
14 2.677742E+00 4.636737E+00 1.313073E+01
15 5.355484E+00 6.181875E+00 8.724572E+00
16 2.677742E+00 7.732728E+00 4.393732E+00

This file is a Density or Potential file
Application 12134916 exit codes: 67
Application 12134916 resources: utime ~0s, stime ~0s, Rss ~6196, inblocks ~23845, outblocks ~52239

Jordan
Posts: 282
Joined: Tue May 07, 2013 9:47 am

Re: can not use Cut3d

Post by Jordan » Tue Dec 09, 2014 10:18 am

Could you check that this is not a memory problem ? If your POT file is large enough and cut3d allocates lots of arrays it might crash the code.

In addition, could you (again, sorry) recompile the whole abinit package without optimization and debug information with for instance :
FCFLAGS_EXTRA="-g -O0 -traceback" for intel compiler or FCFLAGS_EXTRA="-g -O0 -fbacktrace" for gfortran.
on your ./configure command line or in your *.ac file. Don't forget to make clean before make

Jordan

JEJohns
Posts: 55
Joined: Sun May 02, 2010 5:30 pm

Re: can not use Cut3d

Post by JEJohns » Mon Feb 02, 2015 9:39 pm

Hi Jordan,

I see a similar behavior, but it seems to occur only when I'm handling a large file. For example, I'm currently working on a surface with 147 atoms, and an ~18 x 18 x75 bohr hexagonal unit cell. When I try and load the *POT file with cut3d, I get the same error as you jiabo. When I then try and load it using a serial version of cut3d I get the following error:
"At line 96 of rrho.F90 (unit=19, file='e:\DFT\Abinit7.4\MoS2_Fe_POT')
Fortran Runtime Error: I/O past end of record on unformatted file"

So I don't think that it's the memory that is the question because it also loads the associate *DEN file just fine.
So I looked at rrho.F90, and the relevant section is below in bold.

Line 96 of the rrho.F90 is bolded below.
! Formatted (only one spin component is allowed)
case (0)
do ir3=1,nr3
do ir2=1,nr2
do ir1=1,nr1
read(unit=wff%unwff,fmt=*) grid_full(ir1,ir2,ir3,1)
end do
end do
end do

! Unformatted, on one record
case (1)
do ispden=1,nspden
read(unit=wff%unwff) grid_full(1:nr1,1:nr2,1:nr3,ispden)
end do
! ETSF case



That seems pretty straightforward. Loop over the fft grid and number of spin densities and make a grid of V((nx,ny,nz,nspden)). It does this same routine for both DEN & POT types of files. At this point, I realized that my POT file was roughly 1/2 the size of my DEN file. This corresponds to the number of processors I'm parallelizing the FFT over.
I did some tests on a dummy system (a GAN in a giant box, doesn't really matter), and the POT file always has the size of 1/npfft * DEN file. This means that if your system is large and you need to start paralleling over the fft grid, cut3d cannot read the POT files. I'll look more into it since this came up previously in the threads back in 2010, but if anyone else wants to that would be a great help. I'm an experimentalist any my Fortran is iffy at best.

Cheers,
James

Locked