Disappearance of Energy Corrections for mp‑1100405 (ScTeRh) under GGA/GGA+U

In the Materials Project database, the entry mp‑1100405 (ScTeRh) has an energy correction of –0.14 eV/atom when plotting GGA/GGA+U phase diagrams. However, when I reproduce the calculation with VASP and pymatgen, I do not observe this correction.

Procedure

  1. I used MPRelaxSet to generate the VASP input files for mp‑1100405 (ScTeRh).
  2. After the calculation finished, I ran the following Python script to read the VASP output and print the energy correction:
from pymatgen.entries.compatibility import MaterialsProject2020Compatibility
from pymatgen.io.vasp.outputs import Vasprun

# Parse the VASP run (no DOS, but include POTCAR parsing)
vrun = Vasprun("./vasprun.xml", parse_dos=False, parse_potcar_file=True)
entry = vrun.get_computed_entry(inc_structure=True)

# Apply the MP2020 compatibility corrections
compat = MaterialsProject2020Compatibility()
corr_entry = compat.process_entry(entry)

print("Returned object type:", type(corr_entry))
if corr_entry:
    print("Total correction (eV):", corr_entry.correction)
else:
    print("Entry was rejected, see reason →")
    print(compat.get_explanations(entry))

Observed Warning / Output

/python3.12/site‑packages/pymatgen/entries/compatibility.py:621: UserWarning: 
  Failed to guess oxidation states for Entry vasprun‑20250721‑1.0‑d3eaabcc24076197dd917eb0e37226aa (ScTeRh). 
  Assigning anion correction to only the most electronegative atom.

Returned object type: <class 'pymatgen.entries.computed_entries.ComputedStructureEntry'>
Total correction (eV): 0.0

I have tried various debugging steps but cannot determine why the –0.14 eV/atom correction from the Materials Project isn’t being applied.

After multiple rounds of debugging, I think this is a system vulnerability. Because I have found that in some materials, it is possible to output corrections, and in some materials, the above-mentioned errors may occur.

Hey @Xuetian_Li the corrections are done in place, so that entry is modified to include the correction. If you see that entry.correction is still 0 after running process_entry, then please share the output of entry.as_dict()

Hello, the output of entry.as-dict() is:

