The package syrte/fortio to deal with long records in Abinit's WFK file.
Make IrRep compatible with Abinit > 9.0.0, while preserving the compatibility with Abinit 8.x.x. I realized that they changed the header of the WFK file.
The lines that parse records with multiple elements (strings, int, float,...) are now implemented in 2 steps:
1- Parse through record_abinit(fWFK, 'f8') rather than record_abinit(fWFK, '3f8') (this is just an example).
2- Split the record to save it into variables through x, y, z = record[0], record[1],...
I think that way the parsing may be more stable, because it does not require knowing how may elements have to be parsed, only their types. If I'm not wrong, it is implemented that way in WannierBerri.
Clean up the code of the function __init_abinit in kpoint.py and the class AbinitHeader in readfiles.py. It is also made more PEP8 friendly and some error and warning messages have been made more clear.
Fix a bug in the call to Kpoint.write_characters in bandstructure.py: when kpnames was not specified in the CLI, refUC=identity and shiftUC=0,0,0 were always passed to Kpoint.write_characters.
Modify the response to a fail in the matching of symmetries in both unit cells: until now, they must always match. This means that the transformation could only be to the cell of the tables. From now on, the check will still be implemented always, but
1- It must be successful when we want to identify the irreps from the traces (kpnames set in CLI).
2- It is sure that they will match if the user does not specify a transformation in the CLI, because refUC and shiftUC will be calculated automatically to satisfy the match.
3- A warning will be raised and the flow will continue if the user specified in the CLI a transformation that does not match the symmetries in both cells.
In this way, IrRep can be used to calculate the traces in any unit cell setting, not only for the DFT and conventional (tables) cell. In other words, if we want the traces in a cell that is not the conventional, we don't have to run a new DFT calculation with the cell we are interested in; it's enough to give refUC and shiftUC to that cell we want.
Update the list of versions of Abinit for which IrRep has been tested.
This PR implements the following points:
syrte/fortio
to deal with long records in Abinit's WFK file.IrRep
compatible with Abinit > 9.0.0, while preserving the compatibility with Abinit 8.x.x. I realized that they changed the header of the WFK file.record_abinit(fWFK, 'f8')
rather thanrecord_abinit(fWFK, '3f8')
(this is just an example). 2- Split the record to save it into variables throughx, y, z = record[0], record[1],...
I think that way the parsing may be more stable, because it does not require knowing how may elements have to be parsed, only their types. If I'm not wrong, it is implemented that way inWannierBerri
.__init_abinit
inkpoint.py
and the classAbinitHeader
inreadfiles.py
. It is also made more PEP8 friendly and some error and warning messages have been made more clear.Kpoint.write_characters
inbandstructure.py
: whenkpnames
was not specified in the CLI,refUC=identity
andshiftUC=0,0,0
were always passed toKpoint.write_characters
.kpnames
set in CLI). 2- It is sure that they will match if the user does not specify a transformation in the CLI, becauserefUC
andshiftUC
will be calculated automatically to satisfy the match. 3- A warning will be raised and the flow will continue if the user specified in the CLI a transformation that does not match the symmetries in both cells. In this way,IrRep
can be used to calculate the traces in any unit cell setting, not only for the DFT and conventional (tables) cell. In other words, if we want the traces in a cell that is not the conventional, we don't have to run a new DFT calculation with the cell we are interested in; it's enough to giverefUC
andshiftUC
to that cell we want.IrRep
has been tested.