Skip to content

Commit c7614e8

Browse files
authored
👌 Parser: add S matrix not positive definite exit code (#109)
Fixes #103
1 parent 38376ab commit c7614e8

5 files changed

Lines changed: 12 additions & 0 deletions

File tree

src/aiida_hubbard/calculations/hp.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -194,6 +194,8 @@ def define(cls, spec):
194194
message='The electronic minimization cycle did not reach self-consistency.')
195195
spec.exit_code(462, 'ERROR_COMPUTING_CHOLESKY',
196196
message='The code failed during the cholesky factorization.')
197+
spec.exit_code(464, 'ERROR_S_MATRIX_NOT_POSITIVE_DEFINITE',
198+
message='The S matrix was found to be not positive definite.')
197199
spec.exit_code(490, 'ERROR_MISSING_CHI_MATRICES',
198200
message='The code failed to reconstruct the full chi matrix as some chi matrices were missing')
199201
spec.exit_code(495, 'ERROR_INCOMPATIBLE_FFT_GRID',

src/aiida_hubbard/parsers/hp.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,7 @@ def validate_premature_exit(self, logs):
133133
'ERROR_MISSING_PERTURBATION_FILE',
134134
'ERROR_CONVERGENCE_NOT_REACHED',
135135
'ERROR_COMPUTING_CHOLESKY',
136+
'ERROR_S_MATRIX_NOT_POSITIVE_DEFINITE',
136137
'ERROR_MISSING_CHI_MATRICES',
137138
'ERROR_INCOMPATIBLE_FFT_GRID',
138139
'ERROR_FERMI_SHIFT',

src/aiida_hubbard/parsers/parse_raw/hp.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,7 @@ def detect_important_message(logs, line):
8484
'Maximum CPU time exceeded': 'ERROR_OUT_OF_WALLTIME',
8585
'reading inputhp namelist': 'ERROR_INVALID_NAMELIST',
8686
'problems computing cholesky': 'ERROR_COMPUTING_CHOLESKY',
87+
'S matrix not positive definite': 'ERROR_S_MATRIX_NOT_POSITIVE_DEFINITE',
8788
'Reconstruction problem: some chi were not found': 'ERROR_MISSING_CHI_MATRICES',
8889
'incompatible FFT grid': 'ERROR_INCOMPATIBLE_FFT_GRID',
8990
REG_ERROR_CONVERGENCE_NOT_REACHED: 'ERROR_CONVERGENCE_NOT_REACHED',
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
2+
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3+
Error in routine cdiaghg (301):
4+
S matrix not positive definite
5+
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
6+
7+
stopping ...

tests/parsers/test_hp.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -342,6 +342,7 @@ def test_hp_failed_invalid_namelist(aiida_localhost, generate_calc_job_node, gen
342342
('failed_fermi_shift', HpCalculation.exit_codes.ERROR_FERMI_SHIFT.status),
343343
('failed_out_of_walltime', HpCalculation.exit_codes.ERROR_OUT_OF_WALLTIME.status),
344344
('failed_computing_cholesky', HpCalculation.exit_codes.ERROR_COMPUTING_CHOLESKY.status),
345+
('failed_s_matrix_not_positive_definite', HpCalculation.exit_codes.ERROR_S_MATRIX_NOT_POSITIVE_DEFINITE.status),
345346
('failed_missing_chi_matrices', HpCalculation.exit_codes.ERROR_MISSING_CHI_MATRICES.status),
346347
('failed_incompatible_fft_grid', HpCalculation.exit_codes.ERROR_INCOMPATIBLE_FFT_GRID.status),
347348
))

0 commit comments

Comments
 (0)