python3.12/site-packages/pymatgen/entries/compatibility.py: 621: UserWarning: Failed to guess oxidation states for Entry vasprun-20250723-2.0-be3500236364da0779484cd7b3d1960e (ScTeRh). Assigning anion correction to only the most electronegative atom.
  adjustments: list[EnergyAdjustment
] = self.get_adjustments(entry)
{'@module': 'pymatgen.entries.computed_entries', '@class': 'ComputedStructureEntry', 'energy': -79.39333173, 'composition': {'Sc': 4.0, 'Te': 4.0, 'Rh': 4.0
    }, 'entry_id': 'vasprun-20250723-2.0-be3500236364da0779484cd7b3d1960e', 'correction': 0.0, 'energy_adjustments': [], 'parameters': {'potcar_symbols': ['PAW_PBE Sc_sv 07Sep2000', 'PAW_PBE Te 08Apr2002', 'PAW_PBE Rh_pv 25Jan2005'
        ], 'potcar_spec': [
            {'titel': 'PAW_PBE Sc_sv 07Sep2000', 'hash': 'c908d92f64698d610daf891fe81b4c57', 'summary_stats': {'keywords': {'header': ['eatom', 'eaug', 'enmax', 'enmin', 'iunscr', 'lcor', 'lexch', 'lpaw', 'lultra', 'ndata', 'orbitaldescriptions', 'orbitals', 'pomass', 'raug', 'rcloc', 'rcore', 'rdep', 'rdept', 'rmax', 'rpacor', 'rrkj', 'rwigs', 'step', 'titel', 'vrhfin', 'zval', 'nentries'
                        ], 'data': ['localpart', 'gradientcorrectionsusedforxc', 'corecharge-density(partial)', 'kineticenergydensity(partial)', 'atomicpseudocharge-density', 'nonlocalpart', 'reciprocalspacepart', 'realspacepart', 'reciprocalspacepart', 'realspacepart', 'nonlocalpart', 'reciprocalspacepart', 'realspacepart', 'reciprocalspacepart', 'realspacepart', 'nonlocalpart', 'reciprocalspacepart', 'realspacepart', 'reciprocalspacepart', 'realspacepart', 'pawradialsets', '(5e20.12)', 'augmentationcharges(nonsperical)', 'uccopanciesinatom', 'grid', 'aepotential', 'corecharge-density', 'kineticenergy-density', 'mkineticenergy-densitypseudized', 'localpseudopotentialcore', 'pspotentialvalenceonly', 'corecharge-density(pseudized)', 'pseudowavefunction', 'aewavefunction', 'pseudowavefunction', 'aewavefunction', 'pseudowavefunction', 'aewavefunction', 'pseudowavefunction', 'aewavefunction', 'pseudowavefunction', 'aewavefunction', 'pseudowavefunction', 'aewavefunction', 'endofdataset'
                        ]
                    }, 'stats': {'header': {'MEAN': 47.21291675983607, 'ABSMEAN': 47.21291675983607, 'VAR': 19124.301896512028, 'MIN': 0.0, 'MAX': 1273.2868
                        }, 'data': {'MEAN': 475.1501349476418, 'ABSMEAN': 511.0884049869529, 'VAR': 25628201.733524792, 'MIN': -324.624570873, 'MAX': 86058.8575637
                        }
                    }
                }
            },
            {'titel': 'PAW_PBE Te 08Apr2002', 'hash': '11ac22d05d08fb6be6beb8cf78b0127c', 'summary_stats': {'keywords': {'header': ['dexc', 'eatom', 'eaug', 'enmax', 'enmin', 'icore', 'iunscr', 'lcor', 'lexch', 'lpaw', 'lultra', 'ndata', 'orbitaldescriptions', 'orbitals', 'pomass', 'raug', 'rcore', 'rdep', 'rdept', 'rmax', 'rpacor', 'rrkj', 'rwigs', 'step', 'titel', 'vrhfin', 'zval', 'nentries'
                        ], 'data': ['localpart', 'gradientcorrectionsusedforxc', 'corecharge-density(partial)', 'kineticenergydensity(partial)', 'atomicpseudocharge-density', 'nonlocalpart', 'reciprocalspacepart', 'realspacepart', 'reciprocalspacepart', 'realspacepart', 'nonlocalpart', 'reciprocalspacepart', 'realspacepart', 'reciprocalspacepart', 'realspacepart', 'nonlocalpart', 'reciprocalspacepart', 'realspacepart', 'pawradialsets', '(5e20.12)', 'augmentationcharges(nonsperical)', 'uccopanciesinatom', 'grid', 'aepotential', 'corecharge-density', 'kineticenergy-density', 'mkineticenergy-densitypseudized', 'localpseudopotentialcore', 'pspotentialvalenceonly', 'corecharge-density(pseudized)', 'pseudowavefunction', 'aewavefunction', 'pseudowavefunction', 'aewavefunction', 'pseudowavefunction', 'aewavefunction', 'pseudowavefunction', 'aewavefunction', 'pseudowavefunction', 'aewavefunction', 'endofdataset'
                        ]
                    }, 'stats': {'header': {'MEAN': 11.730298631707315, 'ABSMEAN': 11.730298631707315, 'VAR': 2151.9821126635975, 'MIN': 0.0, 'MAX': 368.792
                        }, 'data': {'MEAN': 12099.175277456627, 'ABSMEAN': 12120.200312191555, 'VAR': 12921969032.046568, 'MIN': -547.38786, 'MAX': 1741274.85585
                        }
                    }
                }
            },
            {'titel': 'PAW_PBE Rh_pv 25Jan2005', 'hash': '7754470ff260ceb531591deb18e597cd', 'summary_stats': {'keywords': {'header': ['dexc', 'eatom', 'eaug', 'enmax', 'enmin', 'icore', 'iunscr', 'lcor', 'lexch', 'lpaw', 'lultra', 'ndata', 'orbitaldescriptions', 'orbitals', 'pomass', 'raug', 'rcore', 'rdep', 'rdept', 'rmax', 'rpacor', 'rrkj', 'rwigs', 'step', 'titel', 'vrhfin', 'zval', 'nentries'
                        ], 'data': ['localpart', 'gradientcorrectionsusedforxc', 'corecharge-density(partial)', 'kineticenergydensity(partial)', 'atomicpseudocharge-density', 'nonlocalpart', 'reciprocalspacepart', 'realspacepart', 'reciprocalspacepart', 'realspacepart', 'nonlocalpart', 'reciprocalspacepart', 'realspacepart', 'reciprocalspacepart', 'realspacepart', 'nonlocalpart', 'reciprocalspacepart', 'realspacepart', 'reciprocalspacepart', 'realspacepart', 'pawradialsets', '(5e20.12)', 'augmentationcharges(nonsperical)', 'uccopanciesinatom', 'grid', 'aepotential', 'corecharge-density', 'kineticenergy-density', 'mkineticenergy-densitypseudized', 'localpseudopotentialcore', 'pspotentialvalenceonly', 'corecharge-density(pseudized)', 'pseudowavefunction', 'aewavefunction', 'pseudowavefunction', 'aewavefunction', 'pseudowavefunction', 'aewavefunction', 'pseudowavefunction', 'aewavefunction', 'pseudowavefunction', 'aewavefunction', 'pseudowavefunction', 'aewavefunction', 'endofdataset'
                        ]
                    }, 'stats': {'header': {'MEAN': 86.35735590569105, 'ABSMEAN': 86.35735590569105, 'VAR': 56303.57052008248, 'MIN': 0.0, 'MAX': 2226.4782
                        }, 'data': {'MEAN': 6458.014504975984, 'ABSMEAN': 6505.45362931229, 'VAR': 4284326189.248586, 'MIN': -452.967881648, 'MAX': 1059322.85023
                        }
                    }
                }
            }
        ], 'run_type': 'GGA', 'is_hubbard': False, 'hubbards': {}
    }, 'data': {'oxidation_states': {}
    }, 'structure': {'@module': 'pymatgen.core.structure', '@class': 'Structure', 'charge': 0.0, 'lattice': {'matrix': [
                [
                    6.31287624,
                    -0.0,
                    -0.0
                ],
                [
                    -0.0,
                    6.31287627,
                    -0.0
                ],
                [
                    -0.0,
                    -0.0,
                    6.31287629
                ]
            ], 'pbc': (True, True, True), 'a': 6.31287624, 'b': 6.31287627, 'c': 6.31287629, 'alpha': 90.0, 'beta': 90.0, 'gamma': 90.0, 'volume': 251.5833127936602
        }, 'properties': {}, 'sites': [
            {'species': [
                    {'element': 'Sc', 'occu': 1
                    }
                ], 'abc': [
                    -1.2e-07,
                    -2e-08,
                    3e-08
                ], 'properties': {}, 'label': 'Sc', 'xyz': [
                    -7.575451487999999e-07,
                    -1.262575254e-07,
                    1.8938628869999998e-07
                ]
            },
            {'species': [
                    {'element': 'Sc', 'occu': 1
                    }
                ], 'abc': [
                    -1.3e-07,
                    0.50000002,
                    0.49999997
                ], 'properties': {}, 'label': 'Sc', 'xyz': [
                    -8.206739112e-07,
                    3.1564382612575255,
                    3.1564379556137117
                ]
            },
            {'species': [
                    {'element': 'Sc', 'occu': 1
                    }
                ], 'abc': [
                    0.50000013,
                    -2e-08,
                    0.49999997
                ], 'properties': {}, 'label': 'Sc', 'xyz': [
                    3.156438940673911,
                    -1.262575254e-07,
                    3.1564379556137117
                ]
            },
            {'species': [
                    {'element': 'Sc', 'occu': 1
                    }
                ], 'abc': [
                    0.50000013,
                    0.50000002,
                    3e-08
                ], 'properties': {}, 'label': 'Sc', 'xyz': [
                    3.156438940673911,
                    3.1564382612575255,
                    1.8938628869999998e-07
                ]
            },
            {'species': [
                    {'element': 'Te', 'occu': 1
                    }
                ], 'abc': [
                    0.5,
                    0.5,
                    0.5
                ], 'properties': {}, 'label': 'Te', 'xyz': [
                    3.15643812,
                    3.156438135,
                    3.156438145
                ]
            },
            {'species': [
                    {'element': 'Te', 'occu': 1
                    }
                ], 'abc': [
                    0.5,
                    -0.0,
                    0.0
                ], 'properties': {}, 'label': 'Te', 'xyz': [
                    3.15643812,
                    0.0,
                    0.0
                ]
            },
            {'species': [
                    {'element': 'Te', 'occu': 1
                    }
                ], 'abc': [
                    0.0,
                    0.5,
                    0.0
                ], 'properties': {}, 'label': 'Te', 'xyz': [
                    0.0,
                    3.156438135,
                    0.0
                ]
            },
            {'species': [
                    {'element': 'Te', 'occu': 1
                    }
                ], 'abc': [
                    0.0,
                    -0.0,
                    0.5
                ], 'properties': {}, 'label': 'Te', 'xyz': [
                    0.0,
                    0.0,
                    3.156438145
                ]
            },
            {'species': [
                    {'element': 'Rh', 'occu': 1
                    }
                ], 'abc': [
                    0.25,
                    0.25,
                    0.25
                ], 'properties': {}, 'label': 'Rh', 'xyz': [
                    1.57821906,
                    1.5782190675,
                    1.5782190725
                ]
            },
            {'species': [
                    {'element': 'Rh', 'occu': 1
                    }
                ], 'abc': [
                    0.75,
                    0.75,
                    0.25
                ], 'properties': {}, 'label': 'Rh', 'xyz': [
                    4.734657179999999,
                    4.7346572025,
                    1.5782190725
                ]
            },
            {'species': [
                    {'element': 'Rh', 'occu': 1
                    }
                ], 'abc': [
                    0.75,
                    0.25,
                    0.75
                ], 'properties': {}, 'label': 'Rh', 'xyz': [
                    4.734657179999999,
                    1.5782190675,
                    4.734657217500001
                ]
            },
            {'species': [
                    {'element': 'Rh', 'occu': 1
                    }
                ], 'abc': [
                    0.25,
                    0.75,
                    0.75
                ], 'properties': {}, 'label': 'Rh', 'xyz': [
                    1.57821906,
                    4.7346572025,
                    4.734657217500001
                ]
            }
        ]
    }
}

Thanks, the -0.14 eV/atom correction is due to an anion correction. For this to apply, oxidation states have to be given in the entry. In our build process, these are applied as follows:

from pymatgen.entries.compatibility import MaterialsProject2020Compatibility
from pymatgen.analysis.bond_valence import BVAnalyzer

try:
    bva = BVAnalyzer()
    entry.data["oxidation_states"] = {
        site.species.elements[0].name : bva.get_valences(entry.structure)[i]
        for i, site in enumerate(entry.structure)
    }
except Exception as exc:
    oxi_states = entry.composition.oxi_state_guesses()
    if len(oxi_states) > 0:
        entry.data["oxidation_states"] = oxi_states[0]

compat = MaterialsProject2020Compatibility()
compat.process_entry(entry)