peterspackman / occ

Open Computational Chemistry in C++
https://peterspackman.github.io/occ/
Other
13 stars 2 forks source link

Error when trying to calculate cg energies for one CIF #16

Open MilitaoLucas opened 1 month ago

MilitaoLucas commented 1 month ago

Hello, good evening. When trying and running CrystalGrower for the cif 5FCINH.zip I got the following error:

Fortran runtime error: Bad value during floating point read 

After changing the output's verbosity to debug level, it didn't provide any further details:

****************** Backtrace Start ******************
exception:
    bad optional access
terminating program.

****************** Backtrace End ********************
exception:
    bad optional access

The structure was refined trough Multipole Refinement, so I guess this could be a source of issue. The same structure refined using SHELXL doesn't have the same problem. Both structures are available from CSD in the following link.

peterspackman commented 1 month ago

While the error message isn't particularly helpful here, the issue looks like it's not reading the CIF file (because it can't find the CIF).

You say you're passing it a .zip file, do I understand correctly that it's a zip archive with a a CIF in it? If that works then I'd be surprised, it's certainly not an expected way to run the program (though gemmi may have support for reading compressed CIFs).

Could you provide a few more details here? Are you running it via the CrystalGrower GUI?

MilitaoLucas commented 1 month ago

Github does not accept CIF files. I compressed for it to accept. I am in fact reading the CIF. I initially ran through the CG GUI, but to eliminate possible problems I took the toml and ran it through the command line. I am sorry if it wasn't clear enough.

peterspackman commented 1 month ago

After taking a look, the issue is with unrecognised data item names for the symmetry/space group.

I'll try and update the parsing of CIFs to be a bit more flexible for uncommon data item names, and add more debug output for the context of the failure. For now, a workaround should be pretty easy by just modifying the CIF file itself, adding a line like:

_symmetry_space_group_name_H-M    'P -1'

Should fix it (the space group was P-1 right?)

peterspackman commented 1 month ago

As of 766fc4d the issues for this particular CIF should be fixed, and the symmetry parsing should be a bit more robust (though still no exhaustive for keys for symops etc.)

MilitaoLucas commented 1 month ago

Thank you. I will update later.