[ase-users] Error reading cif file - out of memory.

Gaël DONVAL gael.donval at cnrs-imn.fr
Tue Jan 22 20:50:48 CET 2013


Hi,

Ill-formatted file l.26:
        ; 1925 62 255 259 ZEKGAX
should be:
        1925 62 255 259 ZEKGAX
        ;
        
But I must admit that a piece of code beginning by "while True" is
usually not a bright idea (in cif.py l.68) :)

Cheers,
Gaël 

Le mardi 22 janvier 2013 à 17:47 +0100, Peter Bjerre Jensen a écrit :
> Hi
> 
> Can anyone tell me why, reading the attached cif file is not working and 
> uses A LOT of memory (I used ~10 GB before it was killed).
> 
> The cif file is from the ICSD database.
> 
> I try the following:
> 
> Python 2.4.3 (#1, Jan  9 2013, 06:47:03)
> [GCC 4.1.2 20080704 (Red Hat 4.1.2-54)] on linux2
> Type "help", "copyright", "credits" or "license" for more information.
>  >>> from ase.io import *
>  >>> atoms = read('Zr_RT_53785.cif')
> Traceback (most recent call last):
>    File "<stdin>", line 1, in ?
>    File "/home/camp/pbjen/bin/ase_2686/ase/io/__init__.py", line 201, in 
> read
>      return read_cif(filename, index)
>    File "/home/camp/pbjen/bin/ase_2686/ase/io/cif.py", line 276, in read_cif
>      blocks = parse_cif(fileobj)
>    File "/home/camp/pbjen/bin/ase_2686/ase/io/cif.py", line 185, in 
> parse_cif
>      blocks.append(parse_block(fileobj, line))
>    File "/home/camp/pbjen/bin/ase_2686/ase/io/cif.py", line 167, in 
> parse_block
>      tags = parse_items(fileobj, line)
>    File "/home/camp/pbjen/bin/ase_2686/ase/io/cif.py", line 155, in 
> parse_items
>      temp = parse_multiline_string(fileobj, line)
>    File "/home/camp/pbjen/bin/ase_2686/ase/io/cif.py", line 72, in 
> parse_multiline_string
>      lines.append(line)
> MemoryError
>  >>>
> 
> /Peter
> 
> PS. I think the solution for now for me will be to manually build the 
> unit cell, by entering the parameters; but I do not think this should be 
> necessary?
> 
> _______________________________________________
> ase-users mailing list
> ase-users at listserv.fysik.dtu.dk
> https://listserv.fysik.dtu.dk/mailman/listinfo/ase-users





More information about the ase-users mailing list