Base featurizer
BaseAtomFeaturizer
Bases: ABC
Abstract base featurizer class for all atom featurization classes.
Source code in bionemo/geometric/base_featurizer.py
24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 |
|
__call__(mol, atom_indices=None)
Returns computed atom features.
Source code in bionemo/geometric/base_featurizer.py
37 38 39 |
|
get_atom_features()
abstractmethod
Computes atom features.
Source code in bionemo/geometric/base_featurizer.py
32 33 34 35 |
|
n_dim()
Number of dimensions of computed feature.
Source code in bionemo/geometric/base_featurizer.py
27 28 29 30 |
|
BaseBondFeaturizer
Bases: ABC
Abstract base featurizer class for all bond featurization classes.
Source code in bionemo/geometric/base_featurizer.py
42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 |
|
__call__(mol, bond_indices=None)
Returns computed bond features.
Source code in bionemo/geometric/base_featurizer.py
55 56 57 |
|
get_bond_features()
abstractmethod
Computes bond features.
Source code in bionemo/geometric/base_featurizer.py
50 51 52 53 |
|
n_dim()
Number of dimensions of computed feature.
Source code in bionemo/geometric/base_featurizer.py
45 46 47 48 |
|
BaseMoleculeFeaturizer
Bases: ABC
Abstract base featurizer class for molecule featurization classes.
Source code in bionemo/geometric/base_featurizer.py
60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 |
|
__call__(mol)
Returns computed molecule features.
Source code in bionemo/geometric/base_featurizer.py
73 74 75 |
|
get_molecule_features(mol)
abstractmethod
Computes molecule features.
Source code in bionemo/geometric/base_featurizer.py
68 69 70 71 |
|
n_dim()
Number of dimensions of computed feature.
Source code in bionemo/geometric/base_featurizer.py
63 64 65 66 |
|
get_boolean_atomic_prop(atom, prop_list=None)
Retrieves boolean atomic properties for a given atom.
This function fetches boolean properties of an atom. If a specific list of properties is provided, it retrieves those properties. Otherwise, it fetches all available boolean properties for the atom.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
atom
|
Atom
|
The atom object to retrieve properties from. |
required |
prop_list
|
list
|
A list of specific property names to retrieve. If None, all available properties will be fetched. Defaults to None. |
None
|
Returns:
Name | Type | Description |
---|---|---|
list |
list[bool]
|
A list of boolean values corresponding to the requested properties. |
Source code in bionemo/geometric/base_featurizer.py
99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 |
|
get_double_atomic_prop(atom, prop_list=None)
Retrieves double atomic properties for a given atom.
This function fetches double properties of an atom. If a specific list of properties is provided, it retrieves those properties. Otherwise, it fetches all available double properties for the atom.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
atom
|
The atom object to retrieve properties from. |
required | |
prop_list
|
list
|
A list of specific property names to retrieve. If None, all available properties will be fetched. Defaults to None. |
None
|
Returns:
Name | Type | Description |
---|---|---|
list |
list[float]
|
A list of float values corresponding to the requested properties. |
Source code in bionemo/geometric/base_featurizer.py
119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 |
|
one_hot_enc(val, num_class)
Performs one-hot encoding on an integer value.
This function creates a one-hot encoded representation of the input value
as a list of boolean values. The resulting list has a length equal to
num_class
, where only the element at index val
is set to True.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
val
|
int
|
An integer representing the value to be one-hot encoded. Must be in the range [0, num_class - 1]. |
required |
num_class
|
int
|
An integer representing the total number of classes or possible classes. |
required |
Returns:
Type | Description |
---|---|
list[bool]
|
One-hot encoding of |
Source code in bionemo/geometric/base_featurizer.py
78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 |
|