Construction Result
- class ConstructionResult(construction_state)[source]
Bases:
object
The result of
TopologyGraph.construct()
.Methods
Get the atom infos of the constructed molecule.
Get the atoms of the constructed molecule.
Get the bond infos of the constructed molecule.
Get the bonds of the constructed molecule.
Yield the building blocks.
get_num_building_block
(building_block)Get the number of times building_block is present.
Get the position matrix of the constructed molecule.
- __init__(construction_state)[source]
Initialize a
ConstructionResult
.- Parameters
construction_state (
ConstructionState
) – The state from which the result is initialized.
- get_building_blocks()[source]
Yield the building blocks.
Building blocks are yielded in an order based on their position in the constructed molecule. For two topologically equivalent constructed molecules, but with different building blocks, equivalently positioned building blocks will be yielded at the same time.
- Yields
BuildingBlock
– A building block of the topology graph.
- get_num_building_block(building_block)[source]
Get the number of times building_block is present.
- Parameters
building_block (
BuildingBlock
) – The building block whose frequency in the constructed molecule is desired.- Returns
The number of times building_block was used in the construction of the constructed molecule.
- Return type