STD_CCD_CACHE
- openff.pablo.STD_CCD_CACHE: CcdCache
The CCD, with commonly-required patches for biomolecular simulation.
STD_CCD_CACHEis Pablo’s default residue library.This attribute provides the CCD with a dict-like API. When a residue is requested via the indexing syntax (for example,
STD_CCD_CACHE["ALA"]) or theinoperator, a cache is checked first. If the residue is not present, the CCD is then checked. This requires internet access. If the residue cannot be retrieved from the cache or the CCD, aKeyErroris raised orFalseis returned as appropriate.Iterating over the cache, checking its length, or otherwise treating
STD_CCD_CACHEas a mapping other than with the indexing syntax orinoperator works only on the cache itself. As a result, accessing a residue via indexing may return a value even if these other methods suggest it won’t.Several common residues are packaged with Pablo and never require an internet lookup. This includes the canonical amino and nucleic acids, water, several ions, and a few others. CCD entries that are downloaded are stored in
$XDG_CACHE_HOME/openff-pablo/ccd_cacheand are preserved between Python sessions. Pablo assumes that the files in the cache path were downloaded from the CCD and may do unexpected things if they are edited by hand, though deleting them is safe.STD_CCD_CACHEalso includes a number of patches for CCD entries that are known not to adhere to the high standards required for biomolecular simulation. New patches can be added with thewith_patch()method.The
with_()andwith_replacedmethods allow custom definitions to be added to a new copy ofSTD_CCD_CACHE. These custom definitions are not patched. Since they are stored in the cache, custom definitions supercede any that have not already been downloaded from the CCD.Accessing the CCD requires internet access. Without internet access, only entries packaged with Pablo or already in the cache can be loaded.
For details about the available methods, see the class documentation at
openff.pablo.ccd.CcdCache