Unable to restart from DEN when using ivalence

Dear all,
I am doing a calculation on an excited state by using occopt 9, ivalence and nqfd. If I start from scratch, the run ends normally. If I restart from a previously generated DEN file I obtain the following error:

forrtl: severe (24): end-of-file during read, unit 1024, file abi_DS2_DEN
Image              PC                Routine            Line        Source
libifcoremt.so.5   00002B698B5AAF46  for__io_return        Unknown  Unknown
libifcoremt.so.5   00002B698B5E61AD  for_read_seq          Unknown  Unknown
abinit             0000000001CCD01B  Unknown               Unknown  Unknown
abinit             000000000148C60A  Unknown               Unknown  Unknown
abinit             00000000005F63FE  Unknown               Unknown  Unknown
abinit             0000000000439DE8  Unknown               Unknown  Unknown
abinit             0000000000422C57  Unknown               Unknown  Unknown
abinit             000000000040E349  Unknown               Unknown  Unknown
abinit             000000000040BA12  Unknown               Unknown  Unknown
libc-2.17.so       00002B698DCCE555  __libc_start_main     Unknown  Unknown
abinit             000000000040B929  Unknown               Unknown  Unknown

this happens also if I remove the three keywords, so I believe that it is not a reading problem but the file is really not written properly when those keywords are used. This is only my guess. I here attach the input file ab.abi (4.4 KB)

Thanks a lot in advance for your help!

Antonio

Note that irdden and getden are mutually incompatible. If you use ndtset > 1 you need to use getden to read in previously calculated density files; however, if you want to restart from a previous density file, you typically use irdden 1, and (here’s the important part) change the file name from (say) abo_DS2_DEN to abi_DEN (note that no DS# should appear in the file name).

If you want to run another chain of calculations, using ndtset > 1 but still including your previous density, you can do something like change its name to abo_DS99_DEN and then during the chain of calculations, when you need it, use “getden 99”.

I am using the latest version of abinit.
Despite I have only one dataset, it is labelled as 2 for scripting reasons and I need to use the irdden keyword. With this input, I always restarted from the density file abi_DS2_DEN by using “irdden2 1”, and it worked properly. I did a test and if I have
“irdden2 1” with the file abi_DEN present in the folder, abinit exits with the error


--- !ERROR
src_file: m_ioarr.F90
src_line: 1058
mpi_rank: 0
message: |
    Cannot find file: abi_DS2_DEN

if I have the file abi_DS2_DEN and “irdden2 1”, abinit exits with the end-of-file error that I posted above, while it does not happen whenever I do not set ivalence and the other two related variables.
If I have the file abo_DS1_DEN and “getden2 1”, abinit exits with the same end-of-file error.
I then think that the issue is in how the DEN file is generated with the ivalence/nqfd/occopt 9 options.
Thanks a lot for your quick answer.