chython 3.5__tar.gz → 3.6__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of chython might be problematic. Click here for more details.
- {chython-3.5/chython.egg-info → chython-3.6}/PKG-INFO +3 -1
- {chython-3.5 → chython-3.6}/chython/__init__.py +20 -13
- {chython-3.5 → chython-3.6}/chython/chemistry/_isomers.py +6 -3
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_isomers.py +12 -0
- {chython-3.5 → chython-3.6}/chython/core/_molecule_container.pxi +14 -7
- {chython-3.5 → chython-3.6}/chython/core/_smirks_patch.pxi +5 -3
- {chython-3.5 → chython-3.6}/chython/core/_smirks_read.pxi +8 -2
- {chython-3.5 → chython-3.6}/chython/core/_stereo.pxi +144 -0
- {chython-3.5 → chython-3.6}/chython/core/chains.py +22 -8
- {chython-3.5 → chython-3.6}/chython/core/monomers.py +46 -0
- chython-3.6/chython/core/nucleotides.py +106 -0
- {chython-3.5 → chython-3.6}/chython/core/reaction.py +5 -5
- {chython-3.5 → chython-3.6}/chython/core/test/test_chains.py +12 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_dead_stereo_groups.py +43 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_enrich.py +13 -1
- {chython-3.5 → chython-3.6}/chython/core/test/test_monomers.py +14 -0
- chython-3.6/chython/core/test/test_nucleotides.py +52 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_smirks_filter.py +16 -0
- {chython-3.5 → chython-3.6}/chython/core/wedge.py +5 -2
- {chython-3.5 → chython-3.6}/chython/depict/__init__.py +6 -6
- {chython-3.5 → chython-3.6}/chython/depict/_config.py +27 -9
- {chython-3.5 → chython-3.6}/chython/depict/bonds.py +28 -3
- {chython-3.5 → chython-3.6}/chython/depict/figure.py +25 -9
- chython-3.6/chython/depict/layout/cage.py +288 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/cascade.py +262 -58
- {chython-3.5 → chython-3.6}/chython/depict/layout/molecule.py +145 -80
- chython-3.6/chython/depict/layout/nucleic.py +118 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/peptide.py +265 -37
- {chython-3.5 → chython-3.6}/chython/depict/layout/primitive.py +145 -13
- {chython-3.5 → chython-3.6}/chython/depict/layout/reaction.py +7 -6
- {chython-3.5 → chython-3.6}/chython/depict/layout/relax.py +13 -3
- {chython-3.5 → chython-3.6}/chython/depict/layout/review.py +4 -2
- {chython-3.5 → chython-3.6}/chython/depict/layout/score.py +2 -1
- {chython-3.5 → chython-3.6}/chython/depict/layout/scorecard.py +4 -4
- chython-3.6/chython/depict/layout/shapes.py +690 -0
- {chython-3.5 → chython-3.6}/chython/depict/peptide.py +16 -2
- chython-3.6/chython/depict/test/test_cage.py +215 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/test_clean2d.py +97 -6
- {chython-3.5 → chython-3.6}/chython/depict/test/test_layout_cascade.py +166 -2
- {chython-3.5 → chython-3.6}/chython/depict/test/test_layout_conventions.py +6 -9
- {chython-3.5 → chython-3.6}/chython/depict/test/test_layout_env.py +1 -1
- {chython-3.5 → chython-3.6}/chython/depict/test/test_layout_primitive.py +66 -1
- chython-3.6/chython/depict/test/test_nucleic_layout.py +69 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/test_peptide_draw.py +55 -15
- {chython-3.5 → chython-3.6}/chython/depict/test/test_peptide_layout.py +160 -51
- {chython-3.5 → chython-3.6}/chython/depict/wedge.py +11 -6
- {chython-3.5 → chython-3.6}/chython/reactions/_enumerate.py +129 -17
- {chython-3.5 → chython-3.6}/chython/reactions/_reconstruct.py +129 -15
- {chython-3.5 → chython-3.6}/chython/reactions/tables/functional.tsv +5 -5
- chython-3.6/chython/reactions/tables/protective.tsv +130 -0
- {chython-3.5 → chython-3.6}/chython/reactions/tables/reactions.tsv +1 -1
- {chython-3.5 → chython-3.6}/chython/reactions/test/_frozen_ids.py +2 -2
- {chython-3.5 → chython-3.6}/chython/reactions/test/test_functional.py +15 -0
- {chython-3.5 → chython-3.6}/chython/reactions/test/test_protective.py +46 -1
- {chython-3.5 → chython-3.6}/chython/reactions/test/test_reconstruct.py +82 -25
- {chython-3.5 → chython-3.6}/chython/test/test_facade_names.py +6 -0
- {chython-3.5 → chython-3.6/chython.egg-info}/PKG-INFO +3 -1
- {chython-3.5 → chython-3.6}/chython.egg-info/SOURCES.txt +6 -0
- {chython-3.5 → chython-3.6}/chython.egg-info/requires.txt +3 -0
- {chython-3.5 → chython-3.6}/pyproject.toml +4 -1
- chython-3.5/chython/depict/layout/shapes.py +0 -332
- chython-3.5/chython/reactions/tables/protective.tsv +0 -128
- {chython-3.5 → chython-3.6}/LICENSE +0 -0
- {chython-3.5 → chython-3.6}/MANIFEST.in +0 -0
- {chython-3.5 → chython-3.6}/README.md +0 -0
- {chython-3.5 → chython-3.6}/build_inchi.py +0 -0
- {chython-3.5 → chython-3.6}/chython/_functions.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/__init__.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/_abbreviations.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/_canonicalize.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/_counts.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/_crippen.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/_hydrogens.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/_implicit.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/_kekule_form.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/_maccs.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/_organometallics.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/_perceive.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/_pharmacophore.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/_protomers.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/_qed.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/_residues.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/_resonance.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/_salts.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/_saturate.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/_smarts.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/_standardize.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/_stereo_audit.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/_tables.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/_tpsa.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/tables/abbreviations.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/tables/acids.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/tables/covalent_radii.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/tables/crippen.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/tables/hbond.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/tables/maccs.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/tables/maccs_corpus.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/tables/pharmacophore.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/tables/qed_alerts.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/tables/residues.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/tables/resonance.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/tables/rotatable.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/tables/salts.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/tables/standardize_groups.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/tables/standardize_metals.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/tables/stereo_audit.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/tables/sybyl_types.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/tables/tpsa.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/__init__.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/_corpus.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/_oracle.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/gen_standardize_rules.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_abbreviations.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_acids_tsv.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_canonicalize.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_canonicalize_atom_order.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_counts.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_covalent_radii_tsv.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_crippen.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_crippen_tsv.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_dependency_direction.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_featurizer_injection.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_featurizer_tables_lazy.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_kekule_form.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_maccs.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_maccs_corpus.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_maccs_tsv.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_organometallics.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_perceive.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_pharmacophore.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_protomers.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_qed.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_qed_alerts_tsv.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_reaction_hydrogen_repair.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_reaction_passes.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_residues.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_resonance.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_resonance_tsv.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_salts.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_saturate.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_smarts.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_standardize_differential.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_standardize_groups_port.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_standardize_overvalent_nitrogen.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_standardize_rules_examples.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_standardize_rules_merges.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_standardize_rules_tsv.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_stereo_audit.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_thiele_is_single_purpose.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_tpsa.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_tpsa_tsv.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_valence_report.py +0 -0
- {chython-3.5 → chython-3.6}/chython/chemistry/test/test_z_translation.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/RULES.md +0 -0
- {chython-3.5 → chython-3.6}/chython/core/__init__.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_canonical.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_cip.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_core.pyx +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_descriptors.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_elements.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_facade.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_features.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_fingerprints.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_hydrogens.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_inchi.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_isomorphism.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_kekule.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_layout_score.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_log.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_ml.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_molecule_arena.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_molecule_topology.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_molecule_views.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_morgan.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_pach.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_pach3.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_query_arena.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_query_boxes.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_query_container.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_query_seal.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_reaction_passes.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_rings.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_smarts_read.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_smiles_read.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_smiles_write.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_sssr.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_stereo_meaning.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_thiele.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/_valence.pxi +0 -0
- {chython-3.5 → chython-3.6}/chython/core/elements.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/core/isotopes.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/__init__.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/arena_v4_corpus.bin.gz +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/bench_ml.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/chytorch_oracle.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/gen_element_tables.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/gen_modeling_view_corpus.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/gen_pach3_corpus.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/gen_reaction_pach_corpus.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/gen_v3_fixtures.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/gen_v4_fixtures.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/gen_valence_rules.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/modeling_view_corpus.json.gz +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/modeling_view_corpus.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/oracle.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/pach3_corpus.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/pach_bond_group_corpus.bin.gz +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/pach_corpus.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/pach_v0_corpus.bin.gz +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/pach_v0_native_corpus.bin.gz +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/pach_v2_corpus.bin.gz +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/pach_v3_corpus.bin.gz +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/pach_v4_corpus.bin.gz +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/peptides.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/reaction_pach_corpus.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/reaction_pach_v2_corpus.bin.gz +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_aggregates.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_alternative_spellings.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_apply_scratch_probe.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_arena_f60.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_arena_identity.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_arena_v3_compat.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_arena_v4_compat.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_aromatic_storage.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_atropisomer_axis.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_brace_bond_fields.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_bridgehead_realisability.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_canonical.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_canonical_groups.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_canonical_mirror.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_canonical_stereogenic.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_canonicalize_stereo_groups.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_cip_assign.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_cip_budget.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_cip_cases.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_cip_digraph.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_cip_ranking.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_cip_storage.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_clean_isotopes_and_coordinate_bonds.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_clean_stereo.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_conformers.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_container_log.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_copy_caches.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_cx_wedges.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_derive.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_descriptors.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_element_tables.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_facade.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_features.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_featurizer_injection.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_fingerprints.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_geometry.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_h_unknown.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_helical_units.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_hydrogens.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_identity_memo.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_inchi.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_interop_injection.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_isomorphism.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_kekule.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_log.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_magic.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_meta.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_ml_encoding.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_ml_reaction_transition.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_ml_state_view.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_ml_transition_view.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_ml_unpack_differential.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_modeling_view_frozen.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_molecule.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_morgan.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_no_chython_two_imports.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_oracle.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_pach.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_pach3.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_pack.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_planar_units.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_query.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_r_edit.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_r_query.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_r_semantics.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_r_serialisation.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_r_smirks.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_r_storage.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_reaction_container.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_reaction_identity.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_reaction_pach.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_reaction_passes.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_reaction_patch_stereo.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_reaction_smiles.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_rings.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_rings_c60.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_set_element.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_sgroups.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_smarts_read.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_smiles_r.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_smiles_read.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_smiles_roundtrip.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_smiles_stereo_marks.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_smiles_write.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_smiles_write_aromatic.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_smiles_write_cis_trans.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_smiles_write_detached.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_smiles_write_differential.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_smiles_write_h_unknown.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_smiles_write_stereo.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_smiles_write_sticky.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_smirks_patch.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_smirks_read.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_smirks_report.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_smirks_stereo.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_stereo_acceptance.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_stereo_anchor_identity.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_stereo_group_meaning.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_stereo_group_signs.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_stereo_group_storage.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_stereo_liveness.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_stereo_owners.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_stereo_parity.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_stereo_perception.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_stereo_query.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_stereo_units.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_stereo_v2_differential.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_stereogenicity_symmetry.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_structure.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_thiele.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_thiele_atom_order.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_title.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_topology.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_union_stereo.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_valence.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/test_view_surface.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/v3_fixtures.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/test/v4_fixtures.py +0 -0
- {chython-3.5 → chython-3.6}/chython/core/valence_rules.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/_hooks.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/colorbar.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/colormap.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/field.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/label.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/__init__.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/approved.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/clean2d.js +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/edits.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/env.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/features.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/greedy.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/lattice.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/learn/__init__.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/learn/alphazero.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/learn/demos.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/learn/evaluate.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/learn/judge.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/learn/mcts.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/learn/policy.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/learn/replay.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/learn/sweep.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/learn/targets.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/learn/tensors.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/learn/train.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/pose.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/quality.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/rings.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/search.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/templates.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/layout/tree.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/metrics/__init__.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/metrics/helvetica.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/metrics/times.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/overlay.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/render/__init__.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/render/svg.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/scene.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/style.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/__init__.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/learn/__init__.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/learn/test_alphazero.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/learn/test_demos.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/learn/test_judge.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/learn/test_mcts.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/learn/test_policy.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/learn/test_replay.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/learn/test_targets.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/learn/test_train.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/test_bonds.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/test_colorbar.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/test_colormap.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/test_field.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/test_figure.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/test_label.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/test_layout_controller.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/test_layout_engine.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/test_layout_relax.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/test_metrics.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/test_overlay.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/test_package.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/test_quality.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/test_r_atom.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/test_review.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/test_scene.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/test_scorecard.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/test_style.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/test_svg.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/test_wedge_draw.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/test/test_x3dom.py +0 -0
- {chython-3.5 → chython-3.6}/chython/depict/x3dom.py +0 -0
- {chython-3.5 → chython-3.6}/chython/exceptions.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/__init__.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/_text.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/CTFILE.md +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/__init__.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/_ctab.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/_errors.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/_facade.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/_hydrogens.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/_rdf.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/_rxn.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/_sdf.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/_sgroup.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/_stream.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/_tokens.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/_v2000.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/_v3000.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/test/__init__.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/test/conftest.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/test/test_aromatic.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/test/test_container_log.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/test/test_data_labels.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/test/test_facade.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/test/test_fidelity.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/test/test_hydrogens.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/test/test_r_atom.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/test/test_rdf.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/test/test_rxn.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/test/test_sdf.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/test/test_sgroup.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/test/test_stereo_drawings.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/test/test_stereo_label.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/test/test_stream.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/test/test_tokens.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/test/test_v2000.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/test/test_v3000.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/ctfile/test/test_wedge.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/mol2.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/pdb/__init__.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/pdb/_builder.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/pdb/_legacy.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/pdb/_mmcif.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/pdb/_records.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/pdb/_star.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/test/__init__.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/test/conftest.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/test/oracles.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/test/test_conformance.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/test/test_done_when.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/test/test_isolation.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/test/test_log_prefix.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/test/test_mmcif.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/test/test_mol2.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/test/test_no_review_bookkeeping.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/test/test_oracles.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/test/test_pdb.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/test/test_pdb_builder.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/test/test_perceive_agreement.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/test/test_read_only_facades.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/test/test_xyz.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/test/test_xyz_builder.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/xml/__init__.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/xml/_cml.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/xml/_dialect.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/xml/_errors.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/xml/_facade.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/xml/_mrv.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/xml/_tree.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/xml/test/__init__.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/xml/test/conftest.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/xml/test/test_cml.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/xml/test/test_container_log.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/xml/test/test_dead_stereo_groups.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/xml/test/test_dialect.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/xml/test/test_equivalence.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/xml/test/test_facade.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/xml/test/test_mrv.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/xml/test/test_mrv_census.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/xml/test/test_tree.py +0 -0
- {chython-3.5 → chython-3.6}/chython/formats/xyz.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/__init__.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/_cdk.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/_cdpkit.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/_indigo.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/_iupac.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/_java.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/_openbabel.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/_pandas.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/_rdkit.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/_records.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/_stereo.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/config.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/conformers.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/test/__init__.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/test/conftest.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/test/test_cdk.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/test/test_cdpkit.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/test/test_config.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/test/test_conformers.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/test/test_coordinate_honesty.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/test/test_dispatch.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/test/test_indigo.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/test/test_iupac.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/test/test_log_delivery.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/test/test_openbabel.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/test/test_pandas.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/test/test_rdkit.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/test/test_stereo.py +0 -0
- {chython-3.5 → chython-3.6}/chython/interop/test/test_v2_oracle.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/__init__.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/_numbering.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/_stickers.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/_tables.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/attention/__init__.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/attention/_assign.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/attention/_encode.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/attention/_session.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/tables/roles.tsv +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/test/__init__.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/test/golden_subset.smi +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/test/test_attention.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/test/test_attention_assign.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/test/test_attention_encode.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/test/test_attention_isolation.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/test/test_dependency_direction.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/test/test_enumerate.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/test/test_id_stability.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/test/test_numbering.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/test/test_probes.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/test/test_reconstruct_labels.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/test/test_retro.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/test/test_retro_probes.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/test/test_retro_tables.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/test/test_roles.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/test/test_stickers.py +0 -0
- {chython-3.5 → chython-3.6}/chython/reactions/test/test_tables.py +0 -0
- {chython-3.5 → chython-3.6}/chython/test/__init__.py +0 -0
- {chython-3.5 → chython-3.6}/chython/test/test_code_hygiene.py +0 -0
- {chython-3.5 → chython-3.6}/chython/test/test_container_methods.py +0 -0
- {chython-3.5 → chython-3.6}/chython/test/test_doc_figures.py +0 -0
- {chython-3.5 → chython-3.6}/chython/test/test_doc_references.py +0 -0
- {chython-3.5 → chython-3.6}/chython/test/test_doc_samples.py +0 -0
- {chython-3.5 → chython-3.6}/chython/test/test_hydrogen_parity.py +0 -0
- {chython-3.5 → chython-3.6}/chython/test/test_libinchi_staging.py +0 -0
- {chython-3.5 → chython-3.6}/chython/test/test_log_records.py +0 -0
- {chython-3.5 → chython-3.6}/chython/test/test_optional_numpy.py +0 -0
- {chython-3.5 → chython-3.6}/chython/test/test_packaging.py +0 -0
- {chython-3.5 → chython-3.6}/chython/test/test_performance.py +0 -0
- {chython-3.5 → chython-3.6}/chython/test/test_r_atom_integration.py +0 -0
- {chython-3.5 → chython-3.6}/chython/test/test_release_build.py +0 -0
- {chython-3.5 → chython-3.6}/chython/test/test_stereo_bluebook.py +0 -0
- {chython-3.5 → chython-3.6}/chython/test/test_v2_boundary.py +0 -0
- {chython-3.5 → chython-3.6}/chython/test/test_writer_posture.py +0 -0
- {chython-3.5 → chython-3.6}/chython.egg-info/dependency_links.txt +0 -0
- {chython-3.5 → chython-3.6}/chython.egg-info/top_level.txt +0 -0
- {chython-3.5 → chython-3.6}/setup.cfg +0 -0
- {chython-3.5 → chython-3.6}/setup.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: chython
|
|
3
|
-
Version: 3.
|
|
3
|
+
Version: 3.6
|
|
4
4
|
Summary: Library for processing molecules and reactions in python way
|
|
5
5
|
Author-email: Ramil Nugmanov <nougmanoff@protonmail.com>
|
|
6
6
|
License-Expression: LGPL-3.0-or-later
|
|
@@ -34,6 +34,8 @@ Requires-Dist: onnxruntime>=1.16; extra == "mapping"
|
|
|
34
34
|
Requires-Dist: chython-rxnmap>=2.0; extra == "mapping"
|
|
35
35
|
Provides-Extra: rdkit
|
|
36
36
|
Requires-Dist: rdkit>=2025.9; extra == "rdkit"
|
|
37
|
+
Provides-Extra: v8
|
|
38
|
+
Requires-Dist: mini-racer>=0.12; extra == "v8"
|
|
37
39
|
Provides-Extra: extra-clean2d
|
|
38
40
|
Requires-Dist: jpype1>=1.6.0; extra == "extra-clean2d"
|
|
39
41
|
Requires-Dist: openbabel-wheel>=3.1.1.22; extra == "extra-clean2d"
|
|
@@ -20,17 +20,19 @@
|
|
|
20
20
|
#
|
|
21
21
|
"""chython's public surface: a facade re-exporting the packages below it.
|
|
22
22
|
|
|
23
|
-
`__all__` is empty by design
|
|
24
|
-
object. `smiles` is bidirectional: a string in reads -- a
|
|
25
|
-
reaction SMILES and the result a `ReactionContainer` -- and a
|
|
26
|
-
same door for the wire format, and `unpach`/`unpack` its import
|
|
23
|
+
`__all__` is empty by design; `__version__` is the installed distribution's. `smarts` is the short
|
|
24
|
+
spelling of `read_smarts` and the same function object. `smiles` is bidirectional: a string in reads -- a
|
|
25
|
+
`>` that is not a dative `->` makes it a reaction SMILES and the result a `ReactionContainer` -- and a
|
|
26
|
+
container in writes one. `pach` is the same door for the wire format, and `unpach`/`unpack` its import
|
|
27
|
+
half under chython 2's two names.
|
|
27
28
|
"""
|
|
29
|
+
from importlib.metadata import PackageNotFoundError as _NotInstalled, version as _version
|
|
28
30
|
from sys import modules as _modules
|
|
29
31
|
from types import ModuleType as _ModuleType
|
|
30
32
|
from .core import *
|
|
31
33
|
from .core import read_smarts as smarts
|
|
32
|
-
from .depict import (Clean2DEngine, DepictStyle, get_chain_layout, get_clean2d_engine, get_depict_style,
|
|
33
|
-
|
|
34
|
+
from .depict import (Clean2DEngine, DepictStyle, JSRuntime, get_chain_layout, get_clean2d_engine, get_depict_style,
|
|
35
|
+
get_js_runtime, set_chain_layout, set_clean2d_engine, set_depict_style, set_js_runtime)
|
|
34
36
|
from .formats import *
|
|
35
37
|
# By full path, not through `formats`' star: `pdb` is that subpackage's name too and the function
|
|
36
38
|
# would shadow it.
|
|
@@ -45,8 +47,8 @@ from .interop.config import _facade_alias as _interop_facade_alias
|
|
|
45
47
|
|
|
46
48
|
|
|
47
49
|
class _Facade(_ModuleType):
|
|
48
|
-
"""Gives `chython` itself properties, so `chython.clean2d_engine
|
|
49
|
-
`chython.
|
|
50
|
+
"""Gives `chython` itself properties, so `chython.clean2d_engine`, `chython.js_runtime` and
|
|
51
|
+
`chython.chain_layout` forward both the read and the write to their one home in `depict/_config.py`,
|
|
50
52
|
validated on the spot.
|
|
51
53
|
"""
|
|
52
54
|
@property
|
|
@@ -66,16 +68,21 @@ class _Facade(_ModuleType):
|
|
|
66
68
|
set_chain_layout(flag)
|
|
67
69
|
|
|
68
70
|
@property
|
|
69
|
-
def
|
|
70
|
-
return
|
|
71
|
+
def js_runtime(self) -> JSRuntime:
|
|
72
|
+
return get_js_runtime()
|
|
71
73
|
|
|
72
|
-
@
|
|
73
|
-
def
|
|
74
|
-
|
|
74
|
+
@js_runtime.setter
|
|
75
|
+
def js_runtime(self, runtime: JSRuntime):
|
|
76
|
+
set_js_runtime(runtime)
|
|
75
77
|
|
|
76
78
|
|
|
77
79
|
_modules[__name__].__class__ = _Facade
|
|
78
80
|
|
|
81
|
+
try: # the installed distribution's version; None for a bare source tree
|
|
82
|
+
__version__ = _version('chython')
|
|
83
|
+
except _NotInstalled:
|
|
84
|
+
__version__ = None
|
|
85
|
+
|
|
79
86
|
# `conformer_engine` and `class_paths` live in `chython.interop.config`; aliased here rather than
|
|
80
87
|
# copied, or `chython.conformer_engine = 'cdpkit'` would be a silent no-op. Must run AFTER the
|
|
81
88
|
# `__class__` assignment above: `_facade_alias` subclasses whatever class the module currently has, so
|
|
@@ -564,11 +564,12 @@ def _imine_handover(molecule: MoleculeContainer, lines: list) -> bool:
|
|
|
564
564
|
ring path keeps a ring's hydrogen count and the amidine path stays out of a ring holding a C=C, so the
|
|
565
565
|
hydrogen an exocyclic imine took from the ring is handed back here, and both paths then place the rest.
|
|
566
566
|
The imine nitrogen bears carbon or hydrogen only -- an amidoxime keeps its oxime -- and the ring nitrogen
|
|
567
|
-
is an `-NH-` of single bonds
|
|
567
|
+
is an `-NH-` of single bonds, and gives its hydrogen once: of the two imines of 1,3-diiminoisoindoline
|
|
568
|
+
one takes it, the other stays an imine. Of two such nitrogens the canonical order picks one, the ring path
|
|
568
569
|
deciding between them again when the system is one it places. A ring system with no C=C, a cyclic
|
|
569
570
|
guanidine of a triazinane or creatinine, is the amidine path's and is not touched.
|
|
570
571
|
"""
|
|
571
|
-
moves = []
|
|
572
|
+
moves, used = [], set() # a donor gives its hydrogen, and takes its C=N, once
|
|
572
573
|
positions = None
|
|
573
574
|
for atoms, _ in _ring_systems(molecule):
|
|
574
575
|
if not _conjugated_carbon(molecule, atoms):
|
|
@@ -582,7 +583,8 @@ def _imine_handover(molecule: MoleculeContainer, lines: list) -> bool:
|
|
|
582
583
|
and all(molecule.element_of(y) in (1, 6) for y in molecule.neighbors_of(x) if y != c)]
|
|
583
584
|
if not imines:
|
|
584
585
|
continue
|
|
585
|
-
donors = [y for y in molecule.neighbors_of(c) if y in atoms and
|
|
586
|
+
donors = [y for y in molecule.neighbors_of(c) if y in atoms and y not in used
|
|
587
|
+
and molecule.element_of(y) == 7
|
|
586
588
|
and not molecule.charge_of(y) and not molecule.radical_of(y) and molecule.implicit_h_of(y)
|
|
587
589
|
and all(molecule.order_of(y, z) == 1 for z in molecule.neighbors_of(y))]
|
|
588
590
|
if not donors:
|
|
@@ -595,6 +597,7 @@ def _imine_handover(molecule: MoleculeContainer, lines: list) -> bool:
|
|
|
595
597
|
positions = molecule.atoms_order
|
|
596
598
|
donors.sort(key=positions.__getitem__)
|
|
597
599
|
moves.append((c, imines[0], donors[0]))
|
|
600
|
+
used.add(donors[0])
|
|
598
601
|
if not moves:
|
|
599
602
|
return False
|
|
600
603
|
counts = {n: molecule.implicit_h_of(n) for _, x, y in moves for n in (x, y)}
|
|
@@ -704,3 +704,15 @@ def test_an_amidine_c_n_with_a_choice_of_acceptor_carries_no_e_z():
|
|
|
704
704
|
m = read_smiles(kept)
|
|
705
705
|
standardize_isomers(m)
|
|
706
706
|
assert '/' in str(m) or '\\' in str(m), kept
|
|
707
|
+
|
|
708
|
+
|
|
709
|
+
def test_two_exocyclic_imines_share_one_ring_hydrogen():
|
|
710
|
+
"""1,3-Diiminoisoindoline: both imines sit beside one ring N-H, which gives its hydrogen once. One imine
|
|
711
|
+
takes it, the other stays: the neutral amino-imino form, the formula kept, the same molecule as that
|
|
712
|
+
tautomer written as such."""
|
|
713
|
+
molecule = read_smiles('c1ccc2C(NC(c2c1)=N)=N')
|
|
714
|
+
formula = molecule.brutto_formula
|
|
715
|
+
assert standardize_isomers(molecule)
|
|
716
|
+
assert molecule.brutto_formula == formula and not check_valence(molecule), str(molecule)
|
|
717
|
+
assert not any(molecule.charge_of(n) for n in molecule.atom_numbers)
|
|
718
|
+
assert converge('c1ccc2C(NC(c2c1)=N)=N', 'NC1=NC(=N)c2ccccc12')[2]
|
|
@@ -613,7 +613,7 @@ def _set_depict_fns(*, clean2d=None, layout2d=None, rescale2d=None, reaction_cle
|
|
|
613
613
|
`mol.clean2d()` worked, and no caller could tell why. `chython.depict` calls this at its own import
|
|
614
614
|
time.
|
|
615
615
|
|
|
616
|
-
THE LAYOUT GROUP. The molecule pair takes `(molecule, *, engine=None, force=False,
|
|
616
|
+
THE LAYOUT GROUP. The molecule pair takes `(molecule, *, engine=None, force=False, chain=None)`;
|
|
617
617
|
`clean2d` stores and returns None, `layout2d` returns `{n: (x, y)}` and stores nothing. `rescale2d`
|
|
618
618
|
takes the molecule alone, rewrites the stored plane to average bond length 0.825 and answers whether
|
|
619
619
|
it rescaled. The reaction pair takes the same keywords; `layout2d` returns `(planes, arrow, signs)`
|
|
@@ -6454,6 +6454,13 @@ cdef class MoleculeContainer:
|
|
|
6454
6454
|
if not unit['parity']:
|
|
6455
6455
|
continue
|
|
6456
6456
|
anchor = inverse[unit['anchor']]
|
|
6457
|
+
if anchor not in base_refs and isinstance(unit['owners'], tuple) and unit['anchor'] in unit['owners']:
|
|
6458
|
+
# a cis/trans unit, which either end of its bond may anchor: two records can pick opposite
|
|
6459
|
+
# ends. An allene's anchor is its midpoint, the same in both. The refs come across
|
|
6460
|
+
# unchanged -- a pair exchange is even, and `_parity_in_order` takes it.
|
|
6461
|
+
for x in unit['owners']:
|
|
6462
|
+
if x != unit['anchor'] and inverse[x] in base_refs:
|
|
6463
|
+
anchor = inverse[x]
|
|
6457
6464
|
if anchor not in base_refs:
|
|
6458
6465
|
self._log_event(
|
|
6459
6466
|
'enrich:no-unit-here', 'enrich',
|
|
@@ -8079,21 +8086,21 @@ cdef class MoleculeContainer:
|
|
|
8079
8086
|
"""
|
|
8080
8087
|
return _resonance_fn()(self)
|
|
8081
8088
|
|
|
8082
|
-
def layout2d(self, *, engine=None, force=False,
|
|
8089
|
+
def layout2d(self, *, engine=None, force=False, chain=None):
|
|
8083
8090
|
"""Compute a 2D layout and RETURN it as `{n: (x, y)}`, storing nothing.
|
|
8084
8091
|
|
|
8085
8092
|
THE FORM A RENDERER WANTS: drawing must not change what it draws, so a layout computed for a
|
|
8086
8093
|
picture is handed back rather than stored. `clean2d()` is this plus the decision to keep it.
|
|
8087
8094
|
|
|
8088
8095
|
`force=False` on a molecule that already `has_layout` hands back the STORED plane and computes
|
|
8089
|
-
nothing; `force=True` always recomputes. `engine` overrides `chython.clean2d_engine` and `
|
|
8090
|
-
overrides `chython.
|
|
8096
|
+
nothing; `force=True` always recomputes. `engine` overrides `chython.clean2d_engine` and `chain`
|
|
8097
|
+
overrides `chython.chain_layout` for this one call; only `engine='chython'` reads `chain`.
|
|
8091
8098
|
|
|
8092
8099
|
Registered by `chython.depict`, not implemented here -- see `_depict_fn`.
|
|
8093
8100
|
"""
|
|
8094
|
-
return _depict_fn(_layout2d_impl, 'layout2d')(self, engine=engine, force=force,
|
|
8101
|
+
return _depict_fn(_layout2d_impl, 'layout2d')(self, engine=engine, force=force, chain=chain)
|
|
8095
8102
|
|
|
8096
|
-
def clean2d(self, *, engine=None, force=False,
|
|
8103
|
+
def clean2d(self, *, engine=None, force=False, chain=None):
|
|
8097
8104
|
"""Compute a 2D layout and STORE it on this molecule.
|
|
8098
8105
|
|
|
8099
8106
|
NOT ALWAYS A RECOMPUTATION: a molecule that already carries a non-degenerate plane
|
|
@@ -8102,7 +8109,7 @@ cdef class MoleculeContainer:
|
|
|
8102
8109
|
|
|
8103
8110
|
Registered by `chython.depict`, not implemented here -- see `_depict_fn`.
|
|
8104
8111
|
"""
|
|
8105
|
-
return _depict_fn(_clean2d_impl, 'clean2d')(self, engine=engine, force=force,
|
|
8112
|
+
return _depict_fn(_clean2d_impl, 'clean2d')(self, engine=engine, force=force, chain=chain)
|
|
8106
8113
|
|
|
8107
8114
|
def rescale2d(self):
|
|
8108
8115
|
"""Rescale the STORED coordinates to average bond length 0.825. Did it rescale?
|
|
@@ -1215,7 +1215,7 @@ cdef tuple smk_one(ReactionTemplate t, MoleculeContainer work, set work_bonds, d
|
|
|
1215
1215
|
|
|
1216
1216
|
|
|
1217
1217
|
def smk_apply(ReactionTemplate t, tuple molecules, bint automorphism_filter, object log, bint report,
|
|
1218
|
-
bint dedupe):
|
|
1218
|
+
bint dedupe, object accept=None):
|
|
1219
1219
|
"""Validate eagerly, then hand back the generator.
|
|
1220
1220
|
|
|
1221
1221
|
The split is the point: a bad argument raises from the CALL, not from the first `next()`, so a
|
|
@@ -1231,11 +1231,11 @@ def smk_apply(ReactionTemplate t, tuple molecules, bint automorphism_filter, obj
|
|
|
1231
1231
|
raise TypeError('a template applies to molecules; this one was handed a %s' % type(m).__name__)
|
|
1232
1232
|
if not molecules:
|
|
1233
1233
|
raise ValueError('a template needs at least one molecule to apply to')
|
|
1234
|
-
return smk_enumerate(t, list(molecules), automorphism_filter, log, report, dedupe)
|
|
1234
|
+
return smk_enumerate(t, list(molecules), automorphism_filter, log, report, dedupe, accept)
|
|
1235
1235
|
|
|
1236
1236
|
|
|
1237
1237
|
def smk_enumerate(ReactionTemplate t, list inputs, bint automorphism_filter, object log, bint report,
|
|
1238
|
-
bint dedupe):
|
|
1238
|
+
bint dedupe, object accept=None):
|
|
1239
1239
|
"""Every distinct outcome of one template over one set of inputs.
|
|
1240
1240
|
|
|
1241
1241
|
The inputs are unioned into one working container, which is why an intramolecular template needs
|
|
@@ -1291,6 +1291,8 @@ def smk_enumerate(ReactionTemplate t, list inputs, bint automorphism_filter, obj
|
|
|
1291
1291
|
else:
|
|
1292
1292
|
candidates = t.reactants.get_mapping(work, automorphism_filter)
|
|
1293
1293
|
for mapping in candidates:
|
|
1294
|
+
if accept is not None and not accept(mapping):
|
|
1295
|
+
continue # refused before its outcome is built
|
|
1294
1296
|
# THE OUTCOME CARRIES WHAT ITS OWN PATCH REPORTED, on `rxn.log` under stage `react`, whether or
|
|
1295
1297
|
# not the caller passed a `log=`. A candidate that produced nothing has no container to write
|
|
1296
1298
|
# to, so its line is only on the caller's list -- and a duplicate outcome is not yielded, so
|
|
@@ -1129,7 +1129,7 @@ cdef class ReactionTemplate:
|
|
|
1129
1129
|
return 'read_smirks(%r)' % self.smirks
|
|
1130
1130
|
|
|
1131
1131
|
def __call__(self, *molecules, bint automorphism_filter=True, log=None, bint report=False,
|
|
1132
|
-
bint dedupe=True):
|
|
1132
|
+
bint dedupe=True, accept=None):
|
|
1133
1133
|
"""Apply this template to one molecule or to several, yielding one `ReactionContainer` per
|
|
1134
1134
|
distinct outcome.
|
|
1135
1135
|
|
|
@@ -1172,9 +1172,15 @@ cdef class ReactionTemplate:
|
|
|
1172
1172
|
outcomes by atom id needs every one, since the default keeps only the first of each structure.
|
|
1173
1173
|
`automorphism_filter` is a different collapse -- over the template's own symmetry, not the
|
|
1174
1174
|
outcome's.
|
|
1175
|
+
|
|
1176
|
+
`accept`, a callable taking an embedding `{reactant query atom: atom id}`, is asked before the
|
|
1177
|
+
embedding's outcome is built, and a falsy answer skips it. The ids are the working container's:
|
|
1178
|
+
the first input's own, the later inputs' as `union` renumbers them. Building an outcome copies
|
|
1179
|
+
and reseals the whole input, so a caller that can tell from the embedding alone that the outcome
|
|
1180
|
+
is not the one it wants saves that.
|
|
1175
1181
|
"""
|
|
1176
1182
|
return smk_apply(self, molecules, automorphism_filter,
|
|
1177
|
-
log if log is not None else [], report, dedupe)
|
|
1183
|
+
log if log is not None else [], report, dedupe, accept)
|
|
1178
1184
|
|
|
1179
1185
|
|
|
1180
1186
|
def read_smirks(text, log=None, *, rule_id=None):
|
|
@@ -6115,6 +6115,7 @@ cdef Structure structure_live_groups_view(Structure structure, list dead=None, b
|
|
|
6115
6115
|
cdef uint32_t i
|
|
6116
6116
|
structure = _bridgeheads_filled(drawn, cache, inert) # the implied signs, before any phase is read
|
|
6117
6117
|
structure = _ring_sets_cleared(structure, cache) # a ring set stating nothing is no choice either
|
|
6118
|
+
structure = _pair_signs_moved(structure) # an equivalent pair's sign: on the centre between
|
|
6118
6119
|
view = structure_stereogenic_view(structure, cache)
|
|
6119
6120
|
respelled = _restating_as_abs(structure, view, cache)
|
|
6120
6121
|
if respelled is not structure:
|
|
@@ -6270,6 +6271,149 @@ cdef Structure structure_stored_groups_view(Structure structure, dict cache=None
|
|
|
6270
6271
|
return view
|
|
6271
6272
|
|
|
6272
6273
|
|
|
6274
|
+
cdef frozenset _signing_meaning(Structure s, tuple atoms, uint8_t b, list pairs, dict cache):
|
|
6275
|
+
"""What `s` states about `atoms`, every other parity as drawn: a frozenset of worlds, a world being one choice
|
|
6276
|
+
of the unsigned `atoms` (and of the OR phase when `b` is OR) as the frozenset of species over the AND phases
|
|
6277
|
+
of the signed ones, which are all in group `b`.
|
|
6278
|
+
|
|
6279
|
+
A species is the identity with every one of `atoms` signed and read ABS, so two spellings signing different
|
|
6280
|
+
atoms compare by the molecules they name. A signing no bicycle realises (`_bridgehead_signs`) is no species.
|
|
6281
|
+
Raises AutomorphismBudgetExceeded from an identity.
|
|
6282
|
+
"""
|
|
6283
|
+
cdef uint32_t n = len(atoms), j, mask
|
|
6284
|
+
cdef uint8_t *par = structure_parities(s)
|
|
6285
|
+
cdef uint8_t *vp
|
|
6286
|
+
cdef uint8_t *vs
|
|
6287
|
+
cdef bint is_or = sg_kind(b) != SG_KIND_AND
|
|
6288
|
+
cdef dict worlds = {}
|
|
6289
|
+
cdef list bad = []
|
|
6290
|
+
cdef tuple drawn = tuple(par[<uint32_t> a] for a in atoms)
|
|
6291
|
+
cdef object world, phase
|
|
6292
|
+
cdef Structure v
|
|
6293
|
+
for mask in range(1u << n):
|
|
6294
|
+
phase = None
|
|
6295
|
+
world = []
|
|
6296
|
+
for j in range(n):
|
|
6297
|
+
bit = (mask >> j) & 1
|
|
6298
|
+
if drawn[j]:
|
|
6299
|
+
# signed: one AND or OR phase for all of them, read off the first signed member
|
|
6300
|
+
if phase is None:
|
|
6301
|
+
phase = bit
|
|
6302
|
+
elif phase != bit:
|
|
6303
|
+
break
|
|
6304
|
+
else:
|
|
6305
|
+
world.append(bit)
|
|
6306
|
+
else:
|
|
6307
|
+
v = structure_clone(s)
|
|
6308
|
+
vp = structure_parities(v)
|
|
6309
|
+
vs = structure_stereo_groups(v)
|
|
6310
|
+
for j in range(n):
|
|
6311
|
+
vp[<uint32_t> atoms[j]] = (<uint8_t> (3 - drawn[j]) if (mask >> j) & 1 else drawn[j]) if drawn[j] \
|
|
6312
|
+
else <uint8_t> (1 + ((mask >> j) & 1))
|
|
6313
|
+
vs[<uint32_t> atoms[j]] = sg_pack(SG_KIND_ABS, 0)
|
|
6314
|
+
structure_invalidate_stereo_units(v)
|
|
6315
|
+
refresh_parity_features(v)
|
|
6316
|
+
if pairs:
|
|
6317
|
+
_bridgehead_signs(v, pairs, {}, {}, bad)
|
|
6318
|
+
if bad:
|
|
6319
|
+
bad.clear()
|
|
6320
|
+
continue
|
|
6321
|
+
if is_or:
|
|
6322
|
+
world.append(phase)
|
|
6323
|
+
worlds.setdefault(tuple(world), set()).add(mol_identity_bytes(structure_stereogenic_view(v, cache)))
|
|
6324
|
+
return frozenset(frozenset(w) for w in worlds.values())
|
|
6325
|
+
|
|
6326
|
+
|
|
6327
|
+
cdef Structure _pair_signs_moved(Structure structure):
|
|
6328
|
+
"""`structure` with each AND or OR group of exactly two constitutionally equivalent signed members respelled as
|
|
6329
|
+
one sign, in that group, on an unsigned and ungrouped stereocentre the automorphisms fix, the pair left open --
|
|
6330
|
+
where that states the same molecules (`_signing_meaning`); `structure` itself when none does, else a clone.
|
|
6331
|
+
|
|
6332
|
+
On a meso core the pair and the centre between them name one relative configuration: `|&1:a,b|` on the
|
|
6333
|
+
bridgeheads with C3 open and `|&1:x|` on C3 with the bridgeheads open both state the C3 epimer mixture --
|
|
6334
|
+
exo and endo 6-amino-3-azabicyclo[3.1.0]hexane, tropine and pseudotropine -- and both are written on C3.
|
|
6335
|
+
Where the pair's relative configuration is free, as the trans fusion of bicyclo[4.1.0]heptane, the pair
|
|
6336
|
+
states it too, the meanings differ, and nothing moves.
|
|
6337
|
+
"""
|
|
6338
|
+
cdef uint32_t n = structure.header.atom_count, i, x, a1, a2, flags = 0
|
|
6339
|
+
cdef uint8_t *sg
|
|
6340
|
+
cdef uint8_t *par
|
|
6341
|
+
cdef uint8_t *cp
|
|
6342
|
+
cdef uint8_t *cs
|
|
6343
|
+
cdef uint32_t *comp
|
|
6344
|
+
cdef uint32_t *orbits = NULL
|
|
6345
|
+
cdef dict members = {}, cache = {}
|
|
6346
|
+
cdef list pairs, todo
|
|
6347
|
+
cdef dict size
|
|
6348
|
+
cdef object b, v, signs, want
|
|
6349
|
+
cdef Structure out = structure, bare, c
|
|
6350
|
+
if n == 0 or n > MEANING_ATOM_LIMIT or not structure_has(structure, SEG_STEREO_GROUPS) \
|
|
6351
|
+
or not _has_parity(structure):
|
|
6352
|
+
return structure
|
|
6353
|
+
sg = structure_stereo_groups(structure)
|
|
6354
|
+
par = structure_parities(structure)
|
|
6355
|
+
for i in range(n):
|
|
6356
|
+
if sg[i] and par[i] and sg_kind(sg[i]) != SG_KIND_ABS:
|
|
6357
|
+
members.setdefault(sg[i], []).append(i)
|
|
6358
|
+
todo = [(b, v[0], v[1]) for b, v in members.items() if len(v) == 2]
|
|
6359
|
+
if not todo:
|
|
6360
|
+
return structure
|
|
6361
|
+
bare = structure_clone(structure)
|
|
6362
|
+
memset(structure_parities(bare), 0, <size_t> n)
|
|
6363
|
+
structure_invalidate_stereo_units(bare)
|
|
6364
|
+
refresh_parity_features(bare)
|
|
6365
|
+
orbits = <uint32_t *> PyMem_Malloc(<size_t> n * sizeof(uint32_t))
|
|
6366
|
+
if orbits is NULL:
|
|
6367
|
+
raise MemoryError()
|
|
6368
|
+
try:
|
|
6369
|
+
mol_automorphisms(bare, NULL, orbits, &flags)
|
|
6370
|
+
if flags & (CANON_ASYMMETRIC | CANON_BUDGET_EXCEEDED):
|
|
6371
|
+
return structure
|
|
6372
|
+
size = {}
|
|
6373
|
+
for i in range(n):
|
|
6374
|
+
size[orbits[i]] = size.get(orbits[i], 0) + 1
|
|
6375
|
+
ensure_stereo_units(structure)
|
|
6376
|
+
comp = structure_component_labels(structure)
|
|
6377
|
+
sg = structure_stereo_groups(structure)
|
|
6378
|
+
par = structure_parities(structure)
|
|
6379
|
+
pairs = _coupled_bridgeheads(structure, cache)
|
|
6380
|
+
for b, a1, a2 in todo:
|
|
6381
|
+
if orbits[a1] != orbits[a2]:
|
|
6382
|
+
continue
|
|
6383
|
+
for x in range(n):
|
|
6384
|
+
if (size[orbits[x]] != 1 or par[x] or sg[x] or comp[x] != comp[a1]
|
|
6385
|
+
or stereo_unit_of(structure, x) is NULL):
|
|
6386
|
+
continue
|
|
6387
|
+
try:
|
|
6388
|
+
# a centre at all: kept by the view with the pair signed
|
|
6389
|
+
c = structure_clone(out)
|
|
6390
|
+
structure_parities(c)[x] = 1
|
|
6391
|
+
structure_invalidate_stereo_units(c)
|
|
6392
|
+
refresh_parity_features(c)
|
|
6393
|
+
if not structure_parity_at(structure_stereogenic_view(c, cache), x):
|
|
6394
|
+
continue
|
|
6395
|
+
want = _signing_meaning(out, (a1, a2, x), <uint8_t> b, pairs, cache)
|
|
6396
|
+
for signs in (1, 2):
|
|
6397
|
+
c = structure_clone(out)
|
|
6398
|
+
cp = structure_parities(c)
|
|
6399
|
+
cs = structure_stereo_groups(c)
|
|
6400
|
+
cp[a1] = cp[a2] = cs[a1] = cs[a2] = 0
|
|
6401
|
+
cp[x] = <uint8_t> signs
|
|
6402
|
+
cs[x] = <uint8_t> b
|
|
6403
|
+
structure_invalidate_stereo_units(c)
|
|
6404
|
+
refresh_parity_features(c)
|
|
6405
|
+
if _signing_meaning(c, (a1, a2, x), <uint8_t> b, pairs, cache) == want:
|
|
6406
|
+
out = c
|
|
6407
|
+
break
|
|
6408
|
+
except AutomorphismBudgetExceeded:
|
|
6409
|
+
continue
|
|
6410
|
+
if out is not structure and not structure_parity_at(out, a1):
|
|
6411
|
+
break
|
|
6412
|
+
return out
|
|
6413
|
+
finally:
|
|
6414
|
+
PyMem_Free(orbits)
|
|
6415
|
+
|
|
6416
|
+
|
|
6273
6417
|
cdef Structure _restating_as_abs(Structure structure, Structure view, dict cache):
|
|
6274
6418
|
"""`structure` with each AND or OR group whose inversion restates the molecule read as ABS on its live
|
|
6275
6419
|
members; `structure` itself when there is none, else a clone.
|
|
@@ -29,7 +29,7 @@ chain layout reads.
|
|
|
29
29
|
| `head_to_tail` | the chain closes on itself |
|
|
30
30
|
| `backbone` | the main chain's atoms, consecutive ones bonded or a bead's entry and exit |
|
|
31
31
|
| `beads` | indices `k` of the backbone steps `backbone[k]`-`backbone[k + 1]` that cross a bead, entry to exit |
|
|
32
|
-
| `kind` | `'peptide'` or `'
|
|
32
|
+
| `kind` | `'peptide'`, `'cycle'` or `'nucleic'` |
|
|
33
33
|
"""
|
|
34
34
|
from dataclasses import dataclass
|
|
35
35
|
|
|
@@ -79,9 +79,10 @@ class Chain:
|
|
|
79
79
|
|
|
80
80
|
|
|
81
81
|
def perceive(mol):
|
|
82
|
-
"""The chain or circle `mol` is, or None: a peptide first, then `cycles`."""
|
|
83
|
-
from .monomers import monomers #
|
|
84
|
-
|
|
82
|
+
"""The chain or circle `mol` is, or None: a peptide first, then a nucleic-acid strand, then `cycles`."""
|
|
83
|
+
from .monomers import monomers # both build Chains: imported at call time
|
|
84
|
+
from .nucleotides import nucleotides
|
|
85
|
+
return monomers(mol) or nucleotides(mol) or cycles(mol)
|
|
85
86
|
|
|
86
87
|
|
|
87
88
|
def cycles(mol):
|
|
@@ -98,8 +99,10 @@ heteroatom, repeated three or more times |
|
|
|
98
99
|
| opening | a C(=O)-O or C(=O)-N bond of the cycle, else one between a bead and another unit, else any; ranks |
|
|
99
100
|
| units | an atom on the cycle; a crossed hexagon entered meta, its three-atom arc on the backbone; any other \
|
|
100
101
|
crossed bead, with its entry and exit |
|
|
101
|
-
| groups | every other atom, claimed in rank order from the units without crossing the backbone
|
|
102
|
-
|
|
102
|
+
| groups | every other atom, claimed in rank order from the units without crossing the backbone; a small-ring \
|
|
103
|
+
system's atoms off the backbone one group, a cage fused on a cycle edge never split |
|
|
104
|
+
| links | a bond between two groups off the backbone, moved to start on it, none closing a small-ring system on \
|
|
105
|
+
its backbone atoms; the closure last |
|
|
103
106
|
|
|
104
107
|
A mixture is no cycle: each component is asked on its own.
|
|
105
108
|
"""
|
|
@@ -168,11 +171,22 @@ crossed bead, with its entry and exit |
|
|
|
168
171
|
backbone.append(x)
|
|
169
172
|
residues.append(Residue(frozenset((x,)), 'unit', x, x, (x,)))
|
|
170
173
|
members = _claim(mol, residues, set(backbone), rank)
|
|
174
|
+
on = set(backbone)
|
|
175
|
+
for atoms, _ in systems: # a system fused on a backbone edge: one group, never split
|
|
176
|
+
off = atoms - on
|
|
177
|
+
hosts = sorted({i for i, m in enumerate(members) if m & off}, key=lambda i: min(rank[x] for x in members[i]))
|
|
178
|
+
for i in hosts[1:]:
|
|
179
|
+
members[hosts[0]] |= members[i] & off
|
|
180
|
+
members[i] -= off
|
|
181
|
+
if hosts: # its backbone atoms too: the edge it closes on
|
|
182
|
+
members[hosts[0]] |= atoms & on
|
|
171
183
|
group = {x: i for i, m in enumerate(members) for x in m}
|
|
184
|
+
closing = {frozenset((x, y)) for atoms, _ in systems for x in atoms - on for y in mol.neighbors_of(x)
|
|
185
|
+
if y in atoms and y in on} # a fused system's bonds to its own backbone atoms
|
|
172
186
|
steps = {frozenset(p) for p in zip(backbone, backbone[1:])}
|
|
173
187
|
links = sorted({tuple(sorted((x, y), key=rank.__getitem__)) for x in mol for y in mol.neighbors_of(x)
|
|
174
|
-
if group[x] != group[y] and frozenset((x, y)) not in steps and
|
|
175
|
-
frozenset((x, y)) != frozenset((backbone[-1], backbone[0]))},
|
|
188
|
+
if group[x] != group[y] and frozenset((x, y)) not in steps and frozenset((x, y)) not in closing
|
|
189
|
+
and frozenset((x, y)) != frozenset((backbone[-1], backbone[0]))},
|
|
176
190
|
key=lambda t: (rank[t[0]], rank[t[1]]))
|
|
177
191
|
links = [_to_backbone(mol, members, set(backbone), link, rank) for link in links]
|
|
178
192
|
links.append((backbone[-1], backbone[0]))
|
|
@@ -30,6 +30,8 @@ a link beside an acyclic C=C moves a bond off it |
|
|
|
30
30
|
| chain link | a cut from residue A's exit to residue B's entry, each used once |
|
|
31
31
|
| main chain | the chain with most non-`other` residues; fewer than `MIN_RESIDUES` is not a peptide |
|
|
32
32
|
| branch | an attached chain of >= `MIN_BRANCH` residues; a shorter one merges into its host residue |
|
|
33
|
+
| side-chain ring | the last exit linked into an earlier residue's group: that path opens the chain, closed head to \
|
|
34
|
+
tail, the residues before it hung from its group |
|
|
33
35
|
| order | every choice and every walk goes by `canonical_order()` rank, so the result ignores atom numbering |
|
|
34
36
|
"""
|
|
35
37
|
from collections import deque
|
|
@@ -121,6 +123,11 @@ def monomers(mol, library=None) -> Peptide | None:
|
|
|
121
123
|
if (c, n) not in used and residue_of[c] in placed and residue_of[n] in placed:
|
|
122
124
|
crosslinks.append((c, n))
|
|
123
125
|
|
|
126
|
+
if not cyclic:
|
|
127
|
+
rerouted = _through_side_chain(mol, residues, members, main, crosslinks, rank)
|
|
128
|
+
if rerouted is not None:
|
|
129
|
+
residues, members, main, crosslinks = rerouted
|
|
130
|
+
cyclic = True
|
|
124
131
|
backbone = _oriented(mol, residues, members, main, None, rank)
|
|
125
132
|
if len(main) > 1:
|
|
126
133
|
p0, p1 = residues[main[0]].path, residues[main[1]].path
|
|
@@ -135,6 +142,45 @@ def monomers(mol, library=None) -> Peptide | None:
|
|
|
135
142
|
tuple(crosslinks), cyclic, tuple(backbone))
|
|
136
143
|
|
|
137
144
|
|
|
145
|
+
def _through_side_chain(mol, residues, members, main, crosslinks, rank):
|
|
146
|
+
"""`(residues, members, main, crosslinks)` with the main chain run round the ring a cross-link closes through a
|
|
147
|
+
side chain, or None. The last residue's exit is linked to an atom of an earlier residue's group by a path off
|
|
148
|
+
its small rings to that residue's entry: the path becomes a unit opening the chain, closed head to tail on the
|
|
149
|
+
link, and the fewer than `MIN_BRANCH` residues before that residue hang from its group."""
|
|
150
|
+
last = residues[main[-1]].exit
|
|
151
|
+
small = {x for r in mol.sssr if len(r) <= 7 for x in r}
|
|
152
|
+
for k, i in enumerate(main[:MIN_BRANCH]):
|
|
153
|
+
entry = residues[i].entry
|
|
154
|
+
if entry is None or k == len(main) - 1:
|
|
155
|
+
continue
|
|
156
|
+
for link in crosslinks:
|
|
157
|
+
if last not in link:
|
|
158
|
+
continue
|
|
159
|
+
n = link[0] if link[1] == last else link[1]
|
|
160
|
+
if n not in members[i] or n in residues[i].path:
|
|
161
|
+
continue
|
|
162
|
+
path = _bfs_path(mol, n, entry, members[i] - small - set(residues[i].path), rank)
|
|
163
|
+
if path is None or len(path) < 3:
|
|
164
|
+
continue
|
|
165
|
+
core = path[:-1] # entry excluded: it opens residue `i`
|
|
166
|
+
group, stack = set(), [n]
|
|
167
|
+
while stack:
|
|
168
|
+
x = stack.pop()
|
|
169
|
+
if x in group or x == entry or x in residues[i].path or x not in members[i]:
|
|
170
|
+
continue
|
|
171
|
+
group.add(x)
|
|
172
|
+
stack.extend(mol.neighbors_of(x))
|
|
173
|
+
unit = Residue(frozenset(group), 'other', n, core[-1], tuple(core))
|
|
174
|
+
residues = list(residues) + [unit]
|
|
175
|
+
members = [set(m) for m in members] + [group]
|
|
176
|
+
members[i] -= group
|
|
177
|
+
for j in main[:k]: # the cap and any short tail: hung from residue `i`
|
|
178
|
+
members[i] |= members[j]
|
|
179
|
+
links = [x for x in crosslinks if x is not link]
|
|
180
|
+
return residues, members, [len(residues) - 1] + list(main[k:]), links
|
|
181
|
+
return None
|
|
182
|
+
|
|
183
|
+
|
|
138
184
|
def _heavy(mol, n):
|
|
139
185
|
return [x for x in mol.neighbors_of(n) if mol.element_of(x) != 1]
|
|
140
186
|
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
# -*- coding: utf-8 -*-
|
|
2
|
+
#
|
|
3
|
+
# Copyright 2026 Ramil Nugmanov <nougmanoff@protonmail.com>
|
|
4
|
+
# This file is part of chython.
|
|
5
|
+
#
|
|
6
|
+
# chython is free software; you can redistribute it and/or modify
|
|
7
|
+
# it under the terms of the GNU Lesser General Public License as published by
|
|
8
|
+
# the Free Software Foundation; either version 3 of the License, or
|
|
9
|
+
# (at your option) any later version.
|
|
10
|
+
#
|
|
11
|
+
# This program is distributed in the hope that it will be useful,
|
|
12
|
+
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
13
|
+
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
14
|
+
# GNU Lesser General Public License for more details.
|
|
15
|
+
#
|
|
16
|
+
# You should have received a copy of the GNU Lesser General Public License
|
|
17
|
+
# along with this program; if not, see <https://www.gnu.org/licenses/>.
|
|
18
|
+
#
|
|
19
|
+
"""Nucleic-acid segmentation: nucleotides split at their phosphorus links, the main strand in 5' to 3' order.
|
|
20
|
+
|
|
21
|
+
Read-only topology beside `monomers.py`; `chains.perceive` asks it after peptides and before macrocycles.
|
|
22
|
+
|
|
23
|
+
| Step | Rule |
|
|
24
|
+
| --- | --- |
|
|
25
|
+
| sugar | a five-membered ring of one oxygen, O4': C4' beside it bears an exocyclic C5' bearing an O5', the ring \
|
|
26
|
+
carbon C3' beside C4' bears an exocyclic O3'; a 2' substituent, a base or none at all are the unit's groups; a C5' \
|
|
27
|
+
with no O5', a 5'-vinylphosphonate's, opens the strand only |
|
|
28
|
+
| link | O3' of one unit and O5' of another bonded to one phosphorus: phosphodiester, phosphorothioate, any P(V) |
|
|
29
|
+
| unit path | P, O5', C5', C4', C3', O3', the 5'-phosphorus first, a 5' cap's too; a unit with no 5' phosphorus \
|
|
30
|
+
starts at O5', or C5' |
|
|
31
|
+
| main strand | the longest run of links, 5' to 3'; fewer than `MIN_UNITS` is no strand |
|
|
32
|
+
| groups | every other atom, claimed in rank order from the units without crossing the backbone: bases, 2' groups, \
|
|
33
|
+
the phosphorus' oxygens and sulfur, the conjugates at either end |
|
|
34
|
+
"""
|
|
35
|
+
from .chains import Chain, Residue, _claim
|
|
36
|
+
|
|
37
|
+
|
|
38
|
+
__all__ = ['nucleotides', 'MIN_UNITS']
|
|
39
|
+
|
|
40
|
+
MIN_UNITS = 4
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
def nucleotides(mol):
|
|
44
|
+
"""`mol`'s main strand as a `Chain` of kind nucleic, or None when it has fewer than `MIN_UNITS` linked units."""
|
|
45
|
+
if len(mol.connected_components) != 1:
|
|
46
|
+
return None
|
|
47
|
+
rank = mol.canonical_order()
|
|
48
|
+
units = [u for r in mol.sssr if len(r) == 5 for u in _sugars(mol, r)]
|
|
49
|
+
if len(units) < MIN_UNITS:
|
|
50
|
+
return None
|
|
51
|
+
by_o5 = {u['o5']: u for u in units if u['o5'] is not None}
|
|
52
|
+
after, before = {}, {}
|
|
53
|
+
for u in units:
|
|
54
|
+
for p in mol.neighbors_of(u['o3']):
|
|
55
|
+
if mol.element_of(p) != 15:
|
|
56
|
+
continue
|
|
57
|
+
for o in mol.neighbors_of(p):
|
|
58
|
+
v = by_o5.get(o)
|
|
59
|
+
if v is not None and v is not u and id(v) not in before and id(u) not in after:
|
|
60
|
+
after[id(u)], before[id(v)] = (p, v), u
|
|
61
|
+
best = []
|
|
62
|
+
for u in sorted(units, key=lambda u: rank[u['c4']]):
|
|
63
|
+
if id(u) in before:
|
|
64
|
+
continue
|
|
65
|
+
run = [(None, u)]
|
|
66
|
+
while id(run[-1][1]) in after:
|
|
67
|
+
run.append(after[id(run[-1][1])])
|
|
68
|
+
if len(run) > len(best):
|
|
69
|
+
best = run
|
|
70
|
+
if len(best) < MIN_UNITS:
|
|
71
|
+
return None
|
|
72
|
+
residues, backbone = [], []
|
|
73
|
+
head = best[0][1]
|
|
74
|
+
if head['o5'] is not None: # a 5' cap on a phosphorus, an inverted abasic's: it opens
|
|
75
|
+
caps = [y for y in mol.neighbors_of(head['o5']) if mol.element_of(y) == 15]
|
|
76
|
+
if caps:
|
|
77
|
+
best[0] = (caps[0], head)
|
|
78
|
+
for p, u in best:
|
|
79
|
+
path = ([p] if p is not None else []) + ([u['o5']] if u['o5'] is not None else []) + \
|
|
80
|
+
[u['c5'], u['c4'], u['c3'], u['o3']]
|
|
81
|
+
backbone += path
|
|
82
|
+
residues.append(Residue(frozenset(path) | u['ring'], 'nucleotide', path[0], path[-1], tuple(path)))
|
|
83
|
+
members = _claim(mol, residues, set(backbone), rank)
|
|
84
|
+
for m, r in zip(members, residues):
|
|
85
|
+
m |= r.atoms
|
|
86
|
+
return Chain(tuple(residues), tuple(frozenset(m) for m in members), tuple(range(len(residues))), (), (), False,
|
|
87
|
+
tuple(backbone), (), 'nucleic')
|
|
88
|
+
|
|
89
|
+
|
|
90
|
+
def _sugars(mol, ring):
|
|
91
|
+
"""The furanose readings of `ring`: `{o4, c4, c5, o5, c3, o3, ring}` for each C4' beside its O4'."""
|
|
92
|
+
oxygens = [x for x in ring if mol.element_of(x) == 8]
|
|
93
|
+
if len(oxygens) != 1 or any(mol.element_of(x) != 6 for x in ring if x != oxygens[0]):
|
|
94
|
+
return []
|
|
95
|
+
o4, out = oxygens[0], []
|
|
96
|
+
for c4 in (y for y in mol.neighbors_of(o4) if y in ring):
|
|
97
|
+
c3 = next(y for y in mol.neighbors_of(c4) if y in ring and y != o4)
|
|
98
|
+
for c5 in mol.neighbors_of(c4):
|
|
99
|
+
if c5 in ring or mol.element_of(c5) != 6:
|
|
100
|
+
continue
|
|
101
|
+
o5 = [y for y in mol.neighbors_of(c5) if y != c4 and mol.element_of(y) == 8]
|
|
102
|
+
o3 = [y for y in mol.neighbors_of(c3) if y not in ring and mol.element_of(y) == 8]
|
|
103
|
+
if len(o5) <= 1 and len(o3) == 1: # no O5': a 5' head alone, a vinylphosphonate's
|
|
104
|
+
out.append({'o4': o4, 'c4': c4, 'c5': c5, 'o5': o5[0] if o5 else None, 'c3': c3, 'o3': o3[0],
|
|
105
|
+
'ring': frozenset(ring)})
|
|
106
|
+
return out
|