@classmethod
def get_number_of_electrons(cls, calc, **kwargs):
    """Return the number of electrons."""
    parameters = calc.outputs.output_parameters
    if 'number_of_electrons' not in parameters.attrs():
        return None
    return parameters.get_attr('number_of_electrons')
