schrodinger.livedesign.custom_entity.registration module

This file contains the registration logic for custom entities.

General Description:

This module retrieves the RegistrationData objects for custom entities.

Common Registration Examples:

You can use this module to register:

  • Example 1: Monospecific Antibody An antibody with one unique heavy chain, one unique light chain, one unique antibody arm and a full antibody (containing two duplicate arms)

  • Example 2: Bispecific Antibody An antibody with one or two unqiue heavy chains, one or two unique light chains, two unique antibody arms and a full antibody (containing two unique arms)

  • Example 3: ADC An antibody-drug conjugate with a small molecule, a link and a full antibody (either monospecific or bispecific described above)

  • Example 4: OLED An OLED with layer(s) that contain formulation(s).

A general example can be formulated using the following template:

general_entity = {

‘entity_type’: <A known entity from the EntityClass>, ‘input_property_data’: <A dictionary describing any/all additional input data>, ‘chemical_information’: <A representation of the chemical information (SMILES string, Helm string, etc)> ‘children’: [(child_entity, <Number of repeating child entities>)]

}

The child_entity can be described using the general entity example. When there are no children, an empty list can be provided or the key/value pair omitted.

Unsupported Features:

Currently, this module does not support entities that do not have a corresponding EntityClass. However, custom entities can be constructed and designed using ‘Unknown’ EntityClass types.

class schrodinger.livedesign.custom_entity.registration.EntityComponent

Bases: StrEnum

ENTITY_TYPE = 'entity_type'
INPUT_PROPERTY_DATA = 'input_property_data'
CHEMICAL_INFORMATION = 'chemical_information'
CHILDREN = 'children'
COUNT = 'self_count'
class schrodinger.livedesign.custom_entity.registration.ChildDataComponent

Bases: StrEnum

COUNT = 'count'
class schrodinger.livedesign.custom_entity.registration.InputPropertyDataComponent

Bases: StrEnum

THICKNESS = 'thickness'
ID = 'ID'
schrodinger.livedesign.custom_entity.registration.get_registration_data(data: str, input_format: Format, options: Optional[RegistrationOptions] = None) Iterator[RegistrationData]
schrodinger.livedesign.custom_entity.registration.extract_registration_data(entity: dict) Iterator[RegistrationData]

Given a stack of dictionaries, yield RegistrationData objects.

Parameters:

entity – The dictionary stack.

Returns:

An iterator of RegistrationData objects.

schrodinger.livedesign.custom_entity.registration.get_rdmol(chemical_information: str) str

Given a chemical information string, return the corresponding RDKit molecule in binary base64 format.

Parameters:

chemical_information – The chemical information string.

Returns:

The corresponding RDKit molecule in binary base64 format.

schrodinger.livedesign.custom_entity.registration.get_chemical_model(rdmol_binary: str) Mol

Given a rdmol_binary string, return the corresponding chemical model.

Parameters:

rdmol_binary – The rdmol_binary string.

Returns:

The corresponding chemical model.

schrodinger.livedesign.custom_entity.registration.get_deduplication_hash(entity: dict) str

Given a dictionary that describes an entity, return the corresponding deduplication hash.

Parameters:

entity – The entity dictionary.

Returns:

The corresponding deduplication hash.

schrodinger.livedesign.custom_entity.registration.get_canonical_entity(entity: dict) dict

Given an entity dictionary, return the corresponding canonical entity dictionary.

Parameters:

entity – The entity dictionary.

Returns:

The corresponding canonical entity dictionary.

schrodinger.livedesign.custom_entity.registration.remove_non_deduplication_keys(entity: dict, deduplication_hash_keys: set) None

Given an entity dictionary, remove all keys that are not used for deduplication.

Parameters:

entity – The entity dictionary.

schrodinger.livedesign.custom_entity.registration.get_display_string(chemical_model: Mol) str

Given a chemical model, return the corresponding display string.

Parameters:

chemical_model – The chemical model.

Returns:

The corresponding display string.

schrodinger.livedesign.custom_entity.registration.get_entity_class(entity_type: str) EntityClass

Given a string entity type, return the corresponding EntityClass enum.

Parameters:

entity_type – The string entity type.

Returns:

The corresponding EntityClass enum.

schrodinger.livedesign.custom_entity.registration.validate_registration_data(registration_data: RegistrationData) None

Validate the registration data.

Parameters:

registration_data – The registration data.