[Pw_forum] magnetization.x.xml vs magnetization.x.dat (fwd)

Andrea Ferretti andrea.ferretti at unimore.it
Wed Jan 27 12:35:24 CET 2016



Dear Gosia,

as far as I know the naming scheme of files in the $prefix.save
directory is that the .xml extension refers to (iotk-written) textual XML 
files, while .dat refers to binary files (probably still written in iotk fmt)

Since magnetization is stored binary (I guess), the files dumped should have 
extension .dat.

Usually, QE does not care whether .xml or .dat is used, and goes ahead 
anyway... probably this is not implemented in the piece of code you are 
referring to.

For the charge density, eg, PW/src/potinit.f90 reads

   !
   filename =  TRIM( tmp_dir ) // TRIM( prefix ) // '.save/charge-density.dat'
   exst     =  check_file_exst( TRIM(filename) )
   !
   IF ( .NOT. exst ) THEN
       !
       filename =  TRIM( tmp_dir ) // TRIM( prefix ) // 
'.save/charge-density.xml'
       exst     =  check_file_exst( TRIM(filename) )
       !
   ENDIF
   !


brute force solution:
convert .dat into .xml  using iotk (eg from espresso/bin)
    iotk convert file.xml file.dat

longer term solution:
fixing the sources should be very simple (worst case scenatio just change .xml 
into .dat, better to support both of them)

Andrea

> 
> Dear Quantum Espresso Users and Developers,
> 
> I faced the following problem trying to calculate the band structure for my 
> system:
> 
> I did my scf calculations including SO with non-zero starting magnetization.
> 
> Then I tried to calculate the band structure, and the program crashed due to 
> the lack of magnetization.x.xml file.
> 
> The problem is that the only file I can find is the magnetization.x.dat.
> 
> How can I obtain the xml files for magnetization? Is it posible from the dat 
> file?
> 
> I use QE 5.3.0 version.
> 
>  
> 
> Thanks in advance,
> 
> Malgorzata Wawrzyniak
> 
> UAM Poznan
> 
>  
> 
>

-- 
Andrea Ferretti, PhD
S3 Center, Istituto Nanoscienze, CNR
via Campi 213/A, 41125, Modena, Italy
Tel: +39 059 2055322;  Skype: andrea_ferretti
URL: http://www.nano.cnr.it


More information about the users mailing list