Skip to main content

breadth first fragmentation package

Project description

breadth-first-fragmentation

Usage

Installation

Install latest from the GitHub repository:

$ pip install git+https://github.com/panukorn17/breadth-first-fragmentation.git

or from conda

$ conda install -c panukorn17 breadth_first_fragmentation

or from pypi

$ pip install breadth_first_fragmentation

Documentation

Documentation can be found hosted on this GitHub repository’s pages. Additionally you can find package manager specific guidelines on conda and pypi respectively.

How to use

from breadth_first_fragmentation.fragmentation import break_into_fragments_defragmo
smi = 'CCCN(CCc1cccc(-c2ccccc2)c1)C(=O)C1OC(C(=O)O)=CC(N)C1NC(C)=O'
break_into_fragments_defragmo(smi, min_length=0, verbose=1)
Head fragment:  *CCC
Recurse tail:  N(*)(CCc1cccc(-c2ccccc2)c1)C(=O)C1OC(C(=O)O)=CC(N)C1NC(C)=O
Tail:  *CCc1cccc(-c2ccccc2)c1
Recurse Head:  N(*)(*)C(=O)C1OC(C(=O)O)=CC(N)C1NC(C)=O
Head fragment:  *N(*)*
Recurse tail:  C(*)(=O)C1OC(C(=O)O)=CC(N)C1NC(C)=O
Head fragment:  *C(*)=O
Recurse tail:  C1(*)OC(C(=O)O)=CC(N)C1NC(C)=O
Head fragment:  *NC1C(N)C=C(C(=O)O)OC1*
Recurse tail:  C(*)(C)=O
Final Fragment:  C(*)(C)=O

('CCCN(CCc1cccc(-c2ccccc2)c1)C(=O)C1OC(C(=O)O)=CC(N)C1NC(C)=O',
 '*CCC *CCc1cccc(-c2ccccc2)c1 *N(*)* *C(*)=O *NC1C(N)C=C(C(=O)O)OC1* C(*)(C)=O',
 6)

Visual representation of the breadth-first-fragmentation algorithm:
breadth-first-fragmentation

smi = 'CCCN(CCc1cccc(-c2ccccc2)c1)C(=O)C1OC(C(=O)O)=CC(N)C1NC(C)=O'
break_into_fragments_defragmo(smi, min_length=3, verbose=1)
Head fragment:  *CCC
Recurse tail:  N(*)(CCc1cccc(-c2ccccc2)c1)C(=O)C1OC(C(=O)O)=CC(N)C1NC(C)=O
Tail:  *CCc1cccc(-c2ccccc2)c1
Recurse Head:  N(*)(*)C(=O)C1OC(C(=O)O)=CC(N)C1NC(C)=O
Head fragment:  *C(=O)N(*)*
Recurse tail:  C1(*)OC(C(=O)O)=CC(N)C1NC(C)=O
Head fragment:  *NC1C(N)C=C(C(=O)O)OC1*
Recurse tail:  C(*)(C)=O
Final Fragment:  C(*)(C)=O

('CCCN(CCc1cccc(-c2ccccc2)c1)C(=O)C1OC(C(=O)O)=CC(N)C1NC(C)=O',
 '*CCC *CCc1cccc(-c2ccccc2)c1 *C(=O)N(*)* *NC1C(N)C=C(C(=O)O)OC1* C(*)(C)=O',
 5)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

breadth_first_fragmentation-0.0.1.tar.gz (11.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

breadth_first_fragmentation-0.0.1-py3-none-any.whl (10.8 kB view details)

Uploaded Python 3

File details

Details for the file breadth_first_fragmentation-0.0.1.tar.gz.

File metadata

File hashes

Hashes for breadth_first_fragmentation-0.0.1.tar.gz
Algorithm Hash digest
SHA256 815a37be4586523bebec573a4fab03bb9779ddc692ab42980472f2846c10d231
MD5 73cdf50977e317af7742a07d25e4a427
BLAKE2b-256 45c9e5b51b50e7d6afd437ddeb6c49a91a354978645ef94226f0f53d3aae4583

See more details on using hashes here.

File details

Details for the file breadth_first_fragmentation-0.0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for breadth_first_fragmentation-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 f698bb4eb523994801bd8ba1a2d4742387f80b274601e198c0968a21c55966b7
MD5 2207d623fc62d343ea510576d201d66f
BLAKE2b-256 0a73707e4cdfdeeb12b701dfaea6d8ae57ad59defe109bdb6ca89c47be8b34b5

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page