pub fn _depth(mol_block: &str) -> PyResult<u32>
Expand description
Compute assembly depth; see Pagel et al. (2024).
Python version of depth
.
§Python Parameters
mol_block
: The contents of a.mol
file as astr
.
§Python Returns
- The molecule’s
int
assembly depth.
§Python Example
import assembly_theory as at
# Load a mol block from file.
with open('data/checks/benzene.mol') as f:
mol_block = f.read()
# Calculate the molecule's assembly index.
at.depth(mol_block) # 3