schrodinger.application.desmond.picklejar module

Facilities for pickling objects that are otherwise uneasy to pickle, e.g., class attributes.

Copyright Schrodinger, LLC. All rights reserved.

class schrodinger.application.desmond.picklejar.CustomUnpickler(file, *, fix_imports=True, encoding='ASCII', errors='strict', buffers=())[source]

Bases: _pickle.Unpickler

find_class(module, name)[source]

Return an object from a specified module.

If necessary, the module will be imported. Subclasses may override this method (e.g. to restrict unpickling of arbitrary classes and functions).

This method is called whenever a class or a function object is needed. Both arguments passed are str objects.

__init__(*args, **kwargs)
load()

Load a pickle.

Read a pickled object representation from the open file object given in the constructor, and return the reconstituted object hierarchy specified therein.

memo
persistent_load
class schrodinger.application.desmond.picklejar.PickleJar[source]

Bases: object

jar = {<class 'schrodinger.application.desmond.picklejar.Picklable'>: {}}
static serialize(fh)[source]
static deserialize(fh)[source]
class schrodinger.application.desmond.picklejar.PicklableMetaClass(name, bases, dict)[source]

Bases: type

__init__(name, bases, dict)[source]
mro()

Return a type’s method resolution order.

class schrodinger.application.desmond.picklejar.Picklable[source]

Bases: object

class schrodinger.application.desmond.picklejar.PickleState[source]

Bases: object