Critic2Analysis class

I am trying to use pymatgen to run Critic2 to compute some Bader charges for atoms in a structure. I have Critic2 installed (and have carried out the Bader charge integration within it without problem). Looking at the documentation, it would appear that the Critic2Analysis object would be the appropraite way to do so, however, I am not sure what the “stdout” or “cpreport” types should be. The source code link results in a 404 error, so I thought I would ask here. I also don’t understand the relationship, if any, to the Critic2Caller object. Some better documentation (or source access) would help here. Thanks for the help!

class Critic2Analysis (structure, stdout=None, stderr=None, cpreport=None, yt=None, zpsp=None )[source]

Hi @Paul_Fons,

The basic idea is this:

  • The job of Critic2Caller is just to run critic2, I wrote it specifically to make running from VASP output charge densities easier within our infrastructure. Note that since it was first written, critic2 added a native JSON output which made our jobs a lot easier.

You will typically want to use the method that runs this class from a given Chgcar object or path containing chgcars.

  • The class, Critic2Analysis, then parses the output from and creates some native pymatgen objects using it, specifically the StructureGraph which is usually most useful.

It was done in a two-step process to make it easier to store the output of critic2 and then later re-work the analysis as necessary.